Home | History | Annotate | Line # | Download | only in flash
      1 #ifndef _FLASH_IO_H_
      2 #define _FLASH_IO_H_
      3 
      4 struct flash_io {
      5 	device_t fio_dev;
      6 	struct bintime fio_creation;
      7 	struct bintime fio_last_write;
      8 	struct bufq_state *fio_bufq;
      9 	uint8_t *fio_data;
     10 	daddr_t fio_block;
     11 	kmutex_t fio_lock;
     12 	bool fio_write_pending;
     13 	struct lwp *fio_thread;
     14 	kcondvar_t fio_cv;
     15 	bool fio_exiting;
     16 	struct flash_interface *fio_if;
     17 };
     18 
     19 int flash_io_submit(struct flash_io *, struct buf *);
     20 void flash_sync_thread(void *);
     21 int flash_sync_thread_init(struct flash_io *, device_t,
     22 	struct flash_interface *);
     23 void flash_sync_thread_destroy(struct flash_io *);
     24 
     25 #endif
     26