19 #if !defined (_RTEMS_FLASHDISK_H_) 20 #define _RTEMS_FLASHDISK_H_ 23 #include <sys/ioctl.h> 131 #define RTEMS_FLASHDISK_DEVICE_BASE_NAME "/dev/fdd" 133 #define RTEMS_FDISK_IOCTL_ERASE_DISK _IO('B', 128) 134 #define RTEMS_FDISK_IOCTL_COMPACT _IO('B', 129) 135 #define RTEMS_FDISK_IOCTL_ERASE_USED _IO('B', 130) 136 #define RTEMS_FDISK_IOCTL_MONITORING _IO('B', 131) 137 #define RTEMS_FDISK_IOCTL_INFO_LEVEL _IO('B', 132) 138 #define RTEMS_FDISK_IOCTL_PRINT_STATUS _IO('B', 133) 147 uint32_t block_count;
148 uint32_t unavail_blocks;
149 uint32_t device_count;
150 uint32_t segment_count;
152 uint32_t blocks_used;
153 uint32_t segs_available;
155 uint32_t segs_failed;
158 uint32_t pages_active;
185 #define RTEMS_FDISK_KBYTES(_k) (UINT32_C(1024) * (_k)) 414 #define RTEMS_FDISK_BACKGROUND_ERASE (1 << 0) 419 #define RTEMS_FDISK_BACKGROUND_COMPACT (1 << 1) 426 #define RTEMS_FDISK_CHECK_PAGES (1 << 2) 432 #define RTEMS_FDISK_BLANK_CHECK_BEFORE_WRITE (1 << 3) 447 rtems_device_minor_number minor,
const rtems_fdisk_device_desc * devices
Definition: flashdisk.h:385
uint32_t segment_count
Definition: flashdisk.h:347
uint32_t info_level
Definition: flashdisk.h:404
uint32_t device_count
Definition: flashdisk.h:384
rtems_device_driver rtems_fdisk_initialize(rtems_device_major_number major, rtems_device_minor_number minor, void *arg)
int(* read)(const rtems_fdisk_segment_desc *sd, uint32_t device, uint32_t segment, uint32_t offset, void *buffer, uint32_t size)
Definition: flashdisk.h:220
RTEMS Flash Disk configuration table used to initialise the driver.
Definition: flashdisk.h:381
Definition: rtemscompat1.h:15
struct rtems_fdisk_monitor_data rtems_fdisk_monitor_data
Flash Disk Monitoring Data allows a user to obtain the current status of the disk.
int(* blank)(const rtems_fdisk_segment_desc *sd, uint32_t device, uint32_t segment, uint32_t offset, uint32_t size)
Definition: flashdisk.h:269
rtems_status_code
Classic API Status.
Definition: status.h:43
int(* write)(const rtems_fdisk_segment_desc *sd, uint32_t device, uint32_t segment, uint32_t offset, const void *buffer, uint32_t size)
Definition: flashdisk.h:245
uint16_t count
Definition: flashdisk.h:176
const rtems_flashdisk_config rtems_flashdisk_configuration[]
External reference to the configuration. Please supply. Support is present in confdefs....
struct rtems_fdisk_driver_handlers rtems_fdisk_driver_handlers
Flash Low Level driver handlers.
uint32_t compact_segs
Definition: flashdisk.h:395
uint32_t flags
Definition: flashdisk.h:386
uint32_t unavail_blocks
Definition: flashdisk.h:393
const rtems_fdisk_segment_desc * segments
Definition: flashdisk.h:348
uint32_t offset
Definition: flashdisk.h:178
uint32_t rtems_flashdisk_configuration_size
External reference to the number of configurations. Please supply. Support is present in confdefs....
Flash Segment Descriptor holds, number of continuous segments in the device of this type,...
Definition: flashdisk.h:174
Flash Disk Monitoring Data allows a user to obtain the current status of the disk.
Definition: flashdisk.h:144
int(* erase_device)(const struct rtems_fdisk_device_desc *dd, uint32_t device)
Definition: flashdisk.h:329
int(* erase)(const rtems_fdisk_segment_desc *sd, uint32_t device, uint32_t segment)
Definition: flashdisk.h:313
uint16_t segment
Definition: flashdisk.h:177
unsigned size
Definition: tte.h:74
uint32_t avail_compact_segs
Definition: flashdisk.h:403
struct rtems_flashdisk_config rtems_flashdisk_config
RTEMS Flash Disk configuration table used to initialise the driver.
uint32_t block_size
Definition: flashdisk.h:383
const rtems_fdisk_driver_handlers * flash_ops
Definition: flashdisk.h:349
struct rtems_fdisk_device_desc rtems_fdisk_device_desc
Flash Device Descriptor holds the segments in a device.
Flash Device Descriptor holds the segments in a device.
Definition: flashdisk.h:345
int(* verify)(const rtems_fdisk_segment_desc *sd, uint32_t device, uint32_t segment, uint32_t offset, const void *buffer, uint32_t size)
Definition: flashdisk.h:293
uint32_t size
Definition: flashdisk.h:179
struct rtems_fdisk_segment_desc rtems_fdisk_segment_desc
Flash Segment Descriptor holds, number of continuous segments in the device of this type,...
Flash Low Level driver handlers.
Definition: flashdisk.h:200