1. 11 5月, 2008 2 次提交
    • J
      [SCSI] aha152x: Fix oops on module removal · 64976a03
      James Bottomley 提交于
      Reported-by: NFrank de Jong <frapex@xs4all.nl>
      > after trying to unload the module:
      > BUG: unable to handle kernel paging request at 00100100
      > IP: [<fb9ff667>] :aha152x:aha152x_exit+0x47/0x6a
      > *pde = 00000000
      > Oops: 0000 [#1] PREEMPT SMP
      > Modules linked in: aha152x(-) w83781d hwmon_vid tun ne 8390 bonding
      > usb_storage snd_usb_audio snd_usb_lib snd_rawmidi pwc snd_seq_device
      > compat_ioctl32 snd_hwdep videodev v4l1_compat 3c59x mii intel_agp
      > agpgart snd_pcm_oss snd_pcm snd_timer snd_page_alloc snd_mixer_oss snd
      >
      > Pid: 2837, comm: rmmod Not tainted (2.6.25.3 #1)
      > EIP: 0060:[<fb9ff667>] EFLAGS: 00210212 CPU: 0
      > EIP is at aha152x_exit+0x47/0x6a [aha152x]
      > EAX: 00000001 EBX: 000ffdc4 ECX: f7c517a8 EDX: 00000001
      > ESI: 00000000 EDI: 00000003 EBP: e7880000 ESP: e7881f58
      >   DS: 007b ES: 007b FS: 00d8 GS: 0033 SS: 0068
      > Process rmmod (pid: 2837, ti=e7880000 task=f27eb580 task.ti=e7880000)
      > Stack: fba03700 c01419d2 31616861 00783235 e795ee70 c0157709 b7f24000 e79ae000
      >         c0158271 ffffffff b7f25000 e79ae004 e795e370 b7f25000 e795e37c e795e370
      >         009ae000 fba03700 00000880 e7881fa8 00000000 bf93ec20 bf93ec20 c0102faa
      > Call Trace:
      >   [<c01419d2>] sys_delete_module+0x112/0x1a0
      >   [<c0157709>] remove_vma+0x39/0x50
      >   [<c0158271>] do_munmap+0x181/0x1f0
      >   [<c0102faa>] sysenter_past_esp+0x5f/0x85
      >   [<c0490000>] rsc_parse+0x0/0x3c0
      
      The problem is that the driver calls aha152x_release() under a
      list_for_each_entry().  Unfortunately, aha152x_release() deletes from
      the list in question.  Fix this by using list_for_each_entry_safe().
      
      Cc: Stable Tree <stable@kernel.org>
      Signed-off-by: NJames Bottomley <James.Bottomley@HansenPartnership.com>
      64976a03
    • J
      [SCSI] aha152x: fix init suspiciously returned 1, it should follow 0/-E convention · ad2fa42d
      James Bottomley 提交于
      Reported-by: NFrank de Jong <frapex@xs4all.nl>
      > [1.] One line summary of the problem:
      > linux-2.6.25.3, aha152x'->init suspiciously returned 1, it should
      > follow 0/-E convention. The module / driver works okay. Unloading the
      > module is impossible.
      
      The driver is apparently returning 0 on failure and 1 on success.
      That's a bit unfortunate.  Fix it by altering to -ENODEV and 0.
      
      Cc: Stable Tree <stable@kernel.org>
      Signed-off-by: NJames Bottomley <James.Bottomley@HansenPartnership.com>
      ad2fa42d
  2. 09 5月, 2008 1 次提交
  3. 08 5月, 2008 3 次提交
    • M
      [SCSI] libiscsi regression in 2.6.25: fix nop timer handling · 4cf10435
      Mike Christie 提交于
      The following patch fixes a bug in the iscsi nop processing.
      The target sends iscsi nops to ping the initiator and the
      initiator has to send nops to reply and can send nops to
      ping the target.
      
      In 2.6.25 we moved the nop processing to the kernel to handle
      problems when the userspace daemon is not up, but the target
      is pinging us, and to handle when scsi commands timeout, but
      the transport may be the cause (we can send a nop to check
      the transport). When we added this code we added a bug where
      if the transport timer wakes at the exact same time we are supposed to check
      for a nop timeout we drop the session instead of checking the transport.
      
      This patch checks if a iscsi ping is outstanding and if the ping has
      timed out, to determine if we need to signal a connection problem.
      Signed-off-by: NMike Christie <michaelc@cs.wisc.edu>
      Cc: Stable Tree <stable@kernel.org>
      Signed-off-by: NJames Bottomley <James.Bottomley@HansenPartnership.com>
      4cf10435
    • J
      [SCSI] gdth: fix Error: Driver 'gdth' is already registered, aborting... · a85591fd
      James Bottomley 提交于
      This message appears on modprobe/rmmod/modprobe of the driver.  It's
      caused because if the driver has no instances, it returns an error
      from gdth_init, which causes the module to fail to load.
      Unfortunately, the module's pci driver is still registered at this
      point.
      
      Fix this by making gdth behave like a modern driver and insert even if
      it doesn't find any instances (in case of hot plug or software driven
      binding).
      Signed-off-by: NJames Bottomley <James.Bottomley@HansenPartnership.com>
      a85591fd
    • J
      [SCSI] gdth: fix timer handling · 2d6f0d0c
      James Bottomley 提交于
      The global timer handling is problematic in that if someone unbinds a
      PCI gdth instance, the BUG_ON() in the timer will cause a panic.
      
      Fix this by making the timer start and stop depending on whether there
      are instances present.  This should also permit binding and unbinding
      to work.
      Signed-off-by: NJames Bottomley <James.Bottomley@HansenPartnership.com>
      2d6f0d0c
  4. 06 5月, 2008 1 次提交
  5. 03 5月, 2008 11 次提交
  6. 02 5月, 2008 2 次提交
    • B
      [SCSI] Let scsi_cmnd->cmnd use request->cmd buffer · 64a87b24
      Boaz Harrosh 提交于
       - struct scsi_cmnd had a 16 bytes command buffer of its own.
         This is an unnecessary duplication and copy of request's
         cmd. It is probably left overs from the time that scsi_cmnd
         could function without a request attached. So clean that up.
      
       - Once above is done, few places, apart from scsi-ml, needed
         adjustments due to changing the data type of scsi_cmnd->cmnd.
      
       - Lots of drivers still use MAX_COMMAND_SIZE. So I have left
         that #define but equate it to BLK_MAX_CDB. The way I see it
         and is reflected in the patch below is.
         MAX_COMMAND_SIZE - means: The longest fixed-length (*) SCSI CDB
                            as per the SCSI standard and is not related
                            to the implementation.
         BLK_MAX_CDB.     - The allocated space at the request level
      
       - I have audit all ISA drivers and made sure none use ->cmnd in a DMA
         Operation. Same audit was done by Andi Kleen.
      
      (*)fixed-length here means commands that their size can be determined
         by their opcode and the CDB does not carry a length specifier, (unlike
         the VARIABLE_LENGTH_CMD(0x7f) command). This is actually not exactly
         true and the SCSI standard also defines extended commands and
         vendor specific commands that can be bigger than 16 bytes. The kernel
         will support these using the same infrastructure used for VARLEN CDB's.
         So in effect MAX_COMMAND_SIZE means the maximum size command
         scsi-ml supports without specifying a cmd_len by ULD's
      Signed-off-by: NBoaz Harrosh <bharrosh@panasas.com>
      Signed-off-by: NJames Bottomley <James.Bottomley@HansenPartnership.com>
      64a87b24
    • M
      [SCSI] aacraid: Fix down_interruptible() to check the return value correctly · 0462590e
      Mark Salyzyn 提交于
      On Apr 21, 2008, at 8:42 PM, Yinghai Lu wrote:
      > bisected to:
      >
      > commit e6990c64
      > Author: Mark Salyzyn <Mark_Salyzyn@adaptec.com>
      > Date:   Mon Apr 14 14:20:16 2008 -0400
      >
      >    [SCSI] aacraid: Fix down_interruptible() to check the return value
      
      The return value for down_interruptible was incorrectly checked!
      updated patch enclosed.
      Signed-off-by: NMark Salyzyn <aacraid@adaptec.com>
      Signed-off-by: NJames Bottomley <James.Bottomley@HansenPartnership.com>
      0462590e
  7. 01 5月, 2008 2 次提交
  8. 30 4月, 2008 5 次提交
  9. 29 4月, 2008 13 次提交