1. 24 1月, 2011 4 次提交
  2. 14 1月, 2011 2 次提交
    • T
      [SCSI] sd,sr: kill compat SDEV_MEDIA_CHANGE event · f4013c38
      Tejun Heo 提交于
      SDEV_MEDIA_CHANGE event was first added by commit a341cd0f (SCSI: add
      asynchronous event notification API) for SATA AN support and then
      extended to cover generic media change events by commit 285e9670
      ([SCSI] sr,sd: send media state change modification events).
      
      This event was mapped to block device in userland with all properties
      stripped to simulate CHANGE event on the block device, which, in turn,
      was used to trigger further userspace action on media change.
      
      The recent addition of disk event framework kept this event for
      backward compatibility but it turns out to be unnecessary and causes
      erratic and inefficient behavior.  The new disk event generates proper
      events on the block devices and the compat events are mapped to block
      device with all properties stripped, so the block device ends up
      generating multiple duplicate events for single actual event.
      
      This patch removes the compat event generation from both sr and sd as
      suggested by Kay Sievers.  Both existing and newer versions of udev
      and the associated tools will behave better with the removal of these
      events as they from the beginning were expecting events on the block
      devices.
      Signed-off-by: NTejun Heo <tj@kernel.org>
      Acked-by: NKay Sievers <kay.sievers@vrfy.org>
      Signed-off-by: NJames Bottomley <James.Bottomley@suse.de>
      f4013c38
    • T
      [SCSI] sd: implement sd_check_events() · 2bae0093
      Tejun Heo 提交于
      Replace sd_media_change() with sd_check_events().
      
      * Move media removed logic into set_media_not_present() and
        media_not_present() and set sdev->changed iff an existing media is
        removed or the device indicates UNIT_ATTENTION.
      
      * Make sd_check_events() sets sdev->changed if previously missing
        media becomes present.
      
      * Event is reported only if sdev->changed is set.
      
      This makes media presence event reported if scsi_disk->media_present
      actually changed or the device indicated UNIT_ATTENTION.  For backward
      compatibility, SDEV_EVT_MEDIA_CHANGE is generated each time
      sd_check_events() detects media change event.
      
      [jejb: fix boot failure]
      Signed-off-by: NTejun Heo <tj@kernel.org>
      Acked-by: NJens Axboe <jaxboe@fusionio.com>
      Signed-off-by: NJames Bottomley <James.Bottomley@suse.de>
      2bae0093
  3. 06 1月, 2011 1 次提交
  4. 05 1月, 2011 1 次提交
    • T
      [SCSI] sd,sr: kill compat SDEV_MEDIA_CHANGE event · 140e3008
      Tejun Heo 提交于
      SDEV_MEDIA_CHANGE event was first added by commit a341cd0f (SCSI: add
      asynchronous event notification API) for SATA AN support and then
      extended to cover generic media change events by commit 285e9670
      ([SCSI] sr,sd: send media state change modification events).
      
      This event was mapped to block device in userland with all properties
      stripped to simulate CHANGE event on the block device, which, in turn,
      was used to trigger further userspace action on media change.
      
      The recent addition of disk event framework kept this event for
      backward compatibility but it turns out to be unnecessary and causes
      erratic and inefficient behavior.  The new disk event generates proper
      events on the block devices and the compat events are mapped to block
      device with all properties stripped, so the block device ends up
      generating multiple duplicate events for single actual event.
      
      This patch removes the compat event generation from both sr and sd as
      suggested by Kay Sievers.  Both existing and newer versions of udev
      and the associated tools will behave better with the removal of these
      events as they from the beginning were expecting events on the block
      devices.
      Signed-off-by: NTejun Heo <tj@kernel.org>
      Acked-by: NKay Sievers <kay.sievers@vrfy.org>
      Signed-off-by: NJames Bottomley <James.Bottomley@suse.de>
      140e3008
  5. 04 1月, 2011 3 次提交
  6. 03 1月, 2011 1 次提交
  7. 31 12月, 2010 9 次提交
  8. 28 12月, 2010 1 次提交
    • T
      [SCSI] sd: implement sd_check_events() · eface65c
      Tejun Heo 提交于
      Replace sd_media_change() with sd_check_events().
      
      * Move media removed logic into set_media_not_present() and
        media_not_present() and set sdev->changed iff an existing media is
        removed or the device indicates UNIT_ATTENTION.
      
      * Make sd_check_events() sets sdev->changed if previously missing
        media becomes present.
      
      * Event is reported only if sdev->changed is set.
      
      This makes media presence event reported if scsi_disk->media_present
      actually changed or the device indicated UNIT_ATTENTION.  For backward
      compatibility, SDEV_EVT_MEDIA_CHANGE is generated each time
      sd_check_events() detects media change event.
      
      [jejb: fix boot failure]
      Signed-off-by: NTejun Heo <tj@kernel.org>
      Acked-by: NJens Axboe <jaxboe@fusionio.com>
      Signed-off-by: NJames Bottomley <James.Bottomley@suse.de>
      eface65c
  9. 24 12月, 2010 16 次提交
  10. 23 12月, 2010 2 次提交