1. 10 12月, 2009 14 次提交
    • G
      [SCSI] qla2xxx: Queue depth ramp up/down modification changes. · c45dd305
      Giridhar Malavali 提交于
      Removed the module parameters ql2xqfulltracking and ql2xqfullrampup
      since the queue depth ramp up/down functionality is moved to scsi-ml.
      Signed-off-by: NGiridhar Malavali <giridhar.malavali@qlogic.com>
      Signed-off-by: NJames Bottomley <James.Bottomley@suse.de>
      c45dd305
    • M
      [SCSI] qla2xxx: dpc thread can execute before scsi host has been added · 1486400f
      Michael Reed 提交于
      Fix crash in qla2x00_fdmi_register() due to the dpc
      thread executing before the scsi host has been fully
      added.
      
      Unable to handle kernel NULL pointer dereference (address 00000000000001d0)
      qla2xxx_7_dpc[4140]: Oops 8813272891392 [1]
      
      Call Trace:
       [<a000000100016910>] show_stack+0x50/0xa0
                                      sp=e00000b07c59f930 bsp=e00000b07c591400
       [<a000000100017180>] show_regs+0x820/0x860
                                      sp=e00000b07c59fb00 bsp=e00000b07c5913a0
       [<a00000010003bd60>] die+0x1a0/0x2e0
                                      sp=e00000b07c59fb00 bsp=e00000b07c591360
       [<a0000001000681a0>] ia64_do_page_fault+0x8c0/0x9e0
                                      sp=e00000b07c59fb00 bsp=e00000b07c591310
       [<a00000010000c8e0>] ia64_native_leave_kernel+0x0/0x270
                                      sp=e00000b07c59fb90 bsp=e00000b07c591310
       [<a000000207197350>] qla2x00_fdmi_register+0x850/0xbe0 [qla2xxx]
                                      sp=e00000b07c59fd60 bsp=e00000b07c591290
       [<a000000207171570>] qla2x00_configure_loop+0x1930/0x34c0 [qla2xxx]
                                      sp=e00000b07c59fd60 bsp=e00000b07c591128
       [<a0000002071732b0>] qla2x00_loop_resync+0x1b0/0x2e0 [qla2xxx]
                                      sp=e00000b07c59fdf0 bsp=e00000b07c5910c0
       [<a000000207166d40>] qla2x00_do_dpc+0x9a0/0xce0 [qla2xxx]
                                      sp=e00000b07c59fdf0 bsp=e00000b07c590fa0
       [<a0000001000d5bb0>] kthread+0x110/0x140
                                      sp=e00000b07c59fe00 bsp=e00000b07c590f68
       [<a000000100014a30>] kernel_thread_helper+0xd0/0x100
                                      sp=e00000b07c59fe30 bsp=e00000b07c590f40
       [<a00000010000a4c0>] start_kernel_thread+0x20/0x40
                                      sp=e00000b07c59fe30 bsp=e00000b07c590f40
      
      crash> dis a000000207197350
      0xa000000207197350 <qla2x00_fdmi_register+2128>:        [MMI]       ld1 r45=[r14];;
      crash> scsi_qla_host.host 0xe00000b058c73ff8
        host = 0xe00000b058c73be0,
      crash> Scsi_Host.shost_data 0xe00000b058c73be0
        shost_data = 0x0,  <<<<<<<<<<<
      
      The fc_transport fc_* workqueue threads have yet to be created.
      
      crash> ps | grep _7
         3891      2   2  e00000b075c80000  IN   0.0       0      0  [scsi_eh_7]
         4140      2   3  e00000b07c590000  RU   0.0       0      0  [qla2xxx_7_dpc]
      
      The thread creating adding the Scsi_Host is blocked due to other
      activity in sysfs.
      
      crash> bt 3762
      PID: 3762   TASK: e00000b071e70000  CPU: 3   COMMAND: "modprobe"
       #0 [BSP:e00000b071e71548] schedule at a000000100727e00
       #1 [BSP:e00000b071e714c8] __mutex_lock_slowpath at a0000001007295a0
       #2 [BSP:e00000b071e714a8] mutex_lock at a000000100729830
       #3 [BSP:e00000b071e71478] sysfs_addrm_start at a0000001002584f0
       #4 [BSP:e00000b071e71440] create_dir at a000000100259350
       #5 [BSP:e00000b071e71410] sysfs_create_subdir at a000000100259510
       #6 [BSP:e00000b071e713b0] internal_create_group at a00000010025c880
       #7 [BSP:e00000b071e71388] sysfs_create_group at a00000010025cc50
       #8 [BSP:e00000b071e71368] dpm_sysfs_add at a000000100425050
       #9 [BSP:e00000b071e71310] device_add at a000000100417d90
      #10 [BSP:e00000b071e712d8] scsi_add_host at a00000010045a380
      #11 [BSP:e00000b071e71268] qla2x00_probe_one at a0000002071be950
      #12 [BSP:e00000b071e71248] local_pci_probe at a00000010032e490
      #13 [BSP:e00000b071e71218] pci_device_probe at a00000010032ecd0
      #14 [BSP:e00000b071e711d8] driver_probe_device at a00000010041d480
      #15 [BSP:e00000b071e711a8] __driver_attach at a00000010041d6e0
      #16 [BSP:e00000b071e71170] bus_for_each_dev at a00000010041c240
      #17 [BSP:e00000b071e71150] driver_attach at a00000010041d0a0
      #18 [BSP:e00000b071e71108] bus_add_driver at a00000010041b080
      #19 [BSP:e00000b071e710c0] driver_register at a00000010041dea0
      #20 [BSP:e00000b071e71088] __pci_register_driver at a00000010032f610
      #21 [BSP:e00000b071e71058] (unknown) at a000000207200270
      #22 [BSP:e00000b071e71018] do_one_initcall at a00000010000a9c0
      #23 [BSP:e00000b071e70f98] sys_init_module at a0000001000fef00
      #24 [BSP:e00000b071e70f98] ia64_ret_from_syscall at a00000010000c740
      
      So, it appears that qla2xxx dpc thread is moving forward before the
      scsi host has been completely added.
      
      This patch moves the setting of the init_done (and online) flag to
      after the call to scsi_add_host() to hold off the dpc thread.
      
      Found via large lun count testing using 2.6.31.
      Signed-off-by: NMichael Reed <mdr@sgi.com>
      Acked-by: NGiridhar Malavali <giridhar.malavali@qlogic.com>
      Cc: stable@kernel.org
      Signed-off-by: NJames Bottomley <James.Bottomley@suse.de>
      1486400f
    • B
      [SCSI] libosd: Fix blk_put_request locking again · 5d0961fd
      Boaz Harrosh 提交于
      So libosd has decided to sacrifice some code simplicity for the sake of
      a clean API. One of these things is the possibility for users to call
      osd_end_request, in any condition at any state. This opens up some
      problems with calling blk_put_request when out-side of the completion
      callback but calling __blk_put_request when detecting a from-completion
      state.
      
      The current hack was working just fine until exofs decided to operate on
      all devices in parallel and wait for the sum of the requests, before
      deallocating all osd-requests at once. There are two new possible cases
      1. All request in a group are deallocated as part of the last request's
         async-done, request_queue is locked.
      2. All request in a group where executed asynchronously, but
         de-allocation was delayed to after the async-done, in the context of
         another thread. Async execution but request_queue is not locked.
      
      The solution I chose was to separate the deallocation of the osd_request
      which has the information users need, from the deallocation of the
      internal(2) requests which impose the locking problem. The internal
      block-requests are freed unconditionally inside the async-done-callback,
      when we know the queue is always locked. If at osd_end_request time we
      still have a bock-request, then we know it did not come from within an
      async-done-callback and we can call the regular blk_put_request.
      
      The internal requests were used for carrying error information after
      execution. This information is now copied to osd_request members for
      later analysis by user code.
      
      The external API and behaviour was unchanged, except now it really
      supports what was previously advertised.
      Reported-by: NVineet Agarwal <checkout.vineet@gmail.com>
      Signed-off-by: NBoaz Harrosh <bharrosh@panasas.com>
      Cc: Stable Tree <stable@kernel.org>
      Signed-off-by: NJames Bottomley <James.Bottomley@suse.de>
      5d0961fd
    • N
      [SCSI] megaraid_sas: make driver PCI legacy I/O port free driver · aeab3fd7
      Noriyuki Fujii 提交于
      On the large servers, I/O port resource may not be assigned to all
      the PCI devices since it is limited (to 64KB on Intel Architecture[1])
      and it may also be fragmented (I/O base register of PCI-to-PCI bridge
      will usually be aligned to a 4KB boundary[2]).
      If no I/O port resource is assigned to devices, those devices do not
      work.
      
      [1] Some machines support 64KB I/O port space per PCI segment.
      [2] Some P2P bridges support optional 1KB aligned I/O base.
      
      Therefore, I made a patch for MegaRAID SAS driver to make PCI legacy
      I/O port free.  I have also tested the patch and it had no problem.
      
      The way to make PCI legacy I/O port free is the same as Fusion-MPT
      driver's and it has been merged into 2.6.30.4.
      
      This has already been fixed in e1000 and lpfc.
      
      As a result of the above, the driver can handle its device even when
      there are a huge number of PCI devices being used on the system and no
      I/O port region assigned to the device.
      Signed-off-by: NNoriyuki Fujii <n-fujii@np.css.fujitsu.com>
      Acked-by: N"Yang, Bo" <Bo.Yang@lsi.com>
      Signed-off-by: NJames Bottomley <James.Bottomley@suse.de>
      aeab3fd7
    • M
      [SCSI] Correctly handle thin provisioning write error · d8705f11
      Martin K. Petersen 提交于
      A thin provisioned device may temporarily be out of sufficient
      allocation units to fulfill a write request.  In that case it will
      return a space allocation in progress error.  Wait a bit and retry the
      write.
      Signed-off-by: NMartin K. Petersen <martin.petersen@oracle.com>
      Signed-off-by: NJames Bottomley <James.Bottomley@suse.de>
      d8705f11
    • M
      [SCSI] sd: WRITE SAME(16) / UNMAP support · e339c1a7
      Martin K. Petersen 提交于
      Implement a function for handling discard requests that sends either
      WRITE SAME(16) or UNMAP(10) depending on parameters indicated by the
      device in the block limits VPD.
      
      Extract unmap constraints and report them to the block layer.
      
      Based in part by a patch by Christoph Hellwig <hch@lst.de>.
      Signed-off-by: NMartin K. Petersen <martin.petersen@oracle.com>
      Signed-off-by: NJames Bottomley <James.Bottomley@suse.de>
      e339c1a7
    • F
      [SCSI] st: fix mdata->page_order handling · c982c368
      FUJITA Tomonori 提交于
      dio transfer always resets mdata->page_order to zero. It breaks
      high-order pages previously allocated for non-dio transfer.
      
      This patches adds reserved_page_order to st_buffer structure to save
      page order for non-dio transfer.
      
      http://bugzilla.kernel.org/show_bug.cgi?id=14563
      
      When enlarge_buffer() allocates 524288 from 0, st uses six-order page
      allocation. So mdata->page_order is 6 and frp_seg is 2.
      
      After that, if st uses dio, sgl_map_user_pages() sets
      mdata->page_order to 0 for st_do_scsi(). After that, when we call
      normalize_buffer(), it frees only free frp_seg * PAGE_SIZE (2 * 4096)
      though we should free frp_seg * PAGE_SIZE << 6 (2 * 4096 << 6). So we
      see buffer_size is set to 516096 (524288 - 8192).
      Reported-by: NJoachim Breuer <linux-kernel@jmbreuer.net>
      Tested-by: NJoachim Breuer <linux-kernel@jmbreuer.net>
      Acked-by: NKai Makisara <kai.makisara@kolumbus.fi>
      Signed-off-by: NFUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
      Cc: stable@kernel.org
      Signed-off-by: NJames Bottomley <James.Bottomley@suse.de>
      c982c368
    • J
      [SCSI] be2iscsi: Adding support for various Async messages from chip · 78b9fb6d
      Jayamohan Kallickal 提交于
      This patch allows for future addition of various async messages
      from the chip. This ensures that the driver won't hit a BUG_ON if
      the Firmware used is newer than inbox driver and so is using
      latest async messages.
      Signed-off-by: NJayamohan Kallickal <jayamohank@serverengines.com>
      Reviewed-by: NMike Christie <michaelc@cs.wisc.edu>
      Signed-off-by: NJames Bottomley <James.Bottomley@suse.de>
      78b9fb6d
    • S
      [SCSI] mvsas: add support for Adaptec ASC-1045/1405 SAS/SATA HBA · 7ec4ad01
      Srinivas 提交于
      This is support for Adaptec ASC-1045/1405 SAS/SATA HBA on mvsas, which
      is based on Marvell 88SE6440 chipset.
      Signed-off-by: NSrinivas <satyasrinivasp@hcl.in>
      Cc: Andy Yan <ayan@marvell.com>
      Signed-off-by: NJames Bottomley <James.Bottomley@suse.de>
      7ec4ad01
    • A
      [SCSI] pmcraid: support SMI-S object model of storage pool · 729c8456
      Anil Ravindranath 提交于
      PMC-Sierra mgmt application uses SMI-S model. According to SMI-S, the
      object model exposed by the SMI-S provider should show an StoragePool
      which contains member disks of a RAID Virtual disk and StorageVolume
      based on the StoragePool. But according to SMI-S, there is a possibility
      where StoragePool is created but StorageVolume is not yet created. To
      satisfy this scenario, we are trying a hidden RAID Virtual disk. The
      hidden RAID virtual disk will not be exposed to OS. Once a StorageVolume
      is created for this RAID virtual disk it is exposed.
      
      Signed-off-by: Anil Ravindranath<anil_ravindranath@pmc-sierra.com>
      Signed-off-by: NJames Bottomley <James.Bottomley@suse.de>
      729c8456
    • M
      [SCSI] fc class: fix fc_transport_init error handling · 48de68a4
      Mike Christie 提交于
      If transport_class_register fails we should unregister any
      registered classes, or we will leak memory or other
      resources.
      
      I did a quick modprobe of scsi_transport_fc to test the
      patch.
      Signed-off-by: NMike Christie <michaelc@cs.wisc.edu>
      Cc: Stable Tree <stable@kernel.org>
      Signed-off-by: NJames Bottomley <James.Bottomley@suse.de>
      48de68a4
    • K
      [SCSI] mpt2sas: add missing initialization of scsih_cmds · d685c262
      Kashyap, Desai 提交于
      Internal command scsih_cmds init is included in mpt2sas_base_attach.
      Signed-off-by: NKashyap Desai <kashyap.desai@lsi.com>
      Cc: Stable Tree <stable@kernel.org>
      Signed-off-by: NJames Bottomley <James.Bottomley@suse.de>
      d685c262
    • M
      [SCSI] scsi_dh_rdac: Add two new IBM devices to rdac_dev_list · 6f4fdda4
      Moger, Babu 提交于
      This patch adds two new IBM storage devices which can use rdac device handlers.
      Signed-off-by: NBabu Moger <babu.moger@lsi.com>
      Signed-off-by: NJames Bottomley <James.Bottomley@suse.de>
      6f4fdda4
    • M
      [SCSI] lpfc: fix hang on SGI ia64 platform · 8e68597d
      Michael Reed 提交于
      In testing 2.6.31 on one of our ia64 platforms I've encountered a hang
      due to the driver using hardware ATEs which are a limited resource.
      This is because the driver does not set the dma consistent mask to
      64 bits.
      Signed-off-by: NMichael Reed <mdr@sgi.com>
      Acked-by: NJames Smart <James.Smart@Emulex.Com>
      Signed-off-by: NJames Bottomley <James.Bottomley@suse.de>
      8e68597d
  2. 05 12月, 2009 26 次提交