I have this code:
static int gdrom_set_command_interrupt_handler(void)
{
int err;
#ifdef GDROMDEBUG
printk("%s\n", __FUNCTION__);
#endif
/* need a queue to wait in */
init_waitqueue_head(&command_queue);
err = request_irq(HW_EVENT_GDROM_CMD, gdrom_command_interrupt,
IRQF_DISABLED, "gdrom", NULL);
if (err)
return -err;
#ifdef GDROMDEBUG
printk("Interrupt is registered\n");
#endif
return 0;
}
Which, when run, produces this output...
/ # modprobe gdrom
[ 32.383697] init_gdrom
[ 32.444063] probe_gdrom
[ 32.448559] gdrom_execute_diagnostic
[ 33.949789] Completed: wait_clrbusy
[ 33.953416] Completed: gdrom_wait_busy_sleeps
[ 33.959472] gdrom_identifydevice
[ 33.966199] Completed: wait_clrbusy
[ 33.971730] Completed: wait_clrbusy
[ 33.975238] Completed: gdrom_wait_busy_sleeps
[ 33.982966] GDROM: CD-ROM DRIVE from SE with firmware
6.42
[ 33.991082] GDROM: Block device is registered with major number 254
[ 34.000370] Uniform CD-ROM driver Revision: 3.20
[ 34.006600] gdrom_set_command_interrupt_handler
ie it locks ups in the request for the interrupt. If I change
IRQF_DISABLED to, say IRQF_SHARED, it does retrun reporting an error:
/ # modprobe gdrom
[ 169.130924] init_gdrom
[ 169.190342] probe_gdrom
[ 169.194487] gdrom_execute_diagnostic
[ 170.742247] Completed: wait_clrbusy
[ 170.747856] Completed: gdrom_wait_busy_sleeps
[ 170.753782] gdrom_identifydevice
[ 170.758586] Completed: wait_clrbusy
[ 170.764557] Completed: wait_clrbusy
[ 170.768066] Completed: gdrom_wait_busy_sleeps
[ 170.775367] GDROM: CD-ROM DRIVE from SE with firmware
6.42
[ 170.783721] GDROM: Block device is registered with major number 254
[ 170.789969] Uniform CD-ROM driver Revision: 3.20
[ 170.799784] gdrom_set_command_interrupt_handler
[ 170.804542] GDROM: Could not probe for device - error is 0x16
[ 170.813425] gdrom: probe of gdrom failed with error 22
The previous driver used SA_INTERRUPT, which is the same as
IRQF_DISABLED iiuc
Any ideas why it doesn't even return on IRQF_DISABLED? The kernel does
not detect it as a soft lockup.
|