Skip to content


Subversion checkout URL

You can clone with
Download ZIP
Commits on Jun 22, 2012
  1. @gregkh

    Linux 3.0.36

    gregkh authored
  2. @zonque @gregkh

    USB: fix gathering of interface associations

    zonque authored gregkh committed
    commit b3a3dd0 upstream.
    TEAC's UD-H01 (and probably other devices) have a gap in the interface
    number allocation of their descriptors:
      Configuration Descriptor:
        bLength                 9
        bDescriptorType         2
        wTotalLength          220
        bNumInterfaces          3
        Interface Descriptor:
          bLength                 9
          bDescriptorType         4
          bInterfaceNumber        0
          bAlternateSetting       0
        Interface Association:
          bLength                 8
          bDescriptorType        11
          bFirstInterface         2
          bInterfaceCount         2
          bFunctionClass          1 Audio
          bFunctionSubClass       0
          bFunctionProtocol      32
          iFunction               4
        Interface Descriptor:
          bLength                 9
          bDescriptorType         4
          bInterfaceNumber        2
          bAlternateSetting       0
    Once a configuration is selected, usb_set_configuration() walks the
    known interfaces of a given configuration and calls find_iad() on
    each of them to set the interface association pointer the interface
    is included in.
    The problem here is that the loop variable is taken for the interface
    number in the comparison logic that gathers the association. Which is
    fine as long as the descriptors are sane.
    In the case above, however, the logic gets out of sync and the
    interface association fields of all interfaces beyond the interface
    number gap are wrong.
    Fix this by passing the interface's bInterfaceNumber to find_iad()
    Signed-off-by: Daniel Mack <>
    Reported-by: bEN <>
    Reported-by: Ivan Perrone <>
    Tested-by: ivan perrone <>
    Signed-off-by: Greg Kroah-Hartman <>
  3. @bmork @gregkh

    USB: serial: Enforce USB driver and USB serial driver match

    bmork authored gregkh committed
    commit 954c3f8 upstream.
    We need to make sure that the USB serial driver we find
    matches the USB driver whose probe we are currently
    executing. Otherwise we will end up with USB serial
    devices bound to the correct serial driver but wrong
    USB driver.
    An example of such cross-probing, where the usbserial_generic
    USB driver has found the sierra serial driver:
    May 29 18:26:15 nemi kernel: [ 4442.559246] usbserial_generic 4-4:1.0: Sierra USB modem converter detected
    May 29 18:26:20 nemi kernel: [ 4447.556747] usbserial_generic 4-4:1.2: Sierra USB modem converter detected
    May 29 18:26:25 nemi kernel: [ 4452.557288] usbserial_generic 4-4:1.3: Sierra USB modem converter detected
    sysfs view of the same problem:
    bjorn@nemi:~$ ls -l /sys/bus/usb/drivers/sierra/
    total 0
    --w------- 1 root root 4096 May 29 18:23 bind
    lrwxrwxrwx 1 root root    0 May 29 18:23 module -> ../../../../module/usbserial
    --w------- 1 root root 4096 May 29 18:23 uevent
    --w------- 1 root root 4096 May 29 18:23 unbind
    bjorn@nemi:~$ ls -l /sys/bus/usb-serial/drivers/sierra/
    total 0
    --w------- 1 root root 4096 May 29 18:23 bind
    lrwxrwxrwx 1 root root    0 May 29 18:23 module -> ../../../../module/sierra
    -rw-r--r-- 1 root root 4096 May 29 18:23 new_id
    lrwxrwxrwx 1 root root    0 May 29 18:32 ttyUSB0 -> ../../../../devices/pci0000:00/0000:00:1d.7/usb4/4-4/4-4:1.0/ttyUSB0
    lrwxrwxrwx 1 root root    0 May 29 18:32 ttyUSB1 -> ../../../../devices/pci0000:00/0000:00:1d.7/usb4/4-4/4-4:1.2/ttyUSB1
    lrwxrwxrwx 1 root root    0 May 29 18:32 ttyUSB2 -> ../../../../devices/pci0000:00/0000:00:1d.7/usb4/4-4/4-4:1.3/ttyUSB2
    --w------- 1 root root 4096 May 29 18:23 uevent
    --w------- 1 root root 4096 May 29 18:23 unbind
    bjorn@nemi:~$ ls -l /sys/bus/usb/drivers/usbserial_generic/
    total 0
    lrwxrwxrwx 1 root root    0 May 29 18:33 4-4:1.0 -> ../../../../devices/pci0000:00/0000:00:1d.7/usb4/4-4/4-4:1.0
    lrwxrwxrwx 1 root root    0 May 29 18:33 4-4:1.2 -> ../../../../devices/pci0000:00/0000:00:1d.7/usb4/4-4/4-4:1.2
    lrwxrwxrwx 1 root root    0 May 29 18:33 4-4:1.3 -> ../../../../devices/pci0000:00/0000:00:1d.7/usb4/4-4/4-4:1.3
    --w------- 1 root root 4096 May 29 18:33 bind
    lrwxrwxrwx 1 root root    0 May 29 18:33 module -> ../../../../module/usbserial
    --w------- 1 root root 4096 May 29 18:22 uevent
    --w------- 1 root root 4096 May 29 18:33 unbind
    bjorn@nemi:~$ ls -l /sys/bus/usb-serial/drivers/generic/
    total 0
    --w------- 1 root root 4096 May 29 18:33 bind
    lrwxrwxrwx 1 root root    0 May 29 18:33 module -> ../../../../module/usbserial
    -rw-r--r-- 1 root root 4096 May 29 18:33 new_id
    --w------- 1 root root 4096 May 29 18:22 uevent
    --w------- 1 root root 4096 May 29 18:33 unbind
    So we end up with a mismatch between the USB driver and the
    USB serial driver.  The reason for the above is simple: The
    USB driver probe will succeed if *any* registered serial
    driver matches, and will use that serial driver for all
    serial driver functions.
    This makes ref counting go wrong. We count the USB driver
    as used, but not the USB serial driver.  This may result
    in Oops'es as demonstrated by Johan Hovold <>:
    [11811.646396] drivers/usb/serial/usb-serial.c: get_free_serial 1
    [11811.646443] drivers/usb/serial/usb-serial.c: get_free_serial - minor base = 0
    [11811.646460] drivers/usb/serial/usb-serial.c: usb_serial_probe - registering ttyUSB0
    [11811.646766] usb 6-1: pl2303 converter now attached to ttyUSB0
    [11812.264197] USB Serial deregistering driver FTDI USB Serial Device
    [11812.264865] usbcore: deregistering interface driver ftdi_sio
    [11812.282180] USB Serial deregistering driver pl2303
    [11812.283141] pl2303 ttyUSB0: pl2303 converter now disconnected from ttyUSB0
    [11812.283272] usbcore: deregistering interface driver pl2303
    [11812.301056] USB Serial deregistering driver generic
    [11812.301186] usbcore: deregistering interface driver usbserial_generic
    [11812.301259] drivers/usb/serial/usb-serial.c: usb_serial_disconnect
    [11812.301823] BUG: unable to handle kernel paging request at f8e7438c
    [11812.301845] IP: [<f8e38445>] usb_serial_disconnect+0xb5/0x100 [usbserial]
    [11812.301871] *pde = 357ef067 *pte = 00000000
    [11812.301957] Oops: 0000 [#1] PREEMPT SMP
    [11812.301983] Modules linked in: usbserial(-) [last unloaded: pl2303]
    [11812.302019] Pid: 1323, comm: modprobe Tainted: G        W    3.4.0-rc7+ #101 Dell Inc. Vostro 1520/0T816J
    [11812.302115] EIP: 0060:[<f8e38445>] EFLAGS: 00010246 CPU: 1
    [11812.302130] EIP is at usb_serial_disconnect+0xb5/0x100 [usbserial]
    [11812.302141] EAX: f508a180 EBX: f508a180 ECX: 00000000 EDX: f8e74300
    [11812.302151] ESI: f5050800 EDI: 00000001 EBP: f5141e78 ESP: f5141e58
    [11812.302160]  DS: 007b ES: 007b FS: 00d8 GS: 0033 SS: 0068
    [11812.302170] CR0: 8005003b CR2: f8e7438c CR3: 34848000 CR4: 000007d0
    [11812.302180] DR0: 00000000 DR1: 00000000 DR2: 00000000 DR3: 00000000
    [11812.302189] DR6: ffff0ff0 DR7: 00000400
    [11812.302199] Process modprobe (pid: 1323, ti=f5140000 task=f61e2bc0 task.ti=f5140000)
    [11812.302209] Stack:
    [11812.302216]  f8e3be0f f8e3b29c f8e3ae00 00000000 f513641c f5136400 f513641c f507a540
    [11812.302325]  f5141e98 c133d2c1 00000000 00000000 f509c400 f513641c f507a590 f5136450
    [11812.302372]  f5141ea8 c12f0344 f513641c f507a590 f5141ebc c12f0c67 00000000 f507a590
    [11812.302419] Call Trace:
    [11812.302439]  [<c133d2c1>] usb_unbind_interface+0x51/0x190
    [11812.302456]  [<c12f0344>] __device_release_driver+0x64/0xb0
    [11812.302469]  [<c12f0c67>] driver_detach+0x97/0xa0
    [11812.302483]  [<c12f001c>] bus_remove_driver+0x6c/0xe0
    [11812.302500]  [<c145938d>] ? __mutex_unlock_slowpath+0xcd/0x140
    [11812.302514]  [<c12f0ff9>] driver_unregister+0x49/0x80
    [11812.302528]  [<c1457df6>] ? printk+0x1d/0x1f
    [11812.302540]  [<c133c50d>] usb_deregister+0x5d/0xb0
    [11812.302557]  [<f8e37c55>] ? usb_serial_deregister+0x45/0x50 [usbserial]
    [11812.302575]  [<f8e37c8d>] usb_serial_deregister_drivers+0x2d/0x40 [usbserial]
    [11812.302593]  [<f8e3a6e2>] usb_serial_generic_deregister+0x12/0x20 [usbserial]
    [11812.302611]  [<f8e3acf0>] usb_serial_exit+0x8/0x32 [usbserial]
    [11812.302716]  [<c1080b48>] sys_delete_module+0x158/0x260
    [11812.302730]  [<c110594e>] ? mntput+0x1e/0x30
    [11812.302746]  [<c145c3c3>] ? sysenter_exit+0xf/0x18
    [11812.302746]  [<c107777c>] ? trace_hardirqs_on_caller+0xec/0x170
    [11812.302746]  [<c145c390>] sysenter_do_call+0x12/0x36
    [11812.302746] Code: 24 02 00 00 e8 dd f3 20 c8 f6 86 74 02 00 00 02 74 b4 8d 86 4c 02 00 00 47 e8 78 55 4b c8 0f b6 43 0e 39 f8 7f a9 8b 53 04 89 d8 <ff> 92 8c 00 00 00 89 d8 e8 0e ff ff ff 8b 45 f0 c7 44 24 04 2f
    [11812.302746] EIP: [<f8e38445>] usb_serial_disconnect+0xb5/0x100 [usbserial] SS:ESP 0068:f5141e58
    [11812.302746] CR2: 00000000f8e7438c
    Fix by only evaluating serial drivers pointing back to the
    USB driver we are currently probing.  This still allows two
    or more drivers to match the same device, running their
    serial driver probes to sort out which one to use.
    Signed-off-by: Bjørn Mork <>
    Reviewed-by: Felipe Balbi <>
    Tested-by: Johan Hovold <>
    Signed-off-by: Greg Kroah-Hartman <>
  4. @tomascassidy @gregkh

    USB: serial: sierra: Add support for Sierra Wireless AirCard 320U modem

    tomascassidy authored gregkh committed
    commit 19a3dd1 upstream.
    Add support for Sierra Wireless AirCard 320U modem
    Signed-off-by: Tomas Cassidy <>
    Signed-off-by: Greg Kroah-Hartman <>
  5. @gregkh

    usb: cdc-acm: fix devices not unthrottled on open

    Otto Meta authored gregkh committed
    commit 6c4707f upstream.
    Currently CDC-ACM devices stay throttled when their TTY is closed while
    throttled, stalling further communication attempts after the next open.
    Unthrottling during open/activate got lost starting with kernel
    3.0.0 and this patch reintroduces it.
    Signed-off-by: Otto Meta <>
    Acked-by: Johan Hovold <>
    Signed-off-by: Greg Kroah-Hartman <>
  6. @gregkh

    USB: add NO_D3_DURING_SLEEP flag and revert 151b612

    Alan Stern authored gregkh committed
    commit c2fb8a3 upstream.
    This patch (as1558) fixes a problem affecting several ASUS computers:
    The machine crashes or corrupts memory when going into suspend if the
    ehci-hcd driver is bound to any controllers.  Users have been forced
    to unbind or unload ehci-hcd before putting their systems to sleep.
    After extensive testing, it was determined that the machines don't
    like going into suspend when any EHCI controllers are in the PCI D3
    power state.  Presumably this is a firmware bug, but there's nothing
    we can do about it except to avoid putting the controllers in D3
    during system sleep.
    The patch adds a new flag to indicate whether the problem is present,
    and avoids changing the controller's power state if the flag is set.
    Runtime suspend is unaffected; this matters only for system suspend.
    However as a side effect, the controller will not respond to remote
    wakeup requests while the system is asleep.  Hence USB wakeup is not
    functional -- but of course, this is already true in the current state
    of affairs.
    A similar patch has already been applied as commit
    151b612 (USB: EHCI: fix crash during
    suspend on ASUS computers).  The patch supersedes that one and reverts
    it.  There are two differences:
    	The old patch added the flag at the USB level; this patch
    	adds it at the PCI level.
    	The old patch applied to all chipsets with the same vendor,
    	subsystem vendor, and product IDs; this patch makes an
    	exception for a known-good system (based on DMI information).
    Signed-off-by: Alan Stern <>
    Tested-by: Dâniel Fraga <>
    Tested-by: Andrey Rahmatullin <>
    Tested-by: Steven Rostedt <>
    Reviewed-by: Rafael J. Wysocki <>
    Signed-off-by: Greg Kroah-Hartman <>
  7. @gregkh

    USB: ftdi-sio: Add support for RT Systems USB-RTS01 serial adapter

    Evan McNabb authored gregkh committed
    commit e00a54d upstream.
    Add support for RT Systems USB-RTS01 USB to Serial adapter:
    Tested by controlling Icom IC-718 amateur radio transceiver via hamlib.
    Signed-off-by: Evan McNabb <>
    Signed-off-by: Greg Kroah-Hartman <>
  8. @gregkh

    USB: serial: cp210x: add Optris MS Pro usb id

    Mikko Tuumanen authored gregkh committed
    commit 5bbfa6f upstream.
    Signed-off-by: Mikko Tuumanen <>
    Signed-off-by: Greg Kroah-Hartman <>
  9. @gregkh

    USB: mct_u232: Fix incorrect TIOCMSET return

    Alan Cox authored gregkh committed
    commit 1aa3c63 upstream.
    The low level helper returns 1 on success. The ioctl should however return
    0. As this is the only user of the helper return, make the helper return 0 or
    an error code.
    Signed-off-by: Alan Cox <>
    Signed-off-by: Greg Kroah-Hartman <>
  10. @bmork @gregkh

    USB: qcserial: Add Sierra Wireless device IDs

    bmork authored gregkh committed
    commit c41444c upstream.
    Some additional IDs found in the BSD/GPL licensed out-of-tree
    GobiSerial driver from Sierra Wireless.
    Signed-off-by: Bjørn Mork <>
    Signed-off-by: Greg Kroah-Hartman <>
  11. @gregkh

    USB: mos7840: Fix compilation of usb serial driver

    Tony Zelenoff authored gregkh committed
    commit b9c8766 upstream.
    The __devinitconst section can't be referenced
    from usb_serial_device structure. Thus removed it as
    it done in other mos* device drivers.
    Error itself:
    WARNING: drivers/usb/serial/mos7840.o(.data+0x8): Section mismatch in reference
    from the variable moschip7840_4port_device to the variable
    The variable moschip7840_4port_device references
    the variable __devinitconst id_table
    [v2] no attach now
    Signed-off-by: Tony Zelenoff <>
    Signed-off-by: Greg Kroah-Hartman <>
  12. @Andiry @gregkh

    xHCI: Increase the timeout for controller save/restore state operation

    Andiry authored gregkh committed
    commit 622eb78 upstream.
    When system software decides to power down the xHC with the intent of
    resuming operation at a later time, it will ask xHC to save the internal
    state and restore it when resume to correctly recover from a power event.
    Two bits are used to enable this operation: Save State and Restore State.
    xHCI spec 4.23.2 says software should "Set the Controller Save/Restore
    State flag in the USBCMD register and wait for the Save/Restore State
    Status flag in the USBSTS register to transition to '0'". However, it does
    not define how long software should wait for the SSS/RSS bit to transition
    to 0.
    Currently the timeout is set to 1ms. There is bug report
    indicates that the timeout is too short for ASMedia ASM1042 host controller
    to save/restore the state successfully. Increase the timeout to 10ms helps to
    resolve the issue.
    This patch should be backported to stable kernels as old as 2.6.37, that
    contain the commit 5535b1d "USB: xHCI:
    PCI power management implementation"
    Signed-off-by: Andiry Xu <>
    Signed-off-by: Sarah Sharp <>
    Cc: Ming Lei <>
    Signed-off-by: Greg Kroah-Hartman <>
  13. @gregkh

    hfsplus: fix overflow in sector calculations in hfsplus_submit_bio

    Janne Kalliomäki authored gregkh committed
    commit a6dc8c0 upstream.
    The variable io_size was unsigned int, which caused the wrong sector number
    to be calculated after aligning it. This then caused mount to fail with big
    volumes, as backup volume header information was searched from a
    wrong sector.
    Signed-off-by: Janne Kalliomäki <>
    Signed-off-by: Christoph Hellwig <>
    Signed-off-by: Linus Torvalds <>
    Signed-off-by: Greg Kroah-Hartman <>
  14. @jhovold @gregkh

    USB: option: fix port-data abuse

    jhovold authored gregkh committed
    commit 4273f98 upstream.
    Commit 8b4c6a3 ("USB: option: Use generic USB wwan code")
    moved option port-data allocation to usb_wwan_startup but still cast the
    port data to the old struct...
    Signed-off-by: Johan Hovold <>
    Signed-off-by: Greg Kroah-Hartman <>
  15. @jhovold @gregkh

    USB: option: fix memory leak

    jhovold authored gregkh committed
    commit b9c3aab upstream.
    Fix memory leak introduced by commit 383cedc ("USB: serial:
    full autosuspend support for the option driver") which allocates
    usb-serial data but never frees it.
    Signed-off-by: Johan Hovold <>
    Signed-off-by: Greg Kroah-Hartman <>
  16. @gregkh

    USB: option: add more YUGA device ids

    说不得 authored gregkh committed
    commit 0ef0be1 upstream.
    Signed-off-by: gavin zhu <>
    Signed-off-by: Greg Kroah-Hartman <>
  17. @andrewbird @gregkh

    USB: option: Updated Huawei K4605 has better id

    andrewbird authored gregkh committed
    commit 42ca7da upstream.
    Later firmwares for this device now have proper subclass and
    protocol info so we can identify it nicely without needing to use
    the blacklist. I'm not removing the old 0xff matching as there
    may be devices in the field that still need that.
    Signed-off-by: Andrew Bird <>
    Signed-off-by: Greg Kroah-Hartman <>
  18. @bmork @gregkh

    USB: option: Add Vodafone/Huawei K5005 support

    bmork authored gregkh committed
    commit 4cbbb03 upstream.
    Tested-by: Thomas Schäfer <>
    Signed-off-by: Bjørn Mork <>
    Signed-off-by: Greg Kroah-Hartman <>
  19. @gregkh

    NFSv4.1: Fix a request leak on the back channel

    Trond Myklebust authored gregkh committed
    commit b3b02ae upstream.
    If the call to svc_process_common() fails, then the request
    needs to be freed before we can exit bc_svc_process.
    Signed-off-by: Trond Myklebust <>
    Signed-off-by: Greg Kroah-Hartman <>
  20. @aprzywar @gregkh

    xen/setup: filter APERFMPERF cpuid feature out

    aprzywar authored gregkh committed
    commit 5e62625 upstream.
    Xen PV kernels allow access to the APERF/MPERF registers to read the
    effective frequency. Access to the MSRs is however redirected to the
    currently scheduled physical CPU, making consecutive read and
    compares unreliable. In addition each rdmsr traps into the hypervisor.
    So to avoid bogus readouts and expensive traps, disable the kernel
    internal feature flag for APERF/MPERF if running under Xen.
    This will
    a) remove the aperfmperf flag from /proc/cpuinfo
    b) not mislead the power scheduler (arch/x86/kernel/cpu/sched.c) to
       use the feature to improve scheduling (by default disabled)
    c) not mislead the cpufreq driver to use the MSRs
    This does not cover userland programs which access the MSRs via the
    device file interface, but this will be addressed separately.
    Signed-off-by: Andre Przywara <>
    Signed-off-by: Konrad Rzeszutek Wilk <>
    Signed-off-by: Greg Kroah-Hartman <>
  21. @gregkh

    ARM i.MX imx21ads: Fix overlapping static i/o mappings

    Jaccon Bastiaansen authored gregkh committed
    commit 350ab15 upstream.
    The statically defined I/O memory regions for the i.MX21 on chip
    peripherals and the on board I/O peripherals of the i.MX21ADS board
    overlap. This results in a kernel crash during startup. This is fixed
    by reducing the memory range for the on board I/O peripherals to the
    actually required range.
    Signed-off-by: Jaccon Bastiaansen <>
    Signed-off-by: Sascha Hauer <>
    Signed-off-by: Greg Kroah-Hartman <>
Commits on Jun 17, 2012
  1. @gregkh

    Linux 3.0.35

    gregkh authored
  2. @gregkh

    hugetlb: fix resv_map leak in error path

    Dave Hansen authored gregkh committed
    commit c50ac05 and
    4523e14 upstream.
    When called for anonymous (non-shared) mappings, hugetlb_reserve_pages()
    does a resv_map_alloc().  It depends on code in hugetlbfs's
    vm_ops->close() to release that allocation.
    However, in the mmap() failure path, we do a plain unmap_region() without
    the remove_vma() which actually calls vm_ops->close().
    This is a decent fix.  This leak could get reintroduced if new code (say,
    after hugetlb_reserve_pages() in hugetlbfs_file_mmap()) decides to return
    an error.  But, I think it would have to unroll the reservation anyway.
    Christoph's test case:

    This patch applies to 3.4 and later.  A version for earlier kernels is at
    Signed-off-by: Dave Hansen <>
    Acked-by: Mel Gorman <>
    Acked-by: KOSAKI Motohiro <>
    Reported-by: Christoph Lameter <>
    Tested-by: Christoph Lameter <>
    Cc: Andrea Arcangeli <>
    Signed-off-by: Andrew Morton <>
    Signed-off-by: Linus Torvalds <>
    Signed-off-by: Greg Kroah-Hartman <>
  3. @gregkh

    mm: fix faulty initialization in vmalloc_init()

    KyongHo authored gregkh committed
    commit dbda591 upstream.
    The transfer of ->flags causes some of the static mapping virtual
    addresses to be prematurely freed (before the mapping is removed) because
    VM_LAZY_FREE gets "set" if tmp->flags has VM_IOREMAP set.  This might
    cause subsequent vmalloc/ioremap calls to fail because it might allocate
    one of the freed virtual address ranges that aren't unmapped.
    va->flags has different types of flags from tmp->flags.  If a region with
    VM_IOREMAP set is registered with vm_area_add_early(), it will be removed
    by __purge_vmap_area_lazy().
    Fix vmalloc_init() to correctly initialize vmap_area for the given
    Also initialise va->vm.  If it is not set, find_vm_area() for the early
    vm regions will always fail.
    Signed-off-by: KyongHo Cho <>
    Cc: "Olav Haugan" <>
    Signed-off-by: Andrew Morton <>
    Signed-off-by: Linus Torvalds <>
    Signed-off-by: Greg Kroah-Hartman <>
  4. @minchank @gregkh

    mm/vmalloc.c: change void* into explict vm_struct*

    minchank authored gregkh committed
    commit db1aeca upstream.
    vmap_area->private is void* but we don't use the field for various purpose
    but use only for vm_struct.  So change it to a vm_struct* with naming to
    improve for readability and type checking.
    Signed-off-by: Minchan Kim <>
    Acked-by: David Rientjes <>
    Signed-off-by: Andrew Morton <>
    Signed-off-by: Linus Torvalds <>
    Signed-off-by: Greg Kroah-Hartman <>
  5. @gregkh

    e1000: save skb counts in TX to avoid cache misses

    Dean Nelson authored gregkh committed
    commit 31c15a2 upstream.
    Virtual Machines with emulated e1000 network adapter running on Parallels'
    server were seeing kernel panics due to the e1000 driver dereferencing an
    unexpected NULL pointer retrieved from buffer_info->skb.
    The problem has been addressed for the e1000e driver, but not for the e1000.
    Since the two drivers share similar code in the affected area, a port of the
    following e1000e driver commit solves the issue for the e1000 driver:
    commit 9ed318d
    Author: Tom Herbert <>
    Date:   Wed May 5 14:02:27 2010 +0000
        e1000e: save skb counts in TX to avoid cache misses
        In e1000_tx_map, precompute number of segements and bytecounts which
        are derived from fields in skb; these are stored in buffer_info.  When
        cleaning tx in e1000_clean_tx_irq use the values in the associated
        buffer_info for statistics counting, this eliminates cache misses
        on skb fields.
    Signed-off-by: Dean Nelson <>
    Acked-by: Jeff Kirsher <>
    Signed-off-by: David S. Miller <>
    Signed-off-by: Roman Kagan <>
  6. @gregkh

    fuse: fix stat call on 32 bit platforms

    Pavel Shilovsky authored gregkh committed
    commit 45c72cd upstream.
    Now we store attr->ino at inode->i_ino, return attr->ino at the
    first time and then return inode->i_ino if the attribute timeout
    isn't expired. That's wrong on 32 bit platforms because attr->ino
    is 64 bit and inode->i_ino is 32 bit in this case.
    Fix this by saving 64 bit ino in fuse_inode structure and returning
    it every time we call getattr. Also squash attr->ino into inode->i_ino
    Signed-off-by: Pavel Shilovsky <>
    Signed-off-by: Miklos Szeredi <>
    Signed-off-by: Greg Kroah-Hartman <>
  7. @gregkh

    x86, MCE, AMD: Make APIC LVT thresholding interrupt optional

    Borislav Petkov authored gregkh committed
    commit f227d43 upstream.
    Currently, the APIC LVT interrupt for error thresholding is implicitly
    enabled. However, there are models in the F15h range which do not enable
    it. Make the code machinery which sets up the APIC interrupt support
    an optional setting and add an ->interrupt_capable member to the bank
    representation mirroring that capability and enable the interrupt offset
    programming only if it is true.
    Simplify code and fixup comment style while at it.
    Signed-off-by: Borislav Petkov <>
    Signed-off-by: Robert Richter <>
  8. @gregkh

    iwlwifi: don't mess up the SCD when removing a key

    Emmanuel Grumbach authored gregkh committed
    commit d6ee27e upstream.
    When we remove a key, we put a key index which was supposed
    to tell the fw that we are actually removing the key. But
    instead the fw took that index as a valid index and messed
    up the SRAM of the device.
    This memory corruption on the device mangled the data of
    the SCD. The impact on the user is that SCD queue 2 got
    stuck after having removed keys.
    The message is the log that was printed is:
    Queue 2 stuck for 10000ms
    This doesn't seem to fix the higher queues that get stuck
    from time to time.
    Reviewed-by: Meenakshi Venkataraman <>
    Signed-off-by: Emmanuel Grumbach <>
    Signed-off-by: Johannes Berg <>
    Signed-off-by: John W. Linville <>
    Signed-off-by: Greg Kroah-Hartman <>
  9. @gregkh

    sched: Fix the relax_domain_level boot parameter

    Dimitri Sivanich authored gregkh committed
    commit a841f8c upstream.
    It does not get processed because sched_domain_level_max is 0 at the
    time that setup_relax_domain_level() is run.
    Simply accept the value as it is, as we don't know the value of
    sched_domain_level_max until sched domain construction is completed.
    Fix sched_relax_domain_level in cpuset.  The build_sched_domain() routine calls
    the set_domain_attribute() routine prior to setting the sd->level, however,
    the set_domain_attribute() routine relies on the sd->level to decide whether
    idle load balancing will be off/on.
    Signed-off-by: Dimitri Sivanich <>
    Signed-off-by: Peter Zijlstra <>
    Signed-off-by: Ingo Molnar <>
    Signed-off-by: Greg Kroah-Hartman <>
  10. @gregkh

    acpi_video: fix leaking PCI references

    Alan Cox authored gregkh committed
    commit cfb46f4 upstream.
    Signed-off-by: Alan Cox <>
    Acked-by: Matthew Garrett <>
    Signed-off-by: Len Brown <>
    Signed-off-by: Greg Kroah-Hartman <>
  11. @aprzywar @gregkh

    hwmon: (fam15h_power) Increase output resolution

    aprzywar authored gregkh committed
    commit 941a956 upstream.
    On high CPU load the accumulating values in the running_avg_cap
    register are very low (below 10), so averaging them too early leads
    to unnecessary poor output resolution. Since we pretend to output
    micro-Watt we better keep all the bits we have as long as possible.
    Signed-off-by: Andre Przywara <>
    Signed-off-by: Andreas Herrmann <>
    Acked-by: Guenter Roeck <>
    Signed-off-by: Jean Delvare <>
    Signed-off-by: Tim Gardner <>
    Signed-off-by: Greg Kroah-Hartman <>
  12. @AnilKumarCh @gregkh

    can: c_can: fix race condition in c_can_open()

    AnilKumarCh authored gregkh committed
    commit f461f27 upstream.
    Fix the issue of C_CAN interrupts getting disabled forever when canconfig
    utility is used multiple times. According to NAPI usage we disable all
    the hardware interrupts in ISR and re-enable them in poll(). Current
    implementation calls napi_enable() after hardware interrupts are enabled.
    If we get any interrupts between these two steps then we do not process
    those interrupts because napi is not enabled. Mostly these interrupts
    come because of STATUS is not 0x7 or ERROR interrupts. If napi_enable()
    happens before HW interrupts enabled then c_can_poll() function will be
    called eventual re-enabling.
    This patch moves the napi_enable() call before interrupts enabled.
    Signed-off-by: AnilKumar Ch <>
    Acked-by: Wolfgang Grandegger <>
    Signed-off-by: Marc Kleine-Budde <>
    Signed-off-by: Greg Kroah-Hartman <>
  13. @AnilKumarCh @gregkh

    can: c_can: fix an interrupt thrash issue with c_can driver

    AnilKumarCh authored gregkh committed
    commit 148c87c upstream.
    This patch fixes an interrupt thrash issue with c_can driver.
    In c_can_isr() function interrupts are disabled and enabled only in
    c_can_poll() function. c_can_isr() & c_can_poll() both read the
    irqstatus flag. However, irqstatus is always read as 0 in c_can_poll()
    because all C_CAN interrupts are disabled in c_can_isr(). This causes
    all interrupts to be re-enabled in c_can_poll() which in turn causes
    another interrupt since the event is not really handled. This keeps
    happening causing a flood of interrupts.
    To fix this, read the irqstatus register in isr and use the same cached
    value in the poll function.
    Signed-off-by: AnilKumar Ch <>
    Acked-by: Wolfgang Grandegger <>
    Signed-off-by: Marc Kleine-Budde <>
    Signed-off-by: Greg Kroah-Hartman <>
  14. @AnilKumarCh @gregkh

    can: c_can: fix "BUG! echo_skb is occupied!" during transmit

    AnilKumarCh authored gregkh committed
    commit 617cacc upstream.
    This patch fixes an issue with transmit routine, which causes
    "can_put_echo_skb: BUG! echo_skb is occupied!" message when
    using "cansequence -p" on D_CAN controller.
    In c_can driver, while transmitting packets tx_echo flag holds
    the no of can frames put for transmission into the hardware.
    As the comment above c_can_do_tx() indicates, if we find any packet
    which is not transmitted then we should stop looking for more.
    In the current implementation this is not taken care of causing the
    said message.
    Also, fix the condition used to find if the packet is transmitted
    or not. Current code skips the first tx message object and ends up
    checking one extra invalid object.
    While at it, fix the comment on top of c_can_do_tx() to use the
    terminology "packet" instead of "package" since it is more
    Signed-off-by: AnilKumar Ch <>
    Acked-by: Wolfgang Grandegger <>
    Signed-off-by: Marc Kleine-Budde <>
    Signed-off-by: Greg Kroah-Hartman <>
Something went wrong with that request. Please try again.