kern
view src/bdev.h @ 92:b4264d173aae
fixed the readme file
author | John Tsiombikas <nuclear@member.fsf.org> |
---|---|
date | Thu, 17 Apr 2014 12:30:02 +0300 |
parents | 7ff2b4971216 |
children | 083849df660b |
line source
1 #ifndef BDEV_H_
2 #define BDEV_H_
4 #include "fs.h" /* for dev_t */
6 /* TODO buffer cache */
8 struct block_device {
9 int ata_dev;
10 uint32_t offset, size;
11 };
13 struct block_device *blk_open(dev_t dev);
14 void blk_close(struct block_device *bdev);
16 int blk_read(struct block_device *bdev, uint32_t blk, void *buf);
17 int blk_write(struct block_device *bdev, uint32_t blk, void *buf);
19 dev_t bdev_by_name(const char *name);
21 #endif /* BDEV_H_ */