10 #include "copyright.h" void WriteSector(int sectorNumber, char *data)
SynchDisk::WriteSector Write the contents of a buffer into a disk sector. Return only after the data ...
Definition: synchdisk.cc:94
void ReadSector(int sectorNumber, char *data)
SynchDisk::ReadSector Read the contents of a disk sector into a buffer. Return only after the data ha...
Definition: synchdisk.cc:76
The following class defines a physical disk I/O device. The disk has a single surface, split up into "tracks", and each track split up into "sectors" (the same number of sectors on each track, and each sector has the same number of bytes of storage).
Definition: disk.h:57
void RequestDone()
SynchDisk::RequestDone Disk interrupt handler. Wake up any thread waiting for the disk request to fin...
Definition: synchdisk.cc:109
The following class defines a "synchronous" disk abstraction. As with other I/O devices, the raw physical disk is an asynchronous device – requests to read or write portions of the disk return immediately, and an interrupt occurs later to signal that the operation completed. (Also, the physical characteristics of the disk device assume that only one operation can be requested at a time).
Definition: synchdisk.h:28
The following class defines a "semaphore" whose value is a non-negative integer. The semaphore has on...
Definition: synch.h:42
SynchDisk(const char *name)
SynchDisk::SynchDisk Initialize the synchronous interface to the physical disk, in turn initializing ...
Definition: synchdisk.cc:46
Data structures for synchronizing threads.
~SynchDisk()
SynchDisk::~SynchDisk De-allocate data structures needed for the synchronous disk abstraction...
Definition: synchdisk.cc:59
Data structures to emulate a physical disk