14 Mar, 2012

2 commits


13 Mar, 2012

38 commits

  • Greg Kroah-Hartman
     
  • commit 134d12fae0bb8f3d60dc7440a9e1950bb5427167 upstream.

    For some weird (freudian?) reason, commit 435792d "ARM: OMAP: make
    iommu subsys_initcall to fix builtin omap3isp" unintentionally changed
    the mailbox's initcall instead of the iommu's.

    Fix that.

    Reported-by: Fernando Guzman Lugo
    Signed-off-by: Ohad Ben-Cohen
    Cc: Laurent Pinchart
    Cc: Joerg Roedel
    Cc: Tony Lindgren
    Signed-off-by: Joerg Roedel
    Signed-off-by: Greg Kroah-Hartman

    Ohad Ben-Cohen
     
  • commit c88db233251b026fda775428f0250c760553e216 upstream.

    Rename static struct pci_driver pch_spi_pcidev to
    pch_spi_pcidev_driver to get rid of warnings from modpost checks.

    Signed-off-by: Danny Kukawka
    Signed-off-by: Grant Likely
    Signed-off-by: Greg Kroah-Hartman

    Danny Kukawka
     
  • commit 97e43c983c721a47546e6db3b7711dcd912a6481 upstream.

    Silence following warnings:
    WARNING: drivers/mfd/cs5535-mfd.o(.data+0x20): Section mismatch in
    reference from the variable cs5535_mfd_drv to the function
    .devinit.text:cs5535_mfd_probe()
    The variable cs5535_mfd_drv references
    the function __devinit cs5535_mfd_probe()
    If the reference is valid then annotate the
    variable with __init* or __refdata (see linux/init.h) or name the variable:
    *driver, *_template, *_timer, *_sht, *_ops, *_probe, *_probe_one, *_console

    WARNING: drivers/mfd/cs5535-mfd.o(.data+0x28): Section mismatch in
    reference from the variable cs5535_mfd_drv to the function
    .devexit.text:cs5535_mfd_remove()
    The variable cs5535_mfd_drv references
    the function __devexit cs5535_mfd_remove()
    If the reference is valid then annotate the
    variable with __exit* (see linux/init.h) or name the variable:
    *driver, *_template, *_timer, *_sht, *_ops, *_probe, *_probe_one, *_console

    Rename the variable from *_drv to *_driver so
    modpost ignore the OK references to __devinit/__devexit
    functions.

    Signed-off-by: Christian Gmeiner
    Acked-by: Andres Salomon
    Signed-off-by: Samuel Ortiz
    Signed-off-by: Greg Kroah-Hartman

    Christian Gmeiner
     
  • commit 474de3bbadd9cb75ffc32cc759c40d868343d46c upstream.

    Fix scan_timers() to be __devinit and not __init since
    the function get called from cs5535_mfgpt_probe which is
    __devinit.

    Signed-off-by: Danny Kukawka
    Signed-off-by: Greg Kroah-Hartman

    Danny Kukawka
     
  • commit 0ca93de9b789e0eb05e103f0c04de72df13da73a upstream.

    Fix dm-raid flush support.

    Both md and dm have support for flush, but the dm-raid target
    forgot to set the flag to indicate that flushes should be
    passed on. (Important for data integrity e.g. with writeback cache
    enabled.)

    Signed-off-by: Jonathan Brassow
    Acked-by: Mike Snitzer
    Signed-off-by: Alasdair G Kergon
    Signed-off-by: Greg Kroah-Hartman

    Jonathan E Brassow
     
  • commit 3aa3b2b2b1edb813dc5342d0108befc39541542d upstream.

    The 'rebuild' parameter is used to rebuild individual devices in an
    array (e.g. resynchronize a RAID1 device or recalculate a parity device
    in higher RAID). The MD_CHANGE_DEVS flag must be set when this
    parameter is given in order to write out the superblocks and make the
    change take immediate effect. The code that handles new devices in
    super_load already sets MD_CHANGE_DEVS and 'FirstUse'. (The 'FirstUse'
    flag was being set as a special case for rebuilds in
    super_init_validation.)

    Add a condition for rebuilds in super_load to take care of both flags
    without the special case in 'super_init_validation'.

    Signed-off-by: Jonathan Brassow
    Signed-off-by: Alasdair G Kergon
    Signed-off-by: Greg Kroah-Hartman

    Jonathan E Brassow
     
  • commit af63bcb817cf708f53bcae6edc2e3fb7dd7d8051 upstream.

    Correct the number of mapped sectors shown on a thin device's
    status line by decrementing td->mapped_blocks in __remove() each time
    a block is removed.

    Signed-off-by: Joe Thornber
    Acked-by: Mike Snitzer
    Signed-off-by: Alasdair G Kergon
    Signed-off-by: Greg Kroah-Hartman

    Joe Thornber
     
  • commit 4469a5f387fdde956894137751a41473618a4a52 upstream.

    If dm_sm_disk_create() fails the superblock must be unlocked.

    Signed-off-by: Joe Thornber
    Acked-by: Mike Snitzer
    Signed-off-by: Alasdair G Kergon
    Signed-off-by: Greg Kroah-Hartman

    Joe Thornber
     
  • commit 1f3db25d8be4ac50b897b39609802183ea68a514 upstream.

    The __open_device() error paths in __create_thin() and __create_snap()
    incorrectly call __close_device() even if td was not initialized by
    __open_device(). Remove this.

    Also document __open_device() return values, remove a redundant
    td->changed = 1 in __create_thin(), and insert an additional
    safeguard against creating an already-existing device.

    Signed-off-by: Mike Snitzer
    Signed-off-by: Alasdair G Kergon
    Signed-off-by: Greg Kroah-Hartman

    Mike Snitzer
     
  • commit 1212268fd9816e3b8801e57b896fceaec71969ad upstream.

    The following BUG is hit on the first read that is submitted to a dm
    flakey test device while the device is "down" if the corrupt_bio_byte
    feature wasn't requested when the device's table was loaded.

    Example DM table that will hit this BUG:
    0 2097152 flakey 8:0 2048 0 30

    This bug was introduced by commit a3998799fb4df0b0af8271a7d50c4269032397aa
    (dm flakey: add corrupt_bio_byte feature) in v3.1-rc1.

    BUG: unable to handle kernel paging request at ffff8801cfce3fff
    IP: [] corrupt_bio_data+0x6e/0xae [dm_flakey]
    PGD 1606063 PUD 0
    Oops: 0002 [#1] SMP
    ...
    Call Trace:

    [] flakey_end_io+0x42/0x48 [dm_flakey]
    [] clone_endio+0x54/0xb6 [dm_mod]
    [] bio_endio+0x2d/0x2f
    [] req_bio_endio+0x96/0x9f
    [] blk_update_request+0x1dc/0x3a9
    [] ? rcu_read_unlock+0x21/0x23
    [] blk_update_bidi_request+0x20/0x6e
    [] blk_end_bidi_request+0x1f/0x5d
    [] blk_end_request+0x10/0x12
    [] scsi_io_completion+0x1e5/0x4b1
    [] scsi_finish_command+0xec/0xf5
    [] scsi_softirq_done+0xff/0x108
    [] blk_done_softirq+0x84/0x98
    [] __do_softirq+0xe3/0x1d5
    [] ? _raw_spin_lock+0x62/0x69
    [] ? handle_irq_event+0x4c/0x61
    [] call_softirq+0x1c/0x30
    [] do_softirq+0x4b/0xa3
    [] irq_exit+0x53/0xca
    [] do_IRQ+0x9d/0xb4
    [] common_interrupt+0x73/0x73
    ...

    Signed-off-by: Mike Snitzer
    Signed-off-by: Alasdair G Kergon
    Signed-off-by: Greg Kroah-Hartman

    Mike Snitzer
     
  • commit 0c535e0d6f463365c29623350dbd91642363c39b upstream.

    This patch fixes a crash by recognising discards in dm_io.

    Currently dm_mirror can send REQ_DISCARD bios if running over a
    discard-enabled device and without support in dm_io the system
    crashes badly.

    BUG: unable to handle kernel paging request at 00800000
    IP: __bio_add_page.part.17+0xf5/0x1e0
    ...
    bio_add_page+0x56/0x70
    dispatch_io+0x1cf/0x240 [dm_mod]
    ? km_get_page+0x50/0x50 [dm_mod]
    ? vm_next_page+0x20/0x20 [dm_mod]
    ? mirror_flush+0x130/0x130 [dm_mirror]
    dm_io+0xdc/0x2b0 [dm_mod]
    ...

    Introduced in 2.6.38-rc1 by commit 5fc2ffeabb9ee0fc0e71ff16b49f34f0ed3d05b4
    (dm raid1: support discard).

    Signed-off-by: Milan Broz
    Acked-by: Mike Snitzer
    Signed-off-by: Alasdair G Kergon
    Signed-off-by: Greg Kroah-Hartman

    Milan Broz
     
  • commit 902c6a96a7cb9c50d2a8aed1788efad0a5d8f04c upstream.

    If 'argc' is zero we jump to the 'out:' label, but this leaks the
    (unused) memory that 'dm_split_args()' allocated for 'argv' if the
    string being split consisted entirely of whitespace. Jump to the
    'out_argv:' label instead to free up that memory.

    Signed-off-by: Jesper Juhl
    Signed-off-by: Alasdair G Kergon
    Signed-off-by: Greg Kroah-Hartman

    Jesper Juhl
     
  • commit 6b7f000eb6a0b81d7a809833edb7a457eedf8512 upstream.

    This function is called from enable_iommus(), which in turn is used
    from amd_iommu_resume().

    Signed-off-by: Jan Beulich
    Signed-off-by: Joerg Roedel
    Signed-off-by: Greg Kroah-Hartman

    Jan Beulich
     
  • commit 4231d47e6fe69f061f96c98c30eaf9fb4c14b96d upstream.

    |kernel BUG at kernel/rtmutex.c:724!
    |[] (rt_spin_lock_slowlock+0x108/0x2bc) from [] (defer_bh+0x1c/0xb4)
    |[] (defer_bh+0x1c/0xb4) from [] (rx_complete+0x14c/0x194)
    |[] (rx_complete+0x14c/0x194) from [] (usb_hcd_giveback_urb+0xa0/0xf0)
    |[] (usb_hcd_giveback_urb+0xa0/0xf0) from [] (musb_giveback+0x34/0x40)
    |[] (musb_giveback+0x34/0x40) from [] (musb_advance_schedule+0xb4/0x1c0)
    |[] (musb_advance_schedule+0xb4/0x1c0) from [] (musb_cleanup_urb.isra.9+0x80/0x8c)
    |[] (musb_cleanup_urb.isra.9+0x80/0x8c) from [] (musb_urb_dequeue+0xec/0x108)
    |[] (musb_urb_dequeue+0xec/0x108) from [] (unlink1+0xbc/0xcc)
    |[] (unlink1+0xbc/0xcc) from [] (usb_hcd_unlink_urb+0x54/0xa8)
    |[] (usb_hcd_unlink_urb+0x54/0xa8) from [] (unlink_urbs.isra.17+0x2c/0x58)
    |[] (unlink_urbs.isra.17+0x2c/0x58) from [] (usbnet_terminate_urbs+0x94/0x10c)
    |[] (usbnet_terminate_urbs+0x94/0x10c) from [] (usbnet_stop+0x100/0x15c)
    |[] (usbnet_stop+0x100/0x15c) from [] (__dev_close_many+0x94/0xc8)

    defer_bh() takes the lock which is hold during unlink_urbs(). The safe
    walk suggest that the skb will be removed from the list and this is done
    by defer_bh() so it seems to be okay to drop the lock here.

    Reported-by: Aníbal Almeida Pinto
    Signed-off-by: Sebastian Andrzej Siewior
    Acked-by: Oliver Neukum
    Signed-off-by: David S. Miller
    Signed-off-by: Greg Kroah-Hartman

    Sebastian Siewior
     
  • commit cf00790dea6f210ddd01a6656da58c7c9a4ea0e4 upstream.

    Mesa may set it to 1, causing all primitives to be killed.

    v2: also update the r7xx code

    Signed-off-by: Marek Olšák
    Reviewed-by: Alex Deucher
    Signed-off-by: Dave Airlie
    Signed-off-by: Greg Kroah-Hartman

    Marek Olšák
     
  • commit 9926a67557532acb6cddb1c1add02952175b5c72 upstream.

    Nicolas Cavallari discovered that carl9170 has some
    serious problems delivering data to sleeping stations.

    It turns out that the driver was not honoring two
    important flags (IEEE80211_TX_CTL_POLL_RESPONSE and
    IEEE80211_TX_CTL_CLEAR_PS_FILT) which are set on
    frames that should be sent although the receiving
    station is still in powersave mode.

    Reported-by: Nicolas Cavallari
    Signed-off-by: Christian Lamparter
    Signed-off-by: John W. Linville
    Signed-off-by: Greg Kroah-Hartman

    Christian Lamparter
     
  • commit 992d52529d7840236d3059b51c15d5eb9e81a869 upstream.

    On Access Point mode, when transmitting a packet, if the destination
    station is in powersave mode, we abort transmitting the packet to the
    device queue, but we do not reclaim the allocated memory. Given enough
    packets, we can go in a state where there is no packet on the device
    queue, but we think the device has no memory left, so no packet gets
    transmitted, connections breaks and the AP stops working.

    This undo the allocation done in the TX path when the station is in
    power-save mode.

    Signed-off-by: Nicolas Cavallari
    Acked-by: Christian Lamparter
    Signed-off-by: John W. Linville
    Signed-off-by: Greg Kroah-Hartman

    Nicolas Cavallari
     
  • commit 7ad6307ad6968ce25cecf209d4822d4c722be030 upstream.

    A global delay parameter has the side effect of being overwritten with 0 if a
    single ZL2004 or ZL6105 is instantiated. If other chips supported by the same
    driver are in the system, this will result in access errors for those chips.

    To solve the problem, keep a per-instance copy of the delay parameter, and do
    not change the original parameter.

    Signed-off-by: Guenter Roeck
    Acked-by: Jean Delvare
    Signed-off-by: Greg Kroah-Hartman

    Guenter Roeck
     
  • commit 1bd612a25855f4cc9345052b53d7da697dba6358 upstream.

    Also update IDT datasheet locations.

    Signed-off-by: Guenter Roeck
    Acked-by: Jean Delvare
    Signed-off-by: Greg Kroah-Hartman

    Guenter Roeck
     
  • commit 4de86126a712ba83fa038d277c8282f7ed466a4b upstream.

    These are fully compatible with Jedec JC 42.4 as far as I can see.

    Signed-off-by: Jean Delvare
    Cc: Guenter Roeck
    Signed-off-by: Guenter Roeck
    Signed-off-by: Greg Kroah-Hartman

    Jean Delvare
     
  • commit 7cb3c44fb1f7999e4c53b6a52de6bc25da6de079 upstream.

    There are up to three POUT alarm attributes, not two, since cap_alarm was added.

    Reported-by: Michele Petracca
    Signed-off-by: Guenter Roeck
    Signed-off-by: Greg Kroah-Hartman

    Guenter Roeck
     
  • commit 99c90ab31fad855b9da9dee3a5aa6c27f263e9d6 upstream.

    ALPS touchpad detection fails if some buttons of ALPS are pressed.
    The reason is that the "E6" query response byte is different from
    what is expected.

    This was tested on a Toshiba Portege R500.

    Signed-off-by: Akio Idehara
    Tested-by: Seth Forshee
    Signed-off-by: Dmitry Torokhov
    Signed-off-by: Greg Kroah-Hartman

    Akio Idehara
     
  • commit affc9a0d59ac49bd304e2137bd5e4ffdd6fdfa52 upstream.

    lirc_serial_probe() must fail if request_irq() returns an error, even if
    it isn't EBUSY or EINVAL,

    Signed-off-by: Ben Hutchings
    Signed-off-by: Mauro Carvalho Chehab
    Signed-off-by: Jonathan Nieder
    Signed-off-by: Greg Kroah-Hartman

    Ben Hutchings
     
  • commit 1ff1d88e862948ae5bfe490248c023ff8ac2855d upstream.

    A resume function cannot remove the device it is resuming!

    Signed-off-by: Ben Hutchings
    Signed-off-by: Mauro Carvalho Chehab
    Signed-off-by: Jonathan Nieder
    Signed-off-by: Greg Kroah-Hartman

    Ben Hutchings
     
  • commit c8e57e1b766c2321aa76ee5e6878c69bd2313d62 upstream.

    Failure to allocate the I/O region leaves the IRQ allocated.
    A later failure leaves them both allocated.

    Reported-by: Torsten Crass
    Signed-off-by: Ben Hutchings
    Signed-off-by: Mauro Carvalho Chehab
    Signed-off-by: Jonathan Nieder
    Signed-off-by: Greg Kroah-Hartman

    Ben Hutchings
     
  • commit 9105b8b200410383d0854bbe237ee385d7d33ba6 upstream.

    Currently the module init function registers a platform_device and
    only then allocates its IRQ and I/O region. This allows allocation to
    race with the device's suspend() function. Instead, allocate
    resources in the platform driver's probe() function and free them in
    the remove() function.

    The module exit function removes the platform device before the
    character device that provides access to it. Change it to reverse the
    order of initialisation.

    Signed-off-by: Ben Hutchings
    Signed-off-by: Mauro Carvalho Chehab
    Signed-off-by: Jonathan Nieder
    Signed-off-by: Greg Kroah-Hartman

    Ben Hutchings
     
  • commit 3f31ae121348afd9ed39700ea2a63c17cd7eeed1 upstream.

    xscale2 PMUs indicate overflow not via the PMU control register, but by
    a separate overflow FLAG register instead.

    This patch fixes the xscale2 PMU code to use this register to detect
    to overflow and ensures that we clear any pending overflow when
    disabling a counter.

    Signed-off-by: Will Deacon
    Signed-off-by: Russell King
    Signed-off-by: Greg Kroah-Hartman

    Will Deacon
     
  • commit f6f5a30c834135c9f2fa10400c59ebbdd9188567 upstream.

    The PMU IRQ handlers in perf assume that if a counter has overflowed
    then perf must be responsible. In the paranoid world of crazy hardware,
    this could be false, so check that we do have a valid event before
    attempting to dereference NULL in the interrupt path.

    Signed-off-by: Ming Lei
    Signed-off-by: Will Deacon
    Signed-off-by: Russell King
    Signed-off-by: Greg Kroah-Hartman

    Will Deacon
     
  • commit 99c1745b9c76910e195889044f914b4898b7c9a5 upstream.

    When disabling a counter on an ARMv7 PMU, we should also clear the
    overflow flag in case an overflow occurred whilst stopping the counter.
    This prevents a spurious overflow being picked up later and leading to
    either false accounting or a NULL dereference.

    Reported-by: Ming Lei
    Signed-off-by: Will Deacon
    Signed-off-by: Russell King
    Signed-off-by: Greg Kroah-Hartman

    Will Deacon
     
  • commit 5727347180ebc6b4a866fcbe00dcb39cc03acb37 upstream.

    On ARM, the PMU does not stop counting after an overflow and therefore
    IRQ latency affects the new counter value read by the kernel. This is
    significant for non-sampling runs where it is possible for the new value
    to overtake the previous one, causing the delta to be out by up to
    max_period events.

    Commit a737823d ("ARM: 6835/1: perf: ensure overflows aren't missed due
    to IRQ latency") attempted to fix this problem by allowing interrupt
    handlers to pass an overflow flag to the event update function, causing
    the overflow calculation to assume that the counter passed through zero
    when going from prev to new. Unfortunately, this doesn't work when
    overflow occurs on the perf_task_tick path because we have the flag
    cleared and end up computing a large negative delta.

    This patch removes the overflow flag from armpmu_event_update and
    instead limits the sample_period to half of the max_period for
    non-sampling profiling runs.

    Signed-off-by: Ming Lei
    Signed-off-by: Will Deacon
    Signed-off-by: Russell King
    Signed-off-by: Greg Kroah-Hartman

    Will Deacon
     
  • commit efbc74ace95338484f8d732037b99c7c77098fce upstream.

    Erratum #743622 affects all r2 variants of the Cortex-A9 processor, so
    ensure that the workaround is applied regardless of the revision.

    Reported-by: Russell King
    Signed-off-by: Will Deacon
    Signed-off-by: Russell King
    Signed-off-by: Greg Kroah-Hartman

    Will Deacon
     
  • commit ca888a7958b3d808e4efd08ceff88913f4212c69 upstream.

    The "OMAPDSS: HDMI: PHY burnout fix" commit switched the HDMI driver
    over to using a GPIO for plug detect. Unfortunately the ->detect()
    method was not also updated, causing HDMI to no longer work for the
    omapdrm driver (because it would actually check if a connection was
    detected before attempting to enable display).

    Signed-off-by: Rob Clark
    Signed-off-by: Tomi Valkeinen
    Signed-off-by: Greg Kroah-Hartman

    Rob Clark
     
  • commit c49d005b6cc8491fad5b24f82805be2d6bcbd3dd upstream.

    A hardware bug in the OMAP4 HDMI PHY causes physical damage to the board
    if the HDMI PHY is kept powered on when the cable is not connected.

    This patch solves the problem by adding hot-plug-detection into the HDMI
    IP driver. This is not a real HPD support in the sense that nobody else
    than the IP driver gets to know about the HPD events, but is only meant
    to fix the HW bug.

    The strategy is simple: If the display device is turned off by the user,
    the PHY power is set to OFF. When the display device is turned on by the
    user, the PHY power is set either to LDOON or TXON, depending on whether
    the HDMI cable is connected.

    The reason to avoid PHY OFF when the display device is on, but the cable
    is disconnected, is that when the PHY is turned OFF, the HDMI IP is not
    "ticking" and thus the DISPC does not receive pixel clock from the HDMI
    IP. This would, for example, prevent any VSYNCs from happening, and
    would thus affect the users of omapdss. By using LDOON when the cable is
    disconnected we'll avoid the HW bug, but keep the HDMI working as usual
    from the user's point of view.

    Signed-off-by: Tomi Valkeinen
    Signed-off-by: Greg Kroah-Hartman

    Tomi Valkeinen
     
  • commit aa74274b464d4aa24703963ac89a0ee942d5d267 upstream.

    Both Panda and 4430SDP use GPIO 63 as HDMI hot-plug-detect. Configure
    this GPIO in the board files.

    Signed-off-by: Tomi Valkeinen
    Acked-by: Tony Lindgren
    Signed-off-by: Greg Kroah-Hartman

    Tomi Valkeinen
     
  • commit 78a1ad8f12db70b8b0a4548b90704de08ee216ce upstream.

    The HDMI GPIO pins LS_OE and CT_CP_HPD are not currently configured.
    This patch configures them as output pins.

    Signed-off-by: Tomi Valkeinen
    Acked-by: Tony Lindgren
    Signed-off-by: Greg Kroah-Hartman

    Tomi Valkeinen
     
  • commit 7bb122d155f742fe2d79849090c825be7b4a247e upstream.

    "hdmi_hpd" pin is muxed to INPUT and PULLUP, but the pin is not
    currently used, and in the future when it is used, the pin is used as a
    GPIO and is board specific, not an OMAP4 wide thing.

    So remove the muxing for now.

    Signed-off-by: Tomi Valkeinen
    Acked-by: Tony Lindgren
    Signed-off-by: Greg Kroah-Hartman

    Tomi Valkeinen
     
  • commit 3932a32fcf5393f8be70ac99dc718ad7ad0a415b upstream.

    The GPIO 60 on 4430sdp and Panda is not HPD GPIO, as currently marked in
    the board files, but CT_CP_HPD, which is used to enable/disable HPD
    functionality.

    This patch renames the GPIO.

    Signed-off-by: Tomi Valkeinen
    Acked-by: Tony Lindgren
    Signed-off-by: Greg Kroah-Hartman

    Tomi Valkeinen