]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - drivers/ide/ide-floppy.h
ide: prepare for merging ide-gd-floppy.c with ide-gd.c
[linux-2.6-omap-h63xx.git] / drivers / ide / ide-floppy.h
index ecadc2bc322dc9904acb4507281db91d1138e9a7..b965da2f41ce987118b38d2aff8d9937644efde3 100644 (file)
@@ -1,6 +1,18 @@
 #ifndef __IDE_FLOPPY_H
 #define __IDE_FLOPPY_H
 
+#define DRV_NAME "ide-floppy"
+#define PFX DRV_NAME ": "
+
+/* define to see debug info */
+#define IDEFLOPPY_DEBUG_LOG    0
+
+#if IDEFLOPPY_DEBUG_LOG
+#define ide_debug_log(lvl, fmt, args...) __ide_debug_log(lvl, fmt, args)
+#else
+#define ide_debug_log(lvl, fmt, args...) do {} while (0)
+#endif
+
 /*
  * Most of our global data which we need to save even as we leave the driver
  * due to an interrupt or a timer event is stored in a variable of type
@@ -13,20 +25,14 @@ typedef struct ide_floppy_obj {
        struct kref     kref;
        unsigned int    openers;        /* protected by BKL for now */
 
-       /* Current packet command */
-       struct ide_atapi_pc *pc;
        /* Last failed packet command */
        struct ide_atapi_pc *failed_pc;
        /* used for blk_{fs,pc}_request() requests */
        struct ide_atapi_pc queued_pc;
 
-       struct ide_atapi_pc request_sense_pc;
-       struct request request_sense_rq;
-
        /* Last error information */
        u8 sense_key, asc, ascq;
-       /* delay this long before sending packet command */
-       u8 ticks;
+
        int progress_indication;
 
        /* Device information */
@@ -51,13 +57,23 @@ typedef struct ide_floppy_obj {
 #define        IDEFLOPPY_IOCTL_FORMAT_START            0x4602
 #define IDEFLOPPY_IOCTL_FORMAT_GET_PROGRESS    0x4603
 
+sector_t ide_gd_capacity(ide_drive_t *);
+
 /* ide-floppy.c */
 void ide_floppy_create_mode_sense_cmd(struct ide_atapi_pc *, u8);
 void ide_floppy_create_read_capacity_cmd(struct ide_atapi_pc *);
-void ide_floppy_create_request_sense_cmd(struct ide_atapi_pc *);
+int ide_floppy_get_capacity(ide_drive_t *);
+void ide_floppy_setup(ide_drive_t *);
+ide_startstop_t ide_floppy_do_request(ide_drive_t *, struct request *, sector_t);
+int ide_floppy_end_request(ide_drive_t *, int, int);
 
 /* ide-floppy_ioctl.c */
-int ide_floppy_format_ioctl(ide_drive_t *, struct file *, unsigned int,
-                           void __user *);
+int ide_floppy_ioctl(struct inode *, struct file *, unsigned, unsigned long);
+
+#ifdef CONFIG_IDE_PROC_FS
+/* ide-floppy_proc.c */
+extern ide_proc_entry_t ide_floppy_proc[];
+extern const struct ide_proc_devset ide_floppy_settings[];
+#endif
 
 #endif /*__IDE_FLOPPY_H */