|
StuBS
|
Simpler ATA Treiber, der 28bit Adressierung und polling über IOPorts verwendet. More...
#include <fs/harddisk.h>
Public Member Functions | |
| Harddisk (Drive drive=primary_bus_master) | |
| Block | fix (uint64_t block_number) |
| void | unfix (Block *block) |
| int | sync () |
| int | sync (Block *block) |
Public Member Functions inherited from BlockDevice | |
| virtual Block | fix (uint64_t block_number)=0 |
| virtual void | unfix (Block *block)=0 |
| virtual int | sync (Block *block)=0 |
| virtual int | sync ()=0 |
| bool | set_blocksize (unsigned int blocksize) |
| template<typename T > | |
| T | divide_by_blocksize (T val) const |
| template<typename T > | |
| T | modulo_blocksize (T val) const |
Public Attributes | |
| bool | attached |
| uint32_t | max_lba |
Public Attributes inherited from BlockDevice | |
| unsigned int | blocksize |
| unsigned int | blocksize_bits |
Simpler ATA Treiber, der 28bit Adressierung und polling über IOPorts verwendet.
Hinweis für block_number und sector: Die block_number von fix() verwendet stets die Blockgröße, die über set_blocksize festgelegt wurde. Intern entspricht ein Sektor 512 byte, da die IOPorts diese Adressierung verwenden. block_number wird in read_sectors() oder write_sectors() per convert_lba() abhängig von this->blocksize umgewandelt.
|
virtual |
Implements BlockDevice.
|
virtual |
Implements BlockDevice.
|
virtual |
Implements BlockDevice.
|
virtual |
Implements BlockDevice.