commit 90a8a73c06cc32b609a880d48449d7083327e11a Author: Linus Torvalds Date: Tue Dec 21 11:26:40 2010 -0800 Linux 2.6.37-rc7 commit e5fcdb7ed856b714c878ad470040fe832cbe462b Merge: 7bddaac 093d804 Author: Linus Torvalds Date: Mon Dec 20 21:34:16 2010 -0800 Merge branch 'tty-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty-2.6 * 'tty-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty-2.6: n_gsm: gsm_data_alloc buffer allocation could fail and it is not being checked n_gsm: Fix message length handling when building header commit 7bddaaca472a08bb8a80b653855a1e921b440578 Merge: 9d5004f dbb442b Author: Linus Torvalds Date: Mon Dec 20 21:33:12 2010 -0800 Merge branch 'usb-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb-2.6 * 'usb-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb-2.6: Revert "USB: gadget: Allow function access to device ID data during bind()" USB: misc: uss720.c: add another vendor/product ID USB: usb-storage: unusual_devs entry for the Samsung YP-CP3 USB: gadget: Remove suspended sysfs file before freeing cdev USB: core: Add input prompt and help text for USB_OTG config USB: ftdi_sio: Add D.O.Tec PID xhci: Fix issue with port array setup and buggy hosts. commit 9d5004fcf6e4e8caa9efbc25c9f85059b165329c Merge: 453434c 361cf40 Author: Linus Torvalds Date: Mon Dec 20 21:32:20 2010 -0800 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph-client * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph-client: ceph: handle partial result from get_user_pages ceph: mark user pages dirty on direct-io reads ceph: fix null pointer dereference in ceph_init_dentry for nfs reexport ceph: fix direct-io on non-page-aligned buffers ceph: fix msgr_init error path commit 453434cf3fdcd3954bb52460e37d4945a0913d3e Author: Linus Torvalds Date: Mon Dec 20 21:21:49 2010 -0800 Fix build error in drivers/block/cciss.c .. caused by a missing semi-colon, introduced in commit 0fc13c8995cd ("cciss: fix cciss_revalidate panic"). Reported-by: Stephen Rothwell Reported-by: Thiago Farina Cc: Jens Axboe Signed-off-by: Linus Torvalds commit 8cad7f06e3b1d3f9a28bb7385e8fc09d5e1bf84c Merge: 92d7c9b 0e4d413 Author: Linus Torvalds Date: Mon Dec 20 10:35:04 2010 -0800 Merge branch 'v4l_for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-2.6 * 'v4l_for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-2.6: [media] gspca - sonixj: Better handling of the bridge registers 0x01 and 0x17 [media] gspca - sonixj: Add the bit definitions of the bridge reg 0x01 and 0x17 [media] gspca - sonixj: Set the flag for some devices [media] gspca - sonixj: Add a flag in the driver_info table [media] gspca - sonixj: Fix a bad probe exchange [media] gspca - sonixj: Move bridge init to sd start [media] bttv: remove unneeded locking comments [media] bttv: fix mutex use before init (BZ#24602) [media] Don't export format_by_forcc on two different drivers commit 92d7c9b2312474ce1259d71b4e50e01ae9fa95ea Merge: 9e0afb9 1cf215a Author: Linus Torvalds Date: Mon Dec 20 09:59:08 2010 -0800 Merge branch 'rmobile-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/lethal/sh-2.6 * 'rmobile-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/lethal/sh-2.6: ARM: mach-shmobile: INTC interrupt priority level demux fix ARM: mach-shmobile: fix compile warning in mm/init.c commit 9e0afb9437c68be62085d74407b169732108a929 Merge: 7aeb3be 65ada54 Author: Linus Torvalds Date: Mon Dec 20 09:53:50 2010 -0800 Merge branch 'sh-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/lethal/sh-2.6 * 'sh-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/lethal/sh-2.6: clocksource: sh_cmt: Remove nested spinlock fix commit 7aeb3be341cc7f1fbf2b98fbef980a816736fe8e Merge: 0705859 e13416a Author: Linus Torvalds Date: Mon Dec 20 09:49:54 2010 -0800 Merge branch 'fbdev-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/lethal/fbdev-2.6 * 'fbdev-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/lethal/fbdev-2.6: OMAP: OMAPFB: disable old omapfb for OMAP4 builds OMAP: DSS: VRAM: Align start & size of vram to 2M commit 07058599b486fe342f371200ac4718fedbe9a354 Merge: 7f8635c cb18688 Author: Linus Torvalds Date: Mon Dec 20 09:46:46 2010 -0800 Merge branch 's5p-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/kgene/linux-samsung * 's5p-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/kgene/linux-samsung: ARM: S5PV210: update MAX8998 platform data to get rid of WARN() ARM S3C24XX: Fix compilation of PM code for S3C2416 ARM: S3C24XX: Fix CONFIG_S3C_DEV_NAND Kconfig entry commit 7f8635cc9e66a26d7280ba680b044fa2f65104af Merge: 3cb50dd 0fc13c8 Author: Linus Torvalds Date: Mon Dec 20 09:19:46 2010 -0800 Merge branch 'for-linus' of git://git.kernel.dk/linux-2.6-block * 'for-linus' of git://git.kernel.dk/linux-2.6-block: cciss: fix cciss_revalidate panic block: max hardware sectors limit wrapper block: Deprecate QUEUE_FLAG_CLUSTER and use queue_limits instead blk-throttle: Correct the placement of smp_rmb() blk-throttle: Trim/adjust slice_end once a bio has been dispatched block: check for proper length of iov entries earlier in blk_rq_map_user_iov() drbd: fix for spin_lock_irqsave in endio callback drbd: don't recvmsg with zero length commit 3cb50ddf97a0a1ca4c68bc12fa1e727a6b45fbf2 Author: Al Viro Date: Mon Dec 20 15:53:18 2010 +0000 Fix btrfs b0rkage Buggered-in: 76dda93c6ae2 ("Btrfs: add snapshot/subvolume destroy ioctl") Signed-off-by: Al Viro Acked-by: Chris Mason Signed-off-by: Linus Torvalds commit b8da46d3d55807037b58f14621a0949f18053bde Author: Nicolas Pitre Date: Mon Dec 20 00:29:32 2010 -0500 clarify a usage constraint for cnt32_to_63() The cnt32_to_63 algorithm relies on proper counter data evaluation ordering to work properly. This was missing from the provided documentation. Let's augment the documentation with the missing usage constraint and fix the only instance that got it wrong. Signed-off-by: Nicolas Pitre Acked-by: David Howells Signed-off-by: Linus Torvalds commit de5e9d58200aafea4a33abcadcd12eb69eaba5c4 Merge: 55ec86f 050c6c9 Author: Linus Torvalds Date: Mon Dec 20 09:05:26 2010 -0800 Merge branch 'sched-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip * 'sched-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip: sched: Remove debugging check commit 050c6c9b896625d9fa498265be17b82c5fc65257 Author: Ingo Molnar Date: Sun Dec 19 23:24:27 2010 +0100 sched: Remove debugging check Linus reported that the new warning introduced by commit f26f9aff6aaf "Sched: fix skip_clock_update optimization" triggers. The need_resched flag can be set by other CPUs asynchronously so this debug check is bogus - remove it. Reported-by: Linus Torvalds Cc: Peter Zijlstra Cc: Mike Galbraith LKML-Reference: Signed-off-by: Ingo Molnar commit 55ec86f848a5f872fd43f5d7206464a0af419110 Merge: 21228e4 147dd56 d949750 Author: Linus Torvalds Date: Sun Dec 19 10:44:54 2010 -0800 Merge branches 'x86-fixes-for-linus' and 'perf-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip * 'x86-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip: x86-32: Make sure we can map all of lowmem if we need to x86, vt-d: Handle previous faults after enabling fault handling x86: Enable the intr-remap fault handling after local APIC setup x86, vt-d: Fix the vt-d fault handling irq migration in the x2apic mode x86, vt-d: Quirk for masking vtd spec errors to platform error handling logic x86, xsave: Use alloc_bootmem_align() instead of alloc_bootmem() bootmem: Add alloc_bootmem_align() x86, gcc-4.6: Use gcc -m options when building vdso x86: HPET: Chose a paranoid safe value for the ETIME check x86: io_apic: Avoid unused variable warning when CONFIG_GENERIC_PENDING_IRQ=n * 'perf-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip: perf: Fix off by one in perf_swevent_init() perf: Fix duplicate events with multiple-pmu vs software events ftrace: Have recordmcount honor endianness in fn_ELF_R_INFO scripts/tags.sh: Add magic for trace-events tracing: Fix panic when lseek() called on "trace" opened for writing commit 21228e455756be11fbbcae7e1a184ad9d842f687 Merge: 0a59228 8e92c20 Author: Linus Torvalds Date: Sun Dec 19 10:37:37 2010 -0800 Merge branch 'sched-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip * 'sched-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip: sched: Fix the irqtime code for 32bit sched: Fix the irqtime code to deal with u64 wraps nohz: Fix get_next_timer_interrupt() vs cpu hotplug Sched: fix skip_clock_update optimization sched: Cure more NO_HZ load average woes commit 0a59228168d3722b71f8e3dbc623316fb4be78f4 Merge: 2ba16c4 81711ce Author: Linus Torvalds Date: Sat Dec 18 10:28:54 2010 -0800 Merge git://git.kernel.org/pub/scm/linux/kernel/git/cmetcalf/linux-tile * git://git.kernel.org/pub/scm/linux/kernel/git/cmetcalf/linux-tile: arch/tile: handle rt_sigreturn() more cleanly arch/tile: handle CLONE_SETTLS in copy_thread(), not user space commit 2ba16c4f456eb63f54b1d8b065377d41a1cd6a14 Merge: 46bdfe6 081d835 Author: Linus Torvalds Date: Sat Dec 18 10:23:29 2010 -0800 Merge branch 'upstream' of git://git.linux-mips.org/pub/scm/upstream-linus * 'upstream' of git://git.linux-mips.org/pub/scm/upstream-linus: MIPS: Fix build errors in sc-mips.c commit 46bdfe6a50b88942f5323f837a3afd93a1c86e60 Merge: c15524a a2c606d Author: Linus Torvalds Date: Sat Dec 18 10:13:24 2010 -0800 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jbarnes/pci-2.6 * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jbarnes/pci-2.6: x86: avoid high BIOS area when allocating address space x86: avoid E820 regions when allocating address space x86: avoid low BIOS area when allocating address space resources: add arch hook for preventing allocation in reserved areas Revert "resources: support allocating space within a region from the top down" Revert "PCI: allocate bus resources from the top down" Revert "x86/PCI: allocate space from the end of a region, not the beginning" Revert "x86: allocate space within a region top-down" Revert "PCI: fix pci_bus_alloc_resource() hang, prefer positive decode" PCI: Update MCP55 quirk to not affect non HyperTransport variants commit 81711cee933599fa114abb0d258d8bbabef8adfb Author: Chris Metcalf Date: Tue Dec 14 16:07:25 2010 -0500 arch/tile: handle rt_sigreturn() more cleanly The current tile rt_sigreturn() syscall pattern uses the common idiom of loading up pt_regs with all the saved registers from the time of the signal, then anticipating the fact that we will clobber the ABI "return value" register (r0) as we return from the syscall by setting the rt_sigreturn return value to whatever random value was in the pt_regs for r0. However, this breaks in our 64-bit kernel when running "compat" tasks, since we always sign-extend the "return value" register to properly handle returned pointers that are in the upper 2GB of the 32-bit compat address space. Doing this to the sigreturn path then causes occasional random corruption of the 64-bit r0 register. Instead, we stop doing the crazy "load the return-value register" hack in sigreturn. We already have some sigreturn-specific assembly code that we use to pass the pt_regs pointer to C code. We extend that code to also set the link register to point to a spot a few instructions after the usual syscall return address so we don't clobber the saved r0. Now it no longer matters what the rt_sigreturn syscall returns, and the pt_regs structure can be cleanly and completely reloaded. Signed-off-by: Chris Metcalf commit bc4cf2bb271b2d557fc510426755da786fc985be Author: Chris Metcalf Date: Tue Dec 14 15:57:49 2010 -0500 arch/tile: handle CLONE_SETTLS in copy_thread(), not user space Previously we were just setting up the "tp" register in the new task as started by clone() in libc. However, this is not quite right, since in principle a signal might be delivered to the new task before it had its TLS set up. (Of course, this race window still exists for resetting the libc getpid() cached value in the new task, in principle. But in any case, we are now doing this exactly the way all other architectures do it.) This change is important for 2.6.37 since the tile glibc we will be submitting upstream will not set TLS in user space any more, so it will only work on a kernel that has this fix. It should also be taken for 2.6.36.x in the stable tree if possible. Signed-off-by: Chris Metcalf Cc: stable commit 0e4d413af1a9ddd12f82617734eb535007e186a8 Author: Jean-Francois Moine Date: Tue Dec 14 16:17:40 2010 -0300 [media] gspca - sonixj: Better handling of the bridge registers 0x01 and 0x17 The initial values of the registers 0x01 and 0x17 are taken from the sensor table at capture start and updated according to the flag PDN_INV. Their values are updated at each step of the capture initialization and memorized for reuse in capture stop. This patch also fixed automatically some bad hardcoded values of these registers. Signed-off-by: Jean-François Moine Signed-off-by: Mauro Carvalho Chehab commit 4fd350ee2bf129acb933ad5104bc4754b2c7c9ef Author: Jean-Francois Moine Date: Tue Dec 14 16:16:58 2010 -0300 [media] gspca - sonixj: Add the bit definitions of the bridge reg 0x01 and 0x17 Signed-off-by: Jean-François Moine Signed-off-by: Mauro Carvalho Chehab commit b2272a49e7df37732d73988f00468ce31e1ebc92 Author: Jean-Francois Moine Date: Tue Dec 14 16:16:16 2010 -0300 [media] gspca - sonixj: Set the flag for some devices The flag PDN_INV indicates that the sensor pin S_PWR_DN has not the same value as other webcams with the same sensor. For now, only two webcams have been so detected: the Microsoft's VX1000 and VX3000. Signed-off-by: Jean-François Moine Signed-off-by: Mauro Carvalho Chehab commit c6c14330717f9850b4b4c054b81424b9979cd07d Author: Jean-Francois Moine Date: Tue Dec 14 16:15:37 2010 -0300 [media] gspca - sonixj: Add a flag in the driver_info table Signed-off-by: Jean-François Moine Signed-off-by: Mauro Carvalho Chehab commit 4f67f3adefadbb056c1ce2c228916701b566e6fc Author: Jean-Francois Moine Date: Tue Dec 14 16:15:00 2010 -0300 [media] gspca - sonixj: Fix a bad probe exchange Signed-off-by: Jean-François Moine Signed-off-by: Mauro Carvalho Chehab commit 5e68f400aad4e2c29e2531cc4413c459fa88cb62 Author: Jean-Francois Moine Date: Tue Dec 14 16:14:10 2010 -0300 [media] gspca - sonixj: Move bridge init to sd start Signed-off-by: Jean-François Moine Signed-off-by: Mauro Carvalho Chehab commit 692e42df12e8427219958468301f3d03ca5f0f0d Author: Brandon Philips Date: Fri Dec 17 12:58:22 2010 -0300 [media] bttv: remove unneeded locking comments After Mauro's "bttv: Fix locking issues due to BKL removal code" there are a number of comments that are no longer needed about lock ordering. Remove them. Signed-off-by: Brandon Philips Signed-off-by: Mauro Carvalho Chehab commit 587f0d5d6d44e3529028bf197d424f866fb2411d Author: Mauro Carvalho Chehab Date: Wed Dec 15 18:45:42 2010 -0300 [media] bttv: fix mutex use before init (BZ#24602) Fix a regression where bttv driver causes oopses when loading, since it were using some non-initialized mutexes. While it would be possible to fix the issue, there are some other lock troubles, like to the presence of lock code at free_btres_lock(). It is possible to fix, but the better is to just use the core-assisted locking schema. This way, V4L2 core will serialize access to all ioctl's/open/close/mmap/read/poll operations, avoiding to have two processes accessing the hardware at the same time. Also, as there's just one lock, instead of 3, there's no risk of dead locks. The net result is a cleaner code, with just one lock. Reported-by: Dan Carpenter Reported-by: Brandon Philips Reported-by: Chris Clayton Reported-by: Torsten Kaiser Tested-by: Chris Clayton Tested-by: Torsten Kaiser Signed-off-by: Mauro Carvalho Chehab commit 081d835fa4ce70ad1e42ac76de850a49e23a1557 Author: Kevin Cernekee Date: Tue Nov 2 22:28:01 2010 -0700 MIPS: Fix build errors in sc-mips.c Seen with malta_defconfig on Linus' tree: CC arch/mips/mm/sc-mips.o arch/mips/mm/sc-mips.c: In function 'mips_sc_is_activated': arch/mips/mm/sc-mips.c:77: error: 'config2' undeclared (first use in this function) arch/mips/mm/sc-mips.c:77: error: (Each undeclared identifier is reported only once arch/mips/mm/sc-mips.c:77: error: for each function it appears in.) arch/mips/mm/sc-mips.c:81: error: 'tmp' undeclared (first use in this function) make[2]: *** [arch/mips/mm/sc-mips.o] Error 1 make[1]: *** [arch/mips/mm] Error 2 make: *** [arch/mips] Error 2 [Ralf: Cosmetic changes to minimize the number of arguments passed to mips_sc_is_activated] Signed-off-by: Kevin Cernekee Patchwork: https://patchwork.linux-mips.org/patch/1752/ Signed-off-by: Ralf Baechle commit a2c606d53ab71dee6410f10ef0adf67321d60e06 Author: Bjorn Helgaas Date: Thu Dec 16 10:39:02 2010 -0700 x86: avoid high BIOS area when allocating address space This prevents allocation of the last 2MB before 4GB. The experiment described here shows Windows 7 ignoring the last 1MB: https://bugzilla.kernel.org/show_bug.cgi?id=23542#c27 This patch ignores the top 2MB instead of just 1MB because H. Peter Anvin says "There will be ROM at the top of the 32-bit address space; it's a fact of the architecture, and on at least older systems it was common to have a shadow 1 MiB below." Acked-by: H. Peter Anvin Signed-off-by: Bjorn Helgaas Signed-off-by: Jesse Barnes commit 4dc2287c1805e7fe8a7cb90bbcd44abee8cdb914 Author: Bjorn Helgaas Date: Thu Dec 16 10:38:56 2010 -0700 x86: avoid E820 regions when allocating address space When we allocate address space, e.g., to assign it to a PCI device, don't allocate anything mentioned in the BIOS E820 memory map. On recent machines (2008 and newer), we assign PCI resources from the windows described by the ACPI PCI host bridge _CRS. On many Dell machines, these windows overlap some E820 reserved areas, e.g., BIOS-e820: 00000000bfe4dc00 - 00000000c0000000 (reserved) pci_root PNP0A03:00: host bridge window [mem 0xbff00000-0xdfffffff] If we put devices at 0xbff00000, they don't work, probably because that's really RAM, not I/O memory. This patch prevents that by removing the 0xbfe4dc00-0xbfffffff area from the "available" resource. I'm not very happy with this solution because Windows solves the problem differently (it seems to ignore E820 reserved areas and it allocates top-down instead of bottom-up; details at comment 45 of the bugzilla below). That means we're vulnerable to BIOS defects that Windows would not trip over. For example, if BIOS described a device in ACPI but didn't mention it in E820, Windows would work fine but Linux would fail. Reference: https://bugzilla.kernel.org/show_bug.cgi?id=16228 Acked-by: H. Peter Anvin Signed-off-by: Bjorn Helgaas Signed-off-by: Jesse Barnes commit 30919b0bf356a8ee0ef4f7d38ca8ad99b96820b2 Author: Bjorn Helgaas Date: Thu Dec 16 10:38:51 2010 -0700 x86: avoid low BIOS area when allocating address space This implements arch_remove_reservations() so allocate_resource() can avoid any arch-specific reserved areas. This currently just avoids the BIOS area (the first 1MB), but could be used for E820 reserved areas if that turns out to be necessary. We previously avoided this area in pcibios_align_resource(). This patch moves the test from that PCI-specific path to a generic path, so *all* resource allocations will avoid this area. Acked-by: H. Peter Anvin Signed-off-by: Bjorn Helgaas Signed-off-by: Jesse Barnes commit fcb119183c73bf0781009713f303e28b1fb13d3e Author: Bjorn Helgaas Date: Thu Dec 16 10:38:46 2010 -0700 resources: add arch hook for preventing allocation in reserved areas This adds arch_remove_reservations(), which an arch can implement if it needs to protect part of the address space from allocation. Sometimes that can be done by just putting a region in the resource tree, but there are cases where that doesn't work well. For example, x86 BIOS E820 reservations are not related to devices, so they may overlap part of, all of, or more than a device resource, so they may not end up at the correct spot in the resource tree. Acked-by: H. Peter Anvin Signed-off-by: Bjorn Helgaas Signed-off-by: Jesse Barnes commit c0f5ac5426f7fd82b23dd5c6a1e633b290294a08 Author: Bjorn Helgaas Date: Thu Dec 16 10:38:41 2010 -0700 Revert "resources: support allocating space within a region from the top down" This reverts commit e7f8567db9a7f6b3151b0b275e245c1cef0d9c70. Acked-by: H. Peter Anvin Signed-off-by: Bjorn Helgaas Signed-off-by: Jesse Barnes commit 6db45b76eaa08133187f2cb44d496de7e9503aa8 Author: Bjorn Helgaas Date: Thu Dec 16 10:38:36 2010 -0700 Revert "PCI: allocate bus resources from the top down" This reverts commit b126b4703afa4010b161784a43650337676dd03b. We're going back to the old behavior of allocating from bus resources in _CRS order. Acked-by: H. Peter Anvin Signed-off-by: Bjorn Helgaas Signed-off-by: Jesse Barnes commit d14125ecfee05473de46f06d992db109308c57a3 Author: Bjorn Helgaas Date: Thu Dec 16 10:38:31 2010 -0700 Revert "x86/PCI: allocate space from the end of a region, not the beginning" This reverts commit dc9887dc02e37bcf83f4e792aa14b07782ef54cf. Acked-by: H. Peter Anvin Signed-off-by: Bjorn Helgaas Signed-off-by: Jesse Barnes commit 5e52f1c5e85fdc3831eeae8b546577e94a586f81 Author: Bjorn Helgaas Date: Thu Dec 16 10:38:25 2010 -0700 Revert "x86: allocate space within a region top-down" This reverts commit 1af3c2e45e7a641e774bbb84fa428f2f0bf2d9c9. Acked-by: H. Peter Anvin Signed-off-by: Bjorn Helgaas Signed-off-by: Jesse Barnes commit ac57cd5ee1935d1e60de86d75f13f377775f1c96 Author: Bjorn Helgaas Date: Thu Dec 16 10:38:20 2010 -0700 Revert "PCI: fix pci_bus_alloc_resource() hang, prefer positive decode" This reverts commit 82e3e767c21fef2b1b38868e20eb4e470a1e38e3. We're going back to considering bus resources in the order we found them (in _CRS order, when we're using _CRS), so we don't need to define any ordering. Acked-by: H. Peter Anvin Signed-off-by: Bjorn Helgaas Signed-off-by: Jesse Barnes commit 361cf40519a491f68b28ad90225e4611c4bf8e12 Author: Henry C Chang Date: Fri Dec 17 09:55:59 2010 -0800 ceph: handle partial result from get_user_pages The get_user_pages() helper can return fewer than the requested pages. Error out in that case, and clean up the partial result. Signed-off-by: Henry C Chang Signed-off-by: Sage Weil commit b6aa5901c7a2bd90d0b6b9866300d2648b2568f3 Author: Henry C Chang Date: Wed Dec 15 20:45:41 2010 -0800 ceph: mark user pages dirty on direct-io reads For read operation, we have to set the argument _write_ of get_user_pages to 1 since we will write data to pages. Also, we need to SetPageDirty before releasing these pages. Signed-off-by: Henry C Chang Signed-off-by: Sage Weil commit 92cf765237e2787eb168096305c448caf25ac7f8 Author: Sage Weil Date: Fri Dec 17 09:53:41 2010 -0800 ceph: fix null pointer dereference in ceph_init_dentry for nfs reexport The fh_to_dentry etc. methods use ceph_init_dentry(), which assumes that d_parent is defined. It isn't for those callers, so check! Signed-off-by: Sage Weil commit c15524a40a1603dc56a8691c4f50172fb86c23d8 Merge: a6ac1f0 c20b4dd Author: Linus Torvalds Date: Fri Dec 17 09:45:25 2010 -0800 Merge branch 'for_linus' of git://github.com/at91linux/linux-2.6-at91 * 'for_linus' of git://github.com/at91linux/linux-2.6-at91: at91: Refactor Stamp9G20 and PControl G20 board file at91: Fix uhpck clock rate in upll case commit a6ac1f0af4b39f41fa69477cc44621c612403374 Merge: 508817e 3e26f23 Author: Linus Torvalds Date: Fri Dec 17 09:32:39 2010 -0800 Merge branch 'kvm-updates/2.6.37' of git://git.kernel.org/pub/scm/virt/kvm/kvm * 'kvm-updates/2.6.37' of git://git.kernel.org/pub/scm/virt/kvm/kvm: KVM: Fix preemption counter leak in kvm_timer_init() KVM: enlarge number of possible CPUID leaves KVM: SVM: Do not report xsave in supported cpuid KVM: Fix OSXSAVE after migration commit 508817e7cd8cb585148d12b5673202142ece2330 Merge: 8efc1a1 f08f5a0 Author: Linus Torvalds Date: Fri Dec 17 09:31:59 2010 -0800 Merge branch 'pm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/suspend-2.6 * 'pm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/suspend-2.6: PM / Runtime: Fix pm_runtime_suspended() PM / Hibernate: Restore old swap signature to avoid user space breakage PM / Hibernate: Fix PM_POST_* notification with user-space suspend commit 8efc1a1a22e6daf9d669e6095460c77df683c325 Merge: 7428081 673eb9f Author: Linus Torvalds Date: Fri Dec 17 09:28:17 2010 -0800 Merge branch 'bkl_removal' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-2.6 * 'bkl_removal' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-2.6: [media] uvcvideo: Convert to unlocked_ioctl [media] uvcvideo: Lock stream mutex when accessing format-related information [media] uvcvideo: Move mmap() handler to uvc_queue.c [media] uvcvideo: Move mutex lock/unlock inside uvc_free_buffers [media] uvcvideo: Lock controls mutex when querying menus [media] v4l2-dev: fix race condition [media] V4L: improve the BKL replacement heuristic [media] v4l2-dev: use mutex_lock_interruptible instead of plain mutex_lock [media] cx18: convert to unlocked_ioctl [media] radio-timb: convert to unlocked_ioctl [media] sh_vou: convert to unlocked_ioctl [media] cafe_ccic: replace ioctl by unlocked_ioctl [media] et61x251_core: trivial conversion to unlocked_ioctl [media] sn9c102: convert to unlocked_ioctl [media] BKL: trivial ioctl -> unlocked_ioctl video driver conversions [media] typhoon: convert to unlocked_ioctl [media] si4713: convert to unlocked_ioctl [media] tea5764: convert to unlocked_ioctl [media] cadet: use unlocked_ioctl [media] BKL: trivial BKL removal from V4L2 radio drivers commit 74280817e5013af83089a5dd511f6fb3b2362e09 Merge: a3383e8 5aad6c5 Author: Linus Torvalds Date: Fri Dec 17 09:27:30 2010 -0800 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6 * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6: ALSA: hda - Fix conflict of Mic Boot controls ALSA: HDA: Enable subwoofer on Asus G73Jw ALSA: HDA: Fix auto-mute on Lenovo Edge 14 ASoC: Fix bias power down of non-DAPM codec ASoC: WM8580: Fix R8 initial value ASoC: fix deemphasis control in wm8904/55/60 codecs commit 5aad6c5f7733b94e666e3bf8b57beb7bbee15886 Merge: 8cd1fd2 862af8a Author: Takashi Iwai Date: Fri Dec 17 15:28:37 2010 +0100 Merge branch 'fix/asoc' into for-linus commit 8cd1fd2526a78eaa1785a8ae3fe9f45a8ddd0e17 Merge: d70ab7f 53e8c32 Author: Takashi Iwai Date: Fri Dec 17 15:28:33 2010 +0100 Merge branch 'fix/hda' into for-linus commit 53e8c3239bcc7b89c76179fd33fb6faa3413c00d Author: Takashi Iwai Date: Fri Dec 17 15:23:41 2010 +0100 ALSA: hda - Fix conflict of Mic Boot controls Due to the recent change for multiple mics assignment, we need to handle the index of each Mic Boost control respectively. Otherwise the driver gets the control element conflicts, and gives the unsable state. Reference: kernel bug 25002 https://bugzilla.kernel.org/show_bug.cgi?id=25002 Reported-and-tested-by: Adam Williamson Signed-off-by: Takashi Iwai commit c20b4dd31820a551d0fb60bf27b99345905c2eb6 Author: Christian Glindkamp Date: Thu Dec 9 11:15:59 2010 +0100 at91: Refactor Stamp9G20 and PControl G20 board file As PControl G20 is a carrier board for the Stamp9G20 SoM, some code can be shared. Therefore board-stamp9g20.c is refactored to allow reusing the SoM initialization and board-pcontrol-g20.c is modified to use it. Signed-off-by: Christian Glindkamp Signed-off-by: Nicolas Ferre commit 8251544f9e28058e54c4f35b7cd13b0d191d7555 Author: Ryan Mallon Date: Wed Jun 2 12:55:36 2010 +1200 at91: Fix uhpck clock rate in upll case The uhpck clock should be divided from the utmi clock, not its parent (main). This change is mostly cosmetic as the uhpck rate value is not used anywhere except for the debugfs clock output. Signed-off-by: Ryan Mallon Signed-off-by: Nicolas Ferre commit 1cf215a5b43950d1a304373037828158057ff9fc Author: Magnus Damm Date: Fri Dec 17 15:15:48 2010 +0900 ARM: mach-shmobile: INTC interrupt priority level demux fix Fix interrupt priority level handling on SH-Mobile ARM. SH-Mobile ARM platforms using multiple interrupt priority levels need this patch to fix a potential dead lock that may occur if multiple interrupts with different levels are pending simultaneously. The default INTC configuration is to use the same priority level for all interrupts, so this issue does not trigger by default. It is however common for board code to override the interrupt priority for certain interrupt sources depending on the application. Without this fix such boards may lock up. In detail, this patch updates the INTC code in entry-macro.S to make sure that the INTLVLA register gets set as expected. To trigger this bug modify the board specific code to adjust the interrupt priority level for the ethernet chip. After changing the priority level simply use flood ping to drown the board with interrupts. This patch applies to INTCA-based processors such as sh7372, sh7377 and sh7372. GIC-based processors are not affected. Suitable for v2.6.37-rc and stable from v2.6.34 to v2.6.36. Cc: stable@kernel.org Signed-off-by: Magnus Damm Tested-by: Kuninori Morimoto Signed-off-by: Paul Mundt commit 676b14c36de5bea83f7666e5f5965188426b97a7 Author: Magnus Damm Date: Wed Dec 15 10:59:24 2010 +0000 ARM: mach-shmobile: fix compile warning in mm/init.c Turn down the warning noise from the compiler, basically a SH-Mobile specific version of the patch located in the RMK patch tracker: 6484/1: "fix compile warning in mm/init.c", Without this patch the following warning triggers: CC arch/arm/kernel/sys_arm.o arch/arm/mm/init.c: In function 'mem_init': arch/arm/mm/init.c:606: warning: format '%08lx' expects type 'long unsigned int', but argument 12 has type 'unsigned int' CC arch/arm/kernel/traps.o Signed-off-by: Magnus Damm Signed-off-by: Paul Mundt commit 65ada547d68dc075aa06df92fe325bff07cbc606 Author: Takashi YOSHII Date: Fri Dec 17 07:25:09 2010 +0000 clocksource: sh_cmt: Remove nested spinlock fix There are control flow that sh_cmt_set_next() does double spin-lock. The callers sh_cmt_{start,stop}() already have lock. But another callers sh_cmt_clock_event_{start,next}() does not. Now sh_cmt_set_next() does not lock by itself. All the callers should hold spin-lock before calling it. [damm@opensource.se: use __sh_cmt_set_next() to simplify code] [damm@opensource.se: added stable, suitable for v2.6.35 + v2.6.36] Cc: stable@kernel.org Signed-off-by: Takashi YOSHII Signed-off-by: Magnus Damm Signed-off-by: Paul Mundt commit 0fc13c8995cd96f4123de400c71c223d80400ed9 Author: Stephen M. Cameron Date: Fri Dec 17 09:01:37 2010 +0100 cciss: fix cciss_revalidate panic If you delete a logical drive, and then run BLKRRPART (e.g. via fdisk) on a logical drive which is "after" the deleted logical drive in the h->drv[] array, then cciss_revalidate panics because it will access the null pointer h->drv[x] when x hits the deleted drive. Signed-off-by: Stephen M. Cameron Cc: stable@kernel.org Signed-off-by: Jens Axboe commit 72d4cd9f38b5ed96b75df4c622be25e1c2648dd3 Author: Mike Snitzer Date: Fri Dec 17 08:34:20 2010 +0100 block: max hardware sectors limit wrapper Implement blk_limits_max_hw_sectors() and make blk_queue_max_hw_sectors() a wrapper around it. DM needs this to avoid setting queue_limits' max_hw_sectors and max_sectors directly. dm_set_device_limits() now leverages blk_limits_max_hw_sectors() logic to establish the appropriate max_hw_sectors minimum (PAGE_SIZE). Fixes issue where DM was incorrectly setting max_sectors rather than max_hw_sectors (which caused dm_merge_bvec()'s max_hw_sectors check to be ineffective). Signed-off-by: Mike Snitzer Cc: stable@kernel.org Acked-by: Martin K. Petersen Signed-off-by: Jens Axboe commit e692cb668fdd5a712c6ed2a2d6f2a36ee83997b4 Author: Martin K. Petersen Date: Wed Dec 1 19:41:49 2010 +0100 block: Deprecate QUEUE_FLAG_CLUSTER and use queue_limits instead When stacking devices, a request_queue is not always available. This forced us to have a no_cluster flag in the queue_limits that could be used as a carrier until the request_queue had been set up for a metadevice. There were several problems with that approach. First of all it was up to the stacking device to remember to set queue flag after stacking had completed. Also, the queue flag and the queue limits had to be kept in sync at all times. We got that wrong, which could lead to us issuing commands that went beyond the max scatterlist limit set by the driver. The proper fix is to avoid having two flags for tracking the same thing. We deprecate QUEUE_FLAG_CLUSTER and use the queue limit directly in the block layer merging functions. The queue_limit 'no_cluster' is turned into 'cluster' to avoid double negatives and to ease stacking. Clustering defaults to being enabled as before. The queue flag logic is removed from the stacking function, and explicitly setting the cluster flag is no longer necessary in DM and MD. Reported-by: Ed Lin Signed-off-by: Martin K. Petersen Acked-by: Mike Snitzer Cc: stable@kernel.org Signed-off-by: Jens Axboe commit cb1868869dce7b751b670aadfc1f1360bc224b29 Author: Marek Szyprowski Date: Fri Dec 17 14:47:42 2010 +0900 ARM: S5PV210: update MAX8998 platform data to get rid of WARN() This patch adds new entries required by the new version of MAX8998 driver. Without them, the driver fails to init. See commit 50f19a4596 Signed-off-by: Marek Szyprowski Signed-off-by: Kyungmin Park Signed-off-by: Kukjin Kim commit 0f8f9c2b6c1326e99e51729a5d4aeb9c3ce164e1 Author: Yauhen Kharuzhy Date: Fri Dec 17 14:45:01 2010 +0900 ARM S3C24XX: Fix compilation of PM code for S3C2416 S3C2416 PM code uses low-level sleep routines from S3C2412 code, but these routines are compiled only for S3C2412 SoC. Split S3C2412_PM to two parts: S3C2412_PM, S3C2412_PM_SLEEP and select last in S3C2416's Kconfig. Signed-off-by: Yauhen Kharuzhy Signed-off-by: Kukjin Kim commit 258b78c364b9d3f730b5e3187fc500d472b5c237 Author: Kukjin Kim Date: Fri Dec 3 21:22:42 2010 +0900 ARM: S3C24XX: Fix CONFIG_S3C_DEV_NAND Kconfig entry Should be CONFIG_S3C_DEV_NAND instead of CONFIG_S3C_DEVICE_NAND. Cc: Ben Dooks Signed-off-by: Kukjin Kim commit 147dd5610c8d1bacb88a6c1dfdaceaf257946ed0 Author: H. Peter Anvin Date: Thu Dec 16 19:11:09 2010 -0800 x86-32: Make sure we can map all of lowmem if we need to A relocatable kernel can be anywhere in lowmem -- and in the case of a kdump kernel, is likely to be fairly high. Since the early page tables map everything from address zero up we need to make sure we allocate enough brk that we can map all of lowmem if we need to. Reported-by: Stanislaw Gruszka Signed-off-by: H. Peter Anvin Tested-by: Yinghai Lu LKML-Reference: <4D0AD3ED.8070607@kernel.org> commit dbb442b85a1d82f91cfe0524c4f9b3a5196a10ca Author: Greg Kroah-Hartman Date: Thu Dec 16 15:52:30 2010 -0800 Revert "USB: gadget: Allow function access to device ID data during bind()" This reverts commit 1ab83238740ff1e1773d5c13ecac43c60cf4aec4. Turns out this doesn't allow for the device ids to be overridden properly, so we need to revert the thing. Reported-by: Jef Driesen Cc: Robert Lukassen Cc: stable Signed-off-by: Greg Kroah-Hartman commit a3383e8372c0c11238f9bb9777929bfc3a2d320a Merge: 68a4ec9 7d13162 Author: Linus Torvalds Date: Thu Dec 16 15:45:49 2010 -0800 Merge branch 'for-linus' of git://git.infradead.org/users/eparis/notify * 'for-linus' of git://git.infradead.org/users/eparis/notify: fanotify: fill in the metadata_len field on struct fanotify_event_metadata fanotify: split version into version and metadata_len fanotify: Dont try to open a file descriptor for the overflow event fanotify: Introduce FAN_NOFD fanotify: do not leak user reference on allocation failure inotify: stop kernel memory leak on file creation failure fanotify: on group destroy allow all waiters to bypass permission check fanotify: Dont allow a mask of 0 if setting or removing a mark fanotify: correct broken ref counting in case adding a mark failed fanotify: if set by user unset FMODE_NONOTIFY before fsnotify_perm() is called fanotify: remove packed from access response message fanotify: deny permissions when no event was sent commit ecc1624a2fff45780959efbcb73ace18fdb3c58d Author: Thomas Sailer Date: Tue Dec 14 16:04:05 2010 +0100 USB: misc: uss720.c: add another vendor/product ID Fabio Battaglia report that he has another cable that works with this driver, so this patch adds its vendor/product ID. Signed-off-by: Thomas Sailer Cc: stable Signed-off-by: Greg Kroah-Hartman commit d73a9b3001f29271c2e9f2a806b05a431c5d9591 Author: Vitaly Kuznetsov Date: Tue Dec 14 10:16:49 2010 -0500 USB: usb-storage: unusual_devs entry for the Samsung YP-CP3 Add an unusual_devs entry for the Samsung YP-CP3 MP4 player. User was getting the following errors in dmesg: usb 2-6: reset high speed USB device using ehci_hcd and address 2 usb 2-6: reset high speed USB device using ehci_hcd and address 2 usb 2-6: reset high speed USB device using ehci_hcd and address 2 usb 2-6: USB disconnect, address 2 sd 3:0:0:0: [sdb] Assuming drive cache: write through sdb:<2>ldm_validate_partition_table(): Disk read failed. Dev sdb: unable to read RDB block 0 unable to read partition table Signed-off-by: Vitaly Kuznetsov Acked-by: Alan Stern CC: Matthew Dharm CC: stable@kernel.org Signed-off-by: Greg Kroah-Hartman commit daba58035a044cae75488175a96cc18362a64518 Author: Pavankumar Kondeti Date: Thu Dec 16 14:32:25 2010 +0530 USB: gadget: Remove suspended sysfs file before freeing cdev cdev struct is accessed in suspended sysfs show function. So remove sysfs file before freeing the cdev in composite_unbind. Signed-off-by: Pavankumar Kondeti Signed-off-by: Greg Kroah-Hartman commit f4ce9084476dc518bfd0f35f62f4bd0a130893e0 Author: Pavankumar Kondeti Date: Thu Dec 16 14:32:24 2010 +0530 USB: core: Add input prompt and help text for USB_OTG config bd6882 commit (usb: gadget: fix Kconfig warning) removes the duplicate USB_OTG config from gadget/Kconfig. But does not copy the input prompt and help text to the original config defined in core/Kconfig. Add them now. Signed-off-by: Pavankumar Kondeti Signed-off-by: Greg Kroah-Hartman commit 68a4ec9c03461e94a9577cf499069621bb074833 Merge: b3444d1 c9bace7 Author: Linus Torvalds Date: Thu Dec 16 15:45:25 2010 -0800 Merge branch 'upstream' of git://git.linux-mips.org/pub/scm/upstream-linus * 'upstream' of git://git.linux-mips.org/pub/scm/upstream-linus: (28 commits) MIPS: Add a CONFIG_FORCE_MAX_ZONEORDER Kconfig option. MIPS: LD/SD o32 macro GAS fix update MIPS: Alchemy: fix build with SERIAL_8250=n MIPS: Rename mips_dma_cache_sync back to dma_cache_sync MIPS: MT: Fix typo in comment. SSB: Fix nvram_get on BCM47xx platform MIPS: BCM47xx: Swap serial console if ttyS1 was specified. MIPS: BCM47xx: Use sscanf for parsing mac address MIPS: BCM47xx: Fill values for b43 into SSB sprom MIPS: BCM47xx: Do not read config from CFE MIPS: FDT size is a be32 MIPS: Fix CP0 COUNTER clockevent race MIPS: Fix regression on BCM4710 processor detection MIPS: JZ4740: Fix pcm device name MIPS: Separate two consecutive loads in memset.S MIPS: Send proper signal and siginfo on FP emulator faults. MIPS: AR7: Fix loops per jiffies on TNETD7200 devices MIPS: AR7: Fix double ar7_gpio_init declaration MIPS: Rework GENERIC_HARDIRQS Kconfig. MIPS: Alchemy: Add return value check for strict_strtoul() ... commit 49c2fa08a77a7eefa4cbc73601f64984aceacfa7 Author: Neil Horman Date: Wed Dec 8 09:47:48 2010 -0500 PCI: Update MCP55 quirk to not affect non HyperTransport variants I wrote this quirk awhile ago to properly setup MCP55 chips on hypertransport busses so that interrupts reached whatever cpu happend to boot the kdump kernel. while that works well, it was recently shown to me that a a non-hypertransport variant of the MCP55 exists, and on those system the register that this quirk manipulates causes hangs if you write to it. Since the quirk was only meant to handle errors found on MCP55 chips that have a HT interface, this patch adds a filter to make sure the chip is an HT capable before making the needed register adjustment. This lets the broken MCP55s work with kdump while not breaking the non-HT variants. Resolves https://bugzilla.kernel.org/show_bug.cgi?id=23952 Tested successfully by the reporter and myself. Cc: stable@kernel.org Reported-by: Mathieu Bérard Acked-by: Vivek Goyal Signed-off-by: Neil Horman Signed-off-by: Jesse Barnes commit 093d804611b9a38fe59753b37c29f840518406a9 Author: Ken Mills Date: Mon Dec 13 15:28:03 2010 +0000 n_gsm: gsm_data_alloc buffer allocation could fail and it is not being checked gsm_data_alloc buffer allocation could fail and it is not being checked. Add check for allocated buffer and return if the buffer allocation fails. Signed-off-by: Ken Mills Signed-off-by: Alan Cox Cc: stable@kernel.org Signed-off-by: Greg Kroah-Hartman commit be7a7411d63ccad165d66fe8e0b11b2ee336159b Author: Ken Mills Date: Mon Dec 13 15:27:27 2010 +0000 n_gsm: Fix message length handling when building header Fix message length handling when building header When the message length is greater than 127, the length field in the header is built incorrectly. According to the spec, when the length is less than 128 the length field is a single byte formatted as: bbbbbbb1. When it is greater than 127 then the field is two bytes of the format: bbbbbbb0 bbbbbbbb. Signed-off-by: Ken Mills Signed-off-by: Alan Cox Cc: stable@kernel.org Signed-off-by: Greg Kroah-Hartman commit c9bace7ca1e2aeb95754ebc92c8f88a9f215691d Author: David Daney Date: Mon Oct 11 14:52:45 2010 -0700 MIPS: Add a CONFIG_FORCE_MAX_ZONEORDER Kconfig option. For huge page support with base page size of 16K or 32K, we have to increase the MAX_ORDER so that huge pages can be allocated. [Ralf: I don't think a user should have to configure obscure constants like this but for the time being this will have to suffice.] Signed-off-by: David Daney To: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/1685/ Signed-off-by: Ralf Baechle commit 82b89152f00f7ad17844d5614d5011e8d7944ac9 Author: Maciej W. Rozycki Date: Sun Oct 10 10:42:12 2010 +0100 MIPS: LD/SD o32 macro GAS fix update I am about to commit: http://sourceware.org/ml/binutils/2010-10/msg00033.html that fixes a problem with the LD/SD macro currently implemented by GAS for the o32 ABI in an inconsistent way. This is best illustrated with a simple program, which I'm copying here from the message above for easier reference: $ cat ld.s ld $5,32767($4) ld $5,32768($4) This gets assebled into the following output: $ mips-linux-as -32 -mips3 -o ld.o ld.s $ mips-linux-objdump -d ld.o ld.o: file format elf32-tradbigmips Disassembly of section .text: 00000000 <.text>: 0: dc857fff ld a1,32767(a0) 4: 3c010001 lui at,0x1 8: 00810821 addu at,a0,at c: 8c258000 lw a1,-32768(at) 10: 8c268004 lw a2,-32764(at) ... Oops! The GAS fix makes the macro behave in a consistent way and pairs of LW/SW instructions to be output as appropriate regardless of the size of the offset associated with the address used. The machine instruction is still available, but to reach it macros have to be disabled first. This has a side effect of requiring the use of a machine-addressable memory operand. As some platforms require 64-bit operations for accesses to some I/O registers LD/SD instructions are used in a couple of places in Linux regardless of the ABI selected. Here's a fix for some pieces of code affected I've been able to track down. The fix should be backwards compatible with all supported binutils releases in existence and can be used as a reference for any other places or off-tree code. The use of the "R" constraint guarantees a machine-addressable operand. Signed-off-by: Maciej W. Rozycki Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/1680/ Signed-off-by: Ralf Baechle commit cf745a39dcb10ef80c4a2ff38448f57b69d4c4eb Author: Manuel Lauss Date: Mon Oct 25 18:44:11 2010 +0200 MIPS: Alchemy: fix build with SERIAL_8250=n In commit 7d172bfe ("Alchemy: Add UART PM methods") I introduced platform PM methods which call a function of the 8250 driver; this patch works around link failures when the kernel is built without 8250 support. Signed-off-by: Manuel Lauss To: Linux-MIPS Patchwork: https://patchwork.linux-mips.org/patch/1737/ Signed-off-by: Ralf Baechle commit a3aad4aaf871045ab1dd9c99be6c1ace881d8eb0 Author: Ralf Baechle Date: Thu Dec 9 19:14:09 2010 +0000 MIPS: Rename mips_dma_cache_sync back to dma_cache_sync This fixes IP22 and IP28 build errors. Signed-off-by: Ralf Baechle commit d002aaadf84c081623a0a8502c122d1492fbd47c Author: Ralf Baechle Date: Wed Dec 1 17:33:17 2010 +0000 MIPS: MT: Fix typo in comment. Signed-off-by: Ralf Baechle commit 3f84622d7c7818077f5e6cf4b8a0d1b10dc65147 Author: Hauke Mehrtens Date: Sat Nov 27 19:26:32 2010 +0100 SSB: Fix nvram_get on BCM47xx platform The nvram_get function was never in the mainline kernel, it only existed in an external OpenWrt patch. Use nvram_getenv function, which is in mainline and use an include instead of an extra function declaration. et0macaddr contains the mac address in text from like 00:11:22:33:44:55. We have to parse it before adding it into macaddr. nvram_parse_macaddr will be merged into asm/mach-bcm47xx/nvram.h through the MIPS git tree and will be available soon. It will not build now without nvram_parse_macaddr, but it hasn't before either. Signed-off-by: Hauke Mehrtens To: linux-mips@linux-mips.org Cc: mb@bu3sch.de Cc: netdev@vger.kernel.org Cc: Hauke Mehrtens Acked-by: Michael Buesch Patchwork: https://patchwork.linux-mips.org/patch/1849/ Signed-off-by: Ralf Baechle commit 1690a7f9ab83f5c823f3044275a4a771a059d5bb Author: Hauke Mehrtens Date: Sat Nov 27 17:46:01 2010 +0100 MIPS: BCM47xx: Swap serial console if ttyS1 was specified. Some devices like the Netgear WGT634U are using ttyS1 for default console output. We should switch to that console if it was given in the kernel_args parameters. Signed-off-by: Hauke Mehrtens To: linux-mips@linux-mips.org Cc: Hauke Mehrtens Patchwork: https://patchwork.linux-mips.org/patch/1848/ Signed-off-by: Ralf Baechle commit 59833fcf48ee7b7c8a01e590aa7b7212305c3077 Author: Hauke Mehrtens Date: Sat Nov 27 17:46:00 2010 +0100 MIPS: BCM47xx: Use sscanf for parsing mac address Instead of writing own function for parsing the mac address we now use sscanf. Signed-off-by: Hauke Mehrtens To: linux-mips@linux-mips.org Cc: Hauke Mehrtens Patchwork: https://patchwork.linux-mips.org/patch/1847/ Signed-off-by: Ralf Baechle commit 2aa088d6fd8a6c6e6020ea46b70141f0b7ccf5d2 Author: Hauke Mehrtens Date: Sat Nov 27 17:45:59 2010 +0100 MIPS: BCM47xx: Fill values for b43 into SSB sprom Fill the sprom with all available values from the nvram. Most of these new values are needed for the b43 or b43legacy driver. Parts of this patch have been in OpenWRT for a long time and were written by Michael Buesch. Signed-off-by: Hauke Mehrtens To: linux-mips@linux-mips.org Cc: Hauke Mehrtens Patchwork: https://patchwork.linux-mips.org/patch/1846/ Signed-off-by: Ralf Baechle commit 825710843640dd173bc4b2ea99f1296923e4aa06 Author: Hauke Mehrtens Date: Sat Nov 27 17:45:58 2010 +0100 MIPS: BCM47xx: Do not read config from CFE The config options read out here are not stored in CFE but only in NVRAM on the devices. Remove reading from CFE and only access the NVRAM. Reading out CFE does not harm but is useless here. Signed-off-by: Hauke Mehrtens To: linux-mips@linux-mips.org Cc: Hauke Mehrtens Patchwork: https://patchwork.linux-mips.org/patch/1845/ Signed-off-by: Ralf Baechle commit e31fee7c3a197d88d1d0ced0e8600386da27fec4 Author: Thomas Chou Date: Wed Nov 24 15:35:48 2010 +0800 MIPS: FDT size is a be32 The totalsize field was be32. And the reserve bootmem would cause failure. Signed-off-by: Thomas Chou To: devicetree-discuss@lists.ozlabs.org Cc: linux-kernel@vger.kernel.org Cc: linux-mips@linux-mips.org Cc: grant.likely@secretlab.ca Cc: David Daney Cc: Dezhong Diao Patchwork: https://patchwork.linux-mips.org/patch/1838/ Signed-off-by: Ralf Baechle commit 5878fc936aebf592cca418ca50773cd578f7daf4 Author: Kevin Cernekee Date: Tue Nov 23 10:26:44 2010 -0800 MIPS: Fix CP0 COUNTER clockevent race Consider the following test case: write_c0_compare(read_c0_count()); Even if the counter doesn't increment during execution, this might not generate an interrupt until the counter wraps around. The CPU may perform the comparison each time CP0 COUNT increments, not when CP0 COMPARE is written. If mips_next_event() is called with a very small delta, and CP0 COUNT increments during the calculation of "cnt += delta", it is possible that CP0 COMPARE will be written with the current value of CP0 COUNT. If this is detected, the function should return -ETIME, to indicate that the interrupt might not have actually gotten scheduled. Signed-off-by: Kevin Cernekee Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/1836/ Signed-off-by: Ralf Baechle commit 190fca3e40a65303eac35ac4fbae4f1f1342431c Author: Kevin Cernekee Date: Tue Nov 23 10:26:45 2010 -0800 MIPS: Fix regression on BCM4710 processor detection BCM4710 uses the BMIPS32 core (like BCM6345), not the MIPS 4Kc core as was previously believed. Signed-off-by: Kevin Cernekee Tested-by: Alexandros C. Couloumbis Patchwork: https://patchwork.linux-mips.org/patch/1837/ Signed-off-by: Ralf Baechle commit 4afdea81821880d0fc35e6c7ff54eeed9ec0614d Author: Lars-Peter Clausen Date: Thu Nov 11 19:08:52 2010 +0100 MIPS: JZ4740: Fix pcm device name As part the ASoC multi-component patch (commit f0fba2ad) the jz4740 pcm driver was renamed to 'jz4740-pcm-audio'. Adjust the device name accordingly. Signed-off-by: Lars-Peter Clausen Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/1770/ Signed-off-by: Ralf Baechle commit e5674ad6ca9f1020c2bcc009a55becba3c30d8a3 Author: Tony Wu Date: Wed Nov 10 21:48:15 2010 +0800 MIPS: Separate two consecutive loads in memset.S partial_fixup is used in noreorder block. Separating two consecutive loads can save one cycle on processors with GPR intrelock and can fix load-use on processors that need a load delay slot. Also do so for fwd_fixup. [Ralf: Only R2000/R3000 class processors are lacking the the load-user interlock and even some of those got it retrofitted. With R2000/R3000 being fairly uncommon these days the impact of this bug should be minor.] Signed-off-by: Tony Wu To: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/1768/ Signed-off-by: Ralf Baechle commit 515b029d005b5694cf612a0a5ca6f861a7e45362 Author: David Daney Date: Thu Oct 21 16:32:26 2010 -0700 MIPS: Send proper signal and siginfo on FP emulator faults. We were unconditionally sending SIGBUS with an empty siginfo on FP emulator faults. This differs from what happens when real floating point hardware would get a fault. For most faults we need to send SIGSEGV with the faulting address filled in in the struct siginfo. Reported-by: Camm Maguire Signed-off-by: David Daney To: linux-mips@linux-mips.org Cc: Camm Maguire Patchwork: https://patchwork.linux-mips.org/patch/1727/ Signed-off-by: Ralf Baechle commit 0bc6791707694c77b3543de39f77972a65de917a Author: Florian Fainelli Date: Sun Oct 31 23:49:58 2010 +0100 MIPS: AR7: Fix loops per jiffies on TNETD7200 devices TNETD7200 run their CPU clock faster than the default CPU clock we assume. In order to have the correct loops per jiffies settings, initialize clocks right before setting mips_hpt_frequency. As a side effect, we can no longer use msleep in clocks.c which requires other parts of the kernel to be initialized, so replace these with mdelay. Signed-off-by: Florian Fainelli To: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/1749/ Signed-off-by: Ralf Baechle commit ff42d62047e45075c54a5543bd4f110dfd032d11 Author: Florian Fainelli Date: Sun Oct 31 23:49:57 2010 +0100 MIPS: AR7: Fix double ar7_gpio_init declaration Signed-off-by: Florian Fainelli To: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/1748/ Signed-off-by: Ralf Baechle commit 3bd27e329ca80f4946efdd12bf1f5a9bf0886e76 Author: David Daney Date: Fri Nov 5 15:12:48 2010 -0700 MIPS: Rework GENERIC_HARDIRQS Kconfig. Recent changes to CONFIG_GENERIC_HARDIRQS have caused us to start getting: warning: (SMP && SYS_SUPPORTS_SMP) selects IRQ_PER_CPU which has unmet direct dependencies (HAVE_GENERIC_HARDIRQS) Rearranging our Kconfig quiets the message. Signed-off-by: David Daney To: linux-mips@linux-mips.org Cc: Thomas Gleixner Patchwork: https://patchwork.linux-mips.org/patch/1757/ Signed-off-by: Ralf Baechle commit 690ca2ce0c824e8d3da7b2e273c2c873ab96d1e6 Author: Yoichi Yuasa Date: Mon Nov 8 17:23:52 2010 +0900 MIPS: Alchemy: Add return value check for strict_strtoul() arch/mips/alchemy/devboards/prom.c: In function 'prom_init': arch/mips/alchemy/devboards/prom.c:60: error: ignoring return value of 'strict_strtoul', declared with attribute warn_unused_result Signed-off-by: Yoichi Yuasa Cc: linux-mips Patchwork: https://patchwork.linux-mips.org/patch/1761/ Signed-off-by: Ralf Baechle commit ec79812580e360081b58c3e2e8b5b69b8080b5a0 Author: Wu Zhangjin Date: Mon Nov 8 21:25:24 2010 +0800 MIPS: Loongson: Add return value check for strict_strtoul() cc1: warnings being treated as errors arch/mips/loongson/common/env.c: In function 'prom_init_env': arch/mips/loongson/common/env.c:49: error: ignoring return value of 'strict_strtol', declared with attribute warn_unused_result arch/mips/loongson/common/env.c:50: error: ignoring return value of 'strict_strtol', declared with attribute warn_unused_result arch/mips/loongson/common/env.c:51: error: ignoring return value of 'strict_strtol', declared with attribute warn_unused_result arch/mips/loongson/common/env.c:52: error: ignoring return value of 'strict_strtol', declared with attribute warn_unused_result Signed-off-by: Wu Zhangjin Cc: linux-mips Patchwork: https://patchwork.linux-mips.org/patch/1762/ Signed-off-by: Ralf Baechle commit 863abad4f644b6c12bc8176206b35fa7e7cfe1a9 Author: Jesper Juhl Date: Sat Oct 30 18:37:16 2010 +0200 MIPS: VPE loader: Check vmalloc return value in vpe_open The return value of the vmalloc() call in arch/mips/kernel/vpe.c::vpe_open() is not checked, so we potentially store a null pointer in v->pbuffer. Add a check for a null return and then return -ENOMEM in that case. [Ralf: The check added by Jesper's original patch is where it logically should be. Adding it eleminated the need for the checks in a few other places, so I removed them. There still is a zillion of other things that need to be fixed in this file / API.] Signed-off-by: Jesper Juhl Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/1747/ Signed-off-by: Ralf Baechle commit d62c9ced7ca783e64ff4d9d3d1340cfe2284d47b Author: David Daney Date: Mon Nov 1 17:43:08 2010 -0700 MIPS: compat: Don't clobber personality bits in 32-bit sys_personality(). If PER_LINUX32 has been set on a 32-bit kernel, only twiddle with the low-order personality bits, let the upper bits pass through. Signed-off-by: David Daney To: linux-mips@linux-mips.org Cc: Camm Maguire Patchwork: https://patchwork.linux-mips.org/patch/1751/ Signed-off-by: Ralf Baechle commit 1c0d52b9b5e6ca277c13d6fece9c34ed3159423d Author: David Daney Date: Mon Nov 1 17:43:07 2010 -0700 MIPS: Don't clobber personality high bits. The high bits of current->personality carry settings that we don't want to clobber on each exec. Only clobber them if the lower bits that indicate either PER_LINUX or PER_LINUX32 are invalid. The clobbering prevents us from using useful bits like ADDR_NO_RANDOMIZE. Reported-by: Camm Maguire Signed-off-by: David Daney Cc: Camm Maguire Patchwork: https://patchwork.linux-mips.org/patch/1750/ Signed-off-by: Ralf Baechle commit 1d210386f6ef9000b1cd723cf453c5eb0377e722 Author: Lars-Peter Clausen Date: Thu Nov 4 23:25:57 2010 +0100 MIPS: jz4740: Fix section mismatch in prom.c This patch fixes the following section mismatch: WARNING: arch/mips/built-in.o(.text+0xc): Section mismatch in reference from the function jz4740_init_cmdline() to the variable .init.data:arcs_cmdline While were at it, make jz4740_init_cmdline static as well. Signed-off-by: Lars-Peter Clausen Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/1755/ Signed-off-by: Ralf Baechle commit fe749aab1d21cbb4d87527a7df8799583c233496 Author: Lars-Peter Clausen Date: Thu Nov 4 23:25:56 2010 +0100 MIPS: jz4740: qi_lb60: Fix gpio for the 6th row of the keyboard matrix This patch fixes the gpio number for the 6th row of the keyboard matrix. (And fixes a typo in my name...) Signed-off-by: Lars-Peter Clausen Cc: linux-mips@linux-mips.org Cc: stable@kernel.org Signed-off-by: https://patchwork.linux-mips.org/patch/1754/ Signed-off-by: Ralf Baechle commit a989ff898f9740651d00388c33bdf4f2a7914920 Author: Al Viro Date: Thu Nov 4 11:13:59 2010 +0000 MIPS: Don't stomp on caller's ->regs[2] in copy_thread() We never needed that (->regs[2] is overwritten on return from syscall paths with return value of syscall, so storing it there early made no sense) and with new restart logics since d27240bf7e61d2656de18e158ec910a902030847 it has become really bad - we lose the original syscall number before the place where we decide that we might need a syscall restart. Note that for child we do need the assignment to regs[2] - it won't go through the normal return from syscall path. [Ralf: Issue found and reported by Lluís; initial investigations by me; bug finally found and patch by Al; testing by me and Lluís.] Signed-off-by: Al Viro Tested-by: Lluís Batlle i Rossell Signed-off-by: Ralf Baechle commit 2b3e50234eafc40a04f5f4a2b7bb24b506fd7e87 Author: Ralf Baechle Date: Tue Nov 2 19:38:53 2010 +0000 MIPS: Swarm: Fix typo in symbol name: RTC_M4LT81 -> RTC_M41T81 Signed-off-by: Ralf Baechle commit b3444d164be8f977f4133ef0c6f4a18f2741373f Merge: 4ef5c68 da32dac Author: Linus Torvalds Date: Thu Dec 16 08:51:57 2010 -0800 Merge git://git.kernel.org/pub/scm/linux/kernel/git/rusty/linux-2.6-for-linus * git://git.kernel.org/pub/scm/linux/kernel/git/rusty/linux-2.6-for-linus: lguest: populate initial_page_table lguest: restore boot speed lguest: fix crash lguest_time_init commit 4ef5c68f0a40a95d63c210ba7e3751540e1cb1f1 Merge: 9fe4145 947b10a Author: Linus Torvalds Date: Thu Dec 16 08:34:22 2010 -0800 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ryusuke/nilfs2 * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ryusuke/nilfs2: nilfs2: fix regression of garbage collection ioctl commit 9fe4145530e6072cc838beb95ca68cada8c56909 Merge: b0c3844 ab4e019 Author: Linus Torvalds Date: Thu Dec 16 08:33:44 2010 -0800 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input: Input: define separate EVIOCGKEYCODE_V2/EVIOCSKEYCODE_V2 Input: wacom - add another Bamboo Pen ID (0xd4) commit f08f5a0add20834d3f3d876dfe08005a5df656db Author: Rafael J. Wysocki Date: Thu Dec 16 17:11:58 2010 +0100 PM / Runtime: Fix pm_runtime_suspended() There are some situations (e.g. in __pm_generic_call()), where pm_runtime_suspended() is used to decide whether or not to execute a device's (system) ->suspend() callback. The callback is not executed if pm_runtime_suspended() returns true, but it does so for devices that don't even support runtime PM, because the power.disable_depth device field is ignored by it. This leads to problems (i.e. devices are not suspened when they should), so rework pm_runtime_suspended() so that it returns false if the device's power.disable_depth field is different from zero. Signed-off-by: Rafael J. Wysocki Cc: stable@kernel.org commit be8cd644c49dca4212e975455c8e7119b848ebe8 Author: Rafael J. Wysocki Date: Sat Dec 11 21:46:44 2010 +0100 PM / Hibernate: Restore old swap signature to avoid user space breakage Commit 3624eb0 (PM / Hibernate: Modify signature used to mark swap) attempted to modify hibernate signature used to mark swap partitions containing hibernation images, so that old kernels don't try to handle compressed images. However, this change broke resume from hibernation on Fedora 14 that apparently doesn't pass the resume= argument to the kernel and tries to trigger resume from early user space. This doesn't work, because the signature is now different, so the old signature has to be restored to avoid the problem. Addresses https://bugzilla.kernel.org/show_bug.cgi?id=22732 . Reported-by: Dr. David Alan Gilbert Reported-by: Zhang Rui Reported-by: Pascal Chapperon Signed-off-by: Rafael J. Wysocki commit 1497dd1d29c6a53fcd3c80f7ac8d0e0239e7389e Author: Takashi Iwai Date: Fri Dec 10 00:16:39 2010 +0100 PM / Hibernate: Fix PM_POST_* notification with user-space suspend The user-space hibernation sends a wrong notification after the image restoration because of thinko for the file flag check. RDONLY corresponds to hibernation and WRONLY to restoration, confusingly. Signed-off-by: Takashi Iwai Signed-off-by: Rafael J. Wysocki Cc: stable@kernel.org commit e13416ae7f378f9963ceca596ac464d4120093f3 Merge: b0c3844 b99ddbf Author: Paul Mundt Date: Thu Dec 16 23:38:41 2010 +0900 Merge branch 'for-paul-rc' of git://gitorious.org/linux-omap-dss2/linux into fbdev-fixes-for-linus * 'for-paul-rc' of git://gitorious.org/linux-omap-dss2/linux: OMAP: OMAPFB: disable old omapfb for OMAP4 builds OMAP: DSS: VRAM: Align start & size of vram to 2M commit 3e26f23091da06d02fa62da14c95f3688d27857c Author: Avi Kivity Date: Thu Dec 16 12:16:34 2010 +0200 KVM: Fix preemption counter leak in kvm_timer_init() Based on a patch from Thomas Meyer. Signed-off-by: Avi Kivity commit d949750fed168b6553ca11ed19e4affd19d7a4d7 Merge: ce67783 e63233f7 Author: Ingo Molnar Date: Thu Dec 16 11:21:24 2010 +0100 Merge branch 'tip/perf/urgent' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-2.6-trace into perf/urgent commit 8e92c20183ed0579d94501311b81c42b65cb2129 Author: Peter Zijlstra Date: Thu Dec 9 14:15:34 2010 +0100 sched: Fix the irqtime code for 32bit Since the irqtime accounting is using non-atomic u64 and can be read from remote cpus (writes are strictly cpu local, reads are not) we have to deal with observing partial updates. When we do observe partial updates the clock movement (in particular, ->clock_task movement) will go funny (in either direction), a subsequent clock update (observing the full update) will make it go funny in the oposite direction. Since we rely on these clocks to be strictly monotonic we cannot suffer backwards motion. One possible solution would be to simply ignore all backwards deltas, but that will lead to accounting artefacts, most notable: clock_task + irq_time != clock, this inaccuracy would end up in user visible stats. Therefore serialize the reads using a seqcount. Reviewed-by: Venkatesh Pallipadi Reported-by: Mikael Pettersson Tested-by: Mikael Pettersson Signed-off-by: Peter Zijlstra LKML-Reference: <1292242434.6803.200.camel@twins> Signed-off-by: Ingo Molnar commit fe44d62122829959e960bc699318d58966922a69 Author: Peter Zijlstra Date: Thu Dec 9 14:15:34 2010 +0100 sched: Fix the irqtime code to deal with u64 wraps Some ARM systems have a short sched_clock() [ which needs to be fixed too ], but this exposed a bug in the irq_time code as well, it doesn't deal with wraps at all. Fix the irq_time code to deal with u64 wraps by re-writing the code to only use delta increments, which avoids the whole issue. Reviewed-by: Venkatesh Pallipadi Reported-by: Mikael Pettersson Tested-by: Mikael Pettersson Signed-off-by: Peter Zijlstra LKML-Reference: <1292242433.6803.199.camel@twins> Signed-off-by: Ingo Molnar commit ce677831a4abd0f9f957c90ac6f6a0d0472bafb4 Author: Dan Carpenter Date: Sun Oct 24 21:50:42 2010 +0200 perf: Fix off by one in perf_swevent_init() The perf_swevent_enabled[] array has PERF_COUNT_SW_MAX elements. Signed-off-by: Dan Carpenter Signed-off-by: Peter Zijlstra LKML-Reference: <20101024195041.GT5985@bicker> Signed-off-by: Ingo Molnar commit da32dac101263fb5b155407507c548e3ac2a6a2a Author: Rusty Russell Date: Thu Dec 16 17:03:15 2010 -0600 lguest: populate initial_page_table Two x86 patches broke lguest: 1) v2.6.35-492-g72d7c3b, which changed x86 to use the memblock allocator. In lguest, the host places linear page tables at the top of mem, which used to be enough to get us up to the swapper_pg_dir page tables. With the first patch, the direct mapping tables used that memory: Before: kernel direct mapping tables up to 4000000 @ 7000-1a000 After: kernel direct mapping tables up to 4000000 @ 3fed000-4000000 I initially fixed this by lying about the amount of memory we had, so the kernel wouldn't blatt the lguest boot pagetables (yuk!), but then... 2) v2.6.36-rc8-54-gb40827f, which made x86 boot use initial_page_table. This was initialized in a part of head_32.S which isn't executed by lguest; it is then copied into swapper_pg_dir. So we have to initialize it; and anyway we switch to it before we blatt the old tables, so that fixes the previous damage as well. For the moment, I cut & pasted the code into lguest's boot code, but next merge window I will merge them. Signed-off-by: Rusty Russell Cc: Jeremy Fitzhardinge Cc: Konrad Rzeszutek Wilk To: x86@kernel.org commit bb4093deb259ea9c92415796a6a139e35272f8a8 Author: Rusty Russell Date: Thu Dec 16 17:03:15 2010 -0600 lguest: restore boot speed lguest is dumb and drops *all* the pagetables for set_pte (which is only used for kernel mapping manipulation, so it's OK without highmem). But it's used a lot in boot, too. As a guest optimization, we suppressed this flushing until the first page switch. Now we have initial_page_table, that happens much earlier, so extend the heuristic to wait until we switch to something other than the swapper_pg_dir or initial_page_table. As measured on my laptop under kvm, this dropped the time-to-mount-root from 48 seconds to 4.3 seconds. Signed-off-by: Rusty Russell commit bb6f1d9a99f1947d91693de62ed54ac3bf1e2dfe Author: Rusty Russell Date: Thu Dec 16 17:03:13 2010 -0600 lguest: fix crash lguest_time_init fe25c7fc2e "x86: lguest: Convert to new irq chip functions" converted enable_lguest_irq() to take a struct irq_data *, but didn't fix the one internal caller. Signed-off-by: Rusty Russell To: x86@kernel.org commit 947b10ae0aeda89fc066a7470fdba55f72b0b8fc Author: Ryusuke Konishi Date: Thu Dec 16 09:57:57 2010 +0900 nilfs2: fix regression of garbage collection ioctl On 2.6.37-rc1, garbage collection ioctl of nilfs was broken due to the commit 263d90cefc7d82a0 ("nilfs2: remove own inode hash used for GC"), and leading to filesystem corruption. The patch doesn't queue gc-inodes for log writer if they are reused through the vfs inode cache. Here, gc-inode is the inode which buffers blocks to be relocated on GC. That patch queues gc-inodes in nilfs_init_gcinode() function, but this function is not called when they don't have I_NEW flag. Thus, some of live blocks are wrongly overrode without being moved to new logs. This resolves the problem by moving the gc-inode queueing to an outer function to ensure it's done right. Signed-off-by: Ryusuke Konishi commit ab226e21ad34f6ef52e00d2ab399d2364b4cdfee Author: Henry C Chang Date: Wed Dec 15 20:41:54 2010 -0800 ceph: fix direct-io on non-page-aligned buffers The user buffer may be 512-byte aligned, not page-aligned. We were assuming the buffer was page-aligned and only accounting for non-page-aligned io offsets. Signed-off-by: Henry C Chang Signed-off-by: Sage Weil commit 7d13162332f2b67a941d18cee20f1c0413e020de Author: Eric Paris Date: Tue Dec 7 15:27:57 2010 -0500 fanotify: fill in the metadata_len field on struct fanotify_event_metadata The fanotify_event_metadata now has a field which is supposed to indicate the length of the metadata portion of the event. Fill in that field as well. Based-in-part-on-patch-by: Alexey Zaytsev Signed-off-by: Eric Paris commit 62731fa0c893515dc6cbc3e0a2879a92793c735f Author: Alexey Zaytsev Date: Mon Nov 22 00:33:03 2010 +0000 fanotify: split version into version and metadata_len To implement per event type optional headers we are interested in knowing how long the metadata structure is. This patch slits the __u32 version field into a __u8 version and a __u16 metadata_len field (with __u8 left over). This should allow for backwards compat ABI. Signed-off-by: Alexey Zaytsev [rewrote descrtion and changed object sizes and ordering - eparis] Signed-off-by: Eric Paris commit b99ddbf83c064382b145d2156cc819d1eb4fc54d Author: Tomi Valkeinen Date: Tue Dec 14 14:39:06 2010 +0200 OMAP: OMAPFB: disable old omapfb for OMAP4 builds Build fails when OMAP4 and FB_OMAP are defined: drivers/built-in.o: In function `omapfb_do_probe': drivers/video/omap/omapfb_main.c:1773: undefined reference to `omap2_int_ctrl' Old omapfb does not work on OMAP4, and never will. Change the omapfb build dependency so that old omapfb depends on OMAP1/2/3, fixing the build for plain OMAP4 builds. Reported-by: Russell King Signed-off-by: Tomi Valkeinen commit 4422c04bbb09f1864e2ce27296457f86d4167fe2 Author: Tomi Valkeinen Date: Tue Dec 14 14:16:59 2010 +0200 OMAP: DSS: VRAM: Align start & size of vram to 2M Align the start address and size of VRAM area to 2M as per comments from Russell King: > > So, why SZ_2M? > > Firstly, that's the granularity which we allocate page tables - one > Linux page table covers 2MB of memory. We want to avoid creating page > tables for the main memory mapping as that increases TLB pressure through > the use of additional TLB entries, and more page table walks. > > Plus, we never used to allow the kernel's direct memory mapping to be > mapped at anything less than section size - this restriction has since > been lifted due to OMAP SRAM problems, but I'd rather we stuck with it > to ensure that we have proper behaviour from all parts of the system. > > Secondly, we don't want to end up with lots of fragmentation at the end > of the memory mapping as that'll reduce performance, not only by making > the pfn_valid() search more expensive. > > Emsuring a minimum allocation size and alignment makes sure that the > regions can be coalesced together into one block, and minimises run-time > expenses. > > So please, 2MB, or if you object, at the _very_ _least_ 1MB. But > definitely not PAGE_SIZE. Signed-off-by: Tomi Valkeinen Acked-by: Tony Lindgren commit ac612407932be18697b5ae9da0a80f138b8bea8e Author: David Henningsson Date: Wed Dec 15 09:18:18 2010 +0100 ALSA: HDA: Enable subwoofer on Asus G73Jw Set default association/sequence right on pin 0x17 in order for the automatic parser to recognize the subwoofer correctly. Signed-off-by: David Henningsson Signed-off-by: Takashi Iwai commit ab4e0192196b8d4e43a3945742d4996da934a86f Author: Dmitry Torokhov Date: Tue Dec 14 23:53:21 2010 -0800 Input: define separate EVIOCGKEYCODE_V2/EVIOCSKEYCODE_V2 The desire to keep old names for the EVIOCGKEYCODE/EVIOCSKEYCODE while extending them to support large scancodes was a mistake. While we tried to keep ABI intact (and we succeeded in doing that, programs compiled on older kernels will work on newer ones) there is still a problem with recompiling existing software with newer kernel headers. New kernel headers will supply updated ioctl numbers and kernel will expect that userspace will use struct input_keymap_entry to set and retrieve keymap data. But since the names of ioctls are still the same userspace will happily compile even if not adjusted to make use of the new structure and will start miraculously fail in the field. To avoid this issue let's revert EVIOCGKEYCODE/EVIOCSKEYCODE definitions and add EVIOCGKEYCODE_V2/EVIOCSKEYCODE_V2 so that userspace can explicitly select the style of ioctls it wants to employ. Reviewed-by: Henrik Rydberg Acked-by: Jarod Wilson Acked-by: Mauro Carvalho Chehab Signed-off-by: Dmitry Torokhov commit fe67b24010c66a14d84117ac67d23ed1bcb18a71 Author: David Henningsson Date: Wed Dec 15 08:01:46 2010 +0100 ALSA: HDA: Fix auto-mute on Lenovo Edge 14 BugLink: http://launchpad.net/bugs/690530 The SKU value of this machine dictates that auto-mute should be disabled. Since the SKU value is similar to the PCI SSID, the most likely conclusion is that the SKU value should be ignored. Signed-off-by: David Henningsson Signed-off-by: Takashi Iwai commit d96c9043d1588f04c7f467167f653c07d83232d5 Author: Sage Weil Date: Mon Dec 13 20:30:28 2010 -0800 ceph: fix msgr_init error path create_workqueue() returns NULL on failure. Signed-off-by: Sage Weil commit 7f99d946e71e71d484b7543b49e990508e70d0c0 Author: Suresh Siddha Date: Tue Nov 30 22:22:29 2010 -0800 x86, vt-d: Handle previous faults after enabling fault handling Fault handling is getting enabled after enabling the interrupt-remapping (as the success of interrupt-remapping can affect the apic mode and hence the fault handling mode). Hence there can potentially be some faults between the window of enabling interrupt-remapping in the vt-d and the fault-handling of the vt-d units. Handle any previous faults after enabling the vt-d fault handling. For v2.6.38 cleanup, need to check if we can remove the dmar_fault() in the enable_intr_remapping() and see if we can enable fault handling along with enabling intr-remapping. Signed-off-by: Suresh Siddha LKML-Reference: <20101201062244.630417138@intel.com> Cc: stable@kernel.org [v2.6.32+] Acked-by: Chris Wright Signed-off-by: H. Peter Anvin commit 7f7fbf45c6b748074546f7f16b9488ca71de99c1 Author: Kenji Kaneshige Date: Tue Nov 30 22:22:28 2010 -0800 x86: Enable the intr-remap fault handling after local APIC setup Interrupt-remapping gets enabled very early in the boot, as it determines the apic mode that the processor can use. And the current code enables the vt-d fault handling before the setup_local_APIC(). And hence the APIC LDR registers and data structure in the memory may not be initialized. So the vt-d fault handling in logical xapic/x2apic modes were broken. Fix this by enabling the vt-d fault handling in the end_local_APIC_setup() A cleaner fix of enabling fault handling while enabling intr-remapping will be addressed for v2.6.38. [ Enabling intr-remapping determines the usage of x2apic mode and the apic mode determines the fault-handling configuration. ] Signed-off-by: Kenji Kaneshige LKML-Reference: <20101201062244.541996375@intel.com> Signed-off-by: Suresh Siddha Cc: stable@kernel.org [v2.6.32+] Acked-by: Chris Wright Signed-off-by: H. Peter Anvin commit 086e8ced65d9bcc4a8e8f1cd39b09640f2883f90 Author: Kenji Kaneshige Date: Wed Dec 1 09:40:32 2010 -0800 x86, vt-d: Fix the vt-d fault handling irq migration in the x2apic mode In x2apic mode, we need to set the upper address register of the fault handling interrupt register of the vt-d hardware. Without this irq migration of the vt-d fault handling interrupt is broken. Signed-off-by: Kenji Kaneshige LKML-Reference: <1291225233.2648.39.camel@sbsiddha-MOBL3> Signed-off-by: Suresh Siddha Cc: stable@kernel.org [v2.6.32+] Acked-by: Chris Wright Tested-by: Takao Indoh Signed-off-by: H. Peter Anvin commit 254e42006c893f45bca48f313536fcba12206418 Author: Suresh Siddha Date: Mon Dec 6 12:26:30 2010 -0800 x86, vt-d: Quirk for masking vtd spec errors to platform error handling logic On platforms with Intel 7500 chipset, there were some reports of system hang/NMI's during kexec/kdump in the presence of interrupt-remapping enabled. During kdump, there is a window where the devices might be still using old kernel's interrupt information, while the kdump kernel is coming up. This can cause vt-d faults as the interrupt configuration from the old kernel map to null IRTE entries in the new kernel etc. (with out interrupt-remapping enabled, we still have the same issue but in this case we will see benign spurious interrupt hit the new kernel). Based on platform config settings, these platforms seem to generate NMI/SMI when a vt-d fault happens and there were reports that the resulting SMI causes the system to hang. Fix it by masking vt-d spec defined errors to platform error reporting logic. VT-d spec related errors are already handled by the VT-d OS code, so need to report the same error through other channels. Signed-off-by: Suresh Siddha LKML-Reference: <1291667190.2675.8.camel@sbsiddha-MOBL3.sc.intel.com> Cc: stable@kernel.org [v2.6.32+] Reported-by: Max Asbock Reported-and-tested-by: Takao Indoh Acked-by: Chris Wright Acked-by: Kenji Kaneshige Signed-off-by: H. Peter Anvin commit 10340ae130fb70352eae1ae8a00b7906d91bf166 Author: Suresh Siddha Date: Tue Nov 16 13:23:51 2010 -0800 x86, xsave: Use alloc_bootmem_align() instead of alloc_bootmem() Alignment of alloc_bootmem() depends on the value of L1_CACHE_SHIFT. What we need here, however, is 64 byte alignment. Use alloc_bootmem_align() and explicitly specify the alignment instead. This fixes a kernel boot crash reported by Jody when the cpu in .config is set to MPENTIUMII but the kernel is booted on a xsave-capable CPU. Reported-by: Jody Bruchon Signed-off-by: Suresh Siddha LKML-Reference: <20101116212442.059967454@sbsiddha-MOBL3.sc.intel.com> Signed-off-by: H. Peter Anvin Cc: commit 53dde5f385bc56e312f78b7cb25ffaf8efd4735d Author: Suresh Siddha Date: Tue Nov 16 13:23:50 2010 -0800 bootmem: Add alloc_bootmem_align() Add an alloc_bootmem_align() interface to allocate bootmem with specified alignment. This is necessary to be able to allocate the xsave area in a subsequent patch. Signed-off-by: Suresh Siddha LKML-Reference: <20101116212441.977574826@sbsiddha-MOBL3.sc.intel.com> Acked-by: H. Peter Anvin Signed-off-by: H. Peter Anvin Cc: commit de2a8cf98ecdde25231d6c5e7901e2cffaf32af9 Author: H. Peter Anvin Date: Mon Dec 13 16:01:38 2010 -0800 x86, gcc-4.6: Use gcc -m options when building vdso The vdso Makefile passes linker-style -m options not to the linker but to gcc. This happens to work with earlier gcc, but fails with gcc 4.6. Pass gcc-style -m options, instead. Note: all currently supported versions of gcc supports -m32, so there is no reason to conditionalize it any more. Reported-by: H. J. Lu Signed-off-by: H. Peter Anvin LKML-Reference: Cc: commit 862af8adbe6b9ccb7c00c13717b1f92465f79aa2 Author: Jarkko Nikula Date: Fri Dec 10 20:53:55 2010 +0200 ASoC: Fix bias power down of non-DAPM codec Currently bias of non-DAPM codec will be powered down (standby/off) whenever there is a stream stop. This is wrong in simultaneous playback/capture since the bias is put down immediately after stopping the first stream. Fix this by using the codec->active count when figuring out the needed bias level after stream stop. Signed-off-by: Jarkko Nikula Acked-by: Liam Girdwood Signed-off-by: Mark Brown commit f1c18071ad70e2a78ab31fc26a18fcfa954a05c6 Author: Thomas Gleixner Date: Mon Dec 13 12:43:23 2010 +0100 x86: HPET: Chose a paranoid safe value for the ETIME check commit 995bd3bb5 (x86: Hpet: Avoid the comparator readback penalty) chose 8 HPET cycles as a safe value for the ETIME check, as we had the confirmation that the posted write to the comparator register is delayed by two HPET clock cycles on Intel chipsets which showed readback problems. After that patch hit mainline we got reports from machines with newer AMD chipsets which seem to have an even longer delay. See http://thread.gmane.org/gmane.linux.kernel/1054283 and http://thread.gmane.org/gmane.linux.kernel/1069458 for further information. Boris tried to come up with an ACPI based selection of the minimum HPET cycles, but this failed on a couple of test machines. And of course we did not get any useful information from the hardware folks. For now our only option is to chose a paranoid high and safe value for the minimum HPET cycles used by the ETIME check. Adjust the minimum ns value for the HPET clockevent accordingly. Reported-Bistected-and-Tested-by: Markus Trippelsdorf Signed-off-by: Thomas Gleixner LKML-Reference: Cc: Simon Kirby Cc: Borislav Petkov Cc: Andreas Herrmann Cc: John Stultz commit 57a7872fa0f03e90be0fa224b9ea533f5b03ee4f Author: Kevin Granade Date: Fri Dec 10 23:04:02 2010 -0800 Input: wacom - add another Bamboo Pen ID (0xd4) Add the features struct and device table entry to enable yet another version of Wacom Bamboo Pen (CTL460, Product ID 0xD4). Signed-off-by: Kevin Granade Acked-by: Ping Cheng Signed-off-by: Dmitry Torokhov commit 5363cdc3c5da9bd431552cf5989ab481596f0c6d Author: Florian Faber Date: Wed Dec 1 10:11:08 2010 +0100 USB: ftdi_sio: Add D.O.Tec PID Add FTDI PID to identify D.O.Tec devices correctly. Signed-off-by: Florian Faber Cc: stable Signed-off-by: Greg Kroah-Hartman commit f8bbeabc34aa945ab4275abc9a4dfde0aea798ca Author: Sarah Sharp Date: Thu Dec 9 10:29:00 2010 -0800 xhci: Fix issue with port array setup and buggy hosts. Fix two bugs with the port array setup. The first bug will only show up with broken xHCI hosts with Extended Capabilities registers that have duplicate port speed entries for the same port. The idea with the original code was to set the port_array entry to -1 if the duplicate port speed entry said the port was a different speed than the original port speed entry. That would mean that later, the port would not be exposed to the USB core. Unfortunately, I forgot a continue statement, and the port_array entry would just be overwritten in the next line. The second bug would happen if there are conflicting port speed registers (so that some entry in port_array is -1), or one of the hardware port registers was not described in the port speed registers (so that some entry in port_array is 0). The code that sets up the usb2_ports array would accidentally claim those ports. That wouldn't really cause any user-visible issues, but it is a bug. This patch should go into the stable trees that have the port array and USB 3.0 port disabling prevention patches. Signed-off-by: Sarah Sharp Cc: stable@kernel.org commit 4720dd1b3858f0da2593188cb1e57eb0d3bc4af2 Author: Thomas Gleixner Date: Thu Dec 9 17:43:21 2010 +0100 x86: io_apic: Avoid unused variable warning when CONFIG_GENERIC_PENDING_IRQ=n arch/x86/kernel/apic/io_apic.c: In function 'ack_apic_level': arch/x86/kernel/apic/io_apic.c:2433: warning: unused variable 'desc' Signed-off-by: Andrew Morton LKML-Reference: <201010272107.o9RL7rse018212@imap1.linux-foundation.org> Signed-off-by: Thomas Gleixner commit a0968628097380be52db8b4664da98fc425546a5 Author: Seungwhan Youn Date: Thu Dec 9 18:07:52 2010 +0900 ASoC: WM8580: Fix R8 initial value Acc to WM8580 manual, the default value for R8 is 0x10, not 0x1c. Signed-off-by: Seungwhan Youn Acked-by: Liam Girdwood Signed-off-by: Mark Brown Cc: stable@kernel.org commit 3f343f8512c7882a3637d9aea4ec6b3801cbcdc5 Author: Dmitry Artamonow Date: Wed Dec 8 23:36:17 2010 +0300 ASoC: fix deemphasis control in wm8904/55/60 codecs Deemphasis control's .get callback should update control's value instead of returning it - return value of callback function is used for indicating error or success of operation. Signed-off-by: Dmitry Artamonow Acked-by: Liam Girdwood Signed-off-by: Mark Brown Cc: stable@kernel.org commit dbd87b5af055a0cc9bba17795c9a2b0d17795389 Author: Heiko Carstens Date: Wed Dec 1 10:11:09 2010 +0100 nohz: Fix get_next_timer_interrupt() vs cpu hotplug This fixes a bug as seen on 2.6.32 based kernels where timers got enqueued on offline cpus. If a cpu goes offline it might still have pending timers. These will be migrated during CPU_DEAD handling after the cpu is offline. However while the cpu is going offline it will schedule the idle task which will then call tick_nohz_stop_sched_tick(). That function in turn will call get_next_timer_intterupt() to figure out if the tick of the cpu can be stopped or not. If it turns out that the next tick is just one jiffy off (delta_jiffies == 1) tick_nohz_stop_sched_tick() incorrectly assumes that the tick should not stop and takes an early exit and thus it won't update the load balancer cpu. Just afterwards the cpu will be killed and the load balancer cpu could be the offline cpu. On 2.6.32 based kernel get_nohz_load_balancer() gets called to decide on which cpu a timer should be enqueued (see __mod_timer()). Which leads to the possibility that timers get enqueued on an offline cpu. These will never expire and can cause a system hang. This has been observed 2.6.32 kernels. On current kernels __mod_timer() uses get_nohz_timer_target() which doesn't have that problem. However there might be other problems because of the too early exit tick_nohz_stop_sched_tick() in case a cpu goes offline. The easiest and probably safest fix seems to be to let get_next_timer_interrupt() just lie and let it say there isn't any pending timer if the current cpu is offline. I also thought of moving migrate_[hr]timers() from CPU_DEAD to CPU_DYING, but seeing that there already have been fixes at least in the hrtimer code in this area I'm afraid that this could add new subtle bugs. Signed-off-by: Heiko Carstens Signed-off-by: Peter Zijlstra LKML-Reference: <20101201091109.GA8984@osiris.boeblingen.de.ibm.com> Cc: stable@kernel.org Signed-off-by: Ingo Molnar commit f26f9aff6aaf67e9a430d16c266f91b13a5bff64 Author: Mike Galbraith Date: Wed Dec 8 11:05:42 2010 +0100 Sched: fix skip_clock_update optimization idle_balance() drops/retakes rq->lock, leaving the previous task vulnerable to set_tsk_need_resched(). Clear it after we return from balancing instead, and in setup_thread_stack() as well, so no successfully descheduled or never scheduled task has it set. Need resched confused the skip_clock_update logic, which assumes that the next call to update_rq_clock() will come nearly immediately after being set. Make the optimization robust against the waking a sleeper before it sucessfully deschedules case by checking that the current task has not been dequeued before setting the flag, since it is that useless clock update we're trying to save, and clear unconditionally in schedule() proper instead of conditionally in put_prev_task(). Signed-off-by: Mike Galbraith Reported-by: Bjoern B. Brandenburg Tested-by: Yong Zhang Signed-off-by: Peter Zijlstra Cc: stable@kernel.org LKML-Reference: <1291802742.1417.9.camel@marge.simson.net> Signed-off-by: Ingo Molnar commit 0f004f5a696a9434b7214d0d3cbd0525ee77d428 Author: Peter Zijlstra Date: Tue Nov 30 19:48:45 2010 +0100 sched: Cure more NO_HZ load average woes There's a long-running regression that proved difficult to fix and which is hitting certain people and is rather annoying in its effects. Damien reported that after 74f5187ac8 (sched: Cure load average vs NO_HZ woes) his load average is unnaturally high, he also noted that even with that patch reverted the load avgerage numbers are not correct. The problem is that the previous patch only solved half the NO_HZ problem, it addressed the part of going into NO_HZ mode, not of comming out of NO_HZ mode. This patch implements that missing half. When comming out of NO_HZ mode there are two important things to take care of: - Folding the pending idle delta into the global active count. - Correctly aging the averages for the idle-duration. So with this patch the NO_HZ interaction should be complete and behaviour between CONFIG_NO_HZ=[yn] should be equivalent. Furthermore, this patch slightly changes the load average computation by adding a rounding term to the fixed point multiplication. Reported-by: Damien Wyart Reported-by: Tim McGrath Tested-by: Damien Wyart Tested-by: Orion Poplawski Tested-by: Kyle McMartin Signed-off-by: Peter Zijlstra Cc: stable@kernel.org Cc: Chase Douglas LKML-Reference: <1291129145.32004.874.camel@laptop> Signed-off-by: Ingo Molnar commit 5167695753c63444a9e6cbbef136200a16c7a225 Author: Peter Zijlstra Date: Tue Dec 7 14:18:20 2010 +0100 perf: Fix duplicate events with multiple-pmu vs software events Because the multi-pmu bits can share contexts between struct pmu instances we could get duplicate events by iterating the pmu list. Signed-off-by: Peter Zijlstra Signed-off-by: Thomas Gleixner LKML-Reference: Signed-off-by: Ingo Molnar commit 73c1160ce377d8fc6d84cb630ebf9658808bec49 Author: Andre Przywara Date: Wed Dec 1 12:17:44 2010 +0100 KVM: enlarge number of possible CPUID leaves Currently the number of CPUID leaves KVM handles is limited to 40. My desktop machine (AthlonII) already has 35 and future CPUs will expand this well beyond the limit. Extend the limit to 80 to make room for future processors. KVM-Stable-Tag. Signed-off-by: Andre Przywara Signed-off-by: Avi Kivity commit 24d1b15f72abe3465e871d11cfc9dc34d1aab8b2 Author: Joerg Roedel Date: Tue Dec 7 17:15:05 2010 +0100 KVM: SVM: Do not report xsave in supported cpuid To support xsave properly for the guest the SVM module need software support for it. As long as this is not present do not report the xsave as supported feature in cpuid. As a side-effect this patch moves the bit() helper function into the x86.h file so that it can be used in svm.c too. KVM-Stable-Tag. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit 3ea3aa8cf67d3bbe00a19b6a4013d19efa7d0f41 Author: Sheng Yang Date: Wed Dec 8 10:49:43 2010 +0800 KVM: Fix OSXSAVE after migration CPUID's OSXSAVE is a mirror of CR4.OSXSAVE bit. We need to update the CPUID after migration. KVM-Stable-Tag. Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit fdbf3ceeb659f0b3c0e8dd79b331b7ac05910f1e Author: Lino Sanfilippo Date: Wed Nov 24 18:26:04 2010 +0100 fanotify: Dont try to open a file descriptor for the overflow event We should not try to open a file descriptor for the overflow event since this will always fail. Signed-off-by: Lino Sanfilippo Signed-off-by: Eric Paris commit e9a3854fd4ff3907e6c200a3980e19365ee695e9 Author: Lino Sanfilippo Date: Wed Nov 24 18:22:09 2010 +0100 fanotify: Introduce FAN_NOFD FAN_NOFD is used in fanotify events that do not provide an open file descriptor (like the overflow_event). Signed-off-by: Lino Sanfilippo Signed-off-by: Eric Paris commit 26379198937fcc9bbe7be76be695d06df8334eaa Author: Eric Paris Date: Tue Nov 23 23:48:26 2010 -0500 fanotify: do not leak user reference on allocation failure If fanotify_init is unable to allocate a new fsnotify group it will return but will not drop its reference on the associated user struct. Drop that reference on error. Reported-by: Vegard Nossum Signed-off-by: Eric Paris commit a2ae4cc9a16e211c8a128ba10d22a85431f093ab Author: Eric Paris Date: Tue Nov 23 18:18:37 2010 -0500 inotify: stop kernel memory leak on file creation failure If inotify_init is unable to allocate a new file for the new inotify group we leak the new group. This patch drops the reference on the group on file allocation failure. Reported-by: Vegard Nossum cc: stable@kernel.org Signed-off-by: Eric Paris commit 09e5f14e57c70f9d357862bb56e57026c51092a1 Author: Lino Sanfilippo Date: Fri Nov 19 10:58:07 2010 +0100 fanotify: on group destroy allow all waiters to bypass permission check When fanotify_release() is called, there may still be processes waiting for access permission. Currently only processes for which an event has already been queued into the groups access list will be woken up. Processes for which no event has been queued will continue to sleep and thus cause a deadlock when fsnotify_put_group() is called. Furthermore there is a race allowing further processes to be waiting on the access wait queue after wake_up (if they arrive before clear_marks_by_group() is called). This patch corrects this by setting a flag to inform processes that the group is about to be destroyed and thus not to wait for access permission. [additional changelog from eparis] Lets think about the 4 relevant code paths from the PoV of the 'operator' 'listener' 'responder' and 'closer'. Where operator is the process doing an action (like open/read) which could require permission. Listener is the task (or in this case thread) slated with reading from the fanotify file descriptor. The 'responder' is the thread responsible for responding to access requests. 'Closer' is the thread attempting to close the fanotify file descriptor. The 'operator' is going to end up in: fanotify_handle_event() get_response_from_access() (THIS BLOCKS WAITING ON USERSPACE) The 'listener' interesting code path fanotify_read() copy_event_to_user() prepare_for_access_response() (THIS CREATES AN fanotify_response_event) The 'responder' code path: fanotify_write() process_access_response() (REMOVE A fanotify_response_event, SET RESPONSE, WAKE UP 'operator') The 'closer': fanotify_release() (SUPPOSED TO CLEAN UP THE REST OF THIS MESS) What we have today is that in the closer we remove all of the fanotify_response_events and set a bit so no more response events are ever created in prepare_for_access_response(). The bug is that we never wake all of the operators up and tell them to move along. You fix that in fanotify_get_response_from_access(). You also fix other operators which haven't gotten there yet. So I agree that's a good fix. [/additional changelog from eparis] [remove additional changes to minimize patch size] [move initialization so it was inside CONFIG_FANOTIFY_PERMISSION] Signed-off-by: Lino Sanfilippo Signed-off-by: Eric Paris commit 1734dee4e3a296cb72b4819fc2e7ef2440737dff Author: Lino Sanfilippo Date: Mon Nov 22 18:46:33 2010 +0100 fanotify: Dont allow a mask of 0 if setting or removing a mark In mark_remove_from_mask() we destroy marks that have their event mask cleared. Thus we should not allow the creation of those marks in the first place. With this patch we check if the mask given from user is 0 in case of FAN_MARK_ADD. If so we return an error. Same for FAN_MARK_REMOVE since this does not have any effect. Signed-off-by: Lino Sanfilippo Signed-off-by: Eric Paris commit fa218ab98c31eeacd12b89501e6b99d146ea56cc Author: Lino Sanfilippo Date: Tue Nov 9 18:18:16 2010 +0100 fanotify: correct broken ref counting in case adding a mark failed If adding a mount or inode mark failed fanotify_free_mark() is called explicitly. But at this time the mark has already been put into the destroy list of the fsnotify_mark kernel thread. If the thread is too slow it will try to decrease the reference of a mark, that has already been freed by fanotify_free_mark(). (If its fast enough it will only decrease the marks ref counter from 2 to 1 - note that the counter has been increased to 2 in add_mark() - which has practically no effect.) This patch fixes the ref counting by not calling free_mark() explicitly, but decreasing the ref counter and rely on the fsnotify_mark thread to cleanup in case adding the mark has failed. Signed-off-by: Lino Sanfilippo Signed-off-by: Eric Paris commit b1085ba80cd2784400a7beec3fda5099198ed01c Author: Lino Sanfilippo Date: Fri Nov 5 17:05:27 2010 +0100 fanotify: if set by user unset FMODE_NONOTIFY before fsnotify_perm() is called Unsetting FMODE_NONOTIFY in fsnotify_open() is too late, since fsnotify_perm() is called before. If FMODE_NONOTIFY is set fsnotify_perm() will skip permission checks, so a user can still disable permission checks by setting this flag in an open() call. This patch corrects this by unsetting the flag before fsnotify_perm is called. Signed-off-by: Lino Sanfilippo Signed-off-by: Eric Paris commit 88d60c32765716289abeb362c44adf6c35c6824c Author: Eric Paris Date: Mon Nov 8 18:19:22 2010 -0500 fanotify: remove packed from access response message Since fanotify has decided to be careful about alignment and packing rather than rely on __attribute__((packed)) for multiarch support. Since this attribute isn't doing anything on fanotify_response we just drop it. This does not break API/ABI. Suggested-by: Tvrtko Ursulin Signed-off-by: Eric Paris commit ecf6f5e7d68471b08603f7c20143ac236602364f Author: Eric Paris Date: Mon Nov 8 18:08:14 2010 -0500 fanotify: deny permissions when no event was sent If no event was sent to userspace we cannot expect userspace to respond to permissions requests. Today such requests just hang forever. This patch will deny any permissions event which was unable to be sent to userspace. Reported-by: Tvrtko Ursulin Signed-off-by: Eric Paris commit e63233f75a1a6bfa97ffb52a20cc6801a4c63fb2 Author: John Reiser Date: Mon Nov 22 19:41:44 2010 -0800 ftrace: Have recordmcount honor endianness in fn_ELF_R_INFO It looks to me like the change which introduced "virtual functions" forgot about cross-platform endianness. Thank you to Arnaud for supplying before+after data files do_mounts*.o. This fixes a MIPS build failure triggered by recordmcount. Reported-by: Arnaud Lacombe Tested-by: Arnaud Lacombe Acked-by: Wu Zhangjin Acked-by: Ralf Baechle Signed-off-by: John Reiser Signed-off-by: Steven Rostedt commit 15664125f7cadcb6d725cb2d9b90f9715397848d Author: Peter Zijlstra Date: Wed Nov 24 10:43:55 2010 +0100 scripts/tags.sh: Add magic for trace-events Make tags find the trace-event definitions Acked-by: WANG Cong Signed-off-by: Peter Zijlstra LKML-Reference: <1290591835.2072.438.camel@laptop> Signed-off-by: Steven Rostedt commit a757ee2216211278680dd8ac869aabe7b4a9970d Author: Mauro Carvalho Chehab Date: Thu Dec 2 01:57:03 2010 -0200 [media] Don't export format_by_forcc on two different drivers Drivers should append their name on exported symbols, to avoid conflicts with allyesconfig: drivers/staging/built-in.o: In function `format_by_fourcc': /home/v4l/work_trees/linus/drivers/staging/cx25821/cx25821-video.c:96: multiple definition of `format_by_fourcc' drivers/media/built-in.o:/home/v4l/work_trees/linus/drivers/media/common/saa7146_video.c:88: first defined here Let's rename both occurences with a small shellscript: for i in drivers/staging/cx25821/*.[ch]; do sed s,format_by_fourcc,cx25821_format_by_fourcc,g <$i >a && mv a $i; done for i in drivers/media/common/saa7146*.[ch]; do sed s,format_by_fourcc,saa7146_format_by_fourcc,g <$i >a && mv a $i; done for i in include/media/saa7146*.[ch]; do sed s,format_by_fourcc,saa7146_format_by_fourcc,g <$i >a && mv a $i; done Signed-off-by: Mauro Carvalho Chehab commit 673eb9ff33e26ee6f4278cdab06749aef1bbef5b Author: Laurent Pinchart Date: Sun Nov 21 16:54:56 2010 -0300 [media] uvcvideo: Convert to unlocked_ioctl The uvcvideo driver now locks all ioctls correctly on its own, the BKL isn't needed anymore. Signed-off-by: Laurent Pinchart Signed-off-by: Mauro Carvalho Chehab commit 6947756dfcecc493062a46e77f6bf51dddb5be75 Author: Laurent Pinchart Date: Sun Nov 21 13:36:34 2010 -0300 [media] uvcvideo: Lock stream mutex when accessing format-related information The stream mutex protects access to the struct uvc_streaming ctrl, cur_format and cur_frame fields as well as to the hardware probe control. Lock it appropriately. Signed-off-by: Laurent Pinchart Signed-off-by: Mauro Carvalho Chehab commit 4aa275975beee41fd542a0f6df8cd0fee06089bf Author: Laurent Pinchart Date: Sun Nov 21 15:18:08 2010 -0300 [media] uvcvideo: Move mmap() handler to uvc_queue.c The mmap() implementation belongs to the video buffers queue, move it there. Signed-off-by: Laurent Pinchart Signed-off-by: Mauro Carvalho Chehab commit 8e815e1763b8d4e5adf0dc14bde8c55329cf95a8 Author: Laurent Pinchart Date: Sun Nov 21 14:46:44 2010 -0300 [media] uvcvideo: Move mutex lock/unlock inside uvc_free_buffers Callers outside uvc_queue.c should not be forced to lock/unlock the queue mutex manually. Move the mutex operations inside uvc_free_buffers(). Signed-off-by: Laurent Pinchart Signed-off-by: Mauro Carvalho Chehab commit 23d9f3ef23f0dc4bb20ccd5540b9a91ff08da08f Author: Laurent Pinchart Date: Sun Nov 21 07:58:54 2010 -0300 [media] uvcvideo: Lock controls mutex when querying menus uvc_find_control() must be called with the controls mutex locked. Fix uvc_query_v4l2_menu() accordingly. Signed-off-by: Laurent Pinchart Signed-off-by: Mauro Carvalho Chehab commit ca9afe6f87b569cdf8e797395381f18ae23a2905 Author: Hans Verkuil Date: Fri Nov 26 06:54:53 2010 -0300 [media] v4l2-dev: fix race condition The unregister function had a race condition with the v4l2_open function. Ensure that both functions test and clear the REGISTER flag from within a critical section. Thanks to Laurent Pinchart for finding this race. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 879aa24d6394aa04b690a600a41ff500441ad384 Author: Hans Verkuil Date: Fri Nov 26 06:47:28 2010 -0300 [media] V4L: improve the BKL replacement heuristic The BKL replacement mutex had some serious performance side-effects on V4L drivers. It is replaced by a better heuristic that works around the worst of the side-effects. Read the v4l2-dev.c comments for the whole sorry story. This is a temporary measure only until we can convert all v4l drivers to use unlocked_ioctl. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 2877842de8cbf6272b0a851cb12587b7dd8c2afb Author: Hans Verkuil Date: Fri Nov 26 06:43:51 2010 -0300 [media] v4l2-dev: use mutex_lock_interruptible instead of plain mutex_lock Where reasonable use mutex_lock_interruptible instead of mutex_lock. Also fix the poll, read and write error codes when called with an unregistered device (e.g. after a USB device was disconnected). Poll must return POLLERR|POLLHUP and read/write must return -ENODEV. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 78b055be2710b63cb196fc37669f3b662fecc9e4 Author: Hans Verkuil Date: Fri Nov 19 17:04:31 2010 -0300 [media] cx18: convert to unlocked_ioctl Also added locking around snd_cx18_pcm_ioctl as a precaution as requested by Andy Walls. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 4f68775b7dfc6115169f689a42535486bf10977e Author: Hans Verkuil Date: Tue Nov 16 18:13:06 2010 -0300 [media] radio-timb: convert to unlocked_ioctl Signed-off-by: Hans Verkuil Acked-by: Richard Röjfors Signed-off-by: Mauro Carvalho Chehab commit 697566939dc60048fca6e6dd69c7e089aaeb7ff8 Author: Hans Verkuil Date: Tue Nov 16 18:12:16 2010 -0300 [media] sh_vou: convert to unlocked_ioctl Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 20aa5bb9dc4b5aba1b4d0f15aa92c4e83721a343 Author: Hans Verkuil Date: Sun Nov 14 13:09:21 2010 -0300 [media] cafe_ccic: replace ioctl by unlocked_ioctl Trivial change, approved by Jonathan Corbet . Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit ca2621963de3934613f8aa63e19c03b1751707ae Author: Hans Verkuil Date: Sun Nov 14 11:17:00 2010 -0300 [media] et61x251_core: trivial conversion to unlocked_ioctl Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit feecf93d6b16887bf7e12fcc604bfba9048b2fa5 Author: Hans Verkuil Date: Sun Nov 14 11:13:39 2010 -0300 [media] sn9c102: convert to unlocked_ioctl Trivial conversion, this driver used a mutex already. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 61df3c9b3fe6a7e47d25b27ae4df0ecdb07b8fbd Author: Hans Verkuil Date: Sun Nov 14 10:09:38 2010 -0300 [media] BKL: trivial ioctl -> unlocked_ioctl video driver conversions These drivers could be trivially converted to unlocked_ioctl since they already did locking. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit d2c998f7453af7ad416bc38d09ae9d453d2fac5e Author: Hans Verkuil Date: Sun Nov 14 09:49:34 2010 -0300 [media] typhoon: convert to unlocked_ioctl Convert the typhoon driver from ioctl to unlocked_ioctl. When doing this I noticed a bug where curfreq was not initialized correctly to mutefreq (it wasn't multiplied by 16). The initialization is now also done before the device node is created. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 725ea8cf1c1f5ba53177d20d2d2f6dbc139b643e Author: Hans Verkuil Date: Sun Nov 14 09:48:24 2010 -0300 [media] si4713: convert to unlocked_ioctl Convert ioctl to unlocked_ioctl. Note that for this driver the locking is done inside the sub-device. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit ee71e42321cced11fecb989d743ad9cdb0c384ea Author: Hans Verkuil Date: Sun Nov 14 09:46:23 2010 -0300 [media] tea5764: convert to unlocked_ioctl Convert from ioctl to unlocked_ioctl using the v4l2 core lock. Also removed the 'exclusive access' limitation. There was no need for it and it violates the v4l2 spec as well. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 1cccee0b84e3445a142d0e9edcbf66b677b2e7e5 Author: Hans Verkuil Date: Sun Nov 14 09:43:52 2010 -0300 [media] cadet: use unlocked_ioctl Converted from ioctl to unlocked_ioctl. This driver already used an internal lock, but it was missing in cadet_open and cadet_release and it was not used correctly in cadet_read. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 32958fdd1663aeaa23b5edbfbb0db684ffd4e20e Author: Hans Verkuil Date: Sun Nov 14 09:36:23 2010 -0300 [media] BKL: trivial BKL removal from V4L2 radio drivers The patch converts a bunch of V4L2 radio drivers to unlocked_ioctl. These are all simple conversions: most already had a lock and so the ioctl fop could simply be replaced by unlocked_ioctl. radio-miropcm20.c was converted to use the new V4L2 core lock. While doing this work I noticed that many of these drivers initialized some more fields or muted audio or something like that *after* creating the device node. This should be done before the device node is created to prevent problems. Especially hal tends to grab a device node as soon as it is created. In one or two cases the mutex_init was even done after the device creation! Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 04a6b516cdc6efc2500b52a540cf65be8c5aaf9e Author: Vivek Goyal Date: Wed Dec 1 19:34:52 2010 +0100 blk-throttle: Correct the placement of smp_rmb() o I was discussing what are the variable being updated without spin lock and why do we need barriers and Oleg pointed out that location of smp_rmb() should be between read of td->limits_changed and tg->limits_changed. This patch fixes it. o Following is one possible sequence of events. Say cpu0 is executing throtl_update_blkio_group_read_bps() and cpu1 is executing throtl_process_limit_change(). cpu0 cpu1 tg->limits_changed = true; smp_mb__before_atomic_inc(); atomic_inc(&td->limits_changed); if (!atomic_read(&td->limits_changed)) return; if (tg->limits_changed) do_something; If cpu0 has updated tg->limits_changed and td->limits_changed, we want to make sure that if update to td->limits_changed is visible on cpu1, then update to tg->limits_changed should also be visible. Oleg pointed out to ensure that we need to insert an smp_rmb() between td->limits_changed read and tg->limits_changed read. o I had erroneously put smp_rmb() before atomic_read(&td->limits_changed). This patch fixes it. Reported-by: Oleg Nesterov Signed-off-by: Vivek Goyal Signed-off-by: Jens Axboe commit d1ae8ffdfaa16b2ab2e9346e81cf0ab6eaaae347 Author: Vivek Goyal Date: Wed Dec 1 19:34:46 2010 +0100 blk-throttle: Trim/adjust slice_end once a bio has been dispatched o During some testing I did following and noticed throttling stops working. - Put a very low limit on a cgroup, say 1 byte per second. - Start some reads, this will set slice_end to a very high value. - Change the limit to higher value say 1MB/s - Now IO unthrottles and finishes as expected. - Try to do the read again but IO is not limited to 1MB/s as expected. o What is happening. - Initially low value of limit sets slice_end to a very high value. - During updation of limit, slice_end is not being truncated. - Very high value of slice_end leads to keeping the existing slice valid for a very long time and new slice does not start. - tg_may_dispatch() is called in blk_throtle_bio(), and trim_slice() is not called in this path. So slice_start is some old value and practically we are able to do huge amount of IO. o There are many ways it can be fixed. I have fixed it by trying to adjust/cleanup slice_end in trim_slice(). Generally we extend slices if bio is big and can't be dispatched in one slice. After dispatch of bio, readjust the slice_end to make sure we don't end up with huge values. Signed-off-by: Vivek Goyal Signed-off-by: Jens Axboe commit 364829b1263b44aa60383824e4c1289d83d78ca7 Author: Slava Pestov Date: Wed Nov 24 15:13:16 2010 -0800 tracing: Fix panic when lseek() called on "trace" opened for writing The file_ops struct for the "trace" special file defined llseek as seq_lseek(). However, if the file was opened for writing only, seq_open() was not called, and the seek would dereference a null pointer, file->private_data. This patch introduces a new wrapper for seq_lseek() which checks if the file descriptor is opened for reading first. If not, it does nothing. Cc: Signed-off-by: Slava Pestov LKML-Reference: <1290640396-24179-1-git-send-email-slavapestov@google.com> Signed-off-by: Steven Rostedt commit 5478755616ae2ef1ce144dded589b62b2a50d575 Author: Xiaotian Feng Date: Mon Nov 29 10:03:55 2010 +0100 block: check for proper length of iov entries earlier in blk_rq_map_user_iov() commit 9284bcf checks for proper length of iov entries in blk_rq_map_user_iov(). But if the map is unaligned, kernel will break out the loop without checking for the proper length. So we need to check the proper length before the unalign check. Signed-off-by: Xiaotian Feng Cc: stable@kernel.org Signed-off-by: Jens Axboe commit a115413de13ae6beb0cbfc198afe385a261ab284 Author: Lars Ellenberg Date: Sat Nov 13 20:42:29 2010 +0100 drbd: fix for spin_lock_irqsave in endio callback In commit 9b7f76dc37919ea36caa9680a3f765e5b19b25fb, Author: Lars Ellenberg Date: Wed Aug 11 23:40:24 2010 +0200 drbd: new configuration parameter c-min-rate a bad chunk slipped through, which is now reverted as well, restoring the correct irqsave for the endio callback. This patch also add comments at both req_mod() and in the endio callback so it should not happen again. Signed-off-by: Philipp Reisner Signed-off-by: Lars Ellenberg commit c13f7e1a94007c4381814e7daf033e3e8f0663f3 Author: Lars Ellenberg Date: Fri Oct 29 23:32:01 2010 +0200 drbd: don't recvmsg with zero length This should fix a performance degradation we observed recently. If we don't expect any subheader, we should not call into the tcp stack, as that may add considerable latency if there is no data available at this point. For a synthetic synchronous write load with single outstanding writes, this additional latency when processing the "unplug remote" packet added up to a performance degradation factor >= 10. Signed-off-by: Philipp Reisner Signed-off-by: Lars Ellenberg