#define FD_HD_3 0x55555555 /* high-density 3.5" (1760K) drive */
#define FD_DD_5 0xaaaaaaaa /* double-density 5.25" (440K) drive */
-static long int fd_def_df0 = FD_DD_3; /* default for df0 if it doesn't identify */
+static unsigned long int fd_def_df0 = FD_DD_3; /* default for df0 if it doesn't identify */
-MODULE_PARM(fd_def_df0,"l");
+module_param(fd_def_df0, ulong, 0);
MODULE_LICENSE("GPL");
static struct request_queue *floppy_queue;
static int writefromint;
static char *raw_buf;
-static spinlock_t amiflop_lock = SPIN_LOCK_UNLOCKED;
+static DEFINE_SPINLOCK(amiflop_lock);
#define RAW_BUF_SIZE 30000 /* size of raw disk data */
fd_select(drive);
udelay (1);
fd_deselect(drive);
-
-#ifdef MODULE
-/*
- this is the last interrupt for any drive access, happens after
- release (from floppy_off). So we have to wait until now to decrease
- the use count.
-*/
- if (decusecount)
- MOD_DEC_USE_COUNT;
-#endif
}
static void floppy_off (unsigned int nr)
local_irq_save(flags);
fd_ref[drive]++;
fd_device[drive] = system;
-#ifdef MODULE
- if (unit[drive].motor == 0)
- MOD_INC_USE_COUNT;
-#endif
local_irq_restore(flags);
unit[drive].dtype=&data_types[system];
return amiga_floppy_init();
}
+#if 0 /* not safe to unload */
void cleanup_module(void)
{
int i;
unregister_blkdev(FLOPPY_MAJOR, "fd");
}
#endif
+#endif