18#ifndef ZEPHYR_INCLUDE_DRIVERS_DISK_H_
19#define ZEPHYR_INCLUDE_DRIVERS_DISK_H_
43#define DISK_IOCTL_GET_SECTOR_COUNT 1
45#define DISK_IOCTL_GET_SECTOR_SIZE 2
47#define DISK_IOCTL_RESERVED 3
49#define DISK_IOCTL_GET_ERASE_BLOCK_SZ 4
51#define DISK_IOCTL_CTRL_SYNC 5
58#define DISK_STATUS_OK 0x00
60#define DISK_STATUS_UNINIT 0x01
62#define DISK_STATUS_NOMEDIA 0x02
64#define DISK_STATUS_WR_PROTECT 0x04
int disk_access_register(struct disk_info *disk)
Register disk.
int disk_access_unregister(struct disk_info *disk)
Unregister disk.
struct _dnode sys_dnode_t
Doubly-linked list node structure.
Definition: dlist.h:54
static void cmd(uint32_t command)
Execute a display list command by co-processor engine.
Definition: ft8xx_reference_api.h:153
__UINT32_TYPE__ uint32_t
Definition: stdint.h:90
__UINT8_TYPE__ uint8_t
Definition: stdint.h:88
Runtime device structure (in ROM) per driver instance.
Definition: device.h:399
Disk info.
Definition: disk.h:71
const struct disk_operations * ops
Disk operations.
Definition: disk.h:77
sys_dnode_t node
Internally used list node.
Definition: disk.h:73
const char * name
Disk name.
Definition: disk.h:75
const struct device * dev
Device associated to this disk.
Definition: disk.h:79
Disk operations.
Definition: disk.h:85
int(* read)(struct disk_info *disk, uint8_t *data_buf, uint32_t start_sector, uint32_t num_sector)
Definition: disk.h:88
int(* ioctl)(struct disk_info *disk, uint8_t cmd, void *buff)
Definition: disk.h:92
int(* status)(struct disk_info *disk)
Definition: disk.h:87
int(* write)(struct disk_info *disk, const uint8_t *data_buf, uint32_t start_sector, uint32_t num_sector)
Definition: disk.h:90
int(* init)(struct disk_info *disk)
Definition: disk.h:86