18a8edbf0e
* There is now a 'busses' folder, and the extant USB/SDHCI/Bluetooth/etc. docs now live in it, instead of various other places. * kernel/ports is now kernel/arch, like it is in src/system. SPARC documentation is now in there, too. * VM files (these are rather outdated) are now in kernel/vm. * SCSI ASC info removed, this is easily available online and it doesn't seem to be very relevant.
20 lines
998 B
Plaintext
20 lines
998 B
Plaintext
static void device_destroy(struct vm_store *store)
|
|
Frees the space associated with this store
|
|
|
|
static off_t device_commit(struct vm_store *store, off_t size)
|
|
Sets this store's commited size to size.
|
|
|
|
static int device_has_page(struct vm_store *store, off_t offset)
|
|
Returns 0
|
|
|
|
static ssize_t device_read(struct vm_store *store, off_t offset, iovecs *vecs)
|
|
Returns unimplemented.
|
|
|
|
static ssize_t device_write(struct vm_store *store, off_t offset, iovecs *vecs)
|
|
Returns 0
|
|
|
|
static int device_fault(struct vm_store *store, struct vm_address_space *aspace, off_t offset)
|
|
Should be called when a page is not mapped in. Locks the translation map, Finds the region in the cache that contains this page and maps it in. Unlocks the cache.
|
|
|
|
vm_store *vm_store_create_device(addr base_addr)
|
|
Allocates memory for the vm_store structure, plus the data_store_device structure. Sets cache to null, and data to the device_store_data. Sets the device_store_data's base address to the base address passed in. |