jos_h1 - int console_buffer[256 int nextin int nextout...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
#include "simulator.h" #include "dllist.h" #include <pthread.h> #include <synch.h> typedef struct { int regs[NumTotalRegs]; int size,number_written,number_read; char *read_buffer,*write_buffer; } PCB; typedef struct { Dllist readyq; /* Ready queue */ PCB *running; /* Pointer to the currently running process's PCB */ PCB *nulljob; /* Pointer to a 'null' job -- we'll set running to this when we run noop() */
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: int console_buffer[256]; int nextin; int nextout; sema_t writeok; sema_t consoleWait; sema_t nelem; sema_t writers; sema_t readers; } JOS_GLOBALS; BEGIN_INTERFACE_FUNCTIONS extern JOS_GLOBALS JG; extern jos_scheduler(); extern void do_write(PCB *pcb); extern void do_read(PCB *pcb); extern void do_console_read(); END_INTERFACE_FUNCTIONS...
View Full Document

{[ snackBarMessage ]}

Ask a homework question - tutors are online