aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/scsi_lib.c
diff options
context:
space:
mode:
authorKay Sievers <kay.sievers@vrfy.org>2008-03-19 08:04:47 -0400
committerJames Bottomley <James.Bottomley@HansenPartnership.com>2008-03-19 12:51:28 -0400
commit4d1566ed2100d074ccc654e5cf2e44cdea3a01d0 (patch)
tree8fab30e6e135023b8a595c8e11e8eff30ac17a72 /drivers/scsi/scsi_lib.c
parentc02e600280c605c761190ef82a6e6fa6aa7fb248 (diff)
[SCSI] fix media change events for polled devices
Commit: a341cd0f (SCSI: add asynchronous event notification API) breaks: 285e9670 (sr,sd: send media state change modification events) by introducing an event filter, which is removed here, to make events, we are depending on, happen again. Fix this by removing the event filter. It's pretty much broken at the moment, since a user can't set it (the attribute being read only). A proper fix will be to make the event discriminator distinguish between AN and Polled media change events. Cc: David Zeuthen <david@fubar.dk> Cc: kristen accardi <kaccardi@gmail.com> Cc: Jeff Garzik <jeff@garzik.org> Signed-off-by: Kay Sievers <kay.sievers@vrfy.org> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
Diffstat (limited to 'drivers/scsi/scsi_lib.c')
-rw-r--r--drivers/scsi/scsi_lib.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/scsi/scsi_lib.c b/drivers/scsi/scsi_lib.c
index ba21d97d1855..f40898dc2d14 100644
--- a/drivers/scsi/scsi_lib.c
+++ b/drivers/scsi/scsi_lib.c
@@ -2162,10 +2162,15 @@ void sdev_evt_send(struct scsi_device *sdev, struct scsi_event *evt)
2162{ 2162{
2163 unsigned long flags; 2163 unsigned long flags;
2164 2164
2165#if 0
2166 /* FIXME: currently this check eliminates all media change events
2167 * for polled devices. Need to update to discriminate between AN
2168 * and polled events */
2165 if (!test_bit(evt->evt_type, sdev->supported_events)) { 2169 if (!test_bit(evt->evt_type, sdev->supported_events)) {
2166 kfree(evt); 2170 kfree(evt);
2167 return; 2171 return;
2168 } 2172 }
2173#endif
2169 2174
2170 spin_lock_irqsave(&sdev->list_lock, flags); 2175 spin_lock_irqsave(&sdev->list_lock, flags);
2171 list_add_tail(&evt->node, &sdev->event_list); 2176 list_add_tail(&evt->node, &sdev->event_list);