Commit 2c8440

2026-09-02 15:01:34 Bob Green: -/-
programming/filesystem layer.md ..
@@ 6,37 6,37 @@
---
classDiagram
class vmp_t{
- block_device-t *dev_driver;
- vfs_fs_t *fs_driver;
- char name[16];
- uint8_t block_buff[BLOCK_DEVICE_BLOCK_SIZE];
- unsigned int mounted : 1;
- unsigned int read_only : 1;
- uint8_t subdev;
- union fs_data;
+ block_device-t *dev_driver
+ vfs_fs_t *fs_driver
+ char name[16]
+ uint8_t block_buff[BLOCK_DEVICE_BLOCK_SIZE]
+ unsigned int mounted : 1
+ unsigned int read_only : 1
+ uint8_t subdev
+ union fs_data
}
class block_device_t {
- bool_t active;
- char name[16];
- uint8_t num_sub_devices;
+ bool_t active
+ char name[16]
+ uint8_t num_sub_devices
- int (*init)(block_device_t *dev);
- int (*finish)(void);
+ int (*init)(block_device_t *dev)
+ int (*finish)(void)
- int (*read_block)(uint32_t block_num, uint8_t *buff, uint8_t subdev);
- int (*write_block)(uint32_t block_num, uint8_t *buff, uint8_t subdev);
+ int (*read_block)(uint32_t block_num, uint8_t *buff, uint8_t subdev)
+ int (*write_block)(uint32_t block_num, uint8_t *buff, uint8_t subdev)
- void *driver_data;
+ void *driver_data
}
class vfs_fs_t {
- uint8_t type;
- int (*handles_path)(const char *pathname);
- char *name;
- block_device_t *dev;
- vfs_t api;
+ uint8_t type
+ int (*handles_path)(const char *pathname)
+ char *name
+ block_device_t *dev
+ vfs_t api
}
class fs_data <<union>> {
- ext2_fs_t e2fs;
+ ext2_fs_t e2fs
}
block_device_t <|-- vmp_t
0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9