commit 69ad303ab8321656d6144d13b2444a5595bb6581 Author: Greg Kroah-Hartman Date: Thu Feb 17 15:14:38 2011 -0800 Linux 2.6.36.4 commit 062d29c90bda892a67eecb5e972715e1bd5df9cd Author: Sarah Sharp Date: Tue Dec 28 13:08:42 2010 -0800 xhci: Use GFP_NOIO during device reset. commit a6d940dd759bf240d28624198660ed34582a327b upstream. When xhci_discover_or_reset_device() is called after a host controller power loss, the virtual device may need to be reallocated. Make sure xhci_alloc_dev() uses GFP_NOIO. This avoid causing a deadlock by allowing the kernel to flush pending I/O while reallocating memory for a virtual device for a USB mass storage device that's holding the backing store for dirty memory buffers. This patch should be queued for the 2.6.37 stable tree. Signed-off-by: Sarah Sharp Signed-off-by: Greg Kroah-Hartman commit cc402387cc7fdb826b193994051dad64cdf6377b Author: Sarah Sharp Date: Thu Dec 23 11:12:42 2010 -0800 usb: Realloc xHCI structures after a hub is verified. commit 653a39d1f61bdc9f277766736d21d2e9be0391cb upstream. When there's an xHCI host power loss after a suspend from memory, the USB core attempts to reset and verify the USB devices that are attached to the system. The xHCI driver has to reallocate those devices, since the hardware lost all knowledge of them during the power loss. When a hub is plugged in, and the host loses power, the xHCI hardware structures are not updated to say the device is a hub. This is usually done in hub_configure() when the USB hub is detected. That function is skipped during a reset and verify by the USB core, since the core restores the old configuration and alternate settings, and the hub driver has no idea this happened. This bug makes the xHCI host controller reject the enumeration of low speed devices under the resumed hub. Therefore, make the USB core re-setup the internal xHCI hub device information by calling update_hub_device() when hub_activate() is called for a hub reset resume. After a host power loss, all devices under the roothub get a reset-resume or a disconnect. This patch should be queued for the 2.6.37 stable tree. Signed-off-by: Sarah Sharp Signed-off-by: Greg Kroah-Hartman commit 91e0d66a31148ff5108a1d877ddf54319903148b Author: Zhang Rui Date: Fri Dec 17 13:17:04 2010 -0800 xhci: Do not run xhci_cleanup_msix with irq disabled commit 40a9fb17f32dbe54de3d636142a59288544deed7 upstream. when unloading xhci_hcd, I got: [ 134.856813] xhci_hcd 0000:02:00.0: remove, state 4 [ 134.858140] usb usb3: USB disconnect, address 1 [ 134.874956] xhci_hcd 0000:02:00.0: Host controller not halted, aborting reset. [ 134.876351] BUG: sleeping function called from invalid context at kernel/mutex.c:85 [ 134.877657] in_atomic(): 0, irqs_disabled(): 1, pid: 1451, name: modprobe [ 134.878975] Pid: 1451, comm: modprobe Not tainted 2.6.37-rc5+ #162 [ 134.880298] Call Trace: [ 134.881602] [] __might_sleep+0xeb/0xf0 [ 134.882921] [] mutex_lock+0x24/0x50 [ 134.884229] [] free_desc+0x2e/0x5f [ 134.885538] [] irq_free_descs+0x3b/0x71 [ 134.886853] [] free_irq_at+0x31/0x36 [ 134.888167] [] destroy_irq+0x69/0x71 [ 134.889486] [] native_teardown_msi_irq+0xe/0x10 [ 134.890820] [] default_teardown_msi_irqs+0x57/0x80 [ 134.892158] [] free_msi_irqs+0x8b/0xe9 [ 134.893504] [] pci_disable_msix+0x35/0x39 [ 134.894844] [] xhci_cleanup_msix+0x31/0x51 [xhci_hcd] [ 134.896186] [] xhci_stop+0x3a/0x80 [xhci_hcd] [ 134.897521] [] usb_remove_hcd+0xfd/0x14a [ 134.898859] [] usb_hcd_pci_remove+0x5c/0xc6 [ 134.900193] [] pci_device_remove+0x3f/0x91 [ 134.901535] [] __device_release_driver+0x83/0xd9 [ 134.902899] [] driver_detach+0x86/0xad [ 134.904222] [] bus_remove_driver+0xb2/0xd8 [ 134.905540] [] driver_unregister+0x6c/0x74 [ 134.906839] [] pci_unregister_driver+0x44/0x89 [ 134.908121] [] xhci_unregister_pci+0x15/0x17 [xhci_hcd] [ 134.909396] [] xhci_hcd_cleanup+0xe/0x10 [xhci_hcd] [ 134.910652] [] sys_delete_module+0x1ca/0x23b [ 134.911882] [] ? path_put+0x22/0x26 [ 134.913104] [] ? audit_syscall_entry+0x2c/0x148 [ 134.914333] [] system_call_fastpath+0x16/0x1b [ 134.915658] xhci_hcd 0000:02:00.0: USB bus 3 deregistered [ 134.916465] xhci_hcd 0000:02:00.0: PCI INT A disabled and the same issue when xhci_suspend is invoked. (Note from Sarah: That's fixed by Andiry's patch before this, by synchronizing the irqs rather than freeing them on suspend.) Do not run xhci_cleanup_msix with irq disabled. This patch should be queued for the 2.6.37 stable tree. Signed-off-by: Zhang Rui Signed-off-by: Sarah Sharp Signed-off-by: Greg Kroah-Hartman commit a5caac7e5485057711085b764fb3ad95e071e6e5 Author: Chris Wilson Date: Tue Feb 1 19:43:02 2011 +0000 drm/i915: Only bind to function 0 of the PCI device commit 5fe49d86f9d01044abf687a8cd21edef636d58aa upstream. Early chipsets (gen2/3) used function 1 as a placeholder for multi-head. We used to ignore these since they were not assigned to PCI_CLASS_DISPLAY_VGA. However with 934f992c7 we attempt to bind to all Intel PCI_CLASS_DISPLAY devices (and functions) to work in multi-gpu systems. This fails hard on gen2/3. Reported-by: Ferenc Wágner Tested-by: Ferenc Wágner Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=28012 Signed-off-by: Chris Wilson Signed-off-by: Greg Kroah-Hartman commit 9487d9dcae378886b3d06452b630e211982a079a Author: Stephen Kitt Date: Mon Jan 31 14:25:43 2011 -0800 agp: ensure GART has an address before enabling it commit a70b95c017e8b518e1e069853355e4e497453dbb upstream. Some BIOSs (eg. the AMI BIOS on the Asus P4P800 motherboard) don't initialise the GART address, and pcibios_assign_resources() can ignore it because it can be marked as a host bridge (see https://bugzilla.kernel.org/show_bug.cgi?id=24392#c5 for details). This was handled correctly up to 2.6.35, but the pci_enable_device() cleanup in 2.6.36 96576a9e1a0cdb8 ("agp: intel-agp: do not use PCI resources before pci_enable_device()") means that the kernel tries to enable the GART before assigning it an address; in such cases the GART overlaps with other device assignments and ends up being disabled. This patch fixes https://bugzilla.kernel.org/show_bug.cgi?id=24392 Note that I imagine efficeon-agp.c probably has the same problem, but I can't test that and I'd like to make sure this patch is suitable for -stable (since 2.6.36 and 2.6.37 are affected). Signed-off-by: Stephen Kitt Cc: Bjorn Helgaas Cc: Maciej Rutecki Cc: "Rafael J. Wysocki" Cc: Kulikov Vasiliy Cc: Florian Mickler Signed-off-by: Andrew Morton Signed-off-by: Dave Airlie Signed-off-by: Greg Kroah-Hartman commit 6d621e78c9e6efb6f4f2666434aa986bf6441195 Author: Suresh Siddha Date: Thu Feb 3 12:20:04 2011 -0800 x86, mm: avoid possible bogus tlb entries by clearing prev mm_cpumask after switching mm commit 831d52bc153971b70e64eccfbed2b232394f22f8 upstream. Clearing the cpu in prev's mm_cpumask early will avoid the flush tlb IPI's while the cr3 is still pointing to the prev mm. And this window can lead to the possibility of bogus TLB fills resulting in strange failures. One such problematic scenario is mentioned below. T1. CPU-1 is context switching from mm1 to mm2 context and got a NMI etc between the point of clearing the cpu from the mm_cpumask(mm1) and before reloading the cr3 with the new mm2. T2. CPU-2 is tearing down a specific vma for mm1 and will proceed with flushing the TLB for mm1. It doesn't send the flush TLB to CPU-1 as it doesn't see that cpu listed in the mm_cpumask(mm1). T3. After the TLB flush is complete, CPU-2 goes ahead and frees the page-table pages associated with the removed vma mapping. T4. CPU-2 now allocates those freed page-table pages for something else. T5. As the CR3 and TLB caches for mm1 is still active on CPU-1, CPU-1 can potentially speculate and walk through the page-table caches and can insert new TLB entries. As the page-table pages are already freed and being used on CPU-2, this page walk can potentially insert a bogus global TLB entry depending on the (random) contents of the page that is being used on CPU-2. T6. This bogus TLB entry being global will be active across future CR3 changes and can result in weird memory corruption etc. To avoid this issue, for the prev mm that is handing over the cpu to another mm, clear the cpu from the mm_cpumask(prev) after the cr3 is changed. Marking it for -stable, though we haven't seen any reported failure that can be attributed to this. Signed-off-by: Suresh Siddha Acked-by: Ingo Molnar Signed-off-by: Linus Torvalds Signed-off-by: Greg Kroah-Hartman commit 02a9f4dfb9318e84e6c46cd08adb286cfeaf87eb Author: Chris Wilson Date: Thu Jan 20 13:09:12 2011 +0000 drm/i915: Recognise non-VGA display devices commit 934f992c763ae1e5eefcce8af769c16444085df7 upstream. Starting with SandyBridge (though possible with earlier hacked BIOSes), the BIOS may initialise the IGFX as secondary to a discrete GPU. Prior, it would simply disable the integrated GPU. So we adjust our PCI class mask to match any DISPLAY_CLASS device. In such a configuration, the IGFX is not a primary VGA controller and so should not take part in VGA arbitration, and the error return from vga_client_register() is expected. Signed-off-by: Chris Wilson Signed-off-by: Greg Kroah-Hartman commit 5cc301295c277a59cb8ae9c529b6b1ef130fef0c Author: Chris Wilson Date: Thu Jan 20 10:03:24 2011 +0000 drm/i915: Add dependency on CONFIG_TMPFS commit f7ab9b407b3bc83161c2aa74c992ba4782e87c9c upstream. Without tmpfs, shmem_readpage() is not compiled in causing an OOPS as soon as we try to allocate some swappable pages for GEM. Jan 19 22:52:26 harlie kernel: Modules linked in: i915(+) drm_kms_helper cfbcopyarea video backlight cfbimgblt cfbfillrect Jan 19 22:52:26 harlie kernel: Jan 19 22:52:26 harlie kernel: Pid: 1125, comm: modprobe Not tainted 2.6.37Harlie #10 To be filled by O.E.M./To be filled by O.E.M. Jan 19 22:52:26 harlie kernel: EIP: 0060:[<00000000>] EFLAGS: 00010246 CPU: 3 Jan 19 22:52:26 harlie kernel: EIP is at 0x0 Jan 19 22:52:26 harlie kernel: EAX: 00000000 EBX: f7b7d000 ECX: f3383100 EDX: f7b7d000 Jan 19 22:52:26 harlie kernel: ESI: f1456118 EDI: 00000000 EBP: f2303c98 ESP: f2303c7c Jan 19 22:52:26 harlie kernel: DS: 007b ES: 007b FS: 00d8 GS: 0033 SS: 0068 Jan 19 22:52:26 harlie kernel: Process modprobe (pid: 1125, ti=f2302000 task=f259cd80 task.ti=f2302000) Jan 19 22:52:26 harlie kernel: Stack: Jan 19 22:52:26 harlie udevd-work[1072]: '/sbin/modprobe -b pci:v00008086d00000046sv00000000sd00000000bc03sc00i00' unexpected exit with status 0x0009 Jan 19 22:52:26 harlie kernel: c1074061 000000d0 f2f42b80 00000000 000a13d2 f2d5dcc0 00000001 f2303cac Jan 19 22:52:26 harlie kernel: c107416f 00000000 000a13d2 00000000 f2303cd4 f8d620ed f2cee620 00001000 Jan 19 22:52:26 harlie kernel: 00000000 000a13d2 f1456118 f2d5dcc0 f1a40000 00001000 f2303d04 f8d637ab Jan 19 22:52:26 harlie kernel: Call Trace: Jan 19 22:52:26 harlie kernel: [] ? do_read_cache_page+0x71/0x160 Jan 19 22:52:26 harlie kernel: [] ? read_cache_page_gfp+0x1f/0x30 Jan 19 22:52:26 harlie kernel: [] ? i915_gem_object_get_pages+0xad/0x1d0 [i915] Jan 19 22:52:26 harlie kernel: [] ? i915_gem_object_bind_to_gtt+0xeb/0x2d0 [i915] Jan 19 22:52:26 harlie kernel: [] ? i915_gem_object_pin+0x151/0x190 [i915] Jan 19 22:52:26 harlie kernel: [] ? drm_gem_object_init+0x3d/0x60 Jan 19 22:52:26 harlie kernel: [] ? i915_gem_init_ringbuffer+0x105/0x1e0 [i915] Jan 19 22:52:26 harlie kernel: [] ? i915_driver_load+0x667/0x1160 [i915] Reported-by: John J. Stimson-III Signed-off-by: Chris Wilson Signed-off-by: Greg Kroah-Hartman commit 660e15b4beb5de08c0cbde27bdea9800010b5d57 Author: Knut Petersen Date: Fri Jan 14 15:38:10 2011 +0000 drm/i915/lvds: Add AOpen i915GMm-HFS to the list of false-positive LVDS commit 22ab70d3262ddb6e69b3c246a34e2967ba5eb1e8 upstream. Signed-off-by: Knut Petersen Signed-off-by: Chris Wilson Signed-off-by: Greg Kroah-Hartman commit 332db0727426a93e401c49fb04426d04c494c102 Author: Yuanhan Liu Date: Thu Jan 6 18:26:08 2011 +0800 drm/i915: fix calculation of eDP signal levels on Sandybridge commit 3c5a62b5226ca5db993660281e9c2a7275d9fb02 upstream. Some voltage swing/pre-emphasis level use the same value on eDP Sandybridge, like 400mv_0db and 600mv_0db are with the same value of (0x0 << 22). So, fix them, and point out the value if it isn't a supported voltage swing/pre-emphasis level. Signed-off-by: Yuanhan Liu Signed-off-by: Chris Wilson Signed-off-by: Greg Kroah-Hartman commit 22747485265db8f9e104d2c21e5b98dd16d21993 Author: Chris Wilson Date: Sat Jan 8 15:10:41 2011 +0000 drm: Restore the old_fb upon modeset failure commit 0ba41e449fd0f45f5b29c1009020ab1b298bedda upstream. ... or else we may end up disabling the wrong framebuffer, leading to an OOPS, e.g: [ 6033.229012] kernel BUG at drivers/gpu/drm/i915/i915_gem.c:3271! [ 6033.229012] invalid opcode: 0000 [#1] SMP [ 6033.229012] last sysfs file: /sys/devices/virtual/backlight/acpi_video0/uevent [ 6033.229012] Modules linked in: sunrpc cpufreq_ondemand acpi_cpufreq mperf snd_hda_codec_analog snd_hda_intel snd_hda_codec snd_hwdep snd_seq snd_seq_device snd_pcm snd_timer thinkpad_acpi ppdev snd r852 sm_common iTCO_wdt uvcvideo i2c_i801 iTCO_vendor_support microcode wmi nand videodev nand_ids nand_ecc snd_page_alloc parport_pc parport mtd soundcore joydev v4l1_compat pcspkr uinput ipv6 sdhci_pci sdhci mmc_core yenta_socket i915 drm_kms_helper drm i2c_algo_bit i2c_core video output [last unloaded: scsi_wait_scan] [ 6033.229012] [ 6033.229012] Pid: 4834, comm: Xorg Not tainted 2.6.37-rc8+ #25 7661BL5/7661BL5 [ 6033.229012] EIP: 0060:[] EFLAGS: 00013246 CPU: 0 [ 6033.229012] EIP is at i915_gem_object_unpin+0x23/0x76 [i915] [ 6033.229012] EAX: f68a4000 EBX: f6831f00 ECX: 000600fa EDX: f68a8000 [ 6033.229012] ESI: f68a4014 EDI: f68a42b8 EBP: f2169c44 ESP: f2169c3c [ 6033.229012] DS: 007b ES: 007b FS: 00d8 GS: 00e0 SS: 0068 [ 6033.229012] Process Xorg (pid: 4834, ti=f2168000 task=f21c8000 task.ti=f2168000) [ 6033.229012] Stack: [ 6033.229012] f3a84800 f68a4014 f2169c54 f87045d8 f3a84800 f872d9a8 f2169c68 f7fd8091 [ 6033.229012] f3b952a4 00000000 f68a414c f2169cf0 f7fd9377 00000000 00000000 f7fd98b0 [ 6033.229012] f7fd9f4e 0000000f f7f328a0 00000000 00000000 00000000 f2169ca4 f68a414c [ 6033.229012] Call Trace: [ 6033.229012] [] ? intel_crtc_disable+0x36/0x41 [i915] [ 6033.229012] [] ? drm_helper_disable_unused_functions+0xcd/0xf9 [drm_kms_helper] [ 6033.229012] [] ? drm_crtc_helper_set_config+0x62a/0x7f7 [drm_kms_helper] [ 6033.229012] [] ? __slab_free+0x1b/0xa4 [ 6033.229012] [] ? drm_fb_helper_initial_config+0x466/0x497 [drm_kms_helper] [ 6033.229012] [] ? drm_fb_helper_restore+0x10/0x2a [drm_kms_helper] [ 6033.229012] [] ? i915_driver_lastclose+0x2a/0x57 [i915] [ 6033.229012] [] ? drm_lastclose+0x45/0x23e [drm] [ 6033.229012] [] ? drm_release+0x462/0x4d7 [drm] Signed-off-by: Chris Wilson Signed-off-by: Dave Airlie Signed-off-by: Greg Kroah-Hartman commit 26c394589e578ec0056ef484ef1ace03a18089e5 Author: Alex Deucher Date: Wed Feb 2 19:46:06 2011 -0500 drm/radeon/kms: fix s/r issues with bios scratch regs commit 87364760de5d631390c478fcbac8db1b926e0adf upstream. The accelerate mode bit gets checked by certain atom command tables to set up some register state. It needs to be clear when setting modes and set when not. Fixes: https://bugzilla.kernel.org/show_bug.cgi?id=26942 Signed-off-by: Alex Deucher Signed-off-by: Dave Airlie Signed-off-by: Greg Kroah-Hartman commit 235eb7c354d3025e56d64e4869b3347ceb74284a Author: Alex Deucher Date: Tue Feb 1 19:06:46 2011 -0500 drm/radeon: remove 0x4243 pci id commit 63a507800c8aca5a1891d598ae13f829346e8e39 upstream. 0x4243 is a PCI bridge, not a GPU. Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=33815 Signed-off-by: Alex Deucher Signed-off-by: Dave Airlie Signed-off-by: Greg Kroah-Hartman commit 3e8db9f2984f4f75091d410ad37043266018c437 Author: Alex Deucher Date: Mon Jan 31 16:48:51 2011 -0500 drm/radeon/kms: add pll debugging output commit 51d4bf840a27fe02c883ddc6d9708af056773769 upstream. Signed-off-by: Alex Deucher Signed-off-by: Dave Airlie Signed-off-by: Greg Kroah-Hartman commit 55b95132272a078ce94d298b6a31a5e9ff924df2 Author: Jerome Glisse Date: Wed Jan 26 17:51:03 2011 -0500 radeon/kms: fix dp displayport mode validation commit 6bba2e116808ca12e30c8d88dfedabf8b8d67390 upstream. Check if there is a big enough dp clock & enough dp lane to drive the video mode provided. Signed-off-by: Jerome Glisse Reviewed-By: Alex Deucher Signed-off-by: Dave Airlie Signed-off-by: Greg Kroah-Hartman commit 0afec771614078f663e7847ab442723787c7abb1 Author: Alex Deucher Date: Tue Jan 18 18:26:11 2011 +0000 drm/radeon/kms: make the mac rv630 quirk generic commit be23da8ad219650517cbbb7acbeaeb235667113a upstream. Seems some other boards do this as well. Reported-by: Andrea Merello Signed-off-by: Alex Deucher Signed-off-by: Dave Airlie Signed-off-by: Greg Kroah-Hartman commit 76ca51b75747d69f4ff7d12f004cde5166d04fb5 Author: Alex Deucher Date: Tue Jan 4 17:42:20 2011 -0500 drm/radeon/kms: adjust quirk for acer laptop commit 2f299d5de02da3ffb1f9e1a05c91dcd1173ebd3c upstream. Acer laptop (TravelMate 5730G) has an HDMI connector on the laptop and a DVI connector on the docking station and both share the same encoder, hpd pin, and ddc line. The bios connector table reflects this and is technically correct, however, we drop the DVI connector here since xrandr has no concept of encoders (only crtcs and connectors) and will try and drive both connectors with different crtcs which isn't possible on the hardware side and leaves no crtcs for LVDS or VGA. Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=32732 Signed-off-by: Alex Deucher Signed-off-by: Dave Airlie Signed-off-by: Greg Kroah-Hartman commit 887c8377c0b96e5815b9c68ad969c6efb1b37e0d Author: Alex Deucher Date: Tue Jan 4 00:43:39 2011 -0500 drm/radeon/kms: add quirk for Mac Radeon HD 2600 card commit f598aa7593427ffe3a61e7767c34bd695a5e7ed0 upstream. Reported-by: 屋国遥 Signed-off-by: Alex Deucher Signed-off-by: Dave Airlie Signed-off-by: Greg Kroah-Hartman commit 5ed523f5677013b7d71cd1fe91b070602d4cdb45 Author: Shawn Guo Date: Wed Jan 5 21:13:09 2011 +0000 net/fec: fix MMFR_OP type in fec_enet_mdio_write commit 862f0982eadcea0e114576c57ea426d3d51a69a6 upstream. FEC_MMFR_OP_WRITE should be used than FEC_MMFR_OP_READ in a mdio write operation. It's probably a typo introduced by commit: e6b043d512fa8d9a3801bf5d72bfa3b8fc3b3cc8 netdev/fec.c: add phylib supporting to enable carrier detection (v2) Signed-off-by: Shawn Guo Signed-off-by: David S. Miller Signed-off-by: Greg Kroah-Hartman commit bddab9a6e92697dbef442a23c56722896e8d427b Author: Mike Snitzer Date: Thu Jan 13 19:59:46 2011 +0000 dm mpath: disable blk_abort_queue commit 09c9d4c9b6a2b5909ae3c6265e4cd3820b636863 upstream. Revert commit 224cb3e981f1b2f9f93dbd49eaef505d17d894c2 dm: Call blk_abort_queue on failed paths Multipath began to use blk_abort_queue() to allow for lower latency path deactivation. This was found to cause list corruption: the cmd gets blk_abort_queued/timedout run on it and the scsi eh somehow is able to complete and run scsi_queue_insert while scsi_request_fn is still trying to process the request. https://www.redhat.com/archives/dm-devel/2010-November/msg00085.html Signed-off-by: Mike Snitzer Signed-off-by: Alasdair G Kergon Cc: Mike Anderson Cc: Mike Christie Signed-off-by: Greg Kroah-Hartman commit 1ca36e525b4f1c7d0cce6bba991e837fcb716bf4 Author: Mike Snitzer Date: Thu Jan 13 19:53:46 2011 +0000 dm: dont take i_mutex to change device size commit c217649bf2d60ac119afd71d938278cffd55962b upstream. No longer needlessly hold md->bdev->bd_inode->i_mutex when changing the size of a DM device. This additional locking is unnecessary because i_size_write() is already protected by the existing critical section in dm_swap_table(). DM already has a reference on md->bdev so the associated bd_inode may be changed without lifetime concerns. A negative side-effect of having held md->bdev->bd_inode->i_mutex was that a concurrent DM device resize and flush (via fsync) would deadlock. Dropping md->bdev->bd_inode->i_mutex eliminates this potential for deadlock. The following reproducer no longer deadlocks: https://www.redhat.com/archives/dm-devel/2009-July/msg00284.html Signed-off-by: Mike Snitzer Signed-off-by: Mikulas Patocka Signed-off-by: Alasdair G Kergon Signed-off-by: Greg Kroah-Hartman commit b2420c31459a69d90a89e1b2e7484bcea930fb35 Author: Amitkumar Karwar Date: Tue Jan 11 16:14:24 2011 -0800 ieee80211: correct IEEE80211_ADDBA_PARAM_BUF_SIZE_MASK macro commit 8d661f1e462d50bd83de87ee628aaf820ce3c66c upstream. It is defined in include/linux/ieee80211.h. As per IEEE spec. bit6 to bit15 in block ack parameter represents buffer size. So the bitmask should be 0xFFC0. Signed-off-by: Amitkumar Karwar Signed-off-by: Bing Zhao Reviewed-by: Johannes Berg Signed-off-by: John W. Linville Signed-off-by: Greg Kroah-Hartman commit 267b02bf3ccda4ba557e56e4cbc827cef74e036f Author: Matthew Garrett Date: Thu Oct 21 17:42:40 2010 -0400 tpm: Autodetect itpm devices commit 3f0d3d016d89a5efb8b926d4707eb21fa13f3d27 upstream. Some Lenovos have TPMs that require a quirk to function correctly. This can be autodetected by checking whether the device has a _HID of INTC0102. This is an invalid PNPid, and as such is discarded by the pnp layer - however it's still present in the ACPI code, so we can pull it out that way. This means that the quirk won't be automatically applied on non-ACPI systems, but without ACPI we don't have any way to identify the chip anyway so I don't think that's a great concern. Signed-off-by: Matthew Garrett Acked-by: Rajiv Andrade Tested-by: Jiri Kosina Tested-by: Andy Isaacson Signed-off-by: James Morris Signed-off-by: Greg Kroah-Hartman commit 1d91afd8b1854d363d88cf95dafeaffff6f8bb08 Author: Eric Paris Date: Thu Dec 2 16:13:40 2010 -0500 SELinux: do not compute transition labels on mountpoint labeled filesystems commit 415103f9932d45f7927f4b17e3a9a13834cdb9a1 upstream. selinux_inode_init_security computes transitions sids even for filesystems that use mount point labeling. It shouldn't do that. It should just use the mount point label always and no matter what. This causes 2 problems. 1) it makes file creation slower than it needs to be since we calculate the transition sid and 2) it allows files to be created with a different label than the mount point! # id -Z staff_u:sysadm_r:sysadm_t:s0-s0:c0.c1023 # sesearch --type --class file --source sysadm_t --target tmp_t Found 1 semantic te rules: type_transition sysadm_t tmp_t : file user_tmp_t; # mount -o loop,context="system_u:object_r:tmp_t:s0" /tmp/fs /mnt/tmp # ls -lZ /mnt/tmp drwx------. root root system_u:object_r:tmp_t:s0 lost+found # touch /mnt/tmp/file1 # ls -lZ /mnt/tmp -rw-r--r--. root root staff_u:object_r:user_tmp_t:s0 file1 drwx------. root root system_u:object_r:tmp_t:s0 lost+found Whoops, we have a mount point labeled filesystem tmp_t with a user_tmp_t labeled file! Signed-off-by: Eric Paris Reviewed-by: Reviewed-by: James Morris Signed-off-by: Greg Kroah-Hartman commit b38c0639474250cb4cdb91a36a2a2f781305cdcc Author: Eric Paris Date: Thu Dec 16 11:46:51 2010 -0500 SELinux: define permissions for DCB netlink messages commit 350e4f31e0eaf56dfc3b328d24a11bdf42a41fb8 upstream. Commit 2f90b865 added two new netlink message types to the netlink route socket. SELinux has hooks to define if netlink messages are allowed to be sent or received, but it did not know about these two new message types. By default we allow such actions so noone likely noticed. This patch adds the proper definitions and thus proper permissions enforcement. Signed-off-by: Eric Paris Cc: James Morris Signed-off-by: Greg Kroah-Hartman commit de79143f1a7d8bc3340d982813ccc013cca01ccc Author: David Howells Date: Wed Dec 22 16:24:13 2010 +0000 KEYS: Don't call up_write() if __key_link_begin() returns an error commit 3fc5e98d8cf85e0d77fc597b49e9268dff67400e upstream. In construct_alloc_key(), up_write() is called in the error path if __key_link_begin() fails, but this is incorrect as __key_link_begin() only returns with the nominated keyring locked if it returns successfully. Without this patch, you might see the following in dmesg: ===================================== [ BUG: bad unlock balance detected! ] ------------------------------------- mount.cifs/5769 is trying to release lock (&key->sem) at: [] request_key_and_link+0x263/0x3fc but there are no more locks to release! other info that might help us debug this: 3 locks held by mount.cifs/5769: #0: (&type->s_umount_key#41/1){+.+.+.}, at: [] sget+0x278/0x3e7 #1: (&ret_buf->session_mutex){+.+.+.}, at: [] cifs_get_smb_ses+0x35a/0x443 [cifs] #2: (root_key_user.cons_lock){+.+.+.}, at: [] request_key_and_link+0x10a/0x3fc stack backtrace: Pid: 5769, comm: mount.cifs Not tainted 2.6.37-rc6+ #1 Call Trace: [] ? request_key_and_link+0x263/0x3fc [] print_unlock_inbalance_bug+0xca/0xd5 [] lock_release_non_nested+0xc1/0x263 [] ? request_key_and_link+0x263/0x3fc [] ? request_key_and_link+0x263/0x3fc [] lock_release+0x17d/0x1a4 [] up_write+0x23/0x3b [] request_key_and_link+0x263/0x3fc [] ? cifs_get_spnego_key+0x61/0x21f [cifs] [] request_key+0x41/0x74 [] cifs_get_spnego_key+0x200/0x21f [cifs] [] CIFS_SessSetup+0x55d/0x1273 [cifs] [] cifs_setup_session+0x90/0x1ae [cifs] [] cifs_get_smb_ses+0x37f/0x443 [cifs] [] cifs_mount+0x1aa1/0x23f3 [cifs] [] ? alloc_debug_processing+0xdb/0x120 [] ? cifs_get_spnego_key+0x1ef/0x21f [cifs] [] cifs_do_mount+0x165/0x2b3 [cifs] [] vfs_kern_mount+0xaf/0x1dc [] do_kern_mount+0x4d/0xef [] do_mount+0x6f4/0x733 [] sys_mount+0x88/0xc2 [] system_call_fastpath+0x16/0x1b Reported-by: Jeff Layton Signed-off-by: David Howells Reviewed-and-Tested-by: Jeff Layton Signed-off-by: Linus Torvalds Cc: James Morris Signed-off-by: Greg Kroah-Hartman commit 9c63b4bcf5832c61b458fee328715c0c1ffd5052 Author: Stefan Berger Date: Tue Jan 11 14:37:29 2011 -0500 tpm_tis: Use timeouts returned from TPM commit 9b29050f8f75916f974a2d231ae5d3cd59792296 upstream. The current TPM TIS driver in git discards the timeout values returned from the TPM. The check of the response packet needs to consider that the return_code field is 0 on success and the size of the expected packet is equivalent to the header size + u32 length indicator for the TPM_GetCapability() result + 3 timeout indicators of type u32. I am also adding a sysfs entry 'timeouts' showing the timeouts that are being used. Signed-off-by: Stefan Berger Tested-by: Guillaume Chazarain Signed-off-by: Rajiv Andrade Signed-off-by: Greg Kroah-Hartman commit ac88c7bacc068be260de461037174ba140a2e21a Author: Rajiv Andrade Date: Fri Nov 12 22:30:02 2010 +0100 TPM: Long default timeout fix commit c4ff4b829ef9e6353c0b133b7adb564a68054979 upstream. If duration variable value is 0 at this point, it's because chip->vendor.duration wasn't filled by tpm_get_timeouts() yet. This patch sets then the lowest timeout just to give enough time for tpm_get_timeouts() to further succeed. This fix avoids long boot times in case another entity attempts to send commands to the TPM when the TPM isn't accessible. Signed-off-by: Rajiv Andrade Signed-off-by: James Morris Signed-off-by: Greg Kroah-Hartman commit 43a1ff7eb4d2e51f3852bed286376635e0628c9f Author: Ryusuke Konishi Date: Fri Jan 21 16:40:31 2011 +0900 nilfs2: fix crash after one superblock became unavailable commit 0ca7a5b9ac5d301845dd6382ff25a699b6263a81 upstream. Fixes the following kernel oops in nilfs_setup_super() which could arise if one of two super-blocks is unavailable. > BUG: unable to handle kernel NULL pointer dereference at (null) > Pid: 3529, comm: mount.nilfs2 Not tainted 2.6.37 #1 / > EIP: 0060:[] EFLAGS: 00010202 CPU: 3 > EIP is at memcpy+0xc/0x1b > Call Trace: > [] ? nilfs_setup_super+0x6c/0xa5 [nilfs2] > [] ? nilfs_get_root_dentry+0x81/0xcb [nilfs2] > [] ? nilfs_mount+0x4f9/0x62c [nilfs2] > [] ? kstrdup+0x36/0x3f > [] ? nilfs_mount+0x0/0x62c [nilfs2] > [] ? vfs_kern_mount+0x4d/0x12c > [] ? get_fs_type+0x76/0x8f > [] ? do_kern_mount+0x33/0xbf > [] ? do_mount+0x2ed/0x714 > [] ? copy_mount_options+0x28/0xfc > [] ? sys_mount+0x72/0xaf > [] ? syscall_call+0x7/0xb Reported-by: Wakko Warner Signed-off-by: Ryusuke Konishi Tested-by: Wakko Warner LKML-Reference: <20110121024918.GA29598@animx.eu.org> Signed-off-by: Greg Kroah-Hartman commit f967dc0329beba814f815ab411ea1000b7b8dec1 Author: Joerg Roedel Date: Fri Jan 14 10:10:19 2011 -0200 KVM: MMU: Fix 32 bit legacy paging with NPT commit f87f928882d080eaec8b0d76aecff003d664697d upstream. This patch fixes 32 bit legacy paging with NPT enabled. The mmu_check_root call on the top-level of the loop causes root_gfn to take values (in the tdp_enabled path) which are outside of guest memory. So the mmu_check_root call fails at some point in the loop interation causing the guest to tiple-fault. This patch changes the mmu_check_root calls to the places where they are really necessary. As a side-effect it introduces a check for the root of a pae page table too. Signed-off-by: Joerg Roedel Signed-off-by: Marcelo Tosatti Signed-off-by: Greg Kroah-Hartman commit e9d2581219cb776a9b6eeab9042584e9d5c3b046 Author: Avi Kivity Date: Fri Jan 14 10:10:18 2011 -0200 KVM: MMU: Fix incorrect direct gfn for unpaged mode shadow commit c093b8b46c5f0dd12d799f0d6a3b579863df72f6 upstream. We use the physical address instead of the base gfn for the four PAE page directories we use in unpaged mode. When the guest accesses an address above 1GB that is backed by a large host page, a BUG_ON() in kvm_mmu_set_gfn() triggers. Resolves: https://bugzilla.kernel.org/show_bug.cgi?id=21962 Reported-and-tested-by: Nicolas Prochazka Signed-off-by: Avi Kivity Cc: Marcelo Tosatti Signed-off-by: Greg Kroah-Hartman commit 295c639bff96e344913cd99118eecadf211e2e68 Author: Avi Kivity Date: Fri Jan 14 10:10:17 2011 -0200 KVM: i8259: initialize isr_ack commit a0272630bb594b4eac03a79e77957df7dad8eade upstream. isr_ack is never initialized. So, until the first PIC reset, interrupts may fail to be injected. This can cause Windows XP to fail to boot, as reported in the fallout from the fix to https://bugzilla.kernel.org/show_bug.cgi?id=21962. Reported-and-tested-by: Nicolas Prochazka Signed-off-by: Avi Kivity Signed-off-by: Greg Kroah-Hartman commit 823c5c79a5da97b6f4314be7d0f350fdc19df9b7 Author: Chris Mason Date: Mon Feb 7 19:21:48 2011 -0500 md_make_request: don't touch the bio after calling make_request commit e91ece5590b3c728624ab57043fc7a05069c604a upstream. md_make_request was calling bio_sectors() for part_stat_add after it was calling the make_request function. This is bad because the make_request function can free the bio and because the bi_size field can change around. The fix here was suggested by Jens Axboe. It saves the sector count before the make_request call. I hit this with CONFIG_DEBUG_PAGEALLOC turned on while trying to break his pretty fusionio card. Signed-off-by: Chris Mason Signed-off-by: NeilBrown Signed-off-by: Greg Kroah-Hartman commit 4f8fa9bc7226ba1581e63e3ff1b583f5c1026edd Author: Tejun Heo Date: Sun Jan 9 17:48:20 2011 -0500 pata_mpc52xx: inherit from ata_bmdma_port_ops commit 77c5fd19075d299fe820bb59bb21b0b113676e20 upstream. pata_mpc52xx supports BMDMA but inherits ata_sff_port_ops which triggers BUG_ON() when a DMA command is issued. Fix it. Signed-off-by: Tejun Heo Reported-by: Roman Fietze Cc: Sergei Shtylyov Signed-off-by: Jeff Garzik Signed-off-by: Greg Kroah-Hartman commit 0addbdd392125780ac65bcd9dcf69eae2afb9c01 Author: NeilBrown Date: Fri Jan 14 09:14:34 2011 +1100 md: Fix removal of extra drives when converting RAID6 to RAID5 commit bf2cb0dab8c97f00a71875d9b13dbac17a2f47ca upstream. When a RAID6 is converted to a RAID5, the extra drive should be discarded. However it isn't due to a typo in a comparison. This bug was introduced in commit e93f68a1fc6 in 2.6.35-rc4 and is suitable for any -stable since than. As the extra drive is not removed, the 'degraded' counter is wrong and so the RAID5 will not respond correctly to a subsequent failure. Signed-off-by: NeilBrown Signed-off-by: Greg Kroah-Hartman commit 7896fe54a75c5bfd8dfed08d98cb7e15896e3749 Author: NeilBrown Date: Fri Jan 14 09:14:33 2011 +1100 md: Ensure no IO request to get md device before it is properly initialised. commit 0ca69886a8273ac1350143d562280bfcbe4760dc upstream. When an md device is in the process of coming on line it is possible for an IO request (typically a partition table probe) to get through before the array is fully initialised, which can cause unexpected behaviour (e.g. a crash). So explicitly record when the array is ready for IO and don't allow IO through until then. There is no possibility for a similar problem when the array is going off-line as there must only be one 'open' at that time, and it is busy off-lining the array and so cannot send IO requests. So no memory barrier is needed in md_stop() This has been a bug since commit 409c57f3801 in 2.6.30 which introduced md_make_request. Before then, each personality would register its own make_request_fn when it was ready. This is suitable for any stable kernel from 2.6.30.y onwards. Signed-off-by: NeilBrown Reported-by: "Hawrylewicz Czarnowski, Przemyslaw" Signed-off-by: Greg Kroah-Hartman commit a53775f3a5b7cfdca47560285bf87616a808f25b Author: NeilBrown Date: Fri Jan 14 09:13:53 2011 +1100 md: fix regression resulting in delays in clearing bits in a bitmap commit 6c9879101442b08581e8a0e3ae6b7f643a78fd63 upstream. commit 589a594be1fb (2.6.37-rc4) fixed a problem were md_thread would sometimes call the ->run function at a bad time. If an error is detected during array start up after the md_thread has been started, the md_thread is killed. This resulted in the ->run function being called once. However the array may not be in a state that it is safe to call ->run. However the fix imposed meant that ->run was not called on a timeout. This means that when an array goes idle, bitmap bits do not get cleared promptly. While the array is busy the bits will still be cleared when appropriate so this is not very serious. There is no risk to data. Change the test so that we only avoid calling ->run when the thread is being stopped. This more explicitly addresses the problem situation. This is suitable for 2.6.37-stable and any -stable kernel to which 589a594be1fb was applied. Signed-off-by: NeilBrown Signed-off-by: Greg Kroah-Hartman commit f03114dc3b5ba8d9c271046f45c17aecb0a29402 Author: NeilBrown Date: Wed Jan 12 09:03:35 2011 +1100 md: fix regression with re-adding devices to arrays with no metadata commit bf572541ab44240163eaa2d486b06f306a31d45a upstream. Commit 1a855a0606 (2.6.37-rc4) fixed a problem where devices were re-added when they shouldn't be but caused a regression in a less common case that means sometimes devices cannot be re-added when they should be. In particular, when re-adding a device to an array without metadata we should always access the device, but after the above commit we didn't. This patch sets the In_sync flag in that case so that the re-add succeeds. This patch is suitable for any -stable kernel to which 1a855a0606 was applied. Signed-off-by: NeilBrown Signed-off-by: Greg Kroah-Hartman commit 44c73d2ededd2deed83d74163cf49f60910f0f95 Author: Anton Blanchard Date: Thu Jan 20 14:44:33 2011 -0800 kernel/smp.c: fix smp_call_function_many() SMP race commit 6dc19899958e420a931274b94019e267e2396d3e upstream. I noticed a failure where we hit the following WARN_ON in generic_smp_call_function_interrupt: if (!cpumask_test_and_clear_cpu(cpu, data->cpumask)) continue; data->csd.func(data->csd.info); refs = atomic_dec_return(&data->refs); WARN_ON(refs < 0); <------------------------- We atomically tested and cleared our bit in the cpumask, and yet the number of cpus left (ie refs) was 0. How can this be? It turns out commit 54fdade1c3332391948ec43530c02c4794a38172 ("generic-ipi: make struct call_function_data lockless") is at fault. It removes locking from smp_call_function_many and in doing so creates a rather complicated race. The problem comes about because: - The smp_call_function_many interrupt handler walks call_function.queue without any locking. - We reuse a percpu data structure in smp_call_function_many. - We do not wait for any RCU grace period before starting the next smp_call_function_many. Imagine a scenario where CPU A does two smp_call_functions back to back, and CPU B does an smp_call_function in between. We concentrate on how CPU C handles the calls: CPU A CPU B CPU C CPU D smp_call_function smp_call_function_interrupt walks call_function.queue sees data from CPU A on list smp_call_function smp_call_function_interrupt walks call_function.queue sees (stale) CPU A on list smp_call_function int clears last ref on A list_del_rcu, unlock smp_call_function reuses percpu *data A data->cpumask sees and clears bit in cpumask might be using old or new fn! decrements refs below 0 set data->refs (too late!) The important thing to note is since the interrupt handler walks a potentially stale call_function.queue without any locking, then another cpu can view the percpu *data structure at any time, even when the owner is in the process of initialising it. The following test case hits the WARN_ON 100% of the time on my PowerPC box (having 128 threads does help :) #include #include #define ITERATIONS 100 static void do_nothing_ipi(void *dummy) { } static void do_ipis(struct work_struct *dummy) { int i; for (i = 0; i < ITERATIONS; i++) smp_call_function(do_nothing_ipi, NULL, 1); printk(KERN_DEBUG "cpu %d finished\n", smp_processor_id()); } static struct work_struct work[NR_CPUS]; static int __init testcase_init(void) { int cpu; for_each_online_cpu(cpu) { INIT_WORK(&work[cpu], do_ipis); schedule_work_on(cpu, &work[cpu]); } return 0; } static void __exit testcase_exit(void) { } module_init(testcase_init) module_exit(testcase_exit) MODULE_LICENSE("GPL"); MODULE_AUTHOR("Anton Blanchard"); I tried to fix it by ordering the read and the write of ->cpumask and ->refs. In doing so I missed a critical case but Paul McKenney was able to spot my bug thankfully :) To ensure we arent viewing previous iterations the interrupt handler needs to read ->refs then ->cpumask then ->refs _again_. Thanks to Milton Miller and Paul McKenney for helping to debug this issue. [miltonm@bga.com: add WARN_ON and BUG_ON, remove extra read of refs before initial read of mask that doesn't help (also noted by Peter Zijlstra), adjust comments, hopefully clarify scenario ] [miltonm@bga.com: remove excess tests] Signed-off-by: Anton Blanchard Signed-off-by: Milton Miller Cc: Ingo Molnar Cc: "Paul E. McKenney" Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds Signed-off-by: Greg Kroah-Hartman commit ed8f1a28a0fbe533047de331ae97b87ee1903828 Author: David Dillow Date: Thu Jan 20 14:44:22 2011 -0800 fs/direct-io.c: don't try to allocate more than BIO_MAX_PAGES in a bio commit 20d9600cb407b0b55fef6ee814b60345c6f58264 upstream. When using devices that support max_segments > BIO_MAX_PAGES (256), direct IO tries to allocate a bio with more pages than allowed, which leads to an oops in dio_bio_alloc(). Clamp the request to the supported maximum, and change dio_bio_alloc() to reflect that bio_alloc() will always return a bio when called with __GFP_WAIT and a valid number of vectors. [akpm@linux-foundation.org: remove redundant BUG_ON()] Signed-off-by: David Dillow Reviewed-by: Jeff Moyer Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds Signed-off-by: Greg Kroah-Hartman commit 4e3e37b58d6cba97d9d9f5d9532d587030fcc648 Author: Randy Dunlap Date: Thu Jan 20 14:44:31 2011 -0800 backlight: fix 88pm860x_bl macro collision commit 2550326ac7a062fdfc204f9a3b98bdb9179638fc upstream. Fix collision with kernel-supplied #define: drivers/video/backlight/88pm860x_bl.c:24:1: warning: "CURRENT_MASK" redefined arch/x86/include/asm/page_64_types.h:6:1: warning: this is the location of the previous definition Signed-off-by: Randy Dunlap Cc: Haojian Zhuang Cc: Richard Purdie Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds Signed-off-by: Greg Kroah-Hartman commit 49aaedcac826772e1054c8a5ec9fb9d0af45df8c Author: Michael Büsch Date: Fri Feb 4 23:34:45 2011 +0100 ssb-pcmcia: Fix parsing of invariants tuples commit dd3cb633078fb12e06ce6cebbdfbf55a7562e929 upstream. This fixes parsing of the device invariants (MAC address) for PCMCIA SSB devices. ssb_pcmcia_do_get_invariants expects an iv pointer as data argument. Tested-by: dylan cristiani Signed-off-by: Michael Buesch Signed-off-by: John W. Linville Signed-off-by: Greg Kroah-Hartman commit 71a18194814f64021ec3dfc5a9b07d0eee2a1583 Author: Corey Minyard Date: Thu Feb 10 16:08:38 2011 -0600 char/ipmi: fix OOPS caused by pnp_unregister_driver on unregistered driver commit d2478521afc20227658a10a8c5c2bf1a2aa615b3 upstream. This patch fixes an OOPS triggered when calling modprobe ipmi_si a second time after the first modprobe returned without finding any ipmi devices. This can happen if you reload the module after having the first module load fail. The driver was not deregistering from PNP in that case. Peter Huewe originally reported this patch and supplied a fix, I have a different patch based on Linus' suggestion that cleans things up a bit more. Cc: openipmi-developer@lists.sourceforge.net Reviewed-by: Peter Huewe Cc: Randy Dunlap Signed-off-by: Corey Minyard Signed-off-by: Linus Torvalds Signed-off-by: Greg Kroah-Hartman commit 91bbb90c3b953b03fae72a22ae7a0713a48b3dba Author: Marcin Slusarz Date: Fri Jan 28 11:00:33 2011 -0500 watchdog: Don't change watchdog state on read of sysctl commit 9ffdc6c37df131f89d52001e0ef03091b158826f upstream. Signed-off-by: Marcin Slusarz [ add {}'s to fix a warning ] Signed-off-by: Don Zickus Cc: Peter Zijlstra Cc: Frederic Weisbecker LKML-Reference: <1296230433-6261-3-git-send-email-dzickus@redhat.com> Signed-off-by: Ingo Molnar Signed-off-by: Greg Kroah-Hartman commit 615563d11619a5df5c95577236888434c78e54a9 Author: Marcin Slusarz Date: Fri Jan 28 11:00:32 2011 -0500 watchdog: Fix sysctl consistency commit 397357666de6b5b6adb5fa99f9758ec8cf30ac34 upstream. If it was not possible to enable watchdog for any cpu, switch watchdog_enabled back to 0, because it's visible via kernel.watchdog sysctl. Signed-off-by: Marcin Slusarz Signed-off-by: Don Zickus Cc: Peter Zijlstra Cc: Frederic Weisbecker LKML-Reference: <1296230433-6261-2-git-send-email-dzickus@redhat.com> Signed-off-by: Ingo Molnar Signed-off-by: Greg Kroah-Hartman commit 9b65e47537df40b66fdb50e17c3c50cc121c6254 Author: Guy Martin Date: Mon Dec 6 16:48:04 2010 +0100 parisc : Remove broken line wrapping handling pdc_iodc_print() commit fbea668498e93bb38ac9226c7af9120a25957375 upstream. Remove the broken line wrapping handling in pdc_iodc_print(). It is broken in 3 ways : - It doesn't keep track of the current screen position, it just assumes that the new buffer will be printed at the begining of the screen. - It doesn't take in account that non printable characters won't increase the current position on the screen. - And last but not least, it triggers a kernel panic if a backspace is the first char in the provided buffer : Backtrace: [<0000000040128ec4>] pdc_console_write+0x44/0x78 [<0000000040128f18>] pdc_console_tty_write+0x20/0x38 [<000000004032f1ac>] n_tty_write+0x2a4/0x550 [<000000004032b158>] tty_write+0x1e0/0x2d8 [<00000000401bb420>] vfs_write+0xb8/0x188 [<00000000401bb630>] sys_write+0x68/0xb8 [<0000000040104eb8>] syscall_exit+0x0/0x14 Most terminals handle the line wrapping just fine. I've confirmed that it works correctly on a C8000 with both vga and serial output. Signed-off-by: Guy Martin Signed-off-by: James Bottomley Signed-off-by: Greg Kroah-Hartman commit 40688b6476e61cedd9d6ca5d2e1078c7e35cd7c0 Author: Stefan Richter Date: Sat Jan 15 18:19:48 2011 +0100 firewire: core: fix unstable I/O with Canon camcorder commit 6044565af458e7fa6e748bff437ecc49dea88d79 upstream. Regression since commit 10389536742c, "firewire: core: check for 1394a compliant IRM, fix inaccessibility of Sony camcorder": The camcorder Canon MV5i generates lots of bus resets when asynchronous requests are sent to it (e.g. Config ROM read requests or FCP Command write requests) if the camcorder is not root node. This causes drop- outs in videos or makes the camcorder entirely inaccessible. https://bugzilla.redhat.com/show_bug.cgi?id=633260 Fix this by allowing any Canon device, even if it is a pre-1394a IRM like MV5i are, to remain root node (if it is at least Cycle Master capable). With the FireWire controller cards that I tested, MV5i always becomes root node when plugged in and left to its own devices. Reported-by: Ralf Lange Signed-off-by: Stefan Richter Signed-off-by: Greg Kroah-Hartman commit 1ad94a4f74fd33df13760c679e8edba1b77ab9ad Author: Benjamin Herrenschmidt Date: Thu Jan 20 20:35:23 2011 +0000 powerpc: Fix some 6xx/7xxx CPU setup functions commit 1f1936ff3febf38d582177ea319eaa278f32c91f upstream. Some of those functions try to adjust the CPU features, for example to remove NAP support on some revisions. However, they seem to use r5 as an index into the CPU table entry, which might have been right a long time ago but no longer is. r4 is the right register to use. This probably caused some off behaviours on some PowerMac variants using 750cx or 7455 processor revisions. Signed-off-by: Benjamin Herrenschmidt Signed-off-by: Greg Kroah-Hartman commit 756917be0bc2eab26ce39d20dc594e1c01310188 Author: Anton Blanchard Date: Sat Jan 29 12:37:16 2011 +0000 powerpc/numa: Fix bug in unmap_cpu_from_node commit 429f4d8d20b91e4a6c239f951c06a56a6ac22957 upstream. When converting to the new cpumask code I screwed up: - if (cpu_isset(cpu, numa_cpumask_lookup_table[node])) { - cpu_clear(cpu, numa_cpumask_lookup_table[node]); + if (cpumask_test_cpu(cpu, node_to_cpumask_map[node])) { + cpumask_set_cpu(cpu, node_to_cpumask_map[node]); This was introduced in commit 25863de07af9 (powerpc/cpumask: Convert NUMA code to new cpumask API) Fix it. Signed-off-by: Anton Blanchard Signed-off-by: Benjamin Herrenschmidt Signed-off-by: Greg Kroah-Hartman commit 3ca30e408a08f9b902d4d7d0422be498584cb966 Author: Anton Blanchard Date: Thu Oct 21 00:52:12 2010 +0000 powerpc: Fix hcall tracepoint recursion commit 57cdfdf829a850a317425ed93c6a576c9ee6329c upstream. Spinlocks on shared processor partitions use H_YIELD to notify the hypervisor we are waiting on another virtual CPU. Unfortunately this means the hcall tracepoints can recurse. The patch below adds a percpu depth and checks it on both the entry and exit hcall tracepoints. Signed-off-by: Anton Blanchard Acked-by: Steven Rostedt Signed-off-by: Benjamin Herrenschmidt Signed-off-by: Greg Kroah-Hartman commit 1caf470a3c4ab570b38a6e7c339e06f18909ef98 Author: Timur Tabi Date: Fri Dec 3 10:52:14 2010 -0600 powerpc/85xx: fix compatible properties of the P1022DS DMA nodes used for audio commit b2e0861e51f2961954330dcafe6d148ee3ab5cff upstream. In order to prevent the fsl_dma driver from claiming the DMA channels that the P1022DS audio driver needs, the compatible properties for those nodes must say "fsl,ssi-dma-channel" instead of "fsl,eloplus-dma-channel". Signed-off-by: Timur Tabi Signed-off-by: Kumar Gala Signed-off-by: Greg Kroah-Hartman commit e4bbb71290c897c349f9bed3a92907be95e16656 Author: Justin TerAvest Date: Wed Feb 9 14:20:03 2011 +0100 cfq-iosched: Don't wait if queue already has requests. commit 02a8f01b5a9f396d0327977af4c232d0f94c45fd upstream. Commit 7667aa0630407bc07dc38dcc79d29cc0a65553c1 added logic to wait for the last queue of the group to become busy (have at least one request), so that the group does not lose out for not being continuously backlogged. The commit did not check for the condition that the last queue already has some requests. As a result, if the queue already has requests, wait_busy is set. Later on, cfq_select_queue() checks the flag, and decides that since the queue has a request now and wait_busy is set, the queue is expired. This results in early expiration of the queue. This patch fixes the problem by adding a check to see if queue already has requests. If it does, wait_busy is not set. As a result, time slices do not expire early. The queues with more than one request are usually buffered writers. Testing shows improvement in isolation between buffered writers. Signed-off-by: Justin TerAvest Reviewed-by: Gui Jianfeng Acked-by: Vivek Goyal Signed-off-by: Jens Axboe Signed-off-by: Greg Kroah-Hartman commit 5648b203ebfce5b9b26bc4a95d4072f30d8f8f66 Author: David Miller Date: Sun Feb 13 16:37:07 2011 -0800 klist: Fix object alignment on 64-bit. commit 795abaf1e4e188c4171e3cd3dbb11a9fcacaf505 upstream. Commit c0e69a5bbc6f ("klist.c: bit 0 in pointer can't be used as flag") intended to make sure that all klist objects were at least pointer size aligned, but used the constant "4" which only works on 32-bit. Use "sizeof(void *)" which is correct in all cases. Signed-off-by: David S. Miller Acked-by: Jesper Nilsson Signed-off-by: Linus Torvalds Signed-off-by: Greg Kroah-Hartman commit c04eb9683fbb6374275309b859fcbf02e1db2c78 Author: Mel Gorman Date: Thu Jan 13 15:45:41 2011 -0800 mm: page allocator: adjust the per-cpu counter threshold when memory is low commit 88f5acf88ae6a9778f6d25d0d5d7ec2d57764a97 upstream. Commit aa45484 ("calculate a better estimate of NR_FREE_PAGES when memory is low") noted that watermarks were based on the vmstat NR_FREE_PAGES. To avoid synchronization overhead, these counters are maintained on a per-cpu basis and drained both periodically and when a threshold is above a threshold. On large CPU systems, the difference between the estimate and real value of NR_FREE_PAGES can be very high. The system can get into a case where pages are allocated far below the min watermark potentially causing livelock issues. The commit solved the problem by taking a better reading of NR_FREE_PAGES when memory was low. Unfortately, as reported by Shaohua Li this accurate reading can consume a large amount of CPU time on systems with many sockets due to cache line bouncing. This patch takes a different approach. For large machines where counter drift might be unsafe and while kswapd is awake, the per-cpu thresholds for the target pgdat are reduced to limit the level of drift to what should be a safe level. This incurs a performance penalty in heavy memory pressure by a factor that depends on the workload and the machine but the machine should function correctly without accidentally exhausting all memory on a node. There is an additional cost when kswapd wakes and sleeps but the event is not expected to be frequent - in Shaohua's test case, there was one recorded sleep and wake event at least. To ensure that kswapd wakes up, a safe version of zone_watermark_ok() is introduced that takes a more accurate reading of NR_FREE_PAGES when called from wakeup_kswapd, when deciding whether it is really safe to go back to sleep in sleeping_prematurely() and when deciding if a zone is really balanced or not in balance_pgdat(). We are still using an expensive function but limiting how often it is called. When the test case is reproduced, the time spent in the watermark functions is reduced. The following report is on the percentage of time spent cumulatively spent in the functions zone_nr_free_pages(), zone_watermark_ok(), __zone_watermark_ok(), zone_watermark_ok_safe(), zone_page_state_snapshot(), zone_page_state(). vanilla 11.6615% disable-threshold 0.2584% David said: : We had to pull aa454840 "mm: page allocator: calculate a better estimate : of NR_FREE_PAGES when memory is low and kswapd is awake" from 2.6.36 : internally because tests showed that it would cause the machine to stall : as the result of heavy kswapd activity. I merged it back with this fix as : it is pending in the -mm tree and it solves the issue we were seeing, so I : definitely think this should be pushed to -stable (and I would seriously : consider it for 2.6.37 inclusion even at this late date). Signed-off-by: Mel Gorman Reported-by: Shaohua Li Reviewed-by: Christoph Lameter Tested-by: Nicolas Bareil Cc: David Rientjes Cc: Kyle McMartin Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds Signed-off-by: Greg Kroah-Hartman commit 826099cd9ae4186b8907d7ed5ec5fc450ae83545 Author: Sonic Zhang Date: Tue Jan 11 22:39:35 2011 -0500 mmc: bfin_sdh: fix alloc size for private data commit a34650f0f1ca589cda09c48cb62baf15e680a247 upstream. The bfin_sdh driver allocates the wrong size for the private data in the mmc_host. The first parameter of mmc_alloc_host should be the size of the local driver struct rather than the common mmc_host. Signed-off-by: Sonic Zhang Signed-off-by: Mike Frysinger Signed-off-by: Chris Ball Signed-off-by: Greg Kroah-Hartman commit ca4cf61868e2bafeeb9f320e5da9b431e0f3aabd Author: KAMEZAWA Hiroyuki Date: Tue Jan 25 15:07:27 2011 -0800 memcg: fix account leak at failure of memsw acconting commit 01c88e2d6b7330c0cc5867fe2297e7d826e1337d upstream. Commit 4b53433468 ("memcg: clean up try_charge main loop") removes a cancel of charge at case: memory charge-> success. mem+swap charge-> failure. This leaks usage of memory. Fix it. Signed-off-by: KAMEZAWA Hiroyuki Reviewed-by: Johannes Weiner Acked-by: Daisuke Nishimura Cc: Balbir Singh Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds Signed-off-by: Greg Kroah-Hartman commit 6880ae16eeb4d4f34d9d6090fa8bc0beb9c6ed69 Author: Russell King Date: Sun Jan 30 11:21:05 2011 +0000 ARM: initrd: disable initrd if passed address overlaps reserved region commit b0a2679d27408d97ce31e5f800b44227d3388b84 upstream. Disable the initrd if the passed address already overlaps the reserved region. This avoids oopses on Netwinders when NeTTrom tells the kernel that an initrd is located at mem+4MB, but this overlaps the BSS, resulting in the kernels in-use BSS being freed. This should be applied to v2.6.37-stable. Signed-off-by: Russell King Signed-off-by: Greg Kroah-Hartman commit ceb615bfeb0a612b13a7d58b4e09194b92e85fbb Author: Kacper Kornet Date: Sat Jan 29 00:21:04 2011 +0100 Fix prlimit64 for suid/sgid processes commit aa5bd67dcfdf9af34c7fa36ebc87d4e1f7e91873 upstream. Since check_prlimit_permission always fails in the case of SUID/GUID processes, such processes are not able to read or set their own limits. This commit changes this by assuming that process can always read/change its own limits. Signed-off-by: Kacper Kornet Acked-by: Jiri Slaby Signed-off-by: Linus Torvalds Signed-off-by: Greg Kroah-Hartman commit fd70b698a14e58cdd9f35715f9594a9084ac54c0 Author: Don Skidmore Date: Tue Jan 18 22:53:47 2011 +0000 ixgbe: fix for 82599 erratum on Header Splitting commit a124339ad28389093ed15eca990d39c51c5736cc upstream. We have found a hardware erratum on 82599 hardware that can lead to unpredictable behavior when Header Splitting mode is enabled. So we are no longer enabling this feature on affected hardware. Please see the 82599 Specification Update for more information. Signed-off-by: Don Skidmore Tested-by: Stephen Ko Signed-off-by: Jeff Kirsher Signed-off-by: Greg Kroah-Hartman commit eb77d7cb03db898f8c8d2a3a149ab2aacad478e0 Author: Tim Deegan Date: Thu Feb 10 08:50:41 2011 +0000 fix jiffy calculations in calibrate_delay_direct to handle overflow commit 70a062286b9dfcbd24d2e11601aecfead5cf709a upstream. Fixes a hang when booting as dom0 under Xen, when jiffies can be quite large by the time the kernel init gets this far. Signed-off-by: Tim Deegan [jbeulich@novell.com: !time_after() -> time_before_eq() as suggested by Jiri Slaby] Signed-off-by: Jan Beulich Cc: Jiri Slaby Cc: Jeremy Fitzhardinge Signed-off-by: Linus Torvalds Signed-off-by: Greg Kroah-Hartman commit 17ed50411002357e7d97b293e4977ea3b19803b1 Author: Suresh Siddha Date: Wed Feb 2 17:02:55 2011 -0800 x86, mtrr: Avoid MTRR reprogramming on BP during boot on UP platforms commit f7448548a9f32db38f243ccd4271617758ddfe2c upstream. Markus Kohn ran into a hard hang regression on an acer aspire 1310, when acpi is enabled. git bisect showed the following commit as the bad one that introduced the boot regression. commit d0af9eed5aa91b6b7b5049cae69e5ea956fd85c3 Author: Suresh Siddha Date: Wed Aug 19 18:05:36 2009 -0700 x86, pat/mtrr: Rendezvous all the cpus for MTRR/PAT init Because of the UP configuration of that platform, native_smp_prepare_cpus() bailed out (in smp_sanity_check()) before doing the set_mtrr_aps_delayed_init() Further down the boot path, native_smp_cpus_done() will call the delayed MTRR initialization for the AP's (mtrr_aps_init()) with mtrr_aps_delayed_init not set. This resulted in the boot processor reprogramming its MTRR's to the values seen during the start of the OS boot. While this is not needed ideally, this shouldn't have caused any side-effects. This is because the reprogramming of MTRR's (set_mtrr_state() that gets called via set_mtrr()) will check if the live register contents are different from what is being asked to write and will do the actual write only if they are different. BP's mtrr state is read during the start of the OS boot and typically nothing would have changed when we ask to reprogram it on BP again because of the above scenario on an UP platform. So on a normal UP platform no reprogramming of BP MTRR MSR's happens and all is well. However, on this platform, bios seems to be modifying the fixed mtrr range registers between the start of OS boot and when we double check the live registers for reprogramming BP MTRR registers. And as the live registers are modified, we end up reprogramming the MTRR's to the state seen during the start of the OS boot. During ACPI initialization, something in the bios (probably smi handler?) don't like this fact and results in a hard lockup. We didn't see this boot hang issue on this platform before the commit d0af9eed5aa91b6b7b5049cae69e5ea956fd85c3, because only the AP's (if any) will program its MTRR's to the value that BP had at the start of the OS boot. Fix this issue by checking mtrr_aps_delayed_init before continuing further in the mtrr_aps_init(). Now, only AP's (if any) will program its MTRR's to the BP values during boot. Addresses https://bugzilla.novell.com/show_bug.cgi?id=623393 [ By the way, this behavior of the bios modifying MTRR's after the start of the OS boot is not common and the kernel is not prepared to handle this situation well. Irrespective of this issue, during suspend/resume, linux kernel will try to reprogram the BP's MTRR values to the values seen during the start of the OS boot. So suspend/resume might be already broken on this platform for all linux kernel versions. ] Reported-and-bisected-by: Markus Kohn Tested-by: Markus Kohn Signed-off-by: Suresh Siddha Cc: Thomas Renninger Cc: Rafael Wysocki Cc: Venkatesh Pallipadi LKML-Reference: <1296694975.4418.402.camel@sbsiddha-MOBL3.sc.intel.com> Signed-off-by: Ingo Molnar Signed-off-by: Greg Kroah-Hartman commit 6066deb3a2ca62e7a990676ca3cc82014844881a Author: Eric W. Biederman Date: Sat Jan 29 14:57:22 2011 +0000 net: Fix ip link add netns oops commit 13ad17745c2cbd437d9e24b2d97393e0be11c439 upstream. Ed Swierk writes: > On 2.6.35.7 > ip link add link eth0 netns 9999 type macvlan > where 9999 is a nonexistent PID triggers an oops and causes all network functions to hang: > [10663.821898] BUG: unable to handle kernel NULL pointer dereference at 000000000000006d > [10663.821917] IP: [] __dev_alloc_name+0x9a/0x170 > [10663.821933] PGD 1d3927067 PUD 22f5c5067 PMD 0 > [10663.821944] Oops: 0000 [#1] SMP > [10663.821953] last sysfs file: /sys/devices/system/cpu/cpu0/cpufreq/scaling_cur_freq > [10663.821959] CPU 3 > [10663.821963] Modules linked in: macvlan ip6table_filter ip6_tables rfcomm ipt_MASQUERADE binfmt_misc iptable_nat nf_nat nf_conntrack_ipv4 nf_defrag_ipv4 xt_state nf_conntrack sco ipt_REJECT bnep l2cap xt_tcpudp iptable_filter ip_tables x_tables bridge stp vboxnetadp vboxnetflt vboxdrv kvm_intel kvm parport_pc ppdev snd_hda_codec_intelhdmi snd_hda_codec_conexant arc4 iwlagn iwlcore mac80211 snd_hda_intel snd_hda_codec snd_hwdep snd_pcm snd_seq_midi snd_rawmidi i915 snd_seq_midi_event snd_seq thinkpad_acpi drm_kms_helper btusb tpm_tis nvram uvcvideo snd_timer snd_seq_device bluetooth videodev v4l1_compat v4l2_compat_ioctl32 tpm drm tpm_bios snd cfg80211 psmouse serio_raw intel_ips soundcore snd_page_alloc intel_agp i2c_algo_bit video output netconsole configfs lp parport usbhid hid e1000e sdhci_pci ahci libahci sdhci led_class > [10663.822155] > [10663.822161] Pid: 6000, comm: ip Not tainted 2.6.35-23-generic #41-Ubuntu 2901CTO/2901CTO > [10663.822167] RIP: 0010:[] [] __dev_alloc_name+0x9a/0x170 > [10663.822177] RSP: 0018:ffff88014aebf7b8 EFLAGS: 00010286 > [10663.822182] RAX: 00000000fffffff4 RBX: ffff8801ad900800 RCX: 0000000000000000 > [10663.822187] RDX: ffff880000000000 RSI: 0000000000000000 RDI: ffff88014ad63000 > [10663.822191] RBP: ffff88014aebf808 R08: 0000000000000041 R09: 0000000000000041 > [10663.822196] R10: 0000000000000000 R11: dead000000200200 R12: ffff88014aebf818 > [10663.822201] R13: fffffffffffffffd R14: ffff88014aebf918 R15: ffff88014ad62000 > [10663.822207] FS: 00007f00c487f700(0000) GS:ffff880001f80000(0000) knlGS:0000000000000000 > [10663.822212] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 > [10663.822216] CR2: 000000000000006d CR3: 0000000231f19000 CR4: 00000000000026e0 > [10663.822221] DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 > [10663.822226] DR3: 0000000000000000 DR6: 00000000ffff0ff0 DR7: 0000000000000400 > [10663.822231] Process ip (pid: 6000, threadinfo ffff88014aebe000, task ffff88014afb16e0) > [10663.822236] Stack: > [10663.822240] ffff88014aebf808 ffffffff814a2bb5 ffff88014aebf7e8 00000000a00ee8d6 > [10663.822251] <0> 0000000000000000 ffffffffa00ef940 ffff8801ad900800 ffff88014aebf818 > [10663.822265] <0> ffff88014aebf918 ffff8801ad900800 ffff88014aebf858 ffffffff8149c413 > [10663.822281] Call Trace: > [10663.822290] [] ? dev_addr_init+0x75/0xb0 > [10663.822298] [] dev_alloc_name+0x43/0x90 > [10663.822307] [] rtnl_create_link+0xbe/0x1b0 > [10663.822314] [] rtnl_newlink+0x48a/0x570 > [10663.822321] [] ? rtnl_newlink+0x1ac/0x570 > [10663.822332] [] ? native_x2apic_icr_read+0x4/0x20 > [10663.822339] [] rtnetlink_rcv_msg+0x177/0x290 > [10663.822346] [] ? rtnetlink_rcv_msg+0x0/0x290 > [10663.822354] [] netlink_rcv_skb+0xa9/0xd0 > [10663.822360] [] rtnetlink_rcv+0x25/0x40 > [10663.822367] [] netlink_unicast+0x2de/0x2f0 > [10663.822374] [] netlink_sendmsg+0x1fe/0x2e0 > [10663.822383] [] sock_sendmsg+0xf3/0x120 > [10663.822391] [] ? _raw_spin_lock+0xe/0x20 > [10663.822400] [] ? __d_lookup+0x136/0x150 > [10663.822406] [] ? _raw_spin_lock+0xe/0x20 > [10663.822414] [] ? _atomic_dec_and_lock+0x4d/0x80 > [10663.822422] [] ? mntput_no_expire+0x30/0x110 > [10663.822429] [] ? move_addr_to_kernel+0x65/0x70 > [10663.822435] [] ? verify_iovec+0x88/0xe0 > [10663.822442] [] sys_sendmsg+0x240/0x3a0 > [10663.822450] [] ? __do_fault+0x479/0x560 > [10663.822457] [] ? _raw_spin_lock+0xe/0x20 > [10663.822465] [] ? alloc_fd+0x10a/0x150 > [10663.822473] [] ? do_page_fault+0x15e/0x350 > [10663.822482] [] system_call_fastpath+0x16/0x1b > [10663.822487] Code: 90 48 8d 78 02 be 25 00 00 00 e8 92 1d e2 ff 48 85 c0 75 cf bf 20 00 00 00 e8 c3 b1 c6 ff 49 89 c7 b8 f4 ff ff ff 4d 85 ff 74 bd <4d> 8b 75 70 49 8d 45 70 48 89 45 b8 49 83 ee 58 eb 28 48 8d 55 > [10663.822618] RIP [] __dev_alloc_name+0x9a/0x170 > [10663.822627] RSP > [10663.822631] CR2: 000000000000006d > [10663.822636] ---[ end trace 3dfd6c3ad5327ca7 ]--- This bug was introduced in: commit 81adee47dfb608df3ad0b91d230fb3cef75f0060 Author: Eric W. Biederman Date: Sun Nov 8 00:53:51 2009 -0800 net: Support specifying the network namespace upon device creation. There is no good reason to not support userspace specifying the network namespace during device creation, and it makes it easier to create a network device and pass it to a child network namespace with a well known name. We have to be careful to ensure that the target network namespace for the new device exists through the life of the call. To keep that logic clear I have factored out the network namespace grabbing logic into rtnl_link_get_net. In addtion we need to continue to pass the source network namespace to the rtnl_link_ops.newlink method so that we can find the base device source network namespace. Signed-off-by: Eric W. Biederman Acked-by: Eric Dumazet Where apparently I forgot to add error handling to the path where we create a new network device in a new network namespace, and pass in an invalid pid. Reported-by: Ed Swierk Signed-off-by: "Eric W. Biederman" Signed-off-by: David S. Miller Signed-off-by: Greg Kroah-Hartman commit c17b0a7e854bd2a6f24405f4a9476f1cc1c3e7df Author: Tejun Heo Date: Thu Feb 10 15:01:22 2011 -0800 ptrace: use safer wake up on ptrace_detach() commit 01e05e9a90b8f4c3997ae0537e87720eb475e532 upstream. The wake_up_process() call in ptrace_detach() is spurious and not interlocked with the tracee state. IOW, the tracee could be running or sleeping in any place in the kernel by the time wake_up_process() is called. This can lead to the tracee waking up unexpectedly which can be dangerous. The wake_up is spurious and should be removed but for now reduce its toxicity by only waking up if the tracee is in TRACED or STOPPED state. This bug can possibly be used as an attack vector. I don't think it will take too much effort to come up with an attack which triggers oops somewhere. Most sleeps are wrapped in condition test loops and should be safe but we have quite a number of places where sleep and wakeup conditions are expected to be interlocked. Although the window of opportunity is tiny, ptrace can be used by non-privileged users and with some loading the window can definitely be extended and exploited. Signed-off-by: Tejun Heo Acked-by: Roland McGrath Acked-by: Oleg Nesterov Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds Signed-off-by: Greg Kroah-Hartman commit 0ee4d843f2f6b866b84a5161f47788156b25896c Author: Pavel Machek Date: Sun Jan 9 08:38:48 2011 +0100 serial: unbreak billionton CF card commit d0694e2aeb815042aa0f3e5036728b3db4446f1d upstream. Unbreak Billionton CF bluetooth card. This actually fixes a regression on zaurus. Signed-off-by: Pavel Machek Signed-off-by: Greg Kroah-Hartman commit 12bc54289e180df608f81e498d5baf4f26d88d9d Author: Dario Lombardo Date: Fri Jan 21 15:35:19 2011 +0100 drivers: update to pl2303 usb-serial to support Motorola cables commit 96a3e79edff6f41b0f115a82f1a39d66218077a7 upstream. Added 0x0307 device id to support Motorola cables to the pl2303 usb serial driver. This cable has a modified chip that is a pl2303, but declares itself as 0307. Fixed by adding the right device id to the supported devices list, assigning it the code labeled PL2303_PRODUCT_ID_MOTOROLA. Signed-off-by: Dario Lombardo Signed-off-by: Greg Kroah-Hartman commit 65c888a0816668d5e29e722ee60d9145b514068d Author: Amit Shah Date: Mon Jan 31 13:06:36 2011 +0530 virtio: console: Wake up outvq on host notifications commit 2770c5ea501be69989a7acf54ec4cb3554c47191 upstream. The outvq needs to be woken up on host notifications so that buffers consumed by the host can be reclaimed, outvq freed, and application writes may proceed again. The need for this is now finally noticed when I have qemu patches ready to use nonblocking IO and flow control. CC: Hans de Goede Signed-off-by: Amit Shah Signed-off-by: Rusty Russell Acked-by: Hans de Goede Signed-off-by: Greg Kroah-Hartman commit 63a5df9b95f06aed7226b3c5b5e864898c229506 Author: Bruce Rogers Date: Thu Feb 10 11:03:31 2011 -0800 virtio_net: Add schedule check to napi_enable call commit 3e9d08ec0a68f6faf718d5a7e050fe5ca0ba004f upstream. Under harsh testing conditions, including low memory, the guest would stop receiving packets. With this patch applied we no longer see any problems in the driver while performing these tests for extended periods of time. Make sure napi is scheduled subsequent to each napi_enable. Signed-off-by: Bruce Rogers Signed-off-by: Olaf Kirch Signed-off-by: Rusty Russell Signed-off-by: David S. Miller Signed-off-by: Greg Kroah-Hartman commit 2e0d86e39009cdcd1cc0c7ec9c122cc34af1cd20 Author: Mark Brown Date: Thu Feb 3 16:27:34 2011 +0000 ASoC: Create an AIF1ADCDAT signal widget to match AIF2 commit 7f94de483f4e37e14d646ad6e85a3c82f66fb487 upstream. Due to the different routing for AIF1 and AIF2 we weren't using a single widget to represent the ADCDAT signal. For consistency add one. Signed-off-by: Mark Brown Acked-by: Liam Girdwood Signed-off-by: Greg Kroah-Hartman commit 40fa3eb06faad838478918078f6a0d78c436549e Author: Qiao Zhou Date: Wed Jan 19 19:10:47 2011 +0800 ASoC: WM8994: fix wrong value in tristate function commit 78b3fb46753872fc79bffecc8d50355a8622b39b upstream. fix wrong value in wm8994_set_tristate func. when updating reg bits, it should use "value", not "reg". Signed-off-by: Qiao Zhou Acked-by: Liam Girdwood Signed-off-by: Mark Brown Signed-off-by: Greg Kroah-Hartman commit 47f995d3e55baad144a3b29e0d5b6de285968e85 Author: Mark Brown Date: Fri Jan 21 12:47:33 2011 +0000 ASoC: Handle low measured DC offsets for wm_hubs devices commit 20a4e7fc7e213365ea3771d7bf1e10a6bab853be upstream. The DC servo codes are actually signed numbers so need to be treated as such. Signed-off-by: Mark Brown Acked-by: Liam Girdwood Signed-off-by: Greg Kroah-Hartman commit 30cf71d8fd3a62dbe3148163695c55e7828becf0 Author: Jean Delvare Date: Fri Jan 14 22:03:49 2011 +0100 i2c: Unregister dummy devices last on adapter removal commit 5219bf884b6e2b54e734ca1799b6f0014bb2b4b7 upstream. Remove real devices first and dummy devices last. This gives device driver which instantiated dummy devices themselves a chance to clean them up before we do. Signed-off-by: Jean Delvare Tested-by: Hans Verkuil Signed-off-by: Greg Kroah-Hartman commit e0134bbba1d1b0a802a3186f03715e9a4504dd38 Author: Christian Lamparter Date: Thu Jan 6 23:47:52 2011 +0100 p54: fix sequence no. accounting off-by-one error commit 3b5c5827d1f80ad8ae844a8b1183f59ddb90fe25 upstream. P54_HDR_FLAG_DATA_OUT_SEQNR is meant to tell the firmware that "the frame's sequence number has already been set by the application." Whereas IEEE80211_TX_CTL_ASSIGN_SEQ is set for frames which lack a valid sequence number and either the driver or firmware has to assign one. Yup, it's the exact opposite! Signed-off-by: Christian Lamparter Signed-off-by: John W. Linville Signed-off-by: Greg Kroah-Hartman commit c66bfc3309f06337bd0e0607a936d347f0ab2b9f Author: Rafael J. Wysocki Date: Sat Jan 8 00:29:20 2011 +0100 cpuidle: Make cpuidle_enable_device() call poll_idle_init() commit d8c216cfa57e8a579f41729cbb88c97835d9ac8d upstream. The following scenario is possible with the current cpuidle code and the ACPI cpuidle driver: (1) acpi_processor_cst_has_changed() is called, (2) cpuidle_disable_device() is called, (3) cpuidle_remove_state_sysfs() is called to remove the (presumably outdated) states info from sysfs, (3) acpi_processor_get_power_info() is called, the first entry in the pr->power.states[] table is filled with zeros, (4) acpi_processor_setup_cpuidle() is called and it doesn't fill the first entry in pr->power.states[], (5) cpuidle_enable_device() is called, (6) __cpuidle_register_device() is _not_ called, since the device has already been registered, (7) Consequently, poll_idle_init() is _not_ called either, (8) cpuidle_add_state_sysfs() is called to create the sysfs attributes for the new states and it uses the bogus first table entry from acpi_processor_get_power_info() for creating state0. This problem is avoided if cpuidle_enable_device() unconditionally calls poll_idle_init(). Reported-by: Len Brown Signed-off-by: Rafael J. Wysocki Signed-off-by: Len Brown Signed-off-by: Greg Kroah-Hartman commit e2dc856a9044ac90a7b004dafb84cc4ded479bc2 Author: Hans-Christian Egtvedt Date: Thu Dec 9 00:19:33 2010 +0100 avr32: use syscall prototypes from asm-generic instead of arch commit 664cb7142ced8b827e92e1851d1ed2cae922f225 upstream. This patch removes the redundant syscalls prototypes in the architecture specific syscalls.h header file. These were identical with the ones in asm-generic/syscalls.h. Signed-off-by: Hans-Christian Egtvedt Reported-by: Peter Huewe Reported-by: Sven Schnelle Signed-off-by: Greg Kroah-Hartman commit ca0557b6e7071543f5f96bbccb648f3e5d06369a Author: Sven Neumann Date: Fri Nov 12 11:36:22 2010 +0100 ds2760_battery: Fix calculation of time_to_empty_now commit 86af95039b69a90db15294eb1f9c147f1df0a8ea upstream. A check against division by zero was modified in commit b0525b48. Since this change time_to_empty_now is always reported as zero while the battery is discharging and as a negative value while the battery is charging. This is because current is negative while the battery is discharging. Fix the check introduced by commit b0525b48 so that time_to_empty_now is reported correctly during discharge and as zero while charging. Signed-off-by: Sven Neumann Acked-by: Daniel Mack Signed-off-by: Anton Vorontsov Signed-off-by: Greg Kroah-Hartman commit cbedbe4b52739b6228144f4457afc22d2d1bcc3d Author: Lars-Peter Clausen Date: Thu Nov 11 19:00:52 2010 +0100 jz4740-battery: Protect against concurrent battery readings commit 8ec98fe0b4ffdedce4c1caa9fb3d550f52ad1c6b upstream. We can not handle more then one ADC request at a time to the battery. The patch adds a mutex around the ADC read code to ensure this. Signed-off-by: Lars-Peter Clausen Signed-off-by: Anton Vorontsov Signed-off-by: Greg Kroah-Hartman commit 2138fe2a0ddb182cd6e316ee95b3b8ac174dfd89 Author: Milton Miller Date: Fri Jan 7 02:55:06 2011 -0600 virtio: remove virtio-pci root device commit 8b3bb3ecf1934ac4a7005ad9017de1127e2fbd2f upstream. We sometimes need to map between the virtio device and the given pci device. One such use is OS installer that gets the boot pci device from BIOS and needs to find the relevant block device. Since it can't, installation fails. Instead of creating a top-level devices/virtio-pci directory, create each device under the corresponding pci device node. Symlinks to all virtio-pci devices can be found under the pci driver link in bus/pci/drivers/virtio-pci/devices, and all virtio devices under drivers/bus/virtio/devices. Signed-off-by: Milton Miller Signed-off-by: Rusty Russell Acked-by: Michael S. Tsirkin Tested-by: Michael S. Tsirkin Acked-by: Gleb Natapov Tested-by: "Daniel P. Berrange" Signed-off-by: Greg Kroah-Hartman commit c091db7858ec13758c82797e32b88fa2243410aa Author: Tejun Heo Date: Wed Dec 22 10:06:36 2010 +0100 PCI: pci-stub: ignore zero-length id parameters commit 99a0fadf561e1f553c08f0a29f8b2578f55dd5f0 upstream. pci-stub uses strsep() to separate list of ids and generates a warning message when it fails to parse an id. However, not specifying the parameter results in ids set to an empty string. strsep() happily returns the empty string as the first token and thus triggers the warning message spuriously. Make the tokner ignore zero length ids. Reported-by: Chris Wright Reported-by: Prasad Joshi Signed-off-by: Jesse Barnes Signed-off-by: Greg Kroah-Hartman commit 955b7457cf4d69ce9264d11e49bea1a260a41adb Author: Paul Mundt Date: Tue Jan 11 15:02:59 2011 +0900 sh: Fix up legacy PTEA space attribute mapping. commit efb3e34b6176d30c4fe8635fa8e1beb6280cc2cd upstream. When p3_ioremap() was converted to ioremap_prot() there was some breakage introduced where the 29-bit segmentation logic would trap the area range and return an identity mapping without having allowed the area specification to force mapping through page tables. This wires up a PCC mask for pgprot verification to work out whether to short-circuit the identity mapping on legacy parts, restoring the previous behaviour. Reported-by: Nobuhiro Iwamatsu Signed-off-by: Paul Mundt Signed-off-by: Greg Kroah-Hartman commit e5c89fb9004c17bde4c80450bd0307c65ad302d8 Author: Thomas Taranowski Date: Wed Jan 12 17:00:44 2011 -0800 rapidio: fix hang on RapidIO doorbell queue full condition commit 12a4dc43911785f51a596f771ae0701b18d436f1 upstream. In fsl_rio_dbell_handler() the code currently simply acknowledges the QFI queue full interrupt, but does nothing to resolve the queue full condition. Instead, it jumps to the end of the isr. When a queue full condition occurs, the isr is then re-entered immediately and continually, forever. The fix is to just fall through and read out current doorbell entries. Signed-off-by: Thomas Taranowski Cc: Alexandre Bounine Cc: Kumar Gala Cc: Matt Porter Cc: Li Yang Cc: Thomas Moll Cc: Micha Nelissen Cc: Benjamin Herrenschmidt Cc: Grant Likely Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds Signed-off-by: Greg Kroah-Hartman commit 8cd8793363cd536a18f36f923788b2eabcdfbbcf Author: Theodore Ts'o Date: Mon Jan 10 12:51:28 2011 -0500 ext4: fix memory leak in ext4_free_branches commit 1c5b9e9065567876c2d4a7a16d78f0fed154a5bf upstream. Commit 40389687 moved a call to ext4_forget() out of ext4_free_branches and let ext4_free_blocks() handle calling bforget(). But that change unfortunately did not replace the call to ext4_forget() with brelse(), which was needed to drop the in-use count of the indirect block's buffer head, which lead to a memory leak when deleting files that used indirect blocks. Fix this. Thanks to Hugh Dickins for pointing this out. Signed-off-by: "Theodore Ts'o" Signed-off-by: Greg Kroah-Hartman commit 9166c290bea610c0283cbf91e12bf7baa7134e87 Author: Hugh Dickins Date: Thu Jan 13 15:47:30 2011 -0800 mm: fix migration hangs on anon_vma lock commit 1ce82b69e96c838d007f316b8347b911fdfa9842 upstream. Increased usage of page migration in mmotm reveals that the anon_vma locking in unmap_and_move() has been deficient since 2.6.36 (or even earlier). Review at the time of f18194275c39835cb84563500995e0d503a32d9a ("mm: fix hang on anon_vma->root->lock") missed the issue here: the anon_vma to which we get a reference may already have been freed back to its slab (it is in use when we check page_mapped, but that can change), and so its anon_vma->root may be switched at any moment by reuse in anon_vma_prepare. Perhaps we could fix that with a get_anon_vma_unless_zero(), but let's not: just rely on page_lock_anon_vma() to do all the hard thinking for us, then we don't need any rcu read locking over here. In removing the rcu_unlock label: since PageAnon is a bit in page->mapping, it's impossible for a !page->mapping page to be anon; but insert VM_BUG_ON in case the implementation ever changes. [akpm@linux-foundation.org: coding-style fixes] Signed-off-by: Hugh Dickins Reviewed-by: Mel Gorman Reviewed-by: Rik van Riel Cc: Naoya Horiguchi Cc: "Jun'ichi Nomura" Cc: Andi Kleen Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds Signed-off-by: Greg Kroah-Hartman commit 584494cd43347902fa3ea276cae7a2f53267910f Author: Paul Fox Date: Wed Jan 12 17:00:07 2011 -0800 rtc-cmos: fix suspend/resume commit 2fb08e6ca9f00d1aedb3964983e9c8f84b36b807 upstream. rtc-cmos was setting suspend/resume hooks at the device_driver level. However, the platform bus code (drivers/base/platform.c) only looks for resume hooks at the dev_pm_ops level, or within the platform_driver. Switch rtc_cmos to use dev_pm_ops so that suspend/resume code is executed again. Paul said: : The user visible symptom in our (XO laptop) case was that rtcwake would : fail to wake the laptop. The RTC alarm would expire, but the wakeup : wasn't unmasked. : : As for severity, the impact may have been reduced because if I recall : correctly, the bug only affected platforms with CONFIG_PNP disabled. Signed-off-by: Paul Fox Signed-off-by: Daniel Drake Acked-by: Rafael J. Wysocki Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds Signed-off-by: Greg Kroah-Hartman commit 14a03186beb1a7156937a14d97f139979b7ee336 Author: Dave Anderson Date: Wed Jan 12 17:00:36 2011 -0800 /proc/kcore: fix seeking commit ceff1a770933e2ca2bf995b453dade4ec47a9878 upstream. Commit 34aacb2920 ("procfs: Use generic_file_llseek in /proc/kcore") broke seeking on /proc/kcore. This changes it back to use default_llseek in order to restore the original behavior. The problem with generic_file_llseek is that it only allows seeks up to inode->i_sb->s_maxbytes, which is 2GB-1 on procfs, where the memory file offset values in the /proc/kcore PT_LOAD segments may exceed or start beyond that offset value. A similar revert was made for /proc/vmcore. Signed-off-by: Dave Anderson Acked-by: Frederic Weisbecker Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds Signed-off-by: Greg Kroah-Hartman commit 2a0e113ddab7184bc895e30a5de692cae6313a33 Author: Steve Wise Date: Fri Jan 21 17:00:34 2011 +0000 RDMA/cxgb4: Set the correct device physical function for iWARP connections commit 94788657c94169171971968c9d4b6222c5e704aa upstream. The PF passed to FW was 0, causing PCI failures in an SR-IOV environment. Signed-off-by: Steve Wise Signed-off-by: Roland Dreier Signed-off-by: Greg Kroah-Hartman commit 734c829a870e41c1c05b3cc258de912b3893af73 Author: Chuck Lever Date: Fri Jan 21 15:54:57 2011 +0000 NFS: Fix "kernel BUG at fs/aio.c:554!" commit 839f7ad6932d95f4d5ae7267b95c574714ff3d5b upstream. Nick Piggin reports: > I'm getting use after frees in aio code in NFS > > [ 2703.396766] Call Trace: > [ 2703.396858] [] ? native_sched_clock+0x27/0x80 > [ 2703.396959] [] ? put_lock_stats+0xe/0x40 > [ 2703.397058] [] ? lock_release_holdtime+0xa8/0x140 > [ 2703.397159] [] lock_acquire+0x95/0x1b0 > [ 2703.397260] [] ? aio_put_req+0x2b/0x60 > [ 2703.397361] [] ? get_parent_ip+0x11/0x50 > [ 2703.397464] [] _raw_spin_lock_irq+0x41/0x80 > [ 2703.397564] [] ? aio_put_req+0x2b/0x60 > [ 2703.397662] [] aio_put_req+0x2b/0x60 > [ 2703.397761] [] do_io_submit+0x2be/0x7c0 > [ 2703.397895] [] sys_io_submit+0xb/0x10 > [ 2703.397995] [] system_call_fastpath+0x16/0x1b > > Adding some tracing, it is due to nfs completing the request then > returning something other than -EIOCBQUEUED, so aio.c > also completes the request. To address this, prevent the NFS direct I/O engine from completing async iocbs when the forward path returns an error without starting any I/O. This fix appears to survive ^C during both "xfstest no. 208" and "fsx -Z." It's likely this bug has existed for a very long while, as we are seeing very similar symptoms in OEL 5. Copying stable. Signed-off-by: Chuck Lever Signed-off-by: Trond Myklebust Signed-off-by: Greg Kroah-Hartman commit f66fd5da68a1b6da7b528fe99df0b418719956ec Author: Trond Myklebust Date: Thu Jan 27 14:55:39 2011 -0500 NFS: Fix an NFS client lockdep issue commit e00b8a24041f37e56b4b8415ce4eba1cbc238065 upstream. There is no reason to be freeing the delegation cred in the rcu callback, and doing so is resulting in a lockdep complaint that rpc_credcache_lock is being called from both softirq and non-softirq contexts. Reported-by: Chuck Lever Signed-off-by: Trond Myklebust Signed-off-by: Greg Kroah-Hartman commit f6507ad9cfb84ee92579115c6a5310164399906b Author: Mike Frysinger Date: Tue Jan 11 23:08:19 2011 -0500 ASoC: Blackfin TDM: fix missed snd_soc_dai_get_drvdata update commit 15d2e22b820bad62854d6ad99d8af8320adf4a91 upstream. One spot was missed in this driver when converting from snd_soc_dai.private_data to snd_soc_dai_get_drvdata. Signed-off-by: Mike Frysinger Acked-by: Liam Girdwood Signed-off-by: Mark Brown Signed-off-by: Greg Kroah-Hartman commit 27e729bc9204abb2c989fdfc73cad682a5e5c452 Author: Mike Frysinger Date: Tue Jan 11 19:57:33 2011 -0500 ASoC: Blackfin AC97: fix build error after multi-component update commit e9c2048915048d605fd76539ddd96f00d593e1eb upstream. We need to tweak how we query the active capture/playback state after the recent overhauls of common code. Signed-off-by: Mike Frysinger Acked-by: Liam Girdwood Signed-off-by: Mark Brown Signed-off-by: Greg Kroah-Hartman commit d6b6225fbc958ebb0f077103f8ffd32b40f7fa08 Author: Dimitris Papastamos Date: Fri Jan 14 15:59:13 2011 +0000 ASoC: WM8990: msleep() takes milliseconds not jiffies commit 7ebcf5d6021a696680ee77d9162a2edec2d671dd upstream. Signed-off-by: Dimitris Papastamos Acked-by: Liam Girdwood Signed-off-by: Mark Brown Signed-off-by: Greg Kroah-Hartman commit f9344fd27eab6c76963cae0a7b739f76150e9f65 Author: Mark Brown Date: Fri Dec 3 16:02:10 2010 +0000 ASoC: When disabling WM8994 FLL force a source selection commit 4514e8997fbefd5befd6176ac9785e287b4daed4 upstream. When we disable the WM8994 FLL code path sharing means that we end up writing out a configuration. Currently this is the currently active input and output frequency (which causes snd_soc_update_bits() to suppress actual writes both immediately and in the common case where we reenable the same configuration later) but we allow machine drivers to pass through a source of zero. Since the register values written are one less than the source constants this causes corruption of other bitfields in the register. Fix this by using the most recently configured FLL source when none is provided. Signed-off-by: Mark Brown Acked-by: Liam Girdwood Signed-off-by: Greg Kroah-Hartman commit 62113697bd20e68aead4ab528d59e782081633c6 Author: David Henningsson Date: Thu Feb 10 15:39:19 2011 +0100 ALSA: HDA: Add subwoofer quirk for Acer Aspire 8942G commit a6c47a85b8e7e4a8c47394607c5e5c43224b0892 upstream. According to the reporter, node 0x15 needs to be muted for subwoofer to stop sounding. This pin is marked as unused by BIOS, so fix that. BugLink: http://bugs.launchpad.net/bugs/715877 Reported-by: Hans Peter Signed-off-by: David Henningsson Signed-off-by: Takashi Iwai Signed-off-by: Greg Kroah-Hartman commit 381a2c22666521dd7cda3ed49f85ba1d5d4325dc Author: Clemens Ladisch Date: Thu Feb 10 16:15:44 2011 +0100 ALSA: hrtimer: handle delayed timer interrupts commit b1d4f7f4bdcf9915c41ff8cfc4425c84dabb1fde upstream. If a timer interrupt was delayed too much, hrtimer_forward_now() will forward the timer expiry more than once. When this happens, the additional number of elapsed ALSA timer ticks must be passed to snd_timer_interrupt() to prevent the ALSA timer from falling behind. This mostly fixes MIDI slowdown problems on highly-loaded systems with badly behaved interrupt handlers. Signed-off-by: Clemens Ladisch Reported-and-tested-by: Arthur Marsh Signed-off-by: Takashi Iwai Signed-off-by: Greg Kroah-Hartman commit 68e8c2c1fe160b7d1eab3aff9fa58b0e2b2b7068 Author: Dirk Eibach Date: Wed Feb 9 04:51:34 2011 -0500 hwmon: (lm63) Consider LM64 temperature offset commit 2778fb13ba0fed1b3e4a040e71f7881d399610a3 upstream. LM64 has 16 degrees Celsius temperature offset on all remote sensor registers. This was not considered When LM64 support was added to lm63.c. Signed-off-by: Dirk Eibach Signed-off-by: Guenter Roeck Signed-off-by: Greg Kroah-Hartman commit b3f4bd334620b955f16b33e876720815cae0391a Author: Edgar (gimli) Hucek Date: Tue Nov 9 17:38:42 2010 +0100 input: bcm5974: Add support for MacBookAir3 commit 6021afcf19d8c6f5db6d11cadcfb6a22d0c28a48 upstream. This patch adds support for the MacBookAir3,1 and MacBookAir3,2 models. [rydberg@euromail.se: touchpad range calibration] Signed-off-by: Edgar (gimli) Hucek Signed-off-by: Henrik Rydberg Signed-off-by: Jiri Kosina Signed-off-by: Greg Kroah-Hartman commit ee7ae3824e0a089b04935076eb2c051db701f2c5 Author: Jiri Kosina Date: Sat Jan 8 01:37:26 2011 -0800 Input: i8042 - introduce 'notimeout' blacklist for Dell Vostro V13 commit f8313ef1f448006207f12c107123522c8bc00f15 upstream. i8042 controller present in Dell Vostro V13 errorneously signals spurious timeouts. Introduce i8042.notimeout parameter for ignoring i8042-signalled timeouts and apply this quirk automatically for Dell Vostro V13, based on DMI match. In addition to that, this machine also needs to be added to nomux blacklist. Signed-off-by: Jiri Kosina Signed-off-by: Dmitry Torokhov Cc: Tim Gardner Signed-off-by: Greg Kroah-Hartman commit 5ce60110c2c372cc9e1f1e52636b4f84417142ec Author: Takashi Iwai Date: Wed Feb 2 17:16:38 2011 +0100 ALSA: hda - Fix memory leaks in conexant jack arrays commit 70f7db11c45a313b23922cacf248c613c3b2144c upstream. The Conexant codec driver adds the jack arrays in init callback which may be called also in each PM resume. This results in the addition of new jack element at each time. The fix is to check whether the requested jack is already present in the array. Reference: Novell bug 668929 https://bugzilla.novell.com/show_bug.cgi?id=668929 Signed-off-by: Takashi Iwai Signed-off-by: Greg Kroah-Hartman commit af21ae870ed23f4671b07909342e1d9814529105 Author: David Henningsson Date: Tue Jan 25 19:44:26 2011 +0100 ALSA: HDA: Fix dmesg output of HDMI supported bits commit d757534ed15387202e322854cd72dc58bbb975de upstream. This typo caused the dmesg output of the supported bits of HDMI to be cut off early. Signed-off-by: David Henningsson Signed-off-by: Takashi Iwai Signed-off-by: Greg Kroah-Hartman commit 3c87fc6520b43ad5147ca5f621e70a9d23547fc8 Author: Hans-Christian Egtvedt Date: Mon Jan 24 16:09:56 2011 +0100 ALSA: fix invalid hardware.h include in ac97c for AVR32 architecture commit fd76804f3f5484b35e6a51214c91e916ebba05aa upstream. This patch fixes the non-compiling AC97C driver for AVR32 architecture by include mach/hardware.h only for AT91 architecture. The AVR32 architecture does not supply the hardware.h include file. Signed-off-by: Hans-Christian Egtvedt Signed-off-by: Takashi Iwai Signed-off-by: Greg Kroah-Hartman commit cc87896c02bfa12c4833694f8f0d367f9220d9b6 Author: Raymond Yau Date: Sun Jan 16 10:55:54 2011 +0800 ALSA : au88x0 - Limit number of channels to fix Oops via OSS emu commit d9ab344336f74c012f6643ed3d1ad8ca0136de3b upstream. Fix playback/capture channels patch to change supported playback channels of au8830 to 1,2,4 and capture channels to 1,2. This prevent oops when oss emulation use SNDCTL_DSP_CHANNELS to set 3 Channels Signed-off-by: Raymond Yau Signed-off-by: Takashi Iwai Signed-off-by: Greg Kroah-Hartman commit 76c70be2b09f278fad695ec98184de3d2b45e40f Author: Mauro Carvalho Chehab Date: Mon Oct 25 17:51:15 2010 -0300 em28xx: Fix audio input for Terratec Grabby commit a3fa904ec79b94f0db7faed010ff94d42f7d1d47 upstream. The audio input line was wrong. Fix it. Signed-off-by: Mauro Carvalho Chehab Signed-off-by: Greg Kroah-Hartman commit 4e436129a339e6d9bbb58f07869721d9943662b8 Author: Mauro Carvalho Chehab Date: Thu Jan 6 08:16:04 2011 -0200 radio-aimslab.c: Fix gcc 4.5+ bug commit e3c92215198cb6aa00ad38db2780faa6b72e0a3f upstream. gcc 4.5+ doesn't properly evaluate some inlined expressions. A previous patch were proposed by Andrew Morton using noinline. However, the entire inlined function is bogus, so let's just remove it and be happy. Reported-by: Andrew Morton Signed-off-by: Mauro Carvalho Chehab Signed-off-by: Greg Kroah-Hartman commit 4bd652a53bd711ef0ef8d42c5525bc6d71aeef54 Author: Luis R. Rodriguez Date: Wed Oct 20 10:18:54 2010 -0700 cfg80211: fix allowing country IEs for WIPHY_FLAG_STRICT_REGULATORY commit 749b527b21465fb079796c03ffb4302584dc31c1 upstream. We should be enabling country IE hints for WIPHY_FLAG_STRICT_REGULATORY even if we haven't yet recieved regulatory domain hint for the driver if it needed one. Without this Country IEs are not passed on to drivers that have set WIPHY_FLAG_STRICT_REGULATORY, today this is just all Atheros chipset drivers: ath5k, ath9k, ar9170, carl9170. This was part of the original design, however it was completely overlooked... Cc: Easwar Krishnan Signed-off-by: Luis R. Rodriguez Signed-off-by: John W. Linville Signed-off-by: Greg Kroah-Hartman commit 6b7ea7728843a3e94eacdafc05bddb0206880bc0 Author: Luis R. Rodriguez Date: Wed Oct 20 10:18:53 2010 -0700 cfg80211: pass the reg hint initiator to helpers commit 7ca43d03b1291481bdf894bbaec5d580e7684e7d upstream. This is required later. Cc: Easwar Krishnan Signed-off-by: Luis R. Rodriguez Signed-off-by: John W. Linville Signed-off-by: Greg Kroah-Hartman commit f998964b8b075df0c06120f3f5f2e1e1e97b350e Author: Kashyap, Desai Date: Tue Nov 17 13:16:37 2009 +0530 mpt2sas: add missing initialization of scsih_cmds commit d685c262083dcd5fd98b7499b22a377a3225229c upstream. Internal command scsih_cmds init is included in mpt2sas_base_attach. Signed-off-by: Kashyap Desai Signed-off-by: James Bottomley Signed-off-by: Greg Kroah-Hartman commit 225a7fe7319165735cd10d27c89739e8d8aecab1 Author: Kashyap, Desai Date: Tue Jan 4 11:38:39 2011 +0530 mpt2sas: Kernel Panic during Large Topology discovery commit 4224489f45b503f0a1f1cf310f76dc108f45689a upstream. There was a configuration page timing out during the initial port enable at driver load time. The port enable would fail, and this would result in the driver unloading itself, meanwhile the driver was accessing freed memory in another context resulting in the panic. The fix is to prevent access to freed memory once the driver had issued the diag reset which woke up the sleeping port enable process. The routine _base_reset_handler was reorganized so the last sleeping process woken up was the port_enable. Signed-off-by: Kashyap Desai Signed-off-by: James Bottomley Signed-off-by: Greg Kroah-Hartman commit a3919fdea2ca0e0c92f724374b1971a7ab6e38da Author: Kashyap, Desai Date: Tue Jan 4 11:34:57 2011 +0530 mpt2sas: Correct resizing calculation for max_queue_depth commit 11e1b961ab067ee3acaf723531da4d3f23e1d6f7 upstream. The ioc->hba_queue_depth is not properly resized when the controller firmware reports that it supports more outstanding IO than what can be fit inside the reply descriptor pool depth. This is reproduced by setting the controller global credits larger than 30,000. The bug results in an incorrect sizing of the queues. The fix is to resize the queue_size by dividing queue_diff by two. Signed-off-by: Kashyap Desai Signed-off-by: James Bottomley Signed-off-by: Greg Kroah-Hartman commit bd1c94b55593c2265caa59a434dd942f638993ef Author: Kashyap, Desai Date: Wed Jan 5 17:54:32 2011 +0530 mpt2sas: Fix the race between broadcast asyn event and scsi command completion commit ec07a053597bdab51cbd23619f9f9f392712508a upstream. False timeout after hard resets, there were two issues which leads to timeout. (1) Panic because of invalid memory access in the broadcast asyn event processing routine due to a race between accessing the scsi command pointer from broadcast asyn event processing thread and completing the same scsi command from the interrupt context. (2) Broadcast asyn event notifcations are not handled due to events ignored while the broadcast asyn event is activity being processed from the event process kernel thread. In addition, changed the ABRT_TASK_SET to ABORT_TASK in the broadcast async event processing routine. This is less disruptive to other request that generate Broadcast Asyn Primitives besides target reset. e.g clear reservations, microcode download,and mode select. Signed-off-by: Kashyap Desai Signed-off-by: James Bottomley Signed-off-by: Greg Kroah-Hartman commit 6866dfaf4ca45b3285e0f91b12d08696848a1eea Author: Kashyap, Desai Date: Tue Jan 4 11:34:17 2011 +0530 mpt2sas: fix internal device reset for older firmware prior to MPI Rev K commit efe82a16bc0f9f9e1fc8fa706eb0309fcd57770a upstream. The "internal device reset complete" event is not supported for older firmware prior to MPI Rev K We added a check in the driver so the "internal device reset" event is ignored for older firmware. When ignored, the tm_busy flag doesn't get set nor cleared. Without this fix, IO queues would be froozen indefinetly after the "internal device reset" event, as the "complete" event never sent to clear the flag. Signed-off-by: Kashyap Desai Signed-off-by: James Bottomley Signed-off-by: Greg Kroah-Hartman commit 6d4be83ac8b871f3ebef3bd0f4a63f4f69a5f335 Author: Kashyap, Desai Date: Tue Jan 4 11:32:13 2011 +0530 mpt2sas: Fix device removal handshake for zoned devices commit 4dc2757a2e9a9d1f2faee4fc6119276fc0061c16 upstream. When zoning end devices, the driver is not sending device removal handshake alogrithm to firmware. This results in controller firmware not sending sas topology add events the next time the device is added. The fix is the driver should be doing the device removal handshake even though the PHYSTATUS_VACANT bit is set in the PhyStatus of the event data. The current design is avoiding the handshake when the VACANT bit is set in the phy status. Signed-off-by: Kashyap Desai Signed-off-by: James Bottomley Signed-off-by: Greg Kroah-Hartman commit 9a00ffdc0858005a186f5404a882546557cb5114 Author: David Dillow Date: Sun Jan 16 15:12:39 2011 -0500 fix incorrect value of SCSI_MAX_SG_CHAIN_SEGMENTS due to include file ordering commit ac61c46f4f7665ab4548e90430c37b2529e16cff upstream. If the compiled object doesn't include linux/scatterlist.h before scsi/scsi.h, it will get an incorrect definition of SCSI_MAX_SG_CHAIN_SEGMENTS. Signed-off-by: David Dillow Signed-off-by: James Bottomley Signed-off-by: Greg Kroah-Hartman commit 5c52e065997c9eda03fe5f1011ff05ed7efda402 Author: Kashyap, Desai Date: Tue Jan 4 11:40:23 2011 +0530 mpt2sas: fix Integrated Raid unsynced on shutdown problem commit 3a9c913a3e57b170887d39456e04c18f2305ec67 upstream. Issue: IR shutdown(sending) and IR shutdown(complete) messages not listed in /var/log/messages when driver is removed. The driver needs to issue a MPI2_RAID_ACTION_SYSTEM_SHUTDOWN_INITIATED request when the driver is unloaded so the IR metadata journal is updated. If this request is not sent, then the volume would need a "check consistency" issued on the next bootup if the volume was roamed from one initiator to another. The current driver supports this feature only when the system is rebooted, however this also need to be supported if the driver is unloaded Fix: To fix this issue, the driver is going to need to call the _scsih_ir_shutdown prior to reporting the volumes missing from the OS, hence the device handles are still present. Signed-off-by: Kashyap Desai Signed-off-by: James Bottomley Signed-off-by: Greg Kroah-Hartman commit fc01d7640a37c1a94a45116454c5bb0dc9e734cb Author: James Bottomley Date: Thu Jan 20 17:26:44 2011 -0600 libsas: fix runaway error handler problem commit 9ee91f7fb550a4c82f82d9818e42493484c754af upstream. libsas makes use of scsi_schedule_eh() but forgets to clear the host_eh_scheduled flag in its error handling routine. Because of this, the error handler thread never gets to sleep; it's constantly awake and trying to run the error routine leading to console spew and inability to run anything else (at least on a UP system). The fix is to clear the flag as we splice the work queue. Signed-off-by: James Bottomley Signed-off-by: Greg Kroah-Hartman commit b6a8c9a655803a612d65fe2a139ebff7ded82a1d Author: James Bottomley Date: Fri Dec 17 15:36:34 2010 -0500 fix medium error problems with some arrays which can cause data corruption commit a8733c7baf457b071528e385a0b7d4aaec79287c upstream. Our current handling of medium error assumes that data is returned up to the bad sector. This assumption holds good for all disk devices, all DIF arrays and most ordinary arrays. However, an LSI array engine was recently discovered which reports a medium error without returning any data. This means that when we report good data up to the medium error, we've reported junk originally in the buffer as good. Worse, if the read consists of requested data plus a readahead, and the error occurs in readahead, we'll just strip off the readahead and report junk up to userspace as good data with no error. The fix for this is to have the error position computation take into account the amount of data returned by the driver using the scsi residual data. Unfortunately, not every driver fills in this data, but for those who don't, it's set to zero, which means we'll think a full set of data was transferred and the behaviour will be identical to the prior behaviour of the code (believe the buffer up to the error sector). All modern drivers seem to set the residual, so that should fix up the LSI failure/corruption case. Reported-by: Douglas Gilbert Signed-off-by: James Bottomley Signed-off-by: Greg Kroah-Hartman commit 017f6b7ef726ba5f621d9ff25e9c7f3e839cbea8 Author: Jan Glauber Date: Wed Jan 5 12:47:52 2011 +0100 qdio: use proper QEBSM operand for SIGA-R and SIGA-S commit 958c0ba403cb6a693b54be2389f9ef53377fa259 upstream. If QIOASSIST is enabled for a qdio device the SIGA instruction requires a modified function code. This function code modifier was missing for SIGA-R and SIGA-S which can lead to a kernel panic caused by an operand exception. Signed-off-by: Jan Glauber Signed-off-by: Martin Schwidefsky Signed-off-by: Greg Kroah-Hartman commit 886de5fc897f329a74c59b0787030e4e114e22e3 Author: Rajkumar Manoharan Date: Thu Jan 27 18:39:37 2011 +0530 ath9k_hw: Fix system hang when resuming from S3/S4 commit 5b64aa72ead6f8be488d2be7af579f0d69fb7a6e upstream. The bit 6 & 7 of AR_WA (0x4004) should be enabled only for the chips that are supporting L0s functionality while resuming back from S3/S4. Enabling these bits for AR9280 is causing system hang within a few S3/S4-resume cycles. Cc: Jack Lee Signed-off-by: Rajkumar Manoharan Signed-off-by: John W. Linville Signed-off-by: Greg Kroah-Hartman commit f38ad0651d4a85b52e5f61816a4f95d6697bf531 Author: Luis R. Rodriguez Date: Thu Jan 20 17:47:39 2011 -0800 ath9k_hw: disabled PAPRD for AR9003 commit 6f4810101a629b31b5427872a09ea092cfc5c4bd upstream. AR9003's PAPRD was enabled prematurely, and is causing some large discrepancies on throughput and network connectivity. For example downlink (RX) throughput against an AR9280 AP can vary widlely from 43-73 Mbit/s while disabling this gets AR9382 (2x2) up to around 93 Mbit/s in a 2.4 GHz HT20 setup. Cc: Paul Shaw Signed-off-by: Luis R. Rodriguez Signed-off-by: John W. Linville Signed-off-by: Greg Kroah-Hartman commit 19db6c630c7cb10a32e772b21fe94f91c866d9fa Author: Rajkumar Manoharan Date: Mon Jan 17 15:21:40 2011 +0530 ath9k_hw: do PA offset calibration only on longcal interval commit 811ea256b30b37091b5bbf41517404cf98ab56c1 upstream. The power detector adc offset calibration has to be done on 4 minutes interval (longcal * pa_skip_count). But the commit "ath9k_hw: fix a noise floor calibration related race condition" makes the PA calibration executed more frequently beased on nfcal_pending value. Running PAOffset calibration lesser than longcal interval doesn't help anything and the worse part is that it causes NF load timeouts and RX deaf conditions. In a very noisy environment, where the distance b/w AP & station is ~10 meter and running a downlink udp traffic with frequent background scan causes "Timeout while waiting for nf to load: AR_PHY_AGC_CONTROL=0x40d1a" and moves the chip into deaf state. This issue was originaly reported in Android platform where the network-manager application does bgscan more frequently on AR9271 chips. (AR9285 family usb device). Signed-off-by: Vasanthakumar Thiagarajan Signed-off-by: Rajkumar Manoharan Signed-off-by: John W. Linville Signed-off-by: Greg Kroah-Hartman commit 0a92ff6a8606f7e38053b4af5488532403e7a9a9 Author: Rajkumar Manoharan Date: Thu Dec 30 19:07:44 2010 +0530 ath9k: fix beacon restart on channel change commit 1186488b4a4d4871e40cb1604ba3ede3d4b7cc90 upstream. Restart the beacon timers only if the beacon was already configured. Otherwise beacons timers are restarted unnecessarily in unassociated state too. Signed-off-by: Rajkumar Manoharan Signed-off-by: John W. Linville Signed-off-by: Greg Kroah-Hartman commit 937d8fb4f80b17de1d7e541c850d215875558e81 Author: Luis R. Rodriguez Date: Mon Dec 20 11:29:59 2010 -0500 ath9k: fix aphy / wiphy idle mismatch commit afe68d0a8f5961652e26cea39d74e2cc820de841 upstream. ath9k supports its own set of virtual wiphys, and it uses the mac80211 idle notifications to know when a device needs to be idle or not. We recently changed ath9k to force idle on driver stop() and on resume but forgot to take into account ath9k's own virtual wiphy idle states. These are used internally by ath9k to check if the device's radio should be powered down on each idle call. Without this change its possible that the device could have been forced off but the virtual wiphy idle was left on. Cc: Paul Stewart Cc: Amod Bodas Signed-off-by: Luis R. Rodriguez Signed-off-by: John W. Linville Signed-off-by: Greg Kroah-Hartman commit 2de4a15c5dd070315062c7a9218889d1b3155362 Author: Luis R. Rodriguez Date: Tue Dec 7 15:13:20 2010 -0800 ath9k: fix assumptions for idle calls on suspend/resume commit a08e7ade9ddf4fe79576f953cc5c1725e944d26c upstream. mac80211 will notify drivers when to go idle and ath9k assumed that it would get further notifications for idle states after a device stop() config call but as per agreed semantics the idle state of the radio is left up to driver after mac80211 issues the stop() callback. The driver is resposnbile for ensuring the device remains idle after that even between suspend / resume calls. This fixes suspend/resume when you issue suspend and resume twice on ath9k when ath9k_stop() was already called. We need to put the radio to full sleep in order for resume to work correctly. What might seem fishy is we are turning the radio off after resume. The reason why we do this is because we know we should not have anything enabled after a mac80211 tells us to stop(), if we resume and never get a start() we won't get another stop() by mac80211 so to be safe always bring the 802.11 device with the radio disabled after resume, this ensures that if we suspend we already have the radio disabled and only a start() will ever trigger it on. Cc: Paul Stewart Cc: Amod Bodas Signed-off-by: Luis R. Rodriguez Signed-off-by: John W. Linville Signed-off-by: Greg Kroah-Hartman commit 04bd924d6a17df87da854c73e70e7ec91736a8a7 Author: Vasanthakumar Thiagarajan Date: Wed Nov 10 05:03:15 2010 -0800 ath9k: Fix bug in delimiter padding computation commit 39ec2997c374b528cdbf65099b6d6b8593a67f7f upstream. There is a roundng error in delimiter padding computation which causes severe throughput drop with some of AR9003. signed-off-by: Felix Fietkau Signed-off-by: Vasanthakumar Thiagarajan Signed-off-by: John W. Linville Signed-off-by: Greg Kroah-Hartman commit 53bcdef7cadf61f75c56b2746f90359fc63c8f56 Author: Luis R. Rodriguez Date: Tue Oct 26 15:27:24 2010 -0700 ath9k: move the PCU lock to the sc structure commit 4bdd1e978ede034c1211957eb17eaf50de00d234 upstream. The PCU lock should be used to contend TX DMA as well, this will be done next. This is part of a series of patches which fix stopping TX DMA completley when requested on the driver. For more details about this issue refer to this thread: http://marc.info/?l=linux-wireless&m=128629803703756&w=2 Tested-by: Ben Greear Cc: Kyungwan Nam Signed-off-by: Luis R. Rodriguez Signed-off-by: John W. Linville Signed-off-by: Greg Kroah-Hartman commit ea728e5324acf9f47176c00dbf094d1f9dd2dddb Author: Luis R. Rodriguez Date: Tue Oct 26 15:27:23 2010 -0700 ath9k: simplify hw reset locking commit 9d94674ab754be0e275120a183670ead435f9c0d upstream. The new PCU lock is better placed so we can just contend against that when trying to reset hardware. This is part of a series of patches which fix stopping TX DMA completley when requested on the driver. For more details about this issue refer to this thread: http://marc.info/?l=linux-wireless&m=128629803703756&w=2 Tested-by: Ben Greear Cc: Kyungwan Nam Signed-off-by: Luis R. Rodriguez Signed-off-by: John W. Linville commit 5d09af81ddf7a3cfdff993e07038cf08eed4bc66 Author: Vasanthakumar Thiagarajan Date: Wed Nov 10 05:03:11 2010 -0800 ath9k_hw: Fix XPABIAS level configuration for AR9003 commit 52a0e2477dac2106bc1688cbe9615cdafc9deb7d upstream. Improper configuration of 0x16288 and 0x16290 would affect transmission. Signed-off-by: Vasanthakumar Thiagarajan Signed-off-by: John W. Linville Signed-off-by: Greg Kroah-Hartman commit 08bf11dd39bfeae1b77806ce866de77b0afb6029 Author: Sujith Manoharan Date: Tue Dec 28 14:28:05 2010 +0530 ath9k_htc: Handle pending URBs properly commit ff8f59b5bbdf1527235b8c88d859c7d23691324f upstream. When doing a channel change, the pending URBs have to be killed properly on calling htc_stop(). This fixes the probe response timeout seen when sending UDP traffic at a high rate and running background scan at the same time. Signed-off-by: Sujith Manoharan Signed-off-by: John W. Linville Signed-off-by: Greg Kroah-Hartman commit 1e9afad375f51457588820d8cf687a8656bdbd23 Author: Don Fry Date: Sun Feb 6 09:29:45 2011 -0800 iwlagn: Re-enable RF_KILL interrupt when down commit 3dd823e6b86407aed1a025041d8f1df77e43a9c8 upstream. With commit 554d1d027b19265c4aa3f718b3126d2b86e09a08 only one RF_KILL interrupt will be seen by the driver when the interface is down. Re-enable the interrupt when it occurs to see all transitions. Signed-off-by: Don Fry Signed-off-by: Wey-Yi Guy Signed-off-by: John W. Linville Signed-off-by: Greg Kroah-Hartman commit a15fced40560b8e333b37eb181164df126735e4a Author: Stanislaw Gruszka Date: Thu Dec 23 12:38:21 2010 +0100 iwlagn: enable only rfkill interrupt when device is down commit 554d1d027b19265c4aa3f718b3126d2b86e09a08 upstream. Since commit 6cd0b1cb872b3bf9fc5de4536404206ab74bafdd "iwlagn: fix hw-rfkill while the interface is down", we enable interrupts when device is not ready to receive them. However hardware, when it is in some inconsistent state, can generate other than rfkill interrupts and crash the system. I can reproduce crash with "kernel BUG at drivers/net/wireless/iwlwifi/iwl-agn.c:1010!" message, when forcing firmware restarts. To fix only enable rfkill interrupt when down device and after probe. I checked patch on laptop with 5100 device, rfkill change is still passed to user space when device is down. Signed-off-by: Stanislaw Gruszka Acked-by: Wey-Yi Guy Signed-off-by: John W. Linville Signed-off-by: Greg Kroah-Hartman commit 4466efc5a80c185b64749ee08c572cc6b2383a86 Author: Felix Fietkau Date: Sat Dec 18 19:30:48 2010 +0100 mac80211: fix initialization of skb->cb in ieee80211_subif_start_xmit commit 489ee9195a7de9e6bc833d639ff6b553ffdad90e upstream. The change 'mac80211: Fix BUG in pskb_expand_head when transmitting shared skbs' added a check for copying the skb if it's shared, however the tx info variable still points at the cb of the old skb Signed-off-by: Felix Fietkau Acked-by: Helmut Schaa Signed-off-by: John W. Linville Signed-off-by: Greg Kroah-Hartman commit 481335e5059076b32e768545d6a5d9bafa5ba84d Author: Felix Fietkau Date: Mon Jan 24 19:28:49 2011 +0100 mac80211: fix a crash in ieee80211_beacon_get_tim on change_interface commit eb3e554b4b3a56386ef5214dbe0e3935a350178b upstream. Some drivers (e.g. ath9k) do not always disable beacons when they're supposed to. When an interface is changed using the change_interface op, the mode specific sdata part is in an undefined state and trying to get a beacon at this point can produce weird crashes. To fix this, add a check for ieee80211_sdata_running before using anything from the sdata. Signed-off-by: Felix Fietkau Signed-off-by: John W. Linville Signed-off-by: Greg Kroah-Hartman commit 5df006f7d181e262a68030d89db5a16a30ff7840 Author: Luciano Coelho Date: Wed Jan 12 15:18:11 2011 +0200 mac80211: use maximum number of AMPDU frames as default in BA RX commit 82694f764dad783a123394e2220b92b9be721b43 upstream. When the buffer size is set to zero in the block ack parameter set field, we should use the maximum supported number of subframes. The existing code was bogus and was doing some unnecessary calculations that lead to wrong values. Thanks Johannes for helping me figure this one out. Cc: Johannes Berg Signed-off-by: Luciano Coelho Reviewed-by: Johannes Berg Signed-off-by: John W. Linville commit 5efbd432c45ff09f0cafd8f1329693d3fb802fff Author: Johannes Berg Date: Mon Jan 3 19:42:24 2011 +0100 mac80211: add missing synchronize_rcu commit d2460f4b2fa6dbdeec800414f9cf5b1fc8b71197 upstream. commit ad0e2b5a00dbec303e4682b403bb6703d11dcdb2 Author: Johannes Berg Date: Tue Jun 1 10:19:19 2010 +0200 mac80211: simplify key locking removed the synchronization against RCU and thus opened a race window where we can use a key for TX while it is already freed. Put a synchronisation into the right place to close that window. Reported-by: Jussi Kivilinna Signed-off-by: Johannes Berg Signed-off-by: John W. Linville commit fc17a355cce36e03c43d7f06001296267f90c822 Author: Milton Miller Date: Thu Dec 30 02:01:03 2010 -0600 mac80211: fix mesh forwarding when ratelimited too commit 919bbad580445801c22ef6ccbe624551fee652bd upstream. Commit b51aff057c9d0ef6c529dc25fd9f775faf7b6c63 said: Under memory pressure, the mac80211 mesh code may helpfully print a message that it failed to clone a mesh frame and then will proceed to crash trying to use it anyway. Fix that. Avoid the reference whenever the frame copy is unsuccessful regardless of the debug message being suppressed or printed. Signed-off-by: Milton Miller Signed-off-by: John W. Linville Signed-off-by: Greg Kroah-Hartman commit ce40627dba4a0e216f88e738be707b2b9021a8d1 Author: Denis Kirjanov Date: Mon Jan 10 20:09:30 2011 +0000 staging: rt2860: Fix incorrect netif_stop_queue usage warning commit 9c33008412683eba91bce2dc4575f28c728b6bd1 upstream. The TX queues are allocated inside register_netdev. It doesn't make any sense to stop the queue before allocation. Signed-off-by: Denis Kirjanov Signed-off-by: Greg Kroah-Hartman commit 0a015c0b38c7fe52fd8d45c8ae51aff5764fbd80 Author: Chien-Chia Chen Date: Thu Dec 9 10:52:08 2010 +0800 Staging: rt2860: fix previous patch error commit 1f0613158ea14b399fd7a16470630a729ba9d0c3 upstream. Somehow Greg messed up the last patch and missed a chunk. This patch contains the missing chunk. Acked-by: Chun-Yi Lee Signed-off-by: Chien-Chia Chen Signed-off-by: Greg Kroah-Hartman commit db448d8172e5ab6bba6814e518e7185da55cb9cc Author: Chien-Chia Chen Date: Wed Dec 8 14:20:33 2010 -0800 Staging: rt3090: Fix RT3090 scan AP function commit 1226056d9608d241db4b558a0d88a347ad5c66ae upstream. Fix RT3090 scan AP function. This patch fixes the rt3090 wireless module failed to scan AP around due to Windows driver causing rt3090 module unable to scan AP in Linux. Acked-by: Chun-Yi Lee Signed-off-by: Chien-Chia Chen Signed-off-by: Greg Kroah-Hartman commit f4272b858a4343ed3067002ecfe24d456b1f7f9f Author: Haiyang Zhang Date: Wed Feb 2 13:42:58 2011 -0800 staging: hv: Enable sending GARP packet after live migration commit 7c161d0b900ea9bd9fc5ea5d3fa9916e9eb0dd88 upstream. The hv_netvsc gets RNDIS_STATUS_MEDIA_CONNECT event after the VM is live migrated. Adding call to netif_notify_peers() for this event to send GARP (Gratuitous ARP) to notify network peers. Otherwise, the VM's network connection may stop after a live migration. This patch should also be applied to stable kernel 2.6.32 and later. Signed-off-by: Haiyang Zhang Signed-off-by: Hank Janssen Signed-off-by: Greg Kroah-Hartman commit 12347414227879cb9d1b31d3ad0efd78329bc983 Author: Timo Teräs Date: Fri Dec 17 11:40:24 2010 +0200 staging: hv: fix netvsc sleeping while atomic commit d70c673153d42e8aefd5ac296c8159ef222d076b upstream. The channel callbacks are called directly from vmbus_event_dpc which runs in tasklet context. These callbacks need to use GFP_ATOMIC. Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=16701 Cc: Hank Janssen Cc: Haiyang Zhang Signed-off-by: Timo Teräs Signed-off-by: Greg Kroah-Hartman commit 67afcd29eae493a94c0f3a85691366ade0441486 Author: Ky Srinivasan Date: Thu Dec 16 18:59:19 2010 -0700 Staging: hv: fix sysfs symlink on hv block device commit 268eff909afaca93188d2d14554cbf824f6a0e41 upstream. The block device does not create the proper symlink in sysfs because we forgot to set up the gendisk structure properly. This patch fixes the issue. Signed-off-by: K. Y. Srinivasan Cc: Hank Janssen Cc: Haiyang Zhang Signed-off-by: Greg Kroah-Hartman commit f9ee30612116800cbfffa2e4fd21deca806ca49d Author: Ian Abbott Date: Wed Jan 19 11:48:44 2011 +0000 staging: comedi: ni_labpc: Use shared IRQ for PCMCIA card commit d1ce318496f5943d2cc5e20171fc383a59a1421f upstream. The ni_labpc driver module only requests a shared IRQ for PCI devices, requesting a non-shared IRQ for non-PCI devices. As this module is also used by the ni_labpc_cs module for certain National Instruments PCMCIA cards, it also needs to request a shared IRQ for PCMCIA devices, otherwise you get a IRQ mismatch with the CardBus controller. Signed-off-by: Ian Abbott Signed-off-by: Greg Kroah-Hartman commit f38abda28fc1d44bb220b15682ae3ce48ab6a559 Author: Ruben Smits Date: Sat Dec 11 08:26:18 2010 +0100 staging: comedi: add support for newer jr3 1-channel pci board commit 6292817d58637f85dd623cfe563c7f5ec4f4c470 upstream. add DEVICE_ID to table Signed-off-by: Ruben Smits Signed-off-by: Greg Kroah-Hartman commit b7172afe474aec3cd233065b90b5db45c56081dc Author: Nitin Gupta Date: Sat Feb 5 20:34:20 2011 -0500 staging: zram: fix data corruption issue commit 5414e557fca545614ceedc3d3496f747457e2e3b upstream. In zram_read() and zram_write() we were not incrementing the index number and thus were reading/writing values from/to incorrect sectors on zram disk, resulting in data corruption. Signed-off-by: Nitin Gupta Signed-off-by: Greg Kroah-Hartman commit c2bbe01f172bf66bb2985d361d2a6e2414e4e24b Author: Alan Stern Date: Wed Feb 2 13:59:33 2011 -0500 USB: fix race between root-hub resume and wakeup requests commit bf3d7d40e42a85ca73a34e1385ff34f092a384eb upstream. The USB core keeps track of pending resume requests for root hubs, in order to resolve races between wakeup requests and suspends. However the code that does this is subject to another race (between wakeup requests and resumes) because the WAKEUP_PENDING flag is cleared before the resume occurs, leaving a window in which another wakeup request might arrive. This patch (as1447) fixes the problem by clearing the WAKEUP_PENDING flag after the resume instead of before it. This fixes Bugzilla #24952. Signed-off-by: Alan Stern Tested-by: Paul Bender Tested-by: warpme Signed-off-by: Greg Kroah-Hartman commit c2f38a34645bef1c6475dcacbc51c038fd081cfc Author: Alan Stern Date: Mon Jan 31 10:56:37 2011 -0500 USB: prevent buggy hubs from crashing the USB stack commit d199c96d41d80a567493e12b8e96ea056a1350c1 upstream. If anyone comes across a high-speed hub that (by mistake or by design) claims to have no Transaction Translators, plugging a full- or low-speed device into it will cause the USB stack to crash. This patch (as1446) prevents the problem by ignoring such devices, since the kernel has no way to communicate with them. Signed-off-by: Alan Stern Tested-by: Perry Neben Signed-off-by: Greg Kroah-Hartman commit 8a7dfbe3f7930c25c16f54b5d638350d03594f2f Author: Yin Kangkai Date: Fri Jan 28 12:04:35 2011 +0800 USB: EHCI: fix scheduling while atomic during suspend commit 148fc55fd0449683a1d15bf219ad8d8b6fa17545 upstream. There is a msleep with spin lock held during ehci pci suspend, which will cause kernel BUG: scheduling while atomic. Fix that. [ 184.139620] BUG: scheduling while atomic: kworker/u:11/416/0x00000002 [ 184.139632] 4 locks held by kworker/u:11/416: [ 184.139640] #0: (events_unbound){+.+.+.}, at: [] process_one_work+0x1b3/0x4cb [ 184.139669] #1: ((&entry->work)){+.+.+.}, at: [] process_one_work+0x1b3/0x4cb [ 184.139686] #2: (&__lockdep_no_validate__){+.+.+.}, at: [] __device_suspend+0x2c/0x154 [ 184.139706] #3: (&(&ehci->lock)->rlock){-.-...}, at: [] ehci_pci_suspend+0x35/0x7b [ 184.139725] Modules linked in: serio_raw pegasus joydev mrst_gfx(C) battery [ 184.139748] irq event stamp: 52 [ 184.139753] hardirqs last enabled at (51): [] mutex_lock_nested+0x258/0x293 [ 184.139766] hardirqs last disabled at (52): [] _raw_spin_lock_irqsave+0xf/0x3e [ 184.139777] softirqs last enabled at (0): [] copy_process+0x3d2/0x109d [ 184.139789] softirqs last disabled at (0): [< (null)>] (null) [ 184.139802] Pid: 416, comm: kworker/u:11 Tainted: G C 2.6.37-6.3-adaptation-oaktrail #37 [ 184.139809] Call Trace: [ 184.139820] [] __schedule_bug+0x5e/0x65 [ 184.139829] [] schedule+0xac/0xc4c [ 184.139840] [] ? string+0x37/0x8b [ 184.139853] [] ? lock_timer_base+0x1f/0x3e [ 184.139863] [] ? _raw_spin_lock_irqsave+0x35/0x3e [ 184.139876] [] ? trace_hardirqs_off+0xb/0xd [ 184.139885] [] schedule_timeout+0x283/0x2d9 [ 184.139896] [] ? process_timeout+0x0/0xa [ 184.139906] [] schedule_timeout_uninterruptible+0x15/0x17 [ 184.139916] [] msleep+0x10/0x16 [ 184.139926] [] ehci_adjust_port_wakeup_flags+0x69/0xf6 [ 184.139937] [] ehci_pci_suspend+0x48/0x7b [ 184.139946] [] suspend_common+0x52/0xbb [ 184.139956] [] hcd_pci_suspend+0x26/0x28 [ 184.139967] [] pci_pm_suspend+0x5f/0xd0 [ 184.139976] [] pm_op+0x5d/0xf0 [ 184.139986] [] __device_suspend+0xf5/0x154 [ 184.139996] [] async_suspend+0x16/0x3a [ 184.140006] [] async_run_entry_fn+0x89/0x111 [ 184.140016] [] process_one_work+0x295/0x4cb [ 184.140026] [] ? async_run_entry_fn+0x0/0x111 [ 184.140036] [] worker_thread+0x17f/0x298 [ 184.140045] [] ? worker_thread+0x0/0x298 [ 184.140055] [] kthread+0x64/0x69 [ 184.140064] [] ? kthread+0x0/0x69 [ 184.140075] [] kernel_thread_helper+0x6/0x1a Signed-off-by: Yin Kangkai Acked-by: Alan Stern CC: David Brownell Signed-off-by: Greg Kroah-Hartman commit 018c993641ca462cbcab8377901f35e80aa24504 Author: Michael Williamson Date: Thu Jan 27 18:36:19 2011 -0600 USB: ftdi_sio: Add VID=0x0647, PID=0x0100 for Acton Research spectrograph commit 28fe2eb0162a1d23370dd99ff7d0e35632b1ee91 upstream. Add the USB Vendor ID and Product ID for a Acton Research Corp. spectrograph device with a FTDI chip for serial I/O. Signed-off-by: Michael H Williamson Signed-off-by: Greg Kroah-Hartman commit f6878bd76da266c3cc70ab7f2653aca755c967eb Author: Arvid Ephraim Picciani Date: Tue Jan 25 15:58:40 2011 +0100 USB: cdc-acm: Adding second ACM channel support for Nokia N8 commit 721d92fc6373dee15846216f9d178ec240ec0fd7 upstream. This adds the N8 to the list of devices in cdc-acm, in order to get the secondary ACM device exposed. In the spirit of: http://kerneltrap.org/mailarchive/linux-usb/2010/9/4/6264554 Signed-off-by: Arvid Ephraim Picciani Signed-off-by: Greg Kroah-Hartman commit 0f5b36a3a73328907b91b3a5c5ac958040814010 Author: Jean-Christophe PLAGNIOL-VILLARD Date: Sat Jan 29 15:32:52 2011 +0100 USB: ftdi_sio: add ST Micro Connect Lite uart support commit 6ec2f46c4b4abf48c88c0ae7c476f347b97e1105 upstream. on ST Micro Connect Lite we have 4 port Part A and B for the JTAG Port C Uart Port D for PIO Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD Signed-off-by: Greg Kroah-Hartman commit d9c0d49998ea43c0a99aa1c4deb6e4fe4377cac8 Author: Nick Holloway Date: Wed Jan 26 21:47:43 2011 +0000 USB: Storage: Add unusual_devs entry for VTech Kidizoom commit c25f6b1591b158f7ae3b9132367d0fa6d632e70e upstream. This device suffers from the off-by-one error when reporting the capacity, so add entry with US_FL_FIX_CAPACITY. Signed-off-by: Nick Holloway Signed-off-by: Greg Kroah-Hartman commit 5742d35619abcf7f0b3ada2427d4571373882257 Author: Ionut Nicu Date: Tue Dec 28 22:21:08 2010 +0200 USB: ti_usb: fix module removal commit b14de3857227cd978f515247853fd15cc2425d3e upstream. If usb_deregister() is called after usb_serial_deregister() when the device is plugged in, the following Oops occurs: [ 95.337377] BUG: unable to handle kernel NULL pointer dereference at 00000010 [ 95.338236] IP: [] klist_put+0x12/0x62 [ 95.338356] *pdpt = 000000003001a001 *pde = 0000000000000000 [ 95.338356] Oops: 0000 [#1] SMP [ 95.340499] last sysfs file: /sys/devices/pci0000:00/0000:00:1d.2/usb8/idVendor [ 95.340499] Modules linked in: ti_usb_3410_5052(-) usbserial cpufreq_ondemand acpi_cpufreq mperf iptable_nat nf_nat iptable_mangle ip6t_REJECT nf_conntrack_ipv6 nf_defrag_ipv6 ip6table_filter ip6_tables ipv6 uinput arc4 ecb iwlagn iwlcore mac80211 cfg80211 microcode pcspkr acer_wmi joydev wmi sky2 [last unloaded: scsi_wait_scan] [ 95.341908] [ 95.341908] Pid: 1532, comm: modprobe Not tainted 2.6.37-rc7+ #6 Eiger /Aspire 5930 [ 95.341908] EIP: 0060:[] EFLAGS: 00010246 CPU: 0 [ 95.341908] EIP is at klist_put+0x12/0x62 [ 95.341908] EAX: 00000000 EBX: eedc0c84 ECX: c09c21b4 EDX: 00000001 [ 95.341908] ESI: 00000000 EDI: efaa0c1c EBP: f214fe2c ESP: f214fe1c [ 95.341908] DS: 007b ES: 007b FS: 00d8 GS: 00e0 SS: 0068 [ 95.341908] Process modprobe (pid: 1532, ti=f214e000 task=efaaf080 task.ti=f214e000) [ 95.341908] Stack: [ 95.341908] f214fe24 eedc0c84 efaaf080 efaa0c1c f214fe34 c0776ba8 f214fe5c c0776c76 [ 95.341908] c09c21b4 c09c21b4 eedc0c84 efaaf080 00000000 c0634398 eafe2d1c f7b515f0 [ 95.341908] f214fe6c c0631b5c eafe2d50 eafe2d1c f214fe7c c0631ba2 eafe2d1c eafe2c00 [ 95.341908] Call Trace: [ 95.341908] [] ? klist_del+0xd/0xf [ 95.341908] [] ? klist_remove+0x48/0x74 [ 95.341908] [] ? devres_release_all+0x49/0x51 [ 95.341908] [] ? __device_release_driver+0x7b/0xa4 [ 95.341908] [] ? device_release_driver+0x1d/0x28 [ 95.341908] [] ? bus_remove_device+0x92/0xa1 [ 95.341908] [] ? device_del+0xf9/0x13e [ 95.341908] [] ? usb_serial_disconnect+0xd9/0x116 [usbserial] [ 95.341908] [] ? usb_disable_interface+0x32/0x40 [ 95.341908] [] ? usb_unbind_interface+0x48/0xfd [ 95.341908] [] ? __device_release_driver+0x62/0xa4 [ 95.341908] [] ? driver_detach+0x62/0x81 [ 95.341908] [] ? bus_remove_driver+0x8f/0xae [ 95.341908] [] ? driver_unregister+0x50/0x57 [ 95.341908] [] ? usb_deregister+0x77/0x84 [ 95.341908] [] ? ti_exit+0x26/0x28 [ti_usb_3410_5052] [ 95.341908] [] ? sys_delete_module+0x181/0x1de [ 95.341908] [] ? path_put+0x1a/0x1d [ 95.341908] [] ? audit_syscall_entry+0x116/0x138 [ 95.341908] [] ? sysenter_do_call+0x12/0x28 [ 95.341908] Code: 00 83 7d f0 00 74 09 85 f6 74 05 89 f0 ff 55 f0 8b 43 04 5a 5b 5e 5f 5d c3 55 89 e5 57 56 53 89 c3 83 ec 04 8b 30 83 e6 fe 89 f0 <8b> 7e 10 88 55 f0 e8 47 26 01 00 8a 55 f0 84 d2 74 17 f6 03 01 [ 95.341908] EIP: [] klist_put+0x12/0x62 SS:ESP 0068:f214fe1c [ 95.341908] CR2: 0000000000000010 [ 95.342357] ---[ end trace 8124d00ad871ad18 ]--- Signed-off-by: Ionut Nicu Signed-off-by: Greg Kroah-Hartman commit f5ac6c71eb8e95b7490aca033322bfdcefdf0d2d Author: Bjørn Mork Date: Mon Jan 17 14:19:37 2011 +0100 USB: io_edgeport: fix the reported firmware major and minor commit 271c1150b4f8e1685e5a8cbf76e329ec894481da upstream. The major and minor number saved in the product_info structure were copied from the address instead of the data, causing an inconsistency in the reported versions during firmware loading: usb 4-1: firmware: requesting edgeport/down.fw /usr/src/linux/drivers/usb/serial/io_edgeport.c: downloading firmware version (930) 1.16.4 [..] /usr/src/linux/drivers/usb/serial/io_edgeport.c: edge_startup - time 3 4328191260 /usr/src/linux/drivers/usb/serial/io_edgeport.c: FirmwareMajorVersion 0.0.4 This can cause some confusion whether firmware loaded successfully or not. Signed-off-by: Bjørn Mork Signed-off-by: Greg Kroah-Hartman commit db09b1e675ab7b481fb299fbd8402fbcfab9b4f0 Author: Alan Stern Date: Mon Jan 10 11:24:14 2011 -0500 USB: g_printer: fix bug in module parameter definitions commit ad84e4a9efb7c8ed322bafb6ebdb9c3a49a3d3a8 upstream. This patch (as1442) fixes a bug in g_printer: Module parameters should not be marked "__initdata" if they are accessible in sysfs (i.e., if the mode value in the module_param() macro is nonzero). Otherwise attempts to access the parameters will cause addressing violations. Character-string module parameters must not be marked "__initdata" if the module can be unloaded, because the kernel needs to access the parameter variable at unload time in order to free the dynamically-allocated string. Signed-off-by: Alan Stern CC: Roland Kletzing CC: Craig W. Nadler Signed-off-by: Greg Kroah-Hartman commit 2b9ec6cfec78f22e64916db10f958384369fd0f5 Author: Alan Stern Date: Mon Jan 10 11:23:05 2011 -0500 USB: g_printer: fix bug in unregistration commit d5aa475180d03d45c5dc6134aa833f1b3e89c45e upstream. This patch (as1441) fixes a bug in g_printer. The gadget driver, char device number, and class device should be unregistered in reverse order of registration. As it is now, when the module is unloaded the class device gets unregistered first, causing a crash when the unbind method tries to access it. This fixes Bugzilla #25882. Signed-off-by: Alan Stern CC: Roland Kletzing CC: Craig W. Nadler Signed-off-by: Greg Kroah-Hartman commit 244ccf5a704afee9f628908abf089bd5d6cc9abd Author: Alan Stern Date: Thu Jan 6 10:17:09 2011 -0500 USB: EHCI: fix DMA deallocation bug commit f75593ceaa08e6d27aec1a5de31cded19e850dd1 upstream. This patch (as1440) fixes a bug in ehci-hcd. ehci->periodic_size is used to compute the size in a dma_alloc_coherent() call, but then it gets changed later on. As a result, the corresponding call to dma_free_coherent() passes a different size from the original allocation. Fix the problem by adjusting ehci->periodic_size before carrying out any of the memory allocations. Signed-off-by: Alan Stern Tested-by: Larry Finger CC: David Brownell Signed-off-by: Greg Kroah-Hartman commit 74598f7368e965dfdd0440edbaf8ef1aafa5786e Author: Alex He Date: Tue Dec 21 17:45:46 2010 +0800 USB: EHCI: ASPM quirk of ISOC on AMD Hudson commit baab93afc2844b68d57b0dcca5e1d34c5d7cf411 upstream. AMD Hudson also needs the same ASPM quirk as SB800 Signed-off-by: Alex He Signed-off-by: Greg Kroah-Hartman commit 8c2278f844365a1520a86ea5ce0dede2311bcbb2 Author: Alan Stern Date: Tue Jan 11 14:16:50 2011 -0500 USB serial: add missing .usb_driver field in serial drivers commit 5620b5f7f19e9ee3fcf6ecf493fed7821b7b495b upstream. This patch (as1443) fixes a bug found in many of the USB serial drivers: They don't set the .usb_driver field in their usb_serial_driver structure. This field is needed for assigning dynamic IDs for device matching. In addition, starting with the 2.6.37 kernel, the .usb_driver field is needed for proper autosuspend operation. Without it, attempts to open the device file will fail. Signed-off-by: Alan Stern Reported-by: Dan Williams Signed-off-by: Greg Kroah-Hartman commit fc9bb81e814c078006e48e552888cf00ce3f4fa7 Author: Nicolaus Colberg Date: Wed Jan 12 16:30:03 2011 +0100 USB: adding USB support for Cinterion's HC2x, EU3 and PH8 products commit aa52b3a92918039b273fc9d1994bd34227c40269 upstream. /drivers/usb/serial/option.c: Adding support for Cinterion's HC25, HC28, HC28J, EU3-E, EU3-P and PH8 by correcting/adding Cinterion's and Siemens' Vendor IDs as well as Product IDs and USB_DEVICE tuples Signed-off-by: Nicolaus Colberg Signed-off-by: Greg Kroah-Hartman commit c6ed4bd9da8f8df85d7a15eaee1072356e7c11eb Author: Pieter Maes Date: Tue Jan 18 00:26:16 2011 +0100 USB: serial: Updated support for ICOM devices commit a9d61bc49188e32d2ae9cf0f683cde3e1744feef upstream. I found the original patch on the db0fhn repeater wiki (couldn't find the email of the origial author) I guess it was never commited. I updated and added some Icom HAM-radio devices to the ftdi driver. Added extra comments to make clear what devices it are. Signed-off-by: Pieter Maes Signed-off-by: Greg Kroah-Hartman commit 093881cc3ea93d39a4fbaf6fe219f152fa1b578b Author: Alan Stern Date: Tue Jan 25 13:07:04 2011 -0500 USB: usb-storage: unusual_devs entry for Coby MP3 player commit 3ea3c9b5a8464ec8223125f95e5dddb3bfd02a39 upstream. This patch (as1444) adds an unusual_devs entry for an MP3 player from Coby electronics. The device has two nasty bugs. Signed-off-by: Alan Stern Tested-by: Jasper Mackenzie Signed-off-by: Greg Kroah-Hartman commit d0d842672f600eeb8ba5b142dc15a62a0f85fef4 Author: Alan Stern Date: Mon Jan 3 16:47:49 2011 -0500 USB: usb-storage: unusual_devs entry for CamSport Evo commit 12f68c480c7155a66bd2a76ab2fef28dd5f93fa2 upstream. This patch (as1438) adds an unusual_devs entry for the MagicPixel FW_Omega2 chip, used in the CamSport Evo camera. The firmware incorrectly reports a vendor-specific bDeviceClass. Signed-off-by: Alan Stern Reported-by: Signed-off-by: Greg Kroah-Hartman commit 33bff3a15c5df13ab6d9bd7d399a36d689ea65d2 Author: Richard Schütz Date: Wed Dec 22 14:28:56 2010 +0100 USB: usb-storage: unusual_devs update for TrekStor DataStation maxi g.u external hard drive enclosure commit 7e1e7bd9dbd469267b6e6de1bf8d71a7d65ce86a upstream. The TrekStor DataStation maxi g.u external hard drive enclosure uses a JMicron USB to SATA chip which needs the US_FL_IGNORE_RESIDUE flag to work properly. Signed-off-by: Richard Schütz Signed-off-by: Greg Kroah-Hartman commit 5c8d6903e5fc7c11d0bcb037412025dfb8b4717d Author: Richard Schütz Date: Sun Dec 19 21:18:38 2010 +0100 USB: usb-storage: unusual_devs update for Cypress ATACB commit cae41118f50ef0c431e13159df6d7dd8bbd54004 upstream. New device ID added for unusual Cypress ATACB device. Signed-off-by: Richard Schütz Signed-off-by: Greg Kroah-Hartman commit 89e548395d2df18c8660d4480e0823ed4969c9a6 Author: Dan Williams Date: Fri Dec 31 10:51:51 2010 -0600 USB: qcaux: add Pantech UML290 device ID commit a58861fbde2a350df4d27fc62fb42905669b37ce upstream. Another CDC-ACM + vendor specific interface layout for the QCDM port. Signed-off-by: Dan Williams Signed-off-by: Greg Kroah-Hartman commit f721e5ddf97a27da3abbed0243f2159a48cd6c0b Author: Craig Shelley Date: Sun Jan 2 21:59:08 2011 +0000 USB: CP210x Removed incorrect device ID commit 9926c0df7b31b2128eebe92e0e2b052f380ea464 upstream. Device ID removed 0x10C4/0x8149 for West Mountain Radio Computerized Battery Analyzer. This device is actually based on a SiLabs C8051Fxxx, see http://www.etheus.net/SiUSBXp_Linux_Driver for further info. Signed-off-by: Craig Shelley Signed-off-by: Greg Kroah-Hartman commit c9b75cfd31ffd509bf4a11bb2dfc650652ac3675 Author: Craig Shelley Date: Sun Jan 2 21:51:46 2011 +0000 USB: CP210x Add two device IDs commit faea63f7ccfddfb8fc19798799fcd38c58415172 upstream. Device Ids added for IRZ Automation Teleport SG-10 GSM/GPRS Modem and DekTec DTA Plus VHF/UHF Booster/Attenuator. Signed-off-by: Craig Shelley Signed-off-by: Greg Kroah-Hartman commit 1c8df80314a6851e6eb32d3af177d4e93f0bec2c Author: Libor Pechacek Date: Fri Jan 14 14:30:21 2011 +0100 USB: serial: handle Data Carrier Detect changes commit d14fc1a74e846d7851f24fc9519fe87dc12a1231 upstream. Alan's commit 335f8514f200e63d689113d29cb7253a5c282967 introduced .carrier_raised function in several drivers. That also means tty_port_block_til_ready can now suspend the process trying to open the serial port when Carrier Detect is low and put it into tty_port.open_wait queue. We need to wake up the process when Carrier Detect goes high and trigger TTY hangup when CD goes low. Some of the devices do not report modem status line changes, or at least we don't understand the status message, so for those we remove .carrier_raised again. Signed-off-by: Libor Pechacek Signed-off-by: Greg Kroah-Hartman commit c5f44a1cc059232ec95cbfd93b0519c9078a47e7 Author: Henrik Rydberg Date: Tue Nov 9 15:15:02 2010 +0000 hwmon: (applesmc) Relax the severity of device init failure commit 2344cd0c2e9ea8f3037be11fb997ddbeda0237ca upstream. The device init is used to reset the accelerometer. Failure to reset is not severe enough to stop loading the module or to resume from hibernation. This patch relaxes failure to a warning and drops output in case of success. Signed-off-by: Henrik Rydberg Signed-off-by: Guenter Roeck Signed-off-by: Greg Kroah-Hartman commit cb079f0ee00a8e09b8fa1d0b5199ff59f174cce7 Author: Edgar Hucek Date: Tue Nov 9 15:15:01 2010 +0000 hwmon: (applesmc) Add MacBookAir3,1(3,2) support commit 132af03233b493101a53010383b5abb5b9ff1e51 upstream. This patch add support for the MacBookAir3,1 and MacBookAir3,2 to the applesmc driver. [rydberg@euromail.se: minor cleanup] Cc: stable@kernel.org Signed-off-by: Edgar Hucek Signed-off-by: Henrik Rydberg Signed-off-by: Guenter Roeck Signed-off-by: Greg Kroah-Hartman commit 72d9d03d77a0b52036c515d2e3f12360fea2f569 Author: Jean Delvare Date: Wed Jan 12 21:55:09 2011 +0100 hwmon: (via686a) Initialize fan_div values commit f790674d3f87df6390828ac21a7d1530f71b59c8 upstream. Functions set_fan_min() and set_fan_div() assume that the fan_div values have already been read from the register. The driver currently doesn't initialize them at load time, they are only set when function via686a_update_device() is called. This means that set_fan_min() and set_fan_div() misbehave if, for example, "sensors -s" is called before any monitoring application (e.g. "sensors") is has been run. Fix the problem by always initializing the fan_div values at device bind time. Signed-off-by: Jean Delvare Acked-by: Guenter Roeck Signed-off-by: Greg Kroah-Hartman commit 4224f23c44f94e49eb0e01f38681c6a43112f93a Author: J. K. Cliburn Date: Sat Jan 1 05:02:12 2011 +0000 atl1: fix oops when changing tx/rx ring params commit 2f32c867219734b06abc980d4812f67b6d6fe517 upstream. Commit 3f5a2a713aad28480d86b0add00c68484b54febc zeroes out the statistics message block (SMB) and coalescing message block (CMB) when adapter ring resources are freed. This is desirable behavior, but, as a side effect, the commit leads to an oops when atl1_set_ringparam() attempts to alter the number of rx or tx elements in the ring buffer (by using ethtool -G, for example). We don't want SMB or CMB to change during this operation. Modify atl1_set_ringparam() to preserve SMB and CMB when changing ring parameters. Signed-off-by: Jay Cliburn Reported-by: Tõnu Raitviir Signed-off-by: David S. Miller Signed-off-by: Greg Kroah-Hartman commit cdde102cd5271d9e3927667b2b1bee676b2ab125 Author: Karsten Wiese Date: Tue Jan 4 01:20:37 2011 +0100 ALSA: snd-usb-us122l: Fix missing NULL checks commit cdce2db74e156fbd9a2dc3c7b246166f8b70955b upstream. Fix missing NULL checks in usb_stream_hwdep_poll() and usb_stream_hwdep_ioctl(). Wake up poll waiters before returning from usb_stream_hwdep_ioctl(). Signed-off-by: Karsten Wiese Signed-off-by: Takashi Iwai Signed-off-by: Greg Kroah-Hartman commit 5625ceb657a9963f23d2cd3ea17f5a202da5db05 Author: Karsten Wiese Date: Mon Jan 3 02:41:58 2011 +0100 ALSA: snd-usb-us122l: Fix MIDI output commit 921eebdc18c82268eab446592191b39e35d031d6 upstream. The US-122L always reads 9 bytes per urb unless they are set to 0xFD. Signed-off-by: Karsten Wiese Signed-off-by: Takashi Iwai Signed-off-by: Greg Kroah-Hartman commit f72daeb6eb832b6276a9da367b97dfdbcf204a49 Author: Larry Finger Date: Wed Jan 12 22:24:28 2011 -0600 staging: rt2870sta: Add ID for Linksys WUSB100v2 commit 27c82819a5a42f08fc0f787ab1b0c129cbdda801 upstream. This device was tested with rt2870sta by setting new_id. Signed-off-by: Larry Finger Tested-by: Brian Ormond Signed-off-by: Greg Kroah-Hartman commit 8b4c686efe48e73f8338e8c5c6bf65303443cc09 Author: Greg Kroah-Hartman Date: Tue Jan 25 17:42:29 2011 +0800 rt2x00: add device id for windy31 usb device commit 9c4cf6d94fb362c27a24df5223ed6e327eb7279a upstream. This patch adds the device id for the windy31 USB device to the rt73usb driver. Thanks to Ralf Flaxa for reporting this and providing testing and a sample device. Reported-by: Ralf Flaxa Tested-by: Ralf Flaxa Signed-off-by: Greg Kroah-Hartman Acked-by: Ivo van Doorn Signed-off-by: John W. Linville commit d1cc140ae746d2ad5866aee77073e4897ea2babe Author: Alex He Date: Tue Dec 7 10:10:08 2010 +0800 USB: EHCI: ASPM quirk of ISOC on AMD SB800 commit 05570297ecbe834b1756b522412b68eaffb9ab11 upstream. When ASPM PM Feature is enabled on UMI link, devices that use ISOC stream of data transfer may be exposed to longer latency causing less than optimal per- formance of the device. The longer latencies are normal and are due to link wake time coming out of low power state which happens frequently to save power when the link is not active. The following code will make exception for certain features of ASPM to be by passed and keep the logic normal state only when the ISOC device is connected and active. This change will allow the device to run at optimal performance yet minimize the impact on overall power savings. Signed-off-by: Alex He Acked-by: David Brownell Signed-off-by: Greg Kroah-Hartman commit 2ffaca128dfd5a2de661b85d7d3cc045e24a2540 Author: Márton Németh Date: Mon Dec 13 21:59:09 2010 +0100 staging: usbip: remove double giveback of URB commit 7571f089d7522a95c103558faf313c7af8856ceb upstream. In the vhci_urb_dequeue() function the TCP connection is checked twice. Each time when the TCP connection is closed the URB is unlinked and given back. Remove the second attempt of unlinking and giving back of the URB completely. This patch fixes the bug described at https://bugzilla.kernel.org/show_bug.cgi?id=24872 . Signed-off-by: Márton Németh Signed-off-by: Greg Kroah-Hartman