1. 15 12月, 2011 2 次提交
  2. 03 11月, 2011 1 次提交
  3. 01 11月, 2011 1 次提交
  4. 31 10月, 2011 1 次提交
    • M
      [SCSI] scsi_dh: check queuedata pointer before proceeding further · a18a920c
      Moger, Babu 提交于
      This patch validates sdev pointer in scsi_dh_activate before proceeding further.
      
      Without this check we might see the panic as below. I have seen this
      panic multiple times..
      
      Call trace:
      
       #0 [ffff88007d647b50] machine_kexec at ffffffff81020902
       #1 [ffff88007d647ba0] crash_kexec at ffffffff810875b0
       #2 [ffff88007d647c70] oops_end at ffffffff8139c650
       #3 [ffff88007d647c90] __bad_area_nosemaphore at ffffffff8102dd15
       #4 [ffff88007d647d50] page_fault at ffffffff8139b8cf
          [exception RIP: scsi_dh_activate+0x82]
          RIP: ffffffffa0041922  RSP: ffff88007d647e00  RFLAGS: 00010046
          RAX: 0000000000000000  RBX: 0000000000000000  RCX: 00000000000093c5
          RDX: 00000000000093c5  RSI: ffffffffa02e6640  RDI: ffff88007cc88988
          RBP: 000000000000000f   R8: ffff88007d646000   R9: 0000000000000000
          R10: ffff880082293790  R11: 00000000ffffffff  R12: ffff88007cc88988
          R13: 0000000000000000  R14: 0000000000000286  R15: ffff880037b845e0
          ORIG_RAX: ffffffffffffffff  CS: 0010  SS: 0000
       #5 [ffff88007d647e38] run_workqueue at ffffffff81060268
       #6 [ffff88007d647e78] worker_thread at ffffffff81060386
       #7 [ffff88007d647ee8] kthread at ffffffff81064436
       #8 [ffff88007d647f48] kernel_thread at ffffffff81003fba
      Signed-off-by: NBabu Moger <babu.moger@netapp.com>
      Cc: stable@kernel.org
      Signed-off-by: NJames Bottomley <JBottomley@Parallels.com>
      a18a920c
  5. 16 10月, 2011 1 次提交
  6. 22 9月, 2011 2 次提交
  7. 31 8月, 2011 7 次提交
  8. 28 7月, 2011 1 次提交
  9. 27 7月, 2011 1 次提交
  10. 21 7月, 2011 1 次提交
    • P
      treewide: fix potentially dangerous trailing ';' in #defined values/expressions · 497888cf
      Phil Carmody 提交于
      All these are instances of
        #define NAME value;
      or
        #define NAME(params_opt) value;
      
      These of course fail to build when used in contexts like
        if(foo $OP NAME)
        while(bar $OP NAME)
      and may silently generate the wrong code in contexts such as
        foo = NAME + 1;    /* foo = value; + 1; */
        bar = NAME - 1;    /* bar = value; - 1; */
        baz = NAME & quux; /* baz = value; & quux; */
      
      Reported on comp.lang.c,
      Message-ID: <ab0d55fe-25e5-482b-811e-c475aa6065c3@c29g2000yqd.googlegroups.com>
      Initial analysis of the dangers provided by Keith Thompson in that thread.
      
      There are many more instances of more complicated macros having unnecessary
      trailing semicolons, but this pile seems to be all of the cases of simple
      values suffering from the problem. (Thus things that are likely to be found
      in one of the contexts above, more complicated ones aren't.)
      Signed-off-by: NPhil Carmody <ext-phil.2.carmody@nokia.com>
      Signed-off-by: NJiri Kosina <jkosina@suse.cz>
      497888cf
  11. 02 5月, 2011 1 次提交
  12. 01 5月, 2011 3 次提交
  13. 25 4月, 2011 1 次提交
  14. 31 3月, 2011 1 次提交
  15. 15 3月, 2011 1 次提交
  16. 13 2月, 2011 4 次提交
  17. 25 1月, 2011 6 次提交
  18. 22 12月, 2010 1 次提交
    • M
      [SCSI] scsi_dh: propagate SCSI device deletion · db422318
      Menny Hamburger 提交于
      Currently, when scsi_dh_activate() returns with an error
      (e.g. SCSI_DH_NOSYS) the activate_complete callback is not called and
      the error is not propagated to DM mpath.
      
      When a SCSI device attached to a device handler is deleted, userland
      processes currently performing I/O on the device will have their I/O
      hang forever.
      
      - Set SCSI_DH_NOSYS error when the handler is in the process of being
        deleted (e.g. the SCSI device is in a SDEV_CANCEL or SDEV_DEL state).
      
      - Set SCSI_DH_DEV_OFFLINED error when device is in SDEV_OFFLINE state.
      
      - Call the activate_complete callback function directly from
        scsi_dh_activate if an error has been set (when either the scsi_dh
        internal data has already been deleted or is in the process of being
        deleted).
      
      The patch was tested in an iSCSI environment, RDAC H/W handler and
      multipath.  In the following reproduction process, dd will I/O hang
      forever and the only way to release it will be to reboot the machine:
      1) Perform I/O on a multipath device:
          dd if=/dev/dm-0 of=/dev/zero bs=8k count=1000000 &
      2) Delete all slave SCSI devices contained in the mpath device:
         I)  In an iSCSI environment, the easiest way to do this is by
         stopping iSCSI:
             /etc/init.d/iscsi stop
         II) Another way to delete the devices is by applying the following
         bash scriptlet:
             dm_devs=$(ls /sys/block/ | grep dm- | xargs)
             for dm_dev in $dm_devs; do
               devices=$(ls /sys/block/$dm_dev/slaves)
               for device in $devices; do
                  echo 1 > /sys/block/$device/device/delete
               done
             done
      
      NOTE: when DM mpath's fail_path uses blk_abort_queue this scsi_dh change
      isn't strictly required.  However, DM mpath's call to blk_abort_queue
      will soon be reverted because it has proven to be unsafe due to a race
      (between blk_abort_queue and scsi_request_fn) that can lead to list
      corruption.  Therefore we cannot rely on blk_abort_queue via fail_path,
      but even if we could this scsi_dh change is still preferrable.
      Signed-off-by: NMenny Hamburger <Menny_Hamburger@Dell.com>
      Signed-off-by: NMike Snitzer <snitzer@redhat.com>
      Reviewed-by: NBabu Moger <babu.moger@lsi.com>
      Signed-off-by: NJames Bottomley <James.Bottomley@suse.de>
      db422318
  19. 26 10月, 2010 1 次提交
  20. 08 10月, 2010 1 次提交
  21. 28 7月, 2010 1 次提交
  22. 12 4月, 2010 1 次提交