22 Apr, 2009

1 commit

  • Addresses http://bugzilla.kernel.org/show_bug.cgi?id=13133

    ODEBUG: object is on stack, but not annotated
    ------------[ cut here ]------------
    WARNING: at lib/debugobjects.c:253 __debug_object_init+0x1f3/0x276()
    Hardware name: VMware Virtual Platform
    Modules linked in: mptspi(+) mptscsih mptbase scsi_transport_spi ext3 jbd mbcache
    Pid: 540, comm: insmod Not tainted 2.6.28-mm1 #2
    Call Trace:
    [] warn_slowpath+0x74/0x8a
    [] ? start_critical_timing+0x96/0xb7
    [] ? _spin_unlock_irqrestore+0x2f/0x3c
    [] ? trace_hardirqs_off_caller+0x18/0xaf
    [] ? trace_hardirqs_off+0xb/0xd
    [] ? _spin_unlock_irqrestore+0x2f/0x3c
    [] ? release_console_sem+0x1a5/0x1ad
    [] __debug_object_init+0x1f3/0x276
    [] debug_object_init+0x13/0x17
    [] init_timer+0x10/0x1a
    [] mpt_config+0x1c1/0x2b7 [mptbase]
    [] ? kmalloc+0x8/0xa [mptbase]
    [] ? kmalloc+0x8/0xa [mptbase]
    [] mpt_do_ioc_recovery+0x950/0x1212 [mptbase]
    [] ? __lock_acquire+0xa69/0xacc
    [] ? _spin_unlock_irqrestore+0x36/0x3c
    [] ? _spin_unlock_irq+0x22/0x26
    [] ? string+0x2b/0x76
    [] ? vsnprintf+0x338/0x7b3
    [] ? __lock_acquire+0xa69/0xacc
    [] ? _spin_unlock_irqrestore+0x2f/0x3c
    [] ? __lock_acquire+0xa69/0xacc
    [] ? debug_check_no_locks_freed+0xeb/0x105
    [] ? _spin_unlock_irqrestore+0x36/0x3c
    [] ? debug_check_no_locks_freed+0x2a/0x105
    [] ? lock_release_holdtime+0x43/0x48
    [] ? up_read+0x16/0x29
    [] ? pci_get_slot+0x66/0x72
    [] mpt_attach+0x881/0x9b1 [mptbase]
    [] mptspi_probe+0x11/0x354 [mptspi]

    Noticing that every caller of mpt_config has its CONFIGPARMS struct
    declared on the stack and thus the &pCfg->timer is always on the stack I
    changed init_timer() to init_timer_on_stack() and it seems to have shut
    up.....

    Cc: "Moore, Eric Dean"
    Cc: James Bottomley
    Cc: Thomas Gleixner
    Acked-by: "Desai, Kashyap"
    Cc: [2.6.29.x]
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Eric Paris
     

07 Apr, 2009

2 commits


03 Apr, 2009

1 commit


31 Mar, 2009

1 commit

  • Setting ->owner as done currently (pde->owner = THIS_MODULE) is racy
    as correctly noted at bug #12454. Someone can lookup entry with NULL
    ->owner, thus not pinning enything, and release it later resulting
    in module refcount underflow.

    We can keep ->owner and supply it at registration time like ->proc_fops
    and ->data.

    But this leaves ->owner as easy-manipulative field (just one C assignment)
    and somebody will forget to unpin previous/pin current module when
    switching ->owner. ->proc_fops is declared as "const" which should give
    some thoughts.

    ->read_proc/->write_proc were just fixed to not require ->owner for
    protection.

    rmmod'ed directories will be empty and return "." and ".." -- no harm.
    And directories with tricky enough readdir and lookup shouldn't be modular.
    We definitely don't want such modular code.

    Removing ->owner will also make PDE smaller.

    So, let's nuke it.

    Kudos to Jeff Layton for reminding about this, let's say, oversight.

    http://bugzilla.kernel.org/show_bug.cgi?id=12454

    Signed-off-by: Alexey Dobriyan

    Alexey Dobriyan
     

22 Feb, 2009

1 commit

  • Impact: fix bug

    the third param in module_param(,,) is perm instead of default value.
    we still need to assign default at first. Also, the default is now
    zero not one, so fix the parameter text to reflect that.

    Signed-off-by: Yinghai Lu
    Acked-by: Kashyap Desai
    Signed-off-by: James Bottomley

    Yinghai Lu
     

14 Jan, 2009

3 commits


09 Jan, 2009

2 commits

  • * git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-misc-2.6: (45 commits)
    [SCSI] qla2xxx: Update version number to 8.03.00-k1.
    [SCSI] qla2xxx: Add ISP81XX support.
    [SCSI] qla2xxx: Use proper request/response queues with MQ instantiations.
    [SCSI] qla2xxx: Correct MQ-chain information retrieval during a firmware dump.
    [SCSI] qla2xxx: Collapse EFT/FCE copy procedures during a firmware dump.
    [SCSI] qla2xxx: Don't pollute kernel logs with ZIO/RIO status messages.
    [SCSI] qla2xxx: Don't fallback to interrupt-polling during re-initialization with MSI-X enabled.
    [SCSI] qla2xxx: Remove support for reading/writing HW-event-log.
    [SCSI] cxgb3i: add missing include
    [SCSI] scsi_lib: fix DID_RESET status problems
    [SCSI] fc transport: restore missing dev_loss_tmo callback to LLDD
    [SCSI] aha152x_cs: Fix regression that keeps driver from using shared interrupts
    [SCSI] sd: Correctly handle 6-byte commands with DIX
    [SCSI] sd: DIF: Fix tagging on platforms with signed char
    [SCSI] sd: DIF: Show app tag on error
    [SCSI] Fix error handling for DIF/DIX
    [SCSI] scsi_lib: don't decrement busy counters when inserting commands
    [SCSI] libsas: fix test for negative unsigned and typos
    [SCSI] a2091, gvp11: kill warn_unused_result warnings
    [SCSI] fusion: Move a dereference below a NULL test
    ...

    Fixed up trivial conflict due to moving the async part of sd_probe
    around in the async probes vs using dev_set_name() in naming.

    Linus Torvalds
     
  • David S. Miller
     

08 Jan, 2009

2 commits

  • Convert to net_device_ops and internal net_device_stats

    Signed-off-by: Stephen Hemminger
    Signed-off-by: David S. Miller

    Stephen Hemminger
     
  • * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial: (24 commits)
    trivial: chack -> check typo fix in main Makefile
    trivial: Add a space (and a comma) to a printk in 8250 driver
    trivial: Fix misspelling of "firmware" in docs for ncr53c8xx/sym53c8xx
    trivial: Fix misspelling of "firmware" in powerpc Makefile
    trivial: Fix misspelling of "firmware" in usb.c
    trivial: Fix misspelling of "firmware" in qla1280.c
    trivial: Fix misspelling of "firmware" in a100u2w.c
    trivial: Fix misspelling of "firmware" in megaraid.c
    trivial: Fix misspelling of "firmware" in ql4_mbx.c
    trivial: Fix misspelling of "firmware" in acpi_memhotplug.c
    trivial: Fix misspelling of "firmware" in ipw2100.c
    trivial: Fix misspelling of "firmware" in atmel.c
    trivial: Fix misspelled firmware in Kconfig
    trivial: fix an -> a typos in documentation and comments
    trivial: fix then -> than typos in comments and documentation
    trivial: update Jesper Juhl CREDITS entry with new email
    trivial: fix singal -> signal typo
    trivial: Fix incorrect use of "loose" in event.c
    trivial: printk: fix indentation of new_text_line declaration
    trivial: rtc-stk17ta8: fix sparse warning
    ...

    Linus Torvalds
     

07 Jan, 2009

3 commits

  • * git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core-2.6: (60 commits)
    uio: make uio_info's name and version const
    UIO: Documentation for UIO ioport info handling
    UIO: Pass information about ioports to userspace (V2)
    UIO: uio_pdrv_genirq: allow custom irq_flags
    UIO: use pci_ioremap_bar() in drivers/uio
    arm: struct device - replace bus_id with dev_name(), dev_set_name()
    libata: struct device - replace bus_id with dev_name(), dev_set_name()
    avr: struct device - replace bus_id with dev_name(), dev_set_name()
    block: struct device - replace bus_id with dev_name(), dev_set_name()
    chris: struct device - replace bus_id with dev_name(), dev_set_name()
    dmi: struct device - replace bus_id with dev_name(), dev_set_name()
    gadget: struct device - replace bus_id with dev_name(), dev_set_name()
    gpio: struct device - replace bus_id with dev_name(), dev_set_name()
    gpu: struct device - replace bus_id with dev_name(), dev_set_name()
    hwmon: struct device - replace bus_id with dev_name(), dev_set_name()
    i2o: struct device - replace bus_id with dev_name(), dev_set_name()
    IA64: struct device - replace bus_id with dev_name(), dev_set_name()
    i7300_idle: struct device - replace bus_id with dev_name(), dev_set_name()
    infiniband: struct device - replace bus_id with dev_name(), dev_set_name()
    ISDN: struct device - replace bus_id with dev_name(), dev_set_name()
    ...

    Linus Torvalds
     
  • Remove excess kernel-doc function parameter notation from i2o/.

    Warning(drivers/message/i2o/iop.c:64): Excess function parameter 'msg' description in 'i2o_msg_get_wait'
    Warning(drivers/message/i2o/device.c:62): Excess function parameter 'drv' description in 'i2o_device_claim'
    Warning(drivers/message/i2o/device.c:95): Excess function parameter 'drv' description in 'i2o_device_claim_release'
    Warning(drivers/message/i2o/driver.c:186): Excess function parameter 'msg' description in 'i2o_driver_dispatch'

    Signed-off-by: Randy Dunlap
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Randy Dunlap
     
  • Signed-off-by: Kay Sievers
    Signed-off-by: Greg Kroah-Hartman

    Kay Sievers
     

06 Jan, 2009

2 commits


03 Jan, 2009

1 commit

  • If the NULL test is necessary, then the dereference should be moved below
    the NULL test.

    The semantic patch that makes this change is as follows:
    (http://www.emn.fr/x-info/coccinelle/).

    //
    @disable is_null@
    identifier f;
    expression E;
    identifier fld;
    statement S;
    @@

    + if (E == NULL) S
    f(...,E->fld,...);
    - if (E == NULL) S

    @@
    identifier f;
    expression E;
    identifier fld;
    statement S;
    @@

    + if (!E) S
    f(...,E->fld,...);
    - if (!E) S
    //

    Signed-off-by: Julia Lawall
    Acked-by: "Prakash, Sathya"
    Signed-off-by: James Bottomley

    Julia Lawall
     

30 Dec, 2008

2 commits

  • ARRAY_SIZE is more concise to use when the size of an array is divided by
    the size of its type or the size of its first element.

    Signed-off-by: Julia Lawall
    Acked-by: "Prakash, Sathya"
    Signed-off-by: James Bottomley

    Julia Lawall
     
  • Remove excess kernel-doc function parameter notation:

    Warning(drivers/message/fusion/mptbase.c:964): Excess function parameter or struct member 'handle' description in 'mpt_free_msg_frame'
    Warning(drivers/message/fusion/mptbase.c:5434): Excess function parameter or struct member 'portnum' description in 'mpt_findImVolumes'
    Warning(drivers/message/fusion/mptbase.c:6949): Excess function parameter or struct member 'mr' description in 'mpt_spi_log_info'

    Signed-off-by: Randy Dunlap
    cc: Eric.Moore@lsi.com
    Signed-off-by: James Bottomley

    Randy Dunlap
     

29 Dec, 2008

1 commit

  • * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next-2.6: (1429 commits)
    net: Allow dependancies of FDDI & Tokenring to be modular.
    igb: Fix build warning when DCA is disabled.
    net: Fix warning fallout from recent NAPI interface changes.
    gro: Fix potential use after free
    sfc: If AN is enabled, always read speed/duplex from the AN advertising bits
    sfc: When disabling the NIC, close the device rather than unregistering it
    sfc: SFT9001: Add cable diagnostics
    sfc: Add support for multiple PHY self-tests
    sfc: Merge top-level functions for self-tests
    sfc: Clean up PHY mode management in loopback self-test
    sfc: Fix unreliable link detection in some loopback modes
    sfc: Generate unique names for per-NIC workqueues
    802.3ad: use standard ethhdr instead of ad_header
    802.3ad: generalize out mac address initializer
    802.3ad: initialize ports LACPDU from const initializer
    802.3ad: remove typedef around ad_system
    802.3ad: turn ports is_individual into a bool
    802.3ad: turn ports is_enabled into a bool
    802.3ad: make ntt bool
    ixgbe: Fix set_ringparam in ixgbe to use the same memory pools.
    ...

    Fixed trivial IPv4/6 address printing conflicts in fs/cifs/connect.c due
    to the conversion to %pI (in this networking merge) and the addition of
    doing IPv6 addresses (from the earlier merge of CIFS).

    Linus Torvalds
     

20 Dec, 2008

1 commit

  • * git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-rc-fixes-2.6:
    [SCSI] mpt fusion: clear list of outstanding commands on host reset
    [SCSI] scsi_lib: only call scsi_unprep_request() under queue lock
    [SCSI] ibmvstgt: move crq_queue_create to the end of initialization
    [SCSI] libiscsi REGRESSION: fix passthrough support with older iscsi tools
    [SCSI] aacraid: disable Dell Percraid quirk on Adaptec 2200S and 2120S

    Linus Torvalds
     

17 Dec, 2008

1 commit

  • A bug in the fusion driver was exposed by the switch to block timeout.
    Basically, drivers are supposed to terminate commands once error
    handling begins on them. The fusion apparently wasn't doing this.
    Under the old timeout regime, completions on terminated commands would
    by and large get ignored because of the way command timeouts used to
    work. The new block timers are very intolerant to this, though,
    becuase the request gets cleaned and freed.

    Fixes: http://bugzilla.kernel.org/show_bug.cgi?id=12195

    Reported-by: Alex Shi
    Tested-by: Ming Lin
    Cc: Eric Moore
    Signed-off-by: James Bottomley

    James Bottomley
     

16 Dec, 2008

1 commit


06 Dec, 2008

2 commits


04 Dec, 2008

1 commit


12 Nov, 2008

1 commit


08 Nov, 2008

1 commit


07 Nov, 2008

1 commit


02 Nov, 2008

1 commit

  • As it is, all instances of ->release() for files that have ->fasync()
    need to remember to evict file from fasync lists; forgetting that
    creates a hole and we actually have a bunch that *does* forget.

    So let's keep our lives simple - let __fput() check FASYNC in
    file->f_flags and call ->fasync() there if it's been set. And lose that
    crap in ->release() instances - leaving it there is still valid, but we
    don't have to bother anymore.

    Signed-off-by: Al Viro
    Signed-off-by: Linus Torvalds

    Al Viro
     

31 Oct, 2008

2 commits

  • Conflicts:

    drivers/net/wireless/p54/p54common.c

    David S. Miller
     
  • Fixup i2o kernel-doc warnings:

    Warning(linux-next-20081022//drivers/message/i2o/i2o_block.c:579): No description found for parameter 'bdev'
    Warning(linux-next-20081022//drivers/message/i2o/i2o_block.c:579): No description found for parameter 'mode'
    Warning(linux-next-20081022//drivers/message/i2o/i2o_block.c:608): No description found for parameter 'disk'
    Warning(linux-next-20081022//drivers/message/i2o/i2o_block.c:608): No description found for parameter 'mode'
    Warning(linux-next-20081022//drivers/message/i2o/i2o_block.c:657): No description found for parameter 'bdev'
    Warning(linux-next-20081022//drivers/message/i2o/i2o_block.c:657): No description found for parameter 'mode'

    Signed-off-by: Randy Dunlap
    Cc: Al Viro
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Randy Dunlap
     

28 Oct, 2008

1 commit

  • A number of places still use %02x:...:%02x because it's
    in debug statements or for no real reason. Make a few
    of them use %pM.

    Signed-off-by: Johannes Berg
    Signed-off-by: David S. Miller

    Johannes Berg
     

24 Oct, 2008

2 commits

  • * git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-misc-2.6: (21 commits)
    [SCSI] sd: fix computation of the full size of the device
    [SCSI] lib: string_get_size(): don't hang on zero; no decimals on exact
    [SCSI] sun3x_esp: Convert && to ||
    [SCSI] sd: remove command-size switching code
    [SCSI] 3w-9xxx: remove unnecessary local_irq_save/restore for scsi sg copy API
    [SCSI] 3w-xxxx: remove unnecessary local_irq_save/restore for scsi sg copy API
    [SCSI] fix netlink kernel-doc
    [SCSI] sd: Fix handling of NO_SENSE check condition
    [SCSI] export busy state via q->lld_busy_fn()
    [SCSI] refactor sdev/starget/shost busy checking
    [SCSI] mptfusion: Increase scsi-timeouts, similariy to the LSI 4.x driver.
    [SCSI] aic7xxx: Take the LED out of diagnostic mode on PM resume
    [SCSI] aic79xx: user visible misuse wrong SI units (not disk size!)
    [SCSI] ipr: use memory_read_from_buffer()
    [SCSI] aic79xx: fix shadowed variables
    [SCSI] aic79xx: fix shadowed variables, add statics
    [SCSI] aic7xxx: update *_shipped files
    [SCSI] aic7xxx: update .reg files
    [SCSI] aic7xxx: introduce "dont_generate_debug_code" keyword in aicasm parser
    [SCSI] scsi_dh: Initialize path state to be passive when path is not owned
    ...

    Linus Torvalds
     
  • Make SPI timeout 10s the same as SAS

    Signed-off-by: Bernd Schubert
    Acked-by: "Prakash, Sathya"
    Signed-off-by: James Bottomley

    Bernd Schubert
     

21 Oct, 2008

2 commits

  • Signed-off-by: Al Viro

    Al Viro
     
  • To keep the size of changesets sane we split the switch by drivers;
    to keep the damn thing bisectable we do the following:
    1) rename the affected methods, add ones with correct
    prototypes, make (few) callers handle both. That's this changeset.
    2) for each driver convert to new methods. *ALL* drivers
    are converted in this series.
    3) kill the old (renamed) methods.

    Note that it _is_ a flagday; all in-tree drivers are converted and by the
    end of this series no trace of old methods remain. The only reason why
    we do that this way is to keep the damn thing bisectable and allow per-driver
    debugging if anything goes wrong.

    New methods:
    open(bdev, mode)
    release(disk, mode)
    ioctl(bdev, mode, cmd, arg) /* Called without BKL */
    compat_ioctl(bdev, mode, cmd, arg)
    locked_ioctl(bdev, mode, cmd, arg) /* Called with BKL, legacy */

    Signed-off-by: Al Viro

    Al Viro
     

17 Oct, 2008

1 commit

  • The I2O ioctls assume 32bits. In itself that is fine as they are old
    cards and nobody uses 64bit. However on LKML it was noted this
    assumption is also made for allocated memory and is unsafe on 64bit
    systems.

    Fixing this is a mess. It turns out there is tons of crap buried in a
    header file that does racy 32/64bit filtering on the masks.

    So we:
    - Verify all callers of the racy code can sleep (i2o_dma_[re]alloc)
    - Move the code into a new i2o/memory.c file
    - Remove the gfp_mask argument so nobody can try and misuse the function
    - Wrap a mutex around the problem area (a single mutex is easy to do and
    none of this is performance relevant)
    - Switch the remaining problem kmalloc holdout to use i2o_dma_alloc

    Cc: Markus Lidel
    Cc: Vasily Averin
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Alan Cox