From: Tejun Heo Date: Mon, 12 Jun 2006 05:18:51 +0000 (+0900) Subject: [PATCH] sata_sil: add controller unplug detection in sil_interrupt() X-Git-Tag: v2.6.18-rc1~1079^2~28 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=23fa9618094975f803ed0c6a44604b16747b9637;p=linux-2.6 [PATCH] sata_sil: add controller unplug detection in sil_interrupt() Short-circuit interrupt handling if BMDMA2 is reported as 0xffffffff indicating device removal. Signed-off-by: Tejun Heo Signed-off-by: Jeff Garzik --- diff --git a/drivers/scsi/sata_sil.c b/drivers/scsi/sata_sil.c index 0898cbe645..a7e99a1def 100644 --- a/drivers/scsi/sata_sil.c +++ b/drivers/scsi/sata_sil.c @@ -419,7 +419,8 @@ static irqreturn_t sil_interrupt(int irq, void *dev_instance, if (unlikely(!ap || ap->flags & ATA_FLAG_DISABLED)) continue; - if (!(bmdma2 & (SIL_DMA_COMPLETE | SIL_DMA_SATA_IRQ))) + if (bmdma2 == 0xffffffff || + !(bmdma2 & (SIL_DMA_COMPLETE | SIL_DMA_SATA_IRQ))) continue; sil_host_intr(ap, bmdma2);