aboutsummaryrefslogtreecommitdiffstats
AgeCommit message (Collapse)AuthorFilesLines
2013-12-10mfd: rtsx_pcr: Disable interrupts before cancelling delayed worksHEADmfd-fixes-3.13-2masterThomas Gleixner1-2/+8
This fixes a kernel panic when resuming from suspend to RAM. Without this fix an interrupt hits after the delayed work is canceled and thus requeues it. So we end up freeing an armed timer. Cc: stable@vger.kernel.org Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2013-12-09Merge branch 'drm-fixes' of git://people.freedesktop.org/~airlied/linuxLinus Torvalds53-265/+847
Pull drm fixes from Dave Airlie: "This is probably a bit big, but just because I fell behind last week and didn't get to doing any pulls, so stuff backed up behind me, I actually should have sent this for -rc3 but failed to even manage that. So this has radeon, intel, nouveau, vmware, exynos and tegra fixes in it, and the line count isn't all the bad in the end" * 'drm-fixes' of git://people.freedesktop.org/~airlied/linux: (50 commits) drm: fix the addition of the side-by-side (half) flag for extra 3D modes drm/edid: fix length check when adding extra 3D modes drm/radeon/atom: fix bus probes when hw_i2c is set (v2) drm/radeon: fix null pointer dereference in dce6+ audio code drm/radeon: fixup bad vram size on SI udl: fix issue with imported prime buffers drm/vmwgfx: Add our connectors to sysfs drm/vmwgfx: Fix dma buffer memory size accounting drm/vmwgfx: Fix up and comment the dumb buffer implementation drm/vmwgfx: Correctly set the enabled state on crtcs drm/nv50/disp: min/max are reversed in nv50_crtc_gamma_set() drm/nouveau/sw: fix oops if gpu has its display block disabled drm/nouveau: unreference fence after syncing drm/nouveau/kms: send timestamp data for correct head in flip completion events drm/nouveau/clk: Add support for NVAA/NVAC drm/nouveau/fifo: Hook up pause and resume for NV50 and NV84+ drm/nv10/plane: some chipsets don't support NV12 drm/nv10/plane: add downscaling restrictions drm/nv10/plane: fix format computation drm/nv04-nv30/clk: provide an empty domain list ...
2013-12-09Merge tag 'mfd-fixes-3.13-1' of ↵Linus Torvalds3-3/+3
git://git.kernel.org/pub/scm/linux/kernel/git/sameo/mfd-fixes Pull mfd fixes from Samuel Ortiz: "This is the first 3.13 pull request for MFD fixes. We have: - A ti-ssp build failure fix - An as3722 build failure fix - An lpc_ich copy paste error fix" * tag 'mfd-fixes-3.13-1' of git://git.kernel.org/pub/scm/linux/kernel/git/sameo/mfd-fixes: mfd: lpc_ich: Fix Wildcat Point info name field mfd: ti-ssp: Fix build mfd: Make MFD_AS3722 depend on I2C=y
2013-12-09Merge tag 'pm-3.13-rc3-fixup' of ↵Linus Torvalds3-54/+3
git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm Pull power management fixup from Rafael Wysocki: "This reverts two cpufreq commits that fixed issues for some people, but broke things for others, so revert them and we'll need to fix the original problems differently" * tag 'pm-3.13-rc3-fixup' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: Revert "cpufreq: fix garbage kobjects on errors during suspend/resume" Revert "cpufreq: suspend governors on system suspend/hibernate"
2013-12-09Merge branch 'for-linus' of ↵Linus Torvalds10-14/+239
git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input Pull input updates from Dmitry Torokhov: "An update to ALPS to support devices on Dell XT2 (hopefully working better this time around and although it is largish it should not affect any other ALPS devices) and a tiny update to Elantech driver to support newer devices as well. Also a coupe of new input event codes have been defined" * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input: Input: ALPS - add support for DualPoint device on Dell XT2 model Input: elantech - add support for newer (August 2013) devices Input: add SW_MUTE_DEVICE switch definition Input: usbtouchscreen - separate report and transmit buffer size handling Input: sur40 - suppress false uninitialized variable warning Input: add key code for ambient light sensor button Input: keyboard - "keycode & KEY_MAX" changes some keycode values
2013-12-09Merge git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6Linus Torvalds1-1/+1
Pull crypto fix from Herbert Xu: "Unfortunately the last push that fixed a crash in the crypto scatterwalk code introduced a new crash when SG debugging is enabled. This fixes that" * git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6: crypto: scatterwalk - Use sg_chain_ptr on chain entries
2013-12-09crypto: scatterwalk - Use sg_chain_ptr on chain entriesTom Lendacky1-1/+1
Now that scatterwalk_sg_chain sets the chain pointer bit the sg_page call in scatterwalk_sg_next hits a BUG_ON when CONFIG_DEBUG_SG is enabled. Use sg_chain_ptr instead of sg_page on a chain entry. Cc: stable@vger.kernel.org Signed-off-by: Tom Lendacky <thomas.lendacky@amd.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
2013-12-08Merge tag 'tty-3.13-rc3' of ↵Linus Torvalds1-2/+4
git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty Pull tty fix from Greg KH: "Here is a single n_tty fix for 3.13-rc3 that resolves a regression in 3.12 that has been reported" * tag 'tty-3.13-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty: n_tty: Fix missing newline echo
2013-12-08Merge tag 'staging-3.13-rc3' of ↵Linus Torvalds7-34/+43
git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging Pull staging driver fixes from Greg KH: "Here are some bugfixes for the staging and IIO drivers for 3.13-rc3. The resolve the vm memory issue in the tidspbridge driver, fix a much-reported build failure in an ARM driver, and some other IIO bugfixes that have been reported" * tag 'staging-3.13-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging: Staging: TIDSPBRIDGE: Use vm_iomap_memory for mmap-ing instead of remap_pfn_range Fix build failure for gp2ap020a00f.c iio: hid-sensors: Fix power and report state HID: hid-sensor-hub: Add logical min and max
2013-12-08Merge tag 'char-misc-3.13-rc3' of ↵Linus Torvalds14-73/+97
git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc Pull char/misc driver fixes from Greg KH: "Nothing huge, just a few small bugfixes for problems reported, and a device id update" * tag 'char-misc-3.13-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc: mei: add 9 series PCH mei device ids drivers/char/i8k.c: add Dell XPLS L421X MAINTAINERS: add HSI subsystem misc: mic: Suppress memory space sparse warnings misc: mic: Fix endianness issues. misc: mic: Fix user space namespace pollution from mic_common.h. misc: mic: Bug fix for sysfs poll usage. misc: mic: Minor bug fix in 'retry' loops. misc: mic: Change mic_notify(...) to return true. extcon: remove freed groups caused the panic or warning in unregister flow extcon: arizona: Get pdata from arizona structure not device
2013-12-08Merge tag 'usb-3.13-rc3' of ↵Linus Torvalds36-265/+471
git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb Pull USB fixes from Greg KH: "Here are a bunch of USB fixes for 3.13-rc3. Nothing major, but we seem to have an argument about a XHCI fix, so I'm not including a revert that Sarah requested, because that breaks a USB network driver, and I can't revert the USB network driver fix without reintroducing other bugs that it fixed. So as it is, everything should now be working. Worse case, I can revert the XHCI fix before 3.13-final is out, but it seems to work well here with my testing, so all should be good. Other than that, some driver updates based on reports" * tag 'usb-3.13-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb: (40 commits) usb: hub: Use correct reset for wedged USB3 devices that are NOTATTACHED usb: ohci-pxa27x: include linux/dma-mapping.h USB: cdc-acm: Added support for the Lenovo RD02-D400 USB Modem usb: tools: fix a regression issue that gcc can't link to pthread USB: switch maintainership of chipidea to Peter USB: pl2303: fixed handling of CS5 setting USB: ftdi_sio: fixed handling of unsupported CSIZE setting USB: mos7840: correct handling of CS5 setting USB: spcp8x5: correct handling of CS5 setting usb: wusbcore: fix deadlock in wusbhc_gtk_rekey usb: wusbcore: do device lookup while holding the hc mutex usb: wusbcore: send keepalives to unauthenticated devices USB: option: support new huawei devices USB: serial: option: blacklist interface 1 for Huawei E173s-6 usb: xhci: Link TRB must not occur within a USB payload burst usb: gadget: f_mass_storage: call try_to_freeze only when its safe usb: gadget: tcm_usb_gadget: mark bot_cleanup_old_alt static usb: gadget: ffs: fix sparse warning usb: gadget: zero: module parameters can be static usb: gadget: storage: fix sparse warning ...
2013-12-08Merge tag 'arm64-stable' of ↵Linus Torvalds5-6/+6
git://git.kernel.org/pub/scm/linux/kernel/git/cmarinas/linux-aarch64 Pull ARM64 fixes from Catalin Marinas: - Page table fixes (PROT_NONE, shareability attribute, TLB invalidation) - Secondary CPUs entry endianness fix - Make NR_CPUS default to 8 * tag 'arm64-stable' of git://git.kernel.org/pub/scm/linux/kernel/git/cmarinas/linux-aarch64: arm64: mm: Fix PMD_SECT_PROT_NONE definition arm64: Fix memory shareability attribute for ioremap_wc/cache arm64: kernel: add code to set cpu boot mode to secondary_entry shim arm64: make default NR_CPUS 8 arm64: ensure completion of TLB invalidatation
2013-12-08Revert "cpufreq: fix garbage kobjects on errors during suspend/resume"Rafael J. Wysocki1-0/+3
Commit 2167e2399dc5 (cpufreq: fix garbage kobjects on errors during suspend/resume) breaks suspend/resume on Martin Ziegler's system (hard lockup during resume), so revert it. Fixes: 2167e2399dc5 (cpufreq: fix garbage kobjects on errors during suspend/resume) References: https://bugzilla.kernel.org/show_bug.cgi?id=66751 Reported-by: Martin Ziegler <ziegler@uni-freiburg.de> Cc: 3.12+ <stable@vger.kernel.org> # 3.12+ Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
2013-12-08Revert "cpufreq: suspend governors on system suspend/hibernate"Rafael J. Wysocki3-54/+0
Commit 5a87182aa21d (cpufreq: suspend governors on system suspend/hibernate) causes hibernation problems to happen on Bjørn Mork's and Paul Bolle's systems, so revert it. Fixes: 5a87182aa21d (cpufreq: suspend governors on system suspend/hibernate) Reported-by: Bjørn Mork <bjorn@mork.no> Reported-by: Paul Bolle <pebolle@tiscali.nl> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
2013-12-06Linux 3.13-rc3Linus Torvalds1-1/+1
2013-12-06arm64: mm: Fix PMD_SECT_PROT_NONE definitionSteve Capper1-1/+1
Modify the value of PMD_SECT_PROT_NONE to match that of PTE_NONE. This should have been in commit 3676f9ef5481 (Move PTE_PROT_NONE higher up). Signed-off-by: Steve Capper <steve.capper@linaro.org> Cc: <stable@vger.kernel.org> # 3.11+: 3676f9ef5481: arm64: Move PTE_PROT_NONE higher up Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2013-12-06arm64: Fix memory shareability attribute for ioremap_wc/cacheCatalin Marinas1-1/+1
Write-combine and cacheable mappings use Normal memory on arm64. On SMP systems, the pte needs the shareability bit which is set in pgprot_default. Use this for defining PROT_DEFAULT used by ioremap_wc and ioremap_cache (Device memory is shareable by default, does not need additional attributes). Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2013-12-06arm64: kernel: add code to set cpu boot mode to secondary_entry shimLorenzo Pieralisi1-1/+2
The refactoring of el2_setup split code setting up EL2 and detecting the CPU boot mode in separate chunks. This allows the code that sets up EL2 to run in an endian independent way - ie before the endianess is set up in the respective sctlr registers. This patch brings secondary_entry up-to-date so that CPUs entering the kernel through this code path set-up EL2 and the cpu boot mode properly. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com> Acked-by: Mark Rutland <mark.rutand@arm.com> Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2013-12-06arm64: make default NR_CPUS 8Rob Herring1-2/+1
Rather than continue to add per platform defaults, make the default a likely common core count. 8 is also the default for x86. Signed-off-by: Rob Herring <rob.herring@calxeda.com> Cc: Will Deacon <will.deacon@arm.com> Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2013-12-06arm64: ensure completion of TLB invalidatationMark Rutland1-1/+1
Currently there is no dsb between the tlbi in __cpu_setup and the write to SCTLR_EL1 which enables the MMU in __turn_mmu_on. This means that the TLB invalidation is not guaranteed to have completed at the point address translation is enabled, leading to a number of possible issues including incorrect translations and TLB conflict faults. This patch moves the tlbi in __cpu_setup above an existing dsb used to synchronise I-cache invalidation, ensuring that the TLBs have been invalidated at the point the MMU is enabled. Signed-off-by: Mark Rutland <mark.rutland@arm.com> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Will Deacon <will.deacon@arm.com> Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2013-12-06Merge tag 'trace-fixes-3.13-rc2' of ↵Linus Torvalds2-10/+3
git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace Pull tracing fix from Steven Rostedt: "A regression showed up that there's a large delay when enabling all events. This was prevalent when FTRACE_SELFTEST was enabled which enables all events several times, and caused the system bootup to pause for over a minute. This was tracked down to an addition of a synchronize_sched() performed when system call tracepoints are unregistered. The synchronize_sched() is needed between the unregistering of the system call tracepoint and a deletion of a tracing instance buffer. But placing the synchronize_sched() in the unreg of *every* system call tracepoint is a bit overboard. A single synchronize_sched() before the deletion of the instance is sufficient" * tag 'trace-fixes-3.13-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace: tracing: Only run synchronize_sched() at instance deletion time
2013-12-06Merge git://git.kvack.org/~bcrl/aio-nextLinus Torvalds1-2/+6
Pull aio fix from Benjamin LaHaise: "AIO fix from Gu Zheng that fixes a GPF that Dave Jones uncovered with trinity" * git://git.kvack.org/~bcrl/aio-next: aio: clean up aio ring in the fail path
2013-12-06Merge tag 'scsi-fixes' of ↵Linus Torvalds31-57/+129
git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi Pull SCSI fixes from James Bottomley: "This is a set of nine fixes (and one author update). The libsas one should fix discovery in eSATA devices, the WRITE_SAME one is the largest, but it should fix a lot of problems we've been getting with the emulated RAID devices (they've been effectively lying about support and then firmware has been choking on the commands). The rest are various crash, hang or warn driver fixes" * tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi: [SCSI] bfa: Fix crash when symb name set for offline vport [SCSI] enclosure: fix WARN_ON in dual path device removing [SCSI] pm80xx: Tasklets synchronization fix. [SCSI] pm80xx: Resetting the phy state. [SCSI] pm80xx: Fix for direct attached device. [SCSI] pm80xx: Module author addition [SCSI] hpsa: return 0 from driver probe function on success, not 1 [SCSI] hpsa: do not discard scsi status on aborted commands [SCSI] Disable WRITE SAME for RAID and virtual host adapter drivers [SCSI] libsas: fix usage of ata_tf_to_fis
2013-12-06Merge branch 'for-linus' of ↵Linus Torvalds3-6/+19
git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/linux-security Pull IMA fixes from James Morris: "Here are two more fixes for IMA" * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/linux-security: ima: properly free ima_template_entry structures ima: Do not free 'entry' before it is initialized
2013-12-06Merge tag 'dt-fixes-for-3.13' of ↵Linus Torvalds12-37/+59
git://git.kernel.org/pub/scm/linux/kernel/git/robh/linux Pull devicetree fixes from Rob Herring: - Various DT binding documentation updates - Add Kumar Gala and remove Stephen Warren as DT binding maintainers * tag 'dt-fixes-for-3.13' of git://git.kernel.org/pub/scm/linux/kernel/git/robh/linux: dt: binding: reword PowerPC 8xxx GPIO documentation ARM: tegra: delete nvidia,tegra20-spi.txt binding hwmon: ntc_thermistor: Fix typo (pullup-uV -> pullup-uv) of: add vendor prefix for GMT clk: exynos: Fix typos in DT bindings documentation of: Add vendor prefix for LG Corporation Documentation: net: fsl-fec.txt: Add phy-supply entry ARM: dts: doc: Document missing binding for omap5-mpu dt-bindings: add ARMv8 PMU binding MAINTAINERS: remove swarren from DT bindings MAINTAINERS: Add Kumar to Device Tree Binding maintainers group
2013-12-06aio: clean up aio ring in the fail pathGu Zheng1-2/+6
Clean up the aio ring file in the fail path of aio_setup_ring and ioctx_alloc. And maybe it can fix the GPF issue reported by Dave Jones: https://lkml.org/lkml/2013/11/25/898 Signed-off-by: Gu Zheng <guz.fnst@cn.fujitsu.com> Signed-off-by: Benjamin LaHaise <bcrl@kvack.org>
2013-12-07Merge branch 'free-memory' of ↵James Morris3-6/+19
git://git.kernel.org/pub/scm/linux/kernel/git/zohar/linux-integrity into for-linus
2013-12-05Merge tag 'pm-3.13-rc3' of ↵Linus Torvalds9-11/+87
git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm Pull power management fixes from Rafael Wysocki: - cpufreq regression fix from Bjørn Mork restoring the pre-3.12 behavior of the framework during system suspend/hibernation to avoid garbage sysfs files from being left behind in case of a suspend error - PNP regression fix to restore the correct states of devices after resume from hibernation broken in 3.12. From Dmitry Torokhov. - cpuidle fix to prevent cpuidle device unregistration from crashing due to a NULL pointer dereference if cpuidle has been disabled from the kernel command line. From Konrad Rzeszutek Wilk. - intel_idle fix for the C6 state definition on Intel Avoton/Rangeley processors from Arne Bockholdt. - Power capping framework fix to make the energy_uj sysfs attribute work in accordance with the documentation. From Srinivas Pandruvada. - epoll fix to make it ignore the EPOLLWAKEUP flag if the kernel has been compiled with CONFIG_PM_SLEEP unset (in which case that flag should not have any effect). From Amit Pundir. - cpufreq fix to prevent governor sysfs files from being lost over system suspend/resume in some (arguably unusual) situations. From Viresh Kumar. * tag 'pm-3.13-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: PowerCap: Fix mode for energy counter PNP: fix restoring devices after hibernation cpuidle: Check for dev before deregistering it. epoll: drop EPOLLWAKEUP if PM_SLEEP is disabled cpufreq: fix garbage kobjects on errors during suspend/resume cpufreq: suspend governors on system suspend/hibernate intel_idle: Fixed C6 state on Avoton/Rangeley processors
2013-12-06Merge branches 'pm-epoll', 'pnp' and 'powercap'Rafael J. Wysocki4-5/+30
* pm-epoll: epoll: drop EPOLLWAKEUP if PM_SLEEP is disabled * pnp: PNP: fix restoring devices after hibernation * powercap: PowerCap: Fix mode for energy counter
2013-12-06Merge branches 'pm-cpuidle' and 'pm-cpufreq'Rafael J. Wysocki5-6/+57
* pm-cpuidle: cpuidle: Check for dev before deregistering it. intel_idle: Fixed C6 state on Avoton/Rangeley processors * pm-cpufreq: cpufreq: fix garbage kobjects on errors during suspend/resume cpufreq: suspend governors on system suspend/hibernate
2013-12-05Merge branch 'stable' of ↵Linus Torvalds1-1/+2
git://git.kernel.org/pub/scm/linux/kernel/git/cmetcalf/linux-tile Pull arch/tile ftrace bug fix from Chris Metcalf: "This fixes a build failure with allyesconfig reported by Fengguang Wu and fixed by Tony Lu" * 'stable' of git://git.kernel.org/pub/scm/linux/kernel/git/cmetcalf/linux-tile: ftrace: default to tilegx if ARCH=tile is specified
2013-12-05Merge branch 'for-linus' of git://git.kernel.dk/linux-blockLinus Torvalds11-127/+44
Pull block layer fixes from Jens Axboe: "A small collection of fixes for the current series. It contains: - A fix for a use-after-free of a request in blk-mq. From Ming Lei - A fix for a blk-mq bug that could attempt to dereference a NULL rq if allocation failed - Two xen-blkfront small fixes - Cleanup of submit_bio_wait() type uses in the kernel, unifying that. From Kent - A fix for 32-bit blkg_rwstat reading. I apologize for this one looking mangled in the shortlog, it's entirely my fault for missing an empty line between the description and body of the text" * 'for-linus' of git://git.kernel.dk/linux-block: blk-mq: fix use-after-free of request blk-mq: fix dereference of rq->mq_ctx if allocation fails block: xen-blkfront: Fix possible NULL ptr dereference xen-blkfront: Silence pfn maybe-uninitialized warning block: submit_bio_wait() conversions Update of blkg_stat and blkg_rwstat may happen in bh context
2013-12-05Merge tag 'nfs-for-3.13-3' of git://git.linux-nfs.org/projects/trondmy/linux-nfsLinus Torvalds11-40/+54
Pull NFS client bugfixes from Trond Myklebust: - Stable fix for a NFSv4.1 delegation and state recovery deadlock - Stable fix for a loop on irrecoverable errors when returning delegations - Fix a 3-way deadlock between layoutreturn, open, and state recovery - Update the MAINTAINERS file with contact information for Trond Myklebust - Close needs to handle NFS4ERR_ADMIN_REVOKED - Enabling v4.2 should not recompile nfsd and lockd - Fix a couple of compile warnings * tag 'nfs-for-3.13-3' of git://git.linux-nfs.org/projects/trondmy/linux-nfs: nfs: fix do_div() warning by instead using sector_div() MAINTAINERS: Update contact information for Trond Myklebust NFSv4.1: Prevent a 3-way deadlock between layoutreturn, open and state recovery SUNRPC: do not fail gss proc NULL calls with EACCES NFSv4: close needs to handle NFS4ERR_ADMIN_REVOKED NFSv4: Update list of irrecoverable errors on DELEGRETURN NFSv4 wait on recovery for async session errors NFS: Fix a warning in nfs_setsecurity NFS: Enabling v4.2 should not recompile nfsd and lockd
2013-12-05ftrace: default to tilegx if ARCH=tile is specifiedTony Lu1-1/+2
This matches the existing behavior in arch/tile/Makefile for defconfig. Reported-by: fengguang.wu@intel.com Acked-by: Steven Rostedt <rostedt@goodmis.org> Signed-off-by: Tony Lu <zlu@tilera.com> Signed-off-by: Chris Metcalf <cmetcalf@tilera.com>
2013-12-05Input: ALPS - add support for DualPoint device on Dell XT2 modelYunkang Tang2-3/+204
The device uses special MPU controller that necessitates the new initialization sequence for the device. We also define a new protocol for the trackpad that allows reporting better resolution than older V2 protocol. Signed-off-by: Yunkang Tang <yunkang.tang@cn.alps.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2013-12-05Input: elantech - add support for newer (August 2013) devicesMatt Walker1-0/+1
Added detection for newer Elantech touchpads, so that kernel doesn't fall-back to default PS/2 driver. Supports touchpads released after ~August 2013. Fixes bug: https://lists.launchpad.net/kernel-packages/msg18481.html Tested on an Acer Aspire S7-392-6302. Signed-off by: Matt Walker <matt.g.d.walker@gmail.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2013-12-05Input: add SW_MUTE_DEVICE switch definitionPing Cheng1-0/+1
Some devices, such as new Intuos series tablets, have a hardware switch to turn touch data on/off. To report the state, SW_MUTE_DEVICE is added in include/uapi/linux/input.h. Reviewed_by: Chris Bagwell <chris@cnpbagwell.com> Acked-by: Peter Hutterer <peter.hutterer@who-t.net> Tested-by: Jason Gerecke <killertofu@gmail.com> Signed-off-by: Ping Cheng <pingc@wacom.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2013-12-05tracing: Only run synchronize_sched() at instance deletion timeSteven Rostedt2-10/+3
It has been reported that boot up with FTRACE_SELFTEST enabled can take a very long time. There can be stalls of over a minute. This was tracked down to the synchronize_sched() called when a system call event is disabled. As the self tests enable and disable thousands of events, this makes the synchronize_sched() get called thousands of times. The synchornize_sched() was added with d562aff93bfb53 "tracing: Add support for SOFT_DISABLE to syscall events" which caused this regression (added in 3.13-rc1). The synchronize_sched() is to protect against the events being accessed when a tracer instance is being deleted. When an instance is being deleted all the events associated to it are unregistered. The synchronize_sched() makes sure that no more users are running when it finishes. Instead of calling synchronize_sched() for all syscall events, we only need to call it once, after the events are unregistered and before the instance is deleted. The event_mutex is held during this action to prevent new users from enabling events. Link: http://lkml.kernel.org/r/20131203124120.427b9661@gandalf.local.home Reported-by: Petr Mladek <pmladek@suse.cz> Acked-by: Tom Zanussi <tom.zanussi@linux.intel.com> Acked-by: Petr Mladek <pmladek@suse.cz> Tested-by: Petr Mladek <pmladek@suse.cz> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
2013-12-05Merge tag 'for-linus' of ↵Linus Torvalds1-1/+2
git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs Pull btrfs MAINTAINERS file update: "I'm still getting settled into new devel hardware etc, but I do have one commit for the next rc. This changes my email over to fb.com, and adds a MAINTAINERS entry for Josef as well" * tag 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs: Btrfs: update the MAINTAINERS file
2013-12-05Merge tag 'fbdev-fixes-3.13' of ↵Linus Torvalds5-20/+19
git://git.kernel.org/pub/scm/linux/kernel/git/tomba/linux Pull minor fbdev fixes from Tomi Valkeinen. * tag 'fbdev-fixes-3.13' of git://git.kernel.org/pub/scm/linux/kernel/git/tomba/linux: video: vt8500: fix error handling in probe() atmel_lcdfb: fix module autoload fbdev: sh_mobile_meram: Fix defined but not used compiler warnings video: kyro: fix incorrect sizes when copying to userspace ARM: OMAPFB: panel-sony-acx565akm: fix bad unlock balance
2013-12-05Merge tag 'sound-3.13-rc3' of ↵Linus Torvalds18-87/+146
git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound Pull sound fixes from Takashi Iwai: "A usual pattern of half ASoC and half HD-audio fixes, although HD-audio fixups have more volumes, in addition to a couple of trivial fixes. Nothing to worry much is found here. For ASoC side: a few fixes for PCM rate constraints calculations, regmap byte-order fix, the rest driver specific fixes (atmel, fsl, omap, kirkwood, wm codecs). For HD-audio: Dell headset and mono out fix, ELD update in polling mode, ALC283 Chromebook fixes, a few fixes for old AD codecs and MBA2, one regression fix" * tag 'sound-3.13-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound: (30 commits) ALSA: hda - Fix silent output on MacBook Air 2,1 ALSA: hda - Fix missing ELD info when using jackpoll_ms parameter ALSA: hda/realtek - remove hp_automute_hook from alc283_fixup_chromebook ASoC: wm8731: fix dsp mode configuration ALSA: hda/realtek - Independent of model for HP ALSA: hda - Fix headset mic input after muted internal mic (Dell/Realtek) ALSA: hda - Use always amps for auto-mute on AD1986A codec ALSA: hda/analog - Handle inverted EAPD properly in vmaster hook ALSA: hda - Another fixup for ASUS laptop with ALC660 codec ALSA: atmel: Fix possible array overflow ALSA: hda - Fix complete_all() timing in deferred probes ALSA: hda - Fix bad EAPD setup for HP machines with AD1984A ASoC: core: fix devres parameter in devm_snd_soc_register_card() ASoC: omap: n810: Convert to clk_prepare_enable/clk_disable_unprepare ASoC: fsl: set correct platform drvdata in pcm030_fabric_probe() ASoC: fsl: imx-pcm-fiq: Remove unused 'runtime' variable ASoC: fsl: imx-pcm-fiq: remove bogus period delta calculation ALSA: hda - Fix silent output on ASUS W7J laptop ASoC: core: Use consistent byte ordering in snd_soc_bytes_get ALSA: dice: fix array limits in dice_proc_read() ...
2013-12-05Merge tag 'pinctrl-v3.13-2' of ↵Linus Torvalds5-8/+9
git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-pinctrl Pull pin control fixes from Linus Walleij: - Minor bug fixes for the Rockchip, ST-Ericsson abx500, Renesas PFC r8a7740 and sh7372. - Compilation warning fixes. * tag 'pinctrl-v3.13-2' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-pinctrl: sh-pfc: sh7372: Fix pin bias setup sh-pfc: r8a7740: Fix pin bias setup pinctrl: abx500: Fix header file include guard pinctrl: rockchip: missing unlock on error in rockchip_set_pull() pinctrl: abx500: fix some more bitwise AND tests pinctrl: rockchip: testing the wrong variable
2013-12-05blk-mq: fix use-after-free of requestMing Lei1-2/+2
If accounting is on, we will do the IO completion accounting after we have freed the request. Fix that by moving it sooner instead. Signed-off-by: Jens Axboe <axboe@kernel.dk>
2013-12-05mei: add 9 series PCH mei device idsTomas Winkler2-2/+7
And Lynx Point H Refresh and Wildcat Point LP device ids. Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-12-04Merge branch 'x86/urgent' of ↵Linus Torvalds12-37/+201
git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull x86 and EFI fixes from Peter Anvin: "Half of these are EFI-related: The by far biggest change is the change to hold off the deletion of a sysfs entry while a backend scan is in progress. This is to avoid calling kmemdup() while under a spinlock. The other major change is for each entry in the EFI pstore backend to get a unique identifier, as required by the pstore filesystem proper. The other changes are: A fix to the recent consolidation and optimization of using "asm goto" with read-modify-write operation, which broke the bitops; specifically in such a way that we could end up generating invalid code. A build hack to make sure we compile with -mno-sse. icc, and most likely future versions of gcc, can generate SSE instructions unless we tell it not to. A comment-only patch to a change the was due in part to an unpublished erratum; now when the erratum is published we want to add a comment explaining why" * 'x86/urgent' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: x86/apic, doc: Justification for disabling IO APIC before Local APIC x86, bitops: Correct the assembly constraints to testing bitops x86-64, build: Always pass in -mno-sse efi-pstore: Make efi-pstore return a unique id x86/efi: Fix earlyprintk off-by-one bug efivars, efi-pstore: Hold off deletion of sysfs entry until the scan is completed
2013-12-04drivers/char/i8k.c: add Dell XPLS L421XAlan Cox1-0/+7
Addresses https://bugzilla.kernel.org/show_bug.cgi?id=60772 Signed-off-by: Alan Cox <alan@linux.intel.com> Reported-by: Leho Kraav <leho@kraav.com> Cc: stable <stable@vger.kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-12-04x86/apic, doc: Justification for disabling IO APIC before Local APICFenghua Yu1-0/+11
Since erratum AVR31 in "Intel Atom Processor C2000 Product Family Specification Update" is now published, I added a justification comment for disabling IO APIC before Local APIC, as changed in commit: 522e66464467 x86/apic: Disable I/O APIC before shutdown of the local APIC Signed-off-by: Fenghua Yu <fenghua.yu@intel.com> Link: http://lkml.kernel.org/r/1386202069-51515-1-git-send-email-fenghua.yu@intel.com Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
2013-12-05Merge branch 'drm-fixes-3.13' of git://people.freedesktop.org/~agd5f/linux ↵Dave Airlie14-91/+106
into drm-fixes Some additional fixes for 3.13. Regression fixes for audio and hw_i2c, vram fix for some SI PX cards, race fix in the hwmon code, and a few other odds and ends. * 'drm-fixes-3.13' of git://people.freedesktop.org/~agd5f/linux: drm/radeon/atom: fix bus probes when hw_i2c is set (v2) drm/radeon: fix null pointer dereference in dce6+ audio code drm/radeon: fixup bad vram size on SI drm/radeon: fix VGT_GS_INSTANCE_CNT register drm/radeon: Fix a typo in Cayman and Evergreen registers drm/radeon/dpm: simplify state adjust logic for NI drm/radeon: add radeon_vm_bo_update trace point drm/radeon: add VMID allocation trace point drm/radeon/dpm: Convert to use devm_hwmon_register_with_groups drm/radeon: program DCE2 audio dto just like DCE3 drm/radeon: fix typo in fetching mpll params
2013-12-05PowerCap: Fix mode for energy counterSrinivas Pandruvada1-1/+6
As per the documentation of powercap sysfs, energy_uj field is read only, if it can't be reset. Currently it always allows write but will fail, if there is no reset callback. Changing mode field, to read only if there is no reset callback. Signed-off-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> Reported-by: Dirk Brandewie <dirk.j.brandewie@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
2013-12-05PNP: fix restoring devices after hibernationDmitry Torokhov1-1/+11
On returning from hibernation 'restore' callback is called, not 'resume'. Fix it. Fixes: eaf140b60ec9 (PNP: convert PNP driver bus legacy pm_ops to dev_pm_ops) Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Cc: 3.12+ <stable@vger.kernel.org> # 3.12+ Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
2013-12-05drm: fix the addition of the side-by-side (half) flag for extra 3D modesThomas Wood1-1/+1
Ensure the side-by-side (half) flag is added to any existing flags when adding modes from 3D_Structure_ALL. Signed-off-by: Thomas Wood <thomas.wood@intel.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Dave Airlie <airlied@redhat.com>
2013-12-05drm/edid: fix length check when adding extra 3D modesThomas Wood1-1/+1
Signed-off-by: Thomas Wood <thomas.wood@intel.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Dave Airlie <airlied@redhat.com>
2013-12-04usb: hub: Use correct reset for wedged USB3 devices that are NOTATTACHEDJulius Werner1-2/+3
This patch adds a check for USB_STATE_NOTATTACHED to the hub_port_warm_reset_required() workaround for ports that end up in Compliance Mode in hub_events() when trying to decide which reset function to use. Trying to call usb_reset_device() with a NOTATTACHED device will just fail and leave the port broken. Signed-off-by: Julius Werner <jwerner@chromium.org> Acked-by: Alan Stern <stern@rowland.harvard.edu> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-12-04usb: ohci-pxa27x: include linux/dma-mapping.hDaniel Mack1-0/+1
Include linux/dma-mapping.h to make the new functions available that are used since 22d9d8e83 ("DMA-API: usb: use dma_set_coherent_mask()"). drivers/usb/host/ohci-pxa27x.c: In function ‘ohci_pxa_of_init’: drivers/usb/host/ohci-pxa27x.c:310:2: error: implicit declaration of function ‘dma_coerce_mask_and_coherent’ [-Werror=implicit-function-declaration] drivers/usb/host/ohci-pxa27x.c:310:2: error: implicit declaration of function ‘DMA_BIT_MASK’ [-Werror=implicit-function-declaration] Signed-off-by: Daniel Mack <zonque@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-12-04drm/radeon/atom: fix bus probes when hw_i2c is set (v2)Alex Deucher1-6/+9
When probing the bus, we need to set the byte count to 0 rather than 1. v2: Don't count the first byte. bug: https://bugzilla.kernel.org/show_bug.cgi?id=66241 Signed-off-by: Alex Deucher <alexander.deucher@amd.com> Cc: stable@vger.kernel.org
2013-12-04drm/radeon: fix null pointer dereference in dce6+ audio codeAlex Deucher1-5/+7
Don't crash if the encoder does not have an afmt struct. bug: https://bugs.freedesktop.org/show_bug.cgi?id=72283 Signed-off-by: Alex Deucher <alexander.deucher@amd.com> Cc: stable@vger.kernel.org
2013-12-04drm/radeon: fixup bad vram size on SIAlex Deucher1-2/+9
Some boards seem to have garbage in the upper 16 bits of the vram size register. Check for this and clamp the size properly. Fixes boards reporting bogus amounts of vram. Signed-off-by: Alex Deucher <alexander.deucher@amd.com> Cc: stable@vger.kernel.org
2013-12-04USB: cdc-acm: Added support for the Lenovo RD02-D400 USB ModemDavid Cluytens1-0/+2
Signed-off-by: David Cluytens <david.cluytens@gmail.com> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-12-05Merge tag 'drm-intel-fixes-2013-12-02' of ↵Dave Airlie11-77/+82
git://people.freedesktop.org/~danvet/drm-intel into drm-fixes Just flushing out my pile of bugfixes, most of them for regressions/cc: stable. Nothing really serious going on. For outstanding issues we still have the S4 fun due to the hsw S4 duct-tape pending (seems like I need to switch into angry maintainer mode on that one). And there's the mode merging revert to make my g33 work again still pending for drm core. For that one I don't have any more clue (and it looks like no one else has a good idea either). And apparently the locking WARN fix in here also needs to be replicated for boot, still confirming that one though. * tag 'drm-intel-fixes-2013-12-02' of git://people.freedesktop.org/~danvet/drm-intel: drm/i915: Pin pages whilst allocating for dma-buf vmap() drm/i915: MI_PREDICATE_RESULT_2 is HSW only drm/i915: Make the DERRMR SRM target global GTT drm/i915: use the correct force_wake function at the PC8 code drm/i915: Fix pipe CSC post offset calculation drm/i915: Simplify DP vs. eDP detection drm/i915: Check VBT for eDP ports on VLV drm/i915: use crtc_htotal in watermark calculations to match fastboot v2 drm/i915: Pin relocations for the duration of constructing the execbuffer drm/i915: take mode config lock around crtc disable at suspend drm/i915: Prefer setting PTE cache age to 3 drm/i915/ddi: set sink to power down mode on dp disable
2013-12-05Merge branch 'exynos-drm-fixes' of ↵Dave Airlie2-14/+23
git://git.kernel.org/pub/scm/linux/kernel/git/daeinki/drm-exynos into drm-fixes two outstanding exynos fixes * 'exynos-drm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/daeinki/drm-exynos: drm/exynos: release unhandled page flip events at postclose. drm/exynos: Fix trivial typo in exynos_drm_fimd.c
2013-12-05Merge tag 'drm/for-3.13-rc3' of git://anongit.freedesktop.org/tegra/linux ↵Dave Airlie7-27/+35
into drm-fixes drm/tegra: Fixes for v3.13-rc3 This assortment of patches fix a few build and sparse warnings and make sure to always return -EFAULT on copy_from_user() failures. Finally the upcasting from struct drm_crtc to struct tegra_dc is made safer to prevent potential segmentation faults. * tag 'drm/for-3.13-rc3' of git://anongit.freedesktop.org/tegra/linux: drm/tegra: return -EFAULT if copy_from_user() fails gpu: host1x: Fix a few sparse warnings drm/tegra: Force cast to __iomem to make sparse happy drm/tegra: Make tegra_drm_driver static drm/tegra: Fix address space mismatches drm/tegra: Tightly bind RGB output to DC drm/tegra: Make CRTC upcasting safer gpu: host1x: Silence a few warnings with LPAE=y
2013-12-05udl: fix issue with imported prime buffersRob Clark1-0/+6
5dc9e1e8 was a bit over-ambitious, and accidentially removed handling for imported prime buffers. Signed-off-by: Rob Clark <robdclark@gmail.com> Cc: stable@vger.kernel.org Signed-off-by: Dave Airlie <airlied@redhat.com>
2013-12-05Merge branch 'drm-nouveau-next' of ↵Dave Airlie11-17/+499
git://anongit.freedesktop.org/git/nouveau/linux-2.6 into drm-fixes Fix some pageflip, oopses and some better clock support for some chipsets * 'drm-nouveau-next' of git://anongit.freedesktop.org/git/nouveau/linux-2.6: drm/nv50/disp: min/max are reversed in nv50_crtc_gamma_set() drm/nouveau/sw: fix oops if gpu has its display block disabled drm/nouveau: unreference fence after syncing drm/nouveau/kms: send timestamp data for correct head in flip completion events drm/nouveau/clk: Add support for NVAA/NVAC drm/nouveau/fifo: Hook up pause and resume for NV50 and NV84+ drm/nv10/plane: some chipsets don't support NV12 drm/nv10/plane: add downscaling restrictions drm/nv10/plane: fix format computation drm/nv04-nv30/clk: provide an empty domain list
2013-12-05Merge branch 'vmwgfx-fixes-3.13' of ↵Dave Airlie6-37/+94
git://people.freedesktop.org/~thomash/linux into drm-fixes A couple of fixes. The biggest thing is the DMA buffer accounting that was incorrect. * 'vmwgfx-fixes-3.13' of git://people.freedesktop.org/~thomash/linux: drm/vmwgfx: Add our connectors to sysfs drm/vmwgfx: Fix dma buffer memory size accounting drm/vmwgfx: Fix up and comment the dumb buffer implementation drm/vmwgfx: Correctly set the enabled state on crtcs
2013-12-04usb: tools: fix a regression issue that gcc can't link to pthreadHuang Rui1-2/+3
Reproduce: ray@hr-bak:~/usb$ make -C tools/usb/ make: Entering directory `/home/ray/usb/tools/usb' gcc -Wall -Wextra -g -lpthread -I../include -o testusb testusb.c /tmp/cc0EMxfy.o: In function `main': /home/ray/usb/tools/usb/testusb.c:508: undefined reference to `pthread_create' /home/ray/usb/tools/usb/testusb.c:531: undefined reference to `pthread_join' collect2: error: ld returned 1 exit status make: *** [testusb] Error 1 make: Leaving directory `/home/ray/usb/tools/usb' Comments: In the latest version (4.7.3) of gcc compiler, it requres that libraries must follow the object or source files like below: "gcc hello.c -lpthread" instead of "gcc -lpthread hello.c" And it isn't encountered at gcc version 4.7.2. So this patch fix to move the pthread option after testusb.c. Signed-off-by: Huang Rui <ray.huang@amd.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-12-04x86, bitops: Correct the assembly constraints to testing bitopsH. Peter Anvin5-13/+13
In checkin: 0c44c2d0f459 x86: Use asm goto to implement better modify_and_test() functions the various functions which do modify and test were unified and optimized using "asm goto". However, this change missed the detail that the bitops require an "Ir" constraint rather than an "er" constraint ("I" = integer constant from 0-31, "e" = signed 32-bit integer constant). This would cause code to miscompile if these functions were used on constant bit positions 32-255 and the build to fail if used on constant bit positions above 255. Add the constraints as a parameter to the GEN_BINARY_RMWcc() macro to avoid this problem. Reported-by: Jesse Brandeburg <jesse.brandeburg@intel.com> Signed-off-by: H. Peter Anvin <hpa@linux.intel.com> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/529E8719.4070202@zytor.com
2013-12-04drm/vmwgfx: Add our connectors to sysfsThomas Hellstrom3-0/+5
Some user-space apps expects to find them there. Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com> Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>
2013-12-04drm/vmwgfx: Fix dma buffer memory size accountingThomas Hellstrom3-10/+47
Also request kernel ttm_buffer objects for buffer objects that obviously aren't visible to user-space, and save some device address space. The accounting was broken in a couple of ways: 1) We did not differentiate between user dma buffers and kernel dma buffers. 2) The ttm_bo_acc_size function is broken in that it a) Doesn't take into account the size of the optional dma address array, b) Doesn't take into account the fact that drivers typically embed the ttm_tt structure. This needs to be fixed in ttm, but meanwhile provide a vmwgfx-specific function to do the job. Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com> Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>
2013-12-04drm/vmwgfx: Fix up and comment the dumb buffer implementationThomas Hellstrom1-27/+37
Allocation was duplicating code. Comments were missing. Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com> Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>
2013-12-04drm/vmwgfx: Correctly set the enabled state on crtcsThomas Hellstrom2-0/+5
Failure to do this would make the drm_mode_get_crtc ioctl return without crtc mode info, indicating that no mode was set. Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com> Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>
2013-12-04nfs: fix do_div() warning by instead using sector_div()Helge Deller1-1/+1
When compiling a 32bit kernel with CONFIG_LBDAF=n the compiler complains like shown below. Fix this warning by instead using sector_div() which is provided by the kernel.h header file. fs/nfs/blocklayout/extents.c: In function ‘normalize’: include/asm-generic/div64.h:43:28: warning: comparison of distinct pointer types lacks a cast [enabled by default] fs/nfs/blocklayout/extents.c:47:13: note: in expansion of macro ‘do_div’ nfs/blocklayout/extents.c:47:2: warning: right shift count >= width of type [enabled by default] fs/nfs/blocklayout/extents.c:47:2: warning: passing argument 1 of ‘__div64_32’ from incompatible pointer type [enabled by default] include/asm-generic/div64.h:35:17: note: expected ‘uint64_t *’ but argument is of type ‘sector_t *’ extern uint32_t __div64_32(uint64_t *dividend, uint32_t divisor); Signed-off-by: Helge Deller <deller@gmx.de> Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
2013-12-04MAINTAINERS: Update contact information for Trond MyklebustTrond Myklebust1-2/+2
Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com>
2013-12-04NFSv4.1: Prevent a 3-way deadlock between layoutreturn, open and state recoveryTrond Myklebust1-1/+8
Andy Adamson reports: The state manager is recovering expired state and recovery OPENs are being processed. If kswapd is pruning inodes at the same time, a deadlock can occur when kswapd calls evict_inode on an NFSv4.1 inode with a layout, and the resultant layoutreturn gets an error that the state mangager is to handle, causing the layoutreturn to wait on the (NFS client) cl_rpcwaitq. At the same time an open is waiting for the inode deletion to complete in __wait_on_freeing_inode. If the open is either the open called by the state manager, or an open from the same open owner that is holding the NFSv4 sequence id which causes the OPEN from the state manager to wait for the sequence id on the Seqid_waitqueue, then the state is deadlocked with kswapd. The fix is simply to have layoutreturn ignore all errors except NFS4ERR_DELAY. We already know that layouts are dropped on all server reboots, and that it has to be coded to deal with the "forgetful client model" that doesn't send layoutreturns. Reported-by: Andy Adamson <andros@netapp.com> Link: http://lkml.kernel.org/r/1385402270-14284-1-git-send-email-andros@netapp.com Signed-off-by: Trond Myklebust <Trond.Myklebust@primarydata.com>
2013-12-04Merge tag 'gpio-v3.13-3' of ↵Linus Torvalds4-7/+38
git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-gpio Pull GPIO fixes from Linus Walleij: "Here are a few more GPIO patches, we're a bit noisy for being the GPIO subsystem, mostly due to the new descriptor API, but all is getting into shape. - Fix compile warnings - Fix overly talkative diagnostic messages from usual use cases wrt GPIO descriptors - Add a documentation 00-INDEX - Use platform GPIOs as fallback when ACPI or device tree is used as the primary means to get GPIO lines - A bug fix for the MPC8572/MPC8536 fixing erroneous input data" * tag 'gpio-v3.13-3' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-gpio: gpiolib: change a warning to debug message when failing to get gpio powerpc/gpio: Fix the wrong GPIO input data on MPC8572/MPC8536 gpiolib: use platform GPIO mappings as fallback Documentation: gpiolib: add 00-INDEX file gpiolib: fix lookup of platform-mapped GPIOs gpiolib: add missing declarations
2013-12-04Merge tag 'fixes-for-linus' of ↵Linus Torvalds32-114/+575
git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc Pull ARM SoC fixes from Olof Johansson: "Another batch of fixes for ARM SoCs for 3.13. The diffstat is large, mostly because of: - Another set of fixes to fix regressions caused by moving OMAP from board files to DT. Tony thinks this was the last major set of fixes, with maybe just a few small patches to follow. - More fixes for Marvell platforms, most dealing with misdescribed PCIe hardware, i.e. incorrect number of busses on some SoCs, etc. The line delta adds up due to various ranges moving around when this is fixed. But there's also: - Some smaller tweaks to defconfigs to make more boards bootable in my test setup for better coverage. - There are also a few other smaller fixes, a short series for at91, a couple of reverts for ux500, etc" * tag 'fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: (39 commits) arm: dts: socfpga: Change some clocks of gate-clk type to perip-clk arm: socfpga: Enable ARM_TWD for socfpga ARM: multi_v7_defconfig: enable SDHCI_BCM_KONA and MMC_BLOCK_MINORS=16 ARM: sunxi_defconfig: enable NFS, TMPFS, PRINTK_TIME and nfsroot support ARM: multi_v7_defconfig: enable network for BeagleBone Black ARM: dts: Fix the name of supplies for smsc911x shared by OMAP ARM: OMAP2+: Powerdomain: Fix unchecked dereference of arch_pwrdm ARM: dts: omap3-beagle: Add omap-twl4030 audio support ARM: dts: omap4-sdp: Fix pin muxing for wl12xx ARM: dts: omap4-panda-common: Fix pin muxing for wl12xx ARM: at91: fixed unresolved symbol "at91_pm_set_standby" when built without CONFIG_PM ARM: at91: add usart3 alias to dtsi ARM: at91: sama5d3: reduce TWI internal clock frequency mmc: omap: Fix I2C dependency and make driver usable with device tree mmc: omap: Fix DMA configuration to not rely on device id ARM: dts: omap3-beagle: Fix USB host on beagle boards (for 3.13) ARM: dts: omap3-igep0020: name twl4030 VPLL2 regulator as vdds_dsi ARM: dts: AM33XX IGEP0033: add USB support ARM: dts: AM33XX BASE0033: add 32KBit EEPROM support ARM: dts: AM33XX BASE0033: add pinmux and user led support ...
2013-12-04Merge branch 'parisc-3.13' of ↵Linus Torvalds10-173/+110
git://git.kernel.org/pub/scm/linux/kernel/git/deller/parisc-linux Pull parsic updates from Helge Deller: - a fix for the mmap(MAP_FIXED|MAP_SHARED) syscall to the same address which was already given in a previous call (fixes locale-gen on debian) - change the memory layout of the kernel to avoid the need for the -mlong-calls compiler option (depends on commit 5ecbe3c3c690 - "kernel/extable: fix address-checks for core_kernel and init areas") - defconfig updates, e.g. use the SIL680 driver instead of the SIIMAGE driver - add more parisc machine names to the machine database * 'parisc-3.13' of git://git.kernel.org/pub/scm/linux/kernel/git/deller/parisc-linux: parisc: update 64bit defconfigs and use SIL680 instead of SIIMAGE driver parisc: remove CONFIG_MLONGCALLS=y from defconfigs parisc: fix kernel memory layout in vmlinux.ld.S parisc: use kernel_text_address() in unwind functions parisc: remove empty SERIAL_PORT_DFNS in serial.h parisc: add some more machine names to hardware database parisc: fix mmap(MAP_FIXED|MAP_SHARED) to already mmapped address
2013-12-04Merge tag 'squashfs-fixes' of ↵Linus Torvalds1-1/+4
git://git.kernel.org/pub/scm/linux/kernel/git/pkl/squashfs-next Pull squashfs bugfix from Phillip Lougher: "Just a single bug fix to the new "directly decompress into the page cache" code" * tag 'squashfs-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/pkl/squashfs-next: Squashfs: fix failure to unlock pages on decompress error
2013-12-04Merge git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6Linus Torvalds9-83/+109
Pull crypto fixes from Herbert Xu: "This push fixes a number of crashes triggered by a previous crypto self-test update. It also fixes a build problem in the caam driver, as well as a concurrency issue in s390. Finally there is a pair of fixes to bugs in the crypto scatterwalk code and authenc that may lead to crashes" * git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6: crypto: testmgr - fix sglen in test_aead for case 'dst != src' crypto: talitos - fix aead sglen for case 'dst != src' crypto: caam - fix aead sglen for case 'dst != src' crypto: ccm - Fix handling of zero plaintext when computing mac crypto: s390 - Fix aes-xts parameter corruption crypto: talitos - corrrectly handle zero-length assoc data crypto: scatterwalk - Set the chain pointer indication bit crypto: authenc - Find proper IV address in ablkcipher callback crypto: caam - Add missing Job Ring include
2013-12-04Merge branch 'timers-urgent-for-linus' of ↵Linus Torvalds9-29/+66
git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull timer fixes from Thomas Gleixner: - timekeeping: Cure a subtle drift issue on GENERIC_TIME_VSYSCALL_OLD - nohz: Make CONFIG_NO_HZ=n and nohz=off command line option behave the same way. Fixes a long standing load accounting wreckage. - clocksource/ARM: Kconfig update to avoid ARM=n wreckage - clocksource/ARM: Fixlets for the AT91 and SH clocksource/clockevents - Trivial documentation update and kzalloc conversion from akpms pile * 'timers-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: nohz: Fix another inconsistency between CONFIG_NO_HZ=n and nohz=off time: Fix 1ns/tick drift w/ GENERIC_TIME_VSYSCALL_OLD clocksource: arm_arch_timer: Hide eventstream Kconfig on non-ARM clocksource: sh_tmu: Add clk_prepare/unprepare support clocksource: sh_tmu: Release clock when sh_tmu_register() fails clocksource: sh_mtu2: Add clk_prepare/unprepare support clocksource: sh_mtu2: Release clock when sh_mtu2_register() fails ARM: at91: rm9200: switch back to clockevents_config_and_register tick: Document tick_do_timer_cpu timer: Convert kmalloc_node(...GFP_ZERO...) to kzalloc_node(...) NOHZ: Check for nohz active instead of nohz enabled
2013-12-04ALSA: hda - Fix silent output on MacBook Air 2,1Takashi Iwai1-8/+31
MacBook Air 2,1 has a fairly different pin assignment from its brother MBA 1,1, and yet another quirks are needed for pin 0x18 and 0x19, similarly like what iMac 9,1 requires, in order to make the sound working on it. Reported-and-tested-by: Bruno Prémont <bonbons@linux-vserver.org> Cc: <stable@vger.kernel.org> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-12-04Merge tag 'asoc-v3.13-rc2' of ↵Takashi Iwai310-1817/+4997
git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-linus ASoC: Fixes for v3.13 A smattering of fixes here, some core ones for the rate combination issues for things other than simple bitmasks, for readback of byte controls and for updating the power of value muxes plus a bunch of driver fixes of varying severity. The warning fix in the i.MX FIQ driver is fixing a warning introduced by a previous fix.
2013-12-04video: vt8500: fix error handling in probe()Dan Carpenter1-14/+11
We shouldn't kfree(fbi) because that was allocated with devm_kzalloc(). There were several error paths which returned directly instead of releasing resources. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2013-12-04atmel_lcdfb: fix module autoloadJohan Hovold1-0/+1
Add missing module device table which is needed for module autoloading. Signed-off-by: Johan Hovold <jhovold@gmail.com> Acked-by: Nicolas Ferre <nicolas.ferre@atmel.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2013-12-04ALSA: hda - Fix missing ELD info when using jackpoll_ms parameterDavid Henningsson1-12/+15
In the case of using jackpoll_ms instead of unsol events, the jack was correctly detected, but ELD info was not refreshed on plug-in. And without ELD info, no proper restriction of pcm, which can in turn break sound output on some devices. Signed-off-by: David Henningsson <david.henningsson@canonical.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-12-04ALSA: hda/realtek - remove hp_automute_hook from alc283_fixup_chromebookKailang Yang1-1/+0
I forgot to remove the hp_automute_hook from alc283_fixup_chromebook. It doesn't need this for other chrome os machine. Signed-off-by: Kailang Yang <kailang@realtek.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-12-03Btrfs: update the MAINTAINERS fileChris Mason1-1/+2
Josef and I have new email addresses Signed-off-by: Chris Mason <clm@fb.com> Signed-off-by: Josef Bacik <jbacik@fb.com>
2013-12-03x86-64, build: Always pass in -mno-sseH. Peter Anvin1-1/+7
Always pass in the -mno-sse argument, regardless if -preferred-stack-boundary is supported. We never want to generate SSE instructions in the kernel unless we *really* know what we're doing. According to H. J. Lu, any version of gcc new enough that we support it at all should handle the -mno-sse option, so just add it unconditionally. Reported-by: Kevin B. Smith <kevin.b.smith@intel.com> Signed-off-by: H. Peter Anvin <hpa@linux.intel.com> Cc: H. J. Lu <hjl.tools@gmail.com> Link: http://lkml.kernel.org/n/tip-j21wzqv790q834n7yc6g80j1@git.kernel.org Cc: <stable@vger.kernel.org> # build fix only
2013-12-03parisc: update 64bit defconfigs and use SIL680 instead of SIIMAGE driverHelge Deller3-67/+8
Signed-off-by: Helge Deller <deller@gmx.de>
2013-12-03arm: dts: socfpga: Change some clocks of gate-clk type to perip-clkDinh Nguyen1-3/+4
Some of the clocks that were designated gate-clk do not have a gate, so change those clocks to be of periph-clk type. Signed-off-by: Dinh Nguyen <dinguyen@altera.com> Signed-off-by: Olof Johansson <olof@lixom.net>
2013-12-03arm: socfpga: Enable ARM_TWD for socfpgaDinh Nguyen1-0/+1
Update Kconfig to enable TWD. Signed-off-by: Dinh Nguyen <dinguyen@altera.com> Reviewed-by: Pavel Machek <pavel@denx.de> Signed-off-by: Olof Johansson <olof@lixom.net>
2013-12-03Merge tag 'iio-fixes-for-3.13b' of ↵Greg Kroah-Hartman6-26/+38
git://git.kernel.org/pub/scm/linux/kernel/git/jic23/iio into staging-linus Jonathan writes: Second round of IIO fixes for the 3.13 cycle. 2 fixes here. * The gp2ap020a00f is a simple missing kconfig dependency. * The hid sensors hub fix is a work around for an issue introduced by hardware changes due to a certain large software vendor having an 'interesting' interpretation of the specification and hence indexing some arrays from 1 rather than 0. The fix takes advantage of the logical min and max reading facilities introduced by the precursor patch to figure out whether we have a 0 indexed or 1 indexed device and to adjust appropriately. It also drops a previous kconfig option that allowed this issue to be worked around at build time.
2013-12-03blk-mq: fix dereference of rq->mq_ctx if allocation failsJeff Moyer1-4/+8
If __GFP_WAIT isn't set and we fail allocating, when we go to drop the reference on the ctx, we will attempt to dereference the NULL rq. Fix that. Signed-off-by: Jeff Moyer <jmoyer@redhat.com> Signed-off-by: Jens Axboe <axboe@kernel.dk>
2013-12-03cpuidle: Check for dev before deregistering it.Konrad Rzeszutek Wilk1-1/+1
If not, we could end up in the unfortunate situation where we dereference a NULL pointer b/c we have cpuidle disabled. This is the case when booting under Xen (which uses the ACPI P/C states but disables the CPU idle driver) - and can be easily reproduced when booting with cpuidle.off=1. BUG: unable to handle kernel NULL pointer dereference at (null) IP: [<ffffffff8156db4a>] cpuidle_unregister_device+0x2a/0x90 .. snip.. Call Trace: [<ffffffff813b15b4>] acpi_processor_power_exit+0x3c/0x5c [<ffffffff813af0a9>] acpi_processor_stop+0x61/0xb6 [<ffffffff814215bf>] __device_release_driver+0fffff81421653>] device_release_driver+0x23/0x30 [<ffffffff81420ed8>] bus_remove_device+0x108/0x180 [<ffffffff8141d9d9>] device_del+0x129/0x1c0 [<ffffffff813cb4b0>] ? unregister_xenbus_watch+0x1f0/0x1f0 [<ffffffff8141da8e>] device_unregister+0x1e/0x60 [<ffffffff814243e9>] unregister_cpu+0x39/0x60 [<ffffffff81019e03>] arch_unregister_cpu+0x23/0x30 [<ffffffff813c3c51>] handle_vcpu_hotplug_event+0xc1/0xe0 [<ffffffff813cb4f5>] xenwatch_thread+0x45/0x120 [<ffffffff810af010>] ? abort_exclusive_wait+0xb0/0xb0 [<ffffffff8108ec42>] kthread+0xd2/0xf0 [<ffffffff8108eb70>] ? kthread_create_on_node+0x180/0x180 [<ffffffff816ce17c>] ret_from_fork+0x7c/0xb0 [<ffffffff8108eb70>] ? kthread_create_on_node+0x180/0x180 This problem also appears in 3.12 and could be a candidate for backport. Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com> Cc: All applicable <stable@vger.kernel.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
2013-12-03ARM: multi_v7_defconfig: enable SDHCI_BCM_KONA and MMC_BLOCK_MINORS=16Olof Johansson1-0/+2
Enable MMC/SD on the Broadcom mobile platforms, and increase the block minors from the default 8 to 16 (since the Broadcom board by default has root on the 8th partition). Signed-off-by: Olof Johansson <olof@lixom.net> Cc: stable@vger.kernel.org # v3.12
2013-12-03ARM: sunxi_defconfig: enable NFS, TMPFS, PRINTK_TIME and nfsroot supportOlof Johansson1-0/+7
This enables a few more options on the sunxi defconfigs such that I can use nfsroot to boot them (there is no local storage support yet). It also enables PRINTK_TIME and tmpfs since it's a common distro requirement. Signed-off-by: Olof Johansson <olof@lixom.net>
2013-12-03Merge tag 'omap-for-v3.13/more-dt-regressions' of ↵Olof Johansson5-19/+34
git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap into fixes From Tony Lindgren: Few more legacy booting vs device tree booting fixes that people have noticed while booting things with device tree for things like omap4 WLAN, smsc911x, and beagle audio. Hopefully this will be it for the legacy booting vs device tree fixes for this -rc cycle. * tag 'omap-for-v3.13/more-dt-regressions' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap: ARM: dts: Fix the name of supplies for smsc911x shared by OMAP ARM: OMAP2+: Powerdomain: Fix unchecked dereference of arch_pwrdm ARM: dts: omap3-beagle: Add omap-twl4030 audio support ARM: dts: omap4-sdp: Fix pin muxing for wl12xx ARM: dts: omap4-panda-common: Fix pin muxing for wl12xx
2013-12-03ARM: multi_v7_defconfig: enable network for BeagleBone BlackOlof Johansson1-0/+1
BeagleBone Black uses the TI CPSW ethernet controller, enable it in the multi_v7_defconfig for testing coverage purposes. Signed-off-by: Olof Johansson <olof@lixom.net> Acked-by: Tony Lindgren <tony@atomide.com> Cc: stable@vger.kernel.org # v3.12
2013-12-03Merge tag 'at91-fixes' of git://github.com/at91linux/linux-at91 into fixesOlof Johansson3-3/+11
From Nicolas Ferre: AT91: second round of fixes for 3.13 - reduce IP frequency for I2C on sama5d3 - missing aliases directive for USART3 on 9x5 family - a PM symbol is missing if !CONFIG_PM * tag 'at91-fixes' of git://github.com/at91linux/linux-at91: ARM: at91: fixed unresolved symbol "at91_pm_set_standby" when built without CONFIG_PM ARM: at91: add usart3 alias to dtsi ARM: at91: sama5d3: reduce TWI internal clock frequency
2013-12-03Merge tag 'mvebu-dt-fixes-3.13' of git://git.infradead.org/linux-mvebu into ↵Olof Johansson4-51/+112
fixes From Jason Cooper, mvebu DT fixes for v3.13: - mvebu - PCIe fixes now that we have test devices with more ports. - fix access to coherency registers * tag 'mvebu-dt-fixes-3.13' of git://git.infradead.org/linux-mvebu: ARM: mvebu: re-enable PCIe on Armada 370 DB ARM: mvebu: use the virtual CPU registers to access coherency registers ARM: mvebu: fix second and third PCIe unit of Armada XP mv78260 ARM: mvebu: second PCIe unit of Armada XP mv78230 is only x1 capable
2013-12-03Merge tag 'omap-for-v3.13/fixes-against-rc1-take2' of ↵Olof Johansson15-38/+396
git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap into fixes From Tony Lindgren: Some omap related fixes that have come up with people moving to device tree only based booting for omap2+. The series contains a handful of fixes for the igep boards as they were one of the first omap3 boards to jump over completely to device tree based booting. So these can be considered regressions compared to booting igep in legacy mode with board files in v3.12. Also included are few other device tree vs legacy booting regressions: - yet more missing omap3 .dtsi entries that have showed up booting various boards with device tree only - n900 eMMC device tree fix - fixes for beagle USB EHCI - two fixes to make omap2420 MMC work As we're moving omap2+ to be device tree only for v3.14, I'd like to have v3.13 work equally well for legacy based booting and device tree based booting. So there will be likely few more device tree related booting patches trickling in. This series also includes a regression fix for the omap timer posted mode that may wrongly stay on from the bootloader for some SoCs. * tag 'omap-for-v3.13/fixes-against-rc1-take2' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap: mmc: omap: Fix I2C dependency and make driver usable with device tree mmc: omap: Fix DMA configuration to not rely on device id ARM: dts: omap3-beagle: Fix USB host on beagle boards (for 3.13) ARM: dts: omap3-igep0020: name twl4030 VPLL2 regulator as vdds_dsi ARM: dts: AM33XX IGEP0033: add USB support ARM: dts: AM33XX BASE0033: add 32KBit EEPROM support ARM: dts: AM33XX BASE0033: add pinmux and user led support ARM: dts: AM33XX BASE0033: add pinmux and hdmi node to enable display ARM: dts: omap3-igep0020: Add pinmuxing for DVI output ARM: dts: omap3-igep0020: Add pinmux setup for i2c devices ARM: dts: omap3-igep: Update to use the TI AM/DM37x processor ARM: dts: omap3-igep: Add support for LBEE1USJYC WiFi connected to SDIO ARM: dts: omap3-igep: Fix bus-width for mmc1 ARM: OMAP2+: dss-common: change IGEP's DVI DDC i2c bus ARM: OMAP2+: Disable POSTED mode for errata i103 and i767 ARM: OMAP2+: Fix eMMC on n900 with device tree ARM: OMAP2+: Add fixed regulator to omap2plus_defconfig ARM: OMAP2+: Fix more missing data for omap3.dtsi file Signed-off-by: Olof Johansson <olof@lixom.net>
2013-12-03Merge remote-tracking branches 'asoc/fix/arizona', 'asoc/fix/atmel', ↵Mark Brown8-39/+24
'asoc/fix/fsl', 'asoc/fix/kirkwood', 'asoc/fix/omap', 'asoc/fix/rcar', 'asoc/fix/wm8731' and 'asoc/fix/wm8990' into asoc-linus
2013-12-03Merge remote-tracking branch 'asoc/fix/dapm' into asoc-linusMark Brown1-1/+2
2013-12-03Merge remote-tracking branch 'asoc/fix/core' into asoc-linusMark Brown3-10/+16
2013-12-03USB: switch maintainership of chipidea to PeterGreg Kroah-Hartman1-1/+2
Alexander isn't able to maintain the Chipidea code anymore, and as Peter has been acting as the de-facto maintainer anyway, make it official. Acked-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Acked-by: Peter Chen <Peter.Chen@freescale.com> Acked-by: Marc Kleine-Budde <mkl@pengutronix.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-12-03Staging: TIDSPBRIDGE: Use vm_iomap_memory for mmap-ing instead of ↵Ivaylo Dimitrov1-8/+5
remap_pfn_range This fixes the following bug: ---- Bug Report ---- source file: drivers/staging/tidspbridge/rmgr/drv_interface.c issue : mapping of physical memory without address range checks 259 static int bridge_mmap(struct file *filp, struct vm_area_struct *vma) 260 { 261 u32 status; 262 263 /* VM_IO | VM_DONTEXPAND | VM_DONTDUMP are set by remap_pfn_range() */ 264 vma->vm_page_prot = pgprot_noncached(vma->vm_page_prot); 265 266 dev_dbg(bridge, "%s: vm filp %p start %lx end %lx page_prot %ulx " 267 "flags %lx\n", __func__, filp, 268 vma->vm_start, vma->vm_end, vma->vm_page_prot, 269 vma->vm_flags); 270 271 status = remap_pfn_range(vma, vma->vm_start, vma->vm_pgoff, 272 vma->vm_end - vma->vm_start, 273 vma->vm_page_prot); 274 if (status != 0) 275 status = -EAGAIN; 276 277 return status; 278 } The function provides an interface to remap physical memory to user space, but does not provide any checks to ensure that the memory is within the region that should be accessible. Reported-by: Nico Golde <nico@ngolde.de> Reported-by: Fabian Yamaguchi <fabs@goesec.de> Signed-off-by: Ivaylo Dimitrov <freemangordon@abv.bg> Signed-off-by: Pavel Machek <pavel@ucw.cz> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-12-03ASoC: wm8731: fix dsp mode configurationBo Shen1-2/+2
According to WM8731 "PD, Rev 4.9 October 2012" datasheet, when it works in DSP mode A, LRP = 1, while works in DSP mode B, LRP = 0. So, fix LRP for DSP mode as the datesheet specification. Signed-off-by: Bo Shen <voice.shen@atmel.com> Acked-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Signed-off-by: Mark Brown <broonie@linaro.org> Cc: stable@vger.kernel.org
2013-12-03[SCSI] bfa: Fix crash when symb name set for offline vportVijaya Mohan Guvva3-8/+14
This patch fixes a crash when tried setting symbolic name for an offline vport through sysfs. Crash is due to uninitialized pointer lport->ns, which gets initialized only on linkup (port online). Signed-off-by: Vijaya Mohan Guvva <vmohan@brocade.com> Cc: stable@vger.kernel.org Signed-off-by: James Bottomley <JBottomley@Parallels.com>
2013-12-03epoll: drop EPOLLWAKEUP if PM_SLEEP is disabledAmit Pundir2-3/+13
Drop EPOLLWAKEUP from epoll events mask if CONFIG_PM_SLEEP is disabled. Signed-off-by: Amit Pundir <amit.pundir@linaro.org> Cc: John Stultz <john.stultz@linaro.org> Cc: Alexander Viro <viro@zeniv.linux.org.uk> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
2013-12-03cpufreq: fix garbage kobjects on errors during suspend/resumeBjørn Mork1-3/+0
This is effectively a revert of commit 5302c3fb2e62 ("cpufreq: Perform light-weight init/teardown during suspend/resume"), which enabled suspend/resume optimizations leaving the sysfs files in place. Errors during suspend/resume are not handled properly, leaving dead sysfs attributes in case of failures. There are are number of functions with special code for the "frozen" case, and all these need to also have special error handling. The problem is easy to demonstrate by making cpufreq_driver->init() or cpufreq_driver->get() fail during resume. The code is too complex for a simple fix, with split code paths in multiple blocks within a number of functions. It is therefore best to revert the patch enabling this code until the error handling is in place. Examples of problems resulting from resume errors: WARNING: CPU: 0 PID: 6055 at fs/sysfs/file.c:343 sysfs_open_file+0x77/0x212() missing sysfs attribute operations for kobject: (null) Modules linked in: [stripped as irrelevant] CPU: 0 PID: 6055 Comm: grep Tainted: G D 3.13.0-rc2 #153 Hardware name: LENOVO 2776LEG/2776LEG, BIOS 6EET55WW (3.15 ) 12/19/2011 0000000000000009 ffff8802327ebb78 ffffffff81380b0e 0000000000000006 ffff8802327ebbc8 ffff8802327ebbb8 ffffffff81038635 0000000000000000 ffffffff811823c7 ffff88021a19e688 ffff88021a19e688 ffff8802302f9310 Call Trace: [<ffffffff81380b0e>] dump_stack+0x55/0x76 [<ffffffff81038635>] warn_slowpath_common+0x7c/0x96 [<ffffffff811823c7>] ? sysfs_open_file+0x77/0x212 [<ffffffff810386e3>] warn_slowpath_fmt+0x41/0x43 [<ffffffff81182dec>] ? sysfs_get_active+0x6b/0x82 [<ffffffff81182382>] ? sysfs_open_file+0x32/0x212 [<ffffffff811823c7>] sysfs_open_file+0x77/0x212 [<ffffffff81182350>] ? sysfs_schedule_callback+0x1ac/0x1ac [<ffffffff81122562>] do_dentry_open+0x17c/0x257 [<ffffffff8112267e>] finish_open+0x41/0x4f [<ffffffff81130225>] do_last+0x80c/0x9ba [<ffffffff8112dbbd>] ? inode_permission+0x40/0x42 [<ffffffff81130606>] path_openat+0x233/0x4a1 [<ffffffff81130b7e>] do_filp_open+0x35/0x85 [<ffffffff8113b787>] ? __alloc_fd+0x172/0x184 [<ffffffff811232ea>] do_sys_open+0x6b/0xfa [<ffffffff811233a7>] SyS_openat+0xf/0x11 [<ffffffff8138c812>] system_call_fastpath+0x16/0x1b The failure to restore cpufreq devices on cancelled hibernation is not a new bug. It is caused by the ACPI _PPC call failing unless the hibernate is completed. This makes the acpi_cpufreq driver fail its init. Previously, the cpufreq device could be restored by offlining the cpu temporarily. And as a complete hibernation cycle would do this, it would be automatically restored most of the time. But after commit 5302c3fb2e62 the leftover sysfs attributes will block any device add action. Therefore offlining and onlining CPU 1 will no longer restore the cpufreq object, and a complete suspend/resume cycle will replace it with garbage. Fixes: 5302c3fb2e62 ("cpufreq: Perform light-weight init/teardown during suspend/resume") Cc: 3.12+ <stable@vger.kernel.org> # 3.12+ Signed-off-by: Bjørn Mork <bjorn@mork.no> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
2013-12-03drm/nv50/disp: min/max are reversed in nv50_crtc_gamma_set()Dan Carpenter1-1/+1
We should be taking the minimum here instead of the max. It could lead to a buffer overflow. Fixes: 438d99e3b175 ('drm/nvd0/disp: initial crtc object implementation') Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> a/drm/nv50_display.c b/drm/nv50_display.c index f8e66c08b11a..4e384a2f99c3 100644
2013-12-03drm/nouveau/sw: fix oops if gpu has its display block disabledBen Skeggs1-1/+1
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2013-12-03drm/nouveau: unreference fence after syncingBen Skeggs1-0/+1
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2013-12-03drm/nouveau/kms: send timestamp data for correct head in flip completion eventsMaarten Lankhorst1-1/+1
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2013-12-03drm/nouveau/clk: Add support for NVAA/NVACRoy Spliet4-2/+452
Signed-off-by: Roy Spliet <rspliet@eclipso.eu> Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2013-12-03drm/nouveau/fifo: Hook up pause and resume for NV50 and NV84+Roy Spliet2-0/+6
Signed-off-by: Roy Spliet <rspliet@eclipso.eu> Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2013-12-03drm/nv10/plane: some chipsets don't support NV12Ilia Mirkin1-2/+13
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu> Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2013-12-03drm/nv10/plane: add downscaling restrictionsIlia Mirkin1-1/+9
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu> Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2013-12-03drm/nv10/plane: fix format computationIlia Mirkin1-8/+9
Otherwise none of the format checks pass, since the width was still in 16.16 encoding. Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu> Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2013-12-03drm/nv04-nv30/clk: provide an empty domain listBen Skeggs1-1/+6
Reported-by: Ilia Mirkin <imirkin@alum.mit.edu> Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2013-12-03gpiolib: change a warning to debug message when failing to get gpioHeikki Krogerus1-1/+1
It's the drivers responsibility to react on failure to get the gpio descriptors and not the frameworks. Since there are some common peripherals that may or may not have certain pins connected to gpio lines, depending on the platform, printing the warning there may end up generating useless bug reports. Signed-off-by: Heikki Krogerus <heikki.krogerus@linux.intel.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
2013-12-03powerpc/gpio: Fix the wrong GPIO input data on MPC8572/MPC8536Liu Gang1-2/+6
For MPC8572/MPC8536, the status of GPIOs defined as output cannot be determined by reading GPDAT register, so the code use shadow data register instead. But the code may give the wrong status of GPIOs defined as input under some scenarios: 1. If some pins were configured as inputs and were asserted high before booting the kernel, the shadow data has been initialized with those pin values. 2. Some pins have been configured as output first and have been set to the high value, then reconfigured as input. The above cases will make the shadow data for those input pins to be set to high. Then reading the pin status will always return high even if the actual pin status is low. The code should eliminate the effects of the shadow data to the input pins, and the status of those pins should be read directly from GPDAT. Cc: stable@vger.kernel.org Acked-by: Scott Wood <scottwood@freescale.com> Acked-by: Anatolij Gustschin <agust@denx.de> Signed-off-by: Liu Gang <Gang.Liu@freescale.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
2013-12-03gpiolib: use platform GPIO mappings as fallbackAlexandre Courbot1-3/+13
For platforms that use device tree or ACPI as the standard way to look GPIOs up, allow the platform-defined GPIO mappings to be used as a fallback. This may be useful for platforms that need extra GPIOs mappings not defined by the firmware. Signed-off-by: Alexandre Courbot <acourbot@nvidia.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
2013-12-03Documentation: gpiolib: add 00-INDEX fileAlexandre Courbot1-0/+14
Give a short overview of the various GPIO documentation files. Signed-off-by: Alexandre Courbot <acourbot@nvidia.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
2013-12-03gpiolib: fix lookup of platform-mapped GPIOsAlexandre Courbot1-1/+1
A typo resulted in GPIO lookup failing unconditionally. Signed-off-by: Alexandre Courbot <acourbot@nvidia.com> Reported-by: Stephen Warren <swarren@wwwdotorg.org> Reviewed-by: Mika Westerberg <mika.westerberg@linux.intel.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
2013-12-03gpiolib: add missing declarationsAlexandre Courbot1-0/+3
Add declaration of 'struct of_phandle_args' to avoid the following warning: In file included from arch/arm/mach-tegra/board-paz00.c:21:0: include/linux/gpio/driver.h:102:17: warning: 'struct of_phandle_args' declared inside parameter list include/linux/gpio/driver.h:102:17: warning: its scope is only this definition or declaration, which is probably not what you want Also proactively add other definitions/includes that could be missing in other contexts. Signed-off-by: Alexandre Courbot <acourbot@nvidia.com> Reported-by: Stephen Warren <swarren@wwwdotorg.org> Reviewed-by: Mika Westerberg <mika.westerberg@linux.intel.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
2013-12-03sh-pfc: sh7372: Fix pin bias setupLaurent Pinchart1-1/+1
When computing the pin configuration register offset the bias setup code erroneously compares the pin number range with the loop index instead of the pin number. Fix it. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
2013-12-03sh-pfc: r8a7740: Fix pin bias setupLaurent Pinchart1-1/+1
When computing the pin configuration register offset the bias setup code erroneously compares the pin number range with the loop index instead of the pin number. Fix it. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
2013-12-03drm/tegra: return -EFAULT if copy_from_user() failsDan Carpenter1-11/+15
copy_from_user() returns the number of bytes remaining if it fails, but we want to return -EFAULT here. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Thierry Reding <treding@nvidia.com>
2013-12-03gpu: host1x: Fix a few sparse warningsThierry Reding1-2/+3
Include the bus.h header, so that various function declarations are visible in the source file that implements those functions. This keeps sparse from suggesting that they should be made static. Make the host1x_bus_type variable static since it isn't used globally. Finally replace the slightly unsafe dev_set_name(dev, name) by the more secure dev_set_name(dev, "%s", name). Signed-off-by: Thierry Reding <treding@nvidia.com>
2013-12-03drm/tegra: Force cast to __iomem to make sparse happyThierry Reding1-1/+1
The fbdev screen memory pointer is annotated __iomem, so cast the kernel virtual address to that address space to make the warning go away. Signed-off-by: Thierry Reding <treding@nvidia.com>
2013-12-03drm/tegra: Make tegra_drm_driver staticThierry Reding1-1/+1
There is no need to access it from other files now that the driver has been decoupled from host1x. Signed-off-by: Thierry Reding <treding@nvidia.com>
2013-12-03drm/tegra: Fix address space mismatchesThierry Reding1-4/+4
sparse complains because __user annotations aren't placed consistently. Signed-off-by: Thierry Reding <treding@nvidia.com>
2013-12-03drm/tegra: Tightly bind RGB output to DCThierry Reding1-4/+7
Previously the association to a DC was done via the encoder's .crtc field. That has the disadvantage that when an encoder is detached from its CRTC, that field is set to NULL, leading to situations where it is impossible to access the DC registers required by the RGB output. However, the coupling between DC and RGB output is really fixed on Tegra. While they can be detached logically in DRM, the RGB output can rely on the DC's existence. Signed-off-by: Thierry Reding <treding@nvidia.com>
2013-12-03drm/tegra: Make CRTC upcasting saferThierry Reding1-1/+1
When upcasting a NULL CRTC object, propagate the NULL pointer instead of some invalid pointer. This allows subsequent code to check that the cast object is valid. Signed-off-by: Thierry Reding <treding@nvidia.com>
2013-12-03ALSA: hda/realtek - Independent of model for HPKailang Yang1-10/+28
Create single model for HP. The headset jack module was difference between other chrome book. It need to manual control Mic jack detect. Chrome OS loaded driver by models. Remove old assigned fixup table from ALC269 fixup list entry. Signed-off-by: Kailang Yang <kailang@realtek.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-12-03ALSA: hda - Fix headset mic input after muted internal mic (Dell/Realtek)David Henningsson1-0/+2
By trial and error, I found this patch could work around an issue where the headset mic would stop working if you switch between the internal mic and the headset mic, and the internal mic was muted. It still takes a second or two before the headset mic actually starts working, but still better than nothing. Information update from Kailang: The verb was ADC digital mute(bit 6 default 1). Switch internal mic and headset mic will run alc_headset_mode_default. The coef index 0x11 will set to 0x0041. Because headset mode was fixed type. It doesn't need to run alc_determine_headset_type. So, the value still keep 0x0041. ADC was muted. BugLink: https://bugs.launchpad.net/bugs/1256840 Signed-off-by: David Henningsson <david.henningsson@canonical.com> Cc: <stable@vger.kernel.org> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-12-03dt: binding: reword PowerPC 8xxx GPIO documentationGerhard Sittig1-26/+40
re-format and re-word the device tree binding documentation for MPC8xxx and compatibles, reference the common document for interrupt controllers and remove outdated duplicate SoC specific information Cc: Mark Rutland <mark.rutland@arm.com> Cc: Rob Herring <rob.herring@calxeda.com> Cc: Pawel Moll <Pawel.Moll@arm.com> Cc: Arnd Bergmann <arnd@arndb.de> Cc: <devicetree@vger.kernel.org> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Gerhard Sittig <gsi@denx.de> Signed-off-by: Rob Herring <rob.herring@calxeda.com>
2013-12-03ARM: tegra: delete nvidia,tegra20-spi.txt bindingStephen Warren1-5/+0
This binding shouldn't exist; Tegra20 has two forms of SPI controller that are documented separately in nvidia,tegra20-sflash.txt and nvidia,tegra20-slink.txt. Signed-off-by: Stephen Warren <swarren@nvidia.com> Reviewed-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Rob Herring <rob.herring@calxeda.com>
2013-12-02USB: pl2303: fixed handling of CS5 settingColin Leitner1-16/+14
This patch fixes the CS5 setting on the PL2303 USB-to-serial devices. CS5 has a value of 0 and the CSIZE setting has been skipped altogether by the enclosing if. Tested on 3.11.6 and the scope shows the correct output after the fix has been applied. Tagged to be added to stable, because it fixes a user visible driver bug and is simple enough to backport easily. Signed-off-by: Colin Leitner <colin.leitner@gmail.com> Signed-off-by: Johan Hovold <jhovold@gmail.com> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-12-02USB: ftdi_sio: fixed handling of unsupported CSIZE settingColin Leitner1-13/+24
FTDI UARTs support only 7 or 8 data bits. Until now the ftdi_sio driver would only report this limitation for CS6 to dmesg and fail to reflect this fact to tcgetattr. This patch reverts the unsupported CSIZE setting and reports the fact with less severance to dmesg for both CS5 and CS6. To test the patch it's sufficient to call stty -F /dev/ttyUSB0 cs5 which will succeed without the patch and report an error with the patch applied. As an additional fix this patch ensures that the control request will always include a data bit size. Signed-off-by: Colin Leitner <colin.leitner@gmail.com> Signed-off-by: Johan Hovold <jhovold@gmail.com> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-12-02USB: mos7840: correct handling of CS5 settingColin Leitner1-16/+16
This patch removes an erroneous check of CSIZE, which made it impossible to set CS5. Compiles clean, but couldn't test against hardware. Signed-off-by: Colin Leitner <colin.leitner@gmail.com> Signed-off-by: Johan Hovold <jhovold@gmail.com> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-12-02USB: spcp8x5: correct handling of CS5 settingColin Leitner1-16/+14
This patch removes an erroneous check of CSIZE, which made it impossible to set CS5. Compiles clean, but couldn't test against hardware. Signed-off-by: Colin Leitner <colin.leitner@gmail.com> Signed-off-by: Johan Hovold <jhovold@gmail.com> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-12-02hwmon: ntc_thermistor: Fix typo (pullup-uV -> pullup-uv)Chanwoo Choi1-1/+1
This patch fix typo of property name from 'pullup-uV' to 'pullup-uv'. The ntc_thermistor.c use 'pullup-uv' when parsing dt data. Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> Reviewed-by: Jingoo Han <jg1.han@samsung.com> Acked-by: Naveen Krishna Chatradhi <ch.naveen@samsung.com> Reviewed-by: Tomasz Figa <t.figa@samsung.com> Signed-off-by: Rob Herring <rob.herring@calxeda.com>
2013-12-02of: add vendor prefix for GMTWei Ni1-0/+1
Adding Global Mixed-mode Technology Inc. to the list of devicetree vendor prefixes. Signed-off-by: Wei Ni <wni@nvidia.com> Acked-by: Stephen Warren <swarren@nvidia.com> Reviewed-by: Jean Delvare <khali@linux-fr.org> Signed-off-by: Rob Herring <rob.herring@calxeda.com>
2013-12-02clk: exynos: Fix typos in DT bindings documentationLaurent Pinchart4-4/+4
s/comptible/compatible/ Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Sachin Kamat <sachin.kamat@linaro.org> Signed-off-by: Rob Herring <rob.herring@calxeda.com>
2013-12-02of: Add vendor prefix for LG CorporationThierry Reding1-0/+1
Signed-off-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Rob Herring <rob.herring@calxeda.com>
2013-12-02Documentation: net: fsl-fec.txt: Add phy-supply entryFabio Estevam1-0/+2
phy-supply is an optional property of the fec driver, so add it to the binding documentation. Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> Signed-off-by: Rob Herring <rob.herring@calxeda.com>
2013-12-02ARM: dts: doc: Document missing binding for omap5-mpuSricharan R1-0/+8
The binding and support for omap5-mpu which has a cortex-a15 smp core, gic and integrated L2 cache has been existing for sometime. So Documenting the missing binding here. Cc: Benoit Cousson <bcousson@baylibre.com> Signed-off-by: Sricharan R <r.sricharan@ti.com> Signed-off-by: Rob Herring <rob.herring@calxeda.com>
2013-12-02dt-bindings: add ARMv8 PMU bindingRob Herring1-0/+1
Add missing "arm,armv8-pmuv3" compatible property for ARMv8 PMU. Signed-off-by: Rob Herring <rob.herring@calxeda.com> Cc: Will Deacon <will.deacon@arm.com> Cc: Pawel Moll <pawel.moll@arm.com> Acked-by: Mark Rutland <mark.rutland@arm.com> Cc: Ian Campbell <ijc+devicetree@hellion.org.uk>
2013-12-02MAINTAINERS: remove swarren from DT bindingsStephen Warren1-1/+0
I'm afraid I'm rather burned out w.r.t. DT bindings. As has probably been evident, I don't have and haven't made the time to review many recently. As such, remove myself from that MAINTAINERS entry. Signed-off-by: Stephen Warren <swarren@nvidia.com> Signed-off-by: Rob Herring <rob.herring@calxeda.com>
2013-12-02MAINTAINERS: Add Kumar to Device Tree Binding maintainers groupKumar Gala1-0/+1
I'm tossing my hat into the ring of maintainers/reviewers for device tree bindings based on history of dealing with DT on embedded PPC and starting work on ARM SoCs. Signed-off-by: Kumar Gala <galak@codeaurora.org> Acked-by: Pawel Moll <pawel.moll@arm.com> Cc: Mark Rutland <mark.rutland@arm.com> Acked-by: Stephen Warren <swarren@wwwdotorg.org> Cc: Ian Campbell <ian.campbell@citrix.com> Cc: Rob Herring <rob.herring@calxeda.com> Cc: Grant Likely <grant.likely@linaro.org> Cc: Olof Johansson <olof@lixom.net> Signed-off-by: Rob Herring <rob.herring@calxeda.com>
2013-12-02ima: properly free ima_template_entry structuresRoberto Sassu3-5/+19
The new templates management mechanism records information associated to an event into an array of 'ima_field_data' structures and makes it available through the 'template_data' field of the 'ima_template_entry' structure (the element of the measurements list created by IMA). Since 'ima_field_data' contains dynamically allocated data (which length varies depending on the data associated to a selected template field), it is not enough to just free the memory reserved for a 'ima_template_entry' structure if something goes wrong. This patch creates the new function ima_free_template_entry() which walks the array of 'ima_field_data' structures, frees the memory referenced by the 'data' pointer and finally the space reserved for the 'ima_template_entry' structure. Further, it replaces existing kfree() that have a pointer to an 'ima_template_entry' structure as argument with calls to the new function. Fixes: a71dc65: ima: switch to new template management mechanism Signed-off-by: Roberto Sassu <roberto.sassu@polito.it> Signed-off-by: Mimi Zohar <zohar@us.ibm.com>
2013-12-02ima: Do not free 'entry' before it is initializedChristoph Paasch1-1/+0
7bc5f447ce9d0 (ima: define new function ima_alloc_init_template() to API) moved the initialization of 'entry' in ima_add_boot_aggregate() a bit more below, after the if (ima_used_chip). So, 'entry' is not initialized while being inside this if-block. So, we should not attempt to free it. Found by Coverity (CID: 1131971) Fixes: 7bc5f447ce9d0 (ima: define new function ima_alloc_init_template() to API) Signed-off-by: Christoph Paasch <christoph.paasch@uclouvain.be> Signed-off-by: Mimi Zohar <zohar@us.ibm.com>
2013-12-02usb: wusbcore: fix deadlock in wusbhc_gtk_rekeyThomas Pugliese4-68/+62
When multiple wireless USB devices are connected and one of the devices disconnects, the host will distribute a new group key to the remaining devicese using wusbhc_gtk_rekey. wusbhc_gtk_rekey takes the wusbhc->mutex and holds it while it submits a URB to set the new key. This causes a deadlock in wa_urb_enqueue when it calls a device lookup helper function that takes the same lock. This patch changes wusbhc_gtk_rekey to submit a work item to set the GTK so that the URB is submitted without holding wusbhc->mutex. Signed-off-by: Thomas Pugliese <thomas.pugliese@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-12-02usb: wusbcore: do device lookup while holding the hc mutexThomas Pugliese1-18/+25
This patch modifies the device notification handler to not look up the wusb_dev object before it calls the lower-level handler routines since the wusbhc mutex is not held when calling those routines and the device could go away in the meantime. Instead, let the individual notification handlers get the device ptr if they need to after they have taken the mutex. Signed-off-by: Thomas Pugliese <thomas.pugliese@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-12-02usb: wusbcore: send keepalives to unauthenticated devicesThomas Pugliese1-4/+1
This patch modifies the WUSB device disconnect timer code to send keepalives to all connected devices even if they are not authenticated. This fixes a problem where unauthenticated devices that lose their connection before they are authenticated will stay in the device tree forever. More importantly, devices in this situation will never relinquish their port on the root hub so eventually all root ports will be taken up and no other devices can connect. A comment in the existing code states that there are some devices that may not respond to keepalives if they have not been authenticated. That comment is about 5 years old and I don't know of any WUSB devices that act that way. Either way, any buggy devices that may still be around will continue to work as long as they can transition to the authenticated state within the WUSB LOA timeout of 4s, which is not unreasonable to expect. Signed-off-by: Thomas Pugliese <thomas.pugliese@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-12-02drm/radeon: fix VGT_GS_INSTANCE_CNT registerDave Airlie3-3/+4
This register was incorrect for evergreen and cayman. Signed-off-by: Dave Airlie <airlied@redhat.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2013-12-02drm/radeon: Fix a typo in Cayman and Evergreen registersAlexandre Demers2-2/+2
According to documentation, 0x00008A60 should be PA_SU_LINE_STIPPLE_VALUE. Signed-off-by: Alexandre Demers <alexandre.f.demers@gmail.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2013-12-02drm/radeon/dpm: simplify state adjust logic for NIAlex Deucher1-17/+11
This is based on a similar patch from Alexandre Demers. While fixing up some warnings with that patch I saw some additional cleanups that could be applied. This patch simplifies the logic for patching the power state. Signed-off-by: Alex Deucher <alexander.deucher@amd.com> Cc: Alexandre Demers <alexandre.f.demers@gmail.com>
2013-12-02USB: option: support new huawei devicesFangxiaozhi (Franko)1-0/+24
Add new supporting declarations to option.c, to support Huawei new devices with new bInterfaceProtocol value. Signed-off-by: fangxiaozhi <huananhu@huawei.com> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-12-02USB: serial: option: blacklist interface 1 for Huawei E173s-6Gustavo Zacarias1-0/+3
Interface 1 on this device isn't for option to bind to otherwise an oops on usb_wwan with log flooding will happen when accessing the port: tty_release: ttyUSB1: read/write wait queue active! It doesn't seem to respond to QMI if it's added to qmi_wwan so don't add it there - it's likely used by the card reader. Signed-off-by: Gustavo Zacarias <gustavo@zacarias.com.ar> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-12-02drm/radeon: add radeon_vm_bo_update trace pointChristian König4-12/+32
Also rename the function to better reflect what it is doing. agd5f: fix argument size warning Signed-off-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2013-12-02drm/radeon: add VMID allocation trace pointChristian König2-0/+17
Signed-off-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2013-12-02drm/radeon/dpm: Convert to use devm_hwmon_register_with_groupsGuenter Roeck1-37/+12
Simplify the code and fix race condition seen because attribute files were created after hwmon device registration. Signed-off-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2013-12-02drm/radeon: program DCE2 audio dto just like DCE3Alex Deucher1-6/+2
Seems to work like the DCE3 version despite what the register spec says. bug: https://bugs.freedesktop.org/show_bug.cgi?id=71975 Signed-off-by: Alex Deucher <alexander.deucher@amd.com> Cc: stable@vger.kernel.org
2013-12-02drm/radeon: fix typo in fetching mpll paramsAlex Deucher1-1/+1
Copy-paste typo. Value should be 0-2, not 0-1. Noticed-by: Sylvain BERTRAND <sylware@legeek.net> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> Cc: stable@vger.kernel.org
2013-12-02Merge tag 'for-usb-linus-2013-12-02' of ↵Greg Kroah-Hartman2-2/+54
git://git.kernel.org/pub/scm/linux/kernel/git/sarah/xhci into usb-linus Sarah writes: xhci: Regression fix for 3.13. Hi Greg, Here's one bug fix for 3.13. usb-net added support for bulk scatter-gather in 3.12, and it triggered a bug in the xHCI driver. This bug causes xHCI hosts to send an unexpected short transfer, which will cause the USB ethernet device to stop sending packets. The patch is marked for the 3.12 stable kernel. It's a long standing bug, but the usb-net drivers are the first to trigger it. The only other driver that does bulk scatter-gather (usb-storage) will not trigger this bug. I'm not sure what the effect of the no-op TRBs will be on various xHCI host controllers, so I would only like to be conservative and only queue it for 3.13 and 3.12 stable. Please queue this for 3.13. Sarah Sharp
2013-12-02Fix build failure for gp2ap020a00f.cRussell King - ARM Linux1-0/+1
drivers/built-in.o: In function `gp2ap020a00f_thresh_event_handler': powercap_sys.c:(.text+0x15f90c): undefined reference to `irq_work_queue' make[1]: *** [vmlinux] Error 1 make[1]: Target `uImage' not remade because of errors. make: *** [sub-make] Error 2 make: Target `uImage' not remade because of errors. You need the IRQ work support, but GP2AP020A00F is not selecting this symbol. Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> Signed-off-by: Jonathan Cameron <jic23@kernel.org>
2013-12-02iio: hid-sensors: Fix power and report stateSrinivas Pandruvada3-14/+27
In the original HID sensor hub firmwares all Named array enums were to 0-based. But the most recent hub implemented as 1-based, because of the implementation by one of the major OS vendor. Using logical minimum for the field as the base of enum. So we add logical minimum to the selector values before setting those fields. Some sensor hub FWs already changed logical minimum from 0 to 1 to reflect this and hope every other vendor will follow. There is no easy way to add a common HID quirk for NAry elements, even if the standard specifies these field as NAry, the collection used to describe selectors is still just "logical". Signed-off-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org>
2013-12-02HID: hid-sensor-hub: Add logical min and maxSrinivas Pandruvada2-12/+10
Exporting logical minimum and maximum of HID fields as part of the hid sensor attribute info. This can be used for range checking and to calculate enumeration base for NAry fields of HID sensor hub. Signed-off-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org>
2013-12-02Merge branch 'leds-fixes-for-3.13' of ↵Linus Torvalds1-27/+26
git://git.kernel.org/pub/scm/linux/kernel/git/cooloney/linux-leds Pull LED subsystem bugfix from Bryan Wu. * 'leds-fixes-for-3.13' of git://git.kernel.org/pub/scm/linux/kernel/git/cooloney/linux-leds: leds: pwm: Fix for deferred probe in DT booted mode
2013-12-02usb: xhci: Link TRB must not occur within a USB payload burstDavid Laight2-2/+54
Section 4.11.7.1 of rev 1.0 of the xhci specification states that a link TRB can only occur at a boundary between underlying USB frames (512 bytes for high speed devices). If this isn't done the USB frames aren't formatted correctly and, for example, the USB3 ethernet ax88179_178a card will stop sending (while still receiving) when running a netperf tcp transmit test with (say) and 8k buffer. This should be a candidate for stable, the ax88179_178a driver defaults to gso and tso enabled so it passes a lot of fragmented skb to the USB stack. Notes from Sarah: Discussion: http://marc.info/?l=linux-usb&m=138384509604981&w=2 This patch fixes a long-standing xHCI driver bug that was revealed by a change in 3.12 in the usb-net driver. Commit 638c5115a794981441246fa8fa5d95c1875af5ba "USBNET: support DMA SG" added support to use bulk endpoint scatter-gather (urb->sg). Only the USB ethernet drivers trigger this bug, because the mass storage driver sends sg list entries in page-sized chunks. This patch only fixes the issue for bulk endpoint scatter-gather. The problem will still occur for periodic endpoints, because hosts will interpret no-op transfers as a request to skip a service interval, which is not what we want. Luckily, the USB core isn't set up for scatter-gather on isochronous endpoints, and no USB drivers use scatter-gather for interrupt endpoints. Document this known limitation so that developers won't try to use urb->sg for interrupt endpoints until this issue is fixed. The more comprehensive fix would be to allow link TRBs in the middle of the endpoint ring and revert this patch, but that fix would touch too much code to be allowed in for stable. This patch should be backported to kernels as old as 3.12, that contain the commit 638c5115a794981441246fa8fa5d95c1875af5ba "USBNET: support DMA SG". Without this patch, the USB network device gets wedged, and stops sending packets. Mark Lord confirms this patch fixes the regression: http://marc.info/?l=linux-netdev&m=138487107625966&w=2 Signed-off-by: David Laight <david.laight@aculab.com> Signed-off-by: Sarah Sharp <sarah.a.sharp@linux.intel.com> Tested-by: Mark Lord <mlord@pobox.com> Cc: stable@vger.kernel.org
2013-12-02leds: pwm: Fix for deferred probe in DT booted modePeter Ujfalusi1-27/+26
We need to make sure that the error code from devm_of_pwm_get() is the one the module returns in case of failure. Restructure the code to make this possible for DT booted case. With this patch the driver can ask for deferred probing when the board is booted with DT. Fixes for example omap4-sdp board's keyboard backlight led. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Bryan Wu <cooloney@gmail.com>
2013-12-02uio: we cannot mmap unaligned page contentsLinus Torvalds1-0/+2
In commit 7314e613d5ff ("Fix a few incorrectly checked [io_]remap_pfn_range() calls") the uio driver started more properly checking the passed-in user mapping arguments against the size of the actual uio driver data. That in turn exposed that some driver authors apparently didn't realize that mmap can only work on a page granularity, and had tried to use it with smaller mappings, with the new size check catching that out. So since it's not just the user mmap() arguments that can be confused, make the uio mmap code also verify that the uio driver has the memory allocated at page boundaries in order for mmap to work. If the device memory isn't properly aligned, we return [ENODEV] The fildes argument refers to a file whose type is not supported by mmap(). as per the open group documentation on mmap. Reported-by: Holger Brunck <holger.brunck@keymile.com> Acked-by: Greg KH <gregkh@linuxfoundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2013-12-02ARM: dts: Fix the name of supplies for smsc911x shared by OMAPFlorian Vaussard1-2/+2
drivers/net/ethernet/smsc/smsc911x.c is expecting supplies named "vdd33a" and "vddvario". Currently the shared DTS file provides "vmmc" and "vmmc_aux", and the supply lookup will fail: smsc911x 2c000000.ethernet: Looking up vdd33a-supply from device tree smsc911x 2c000000.ethernet: Looking up vdd33a-supply property in node /ocp/gpmc@6e000000/ethernet@gpmc failed smsc911x 2c000000.ethernet: Looking up vddvario-supply from device tree smsc911x 2c000000.ethernet: Looking up vddvario-supply property in node /ocp/gpmc@6e000000/ethernet@gpmc failed Fix it! Looks like commmit 6b2978ac40e4 (ARM: dts: Shared file for omap GPMC connected smsc911x) made the problem more visible by moving the smc911x configuration from the omap3-igep0020.dts file to the generic file. But it seems we've had this problem since commit d72b4415011e (ARM: dts: omap3-igep0020: Add SMSC911x LAN chip support). Tested on OMAP3 Overo platform. Signed-off-by: Florian Vaussard <florian.vaussard@epfl.ch> [tony@atomide.com: updated comments for the commits causing the problem] Signed-off-by: Tony Lindgren <tony@atomide.com>
2013-12-02ARM: OMAP2+: Powerdomain: Fix unchecked dereference of arch_pwrdmRajendra Nayak1-1/+2
Commit 'cd8abed' "ARM: OMAP2+: Powerdomain: Remove the need to always have a voltdm associated to a pwrdm" leads to the following Smatch complaint: arch/arm/mach-omap2/powerdomain.c:131 _pwrdm_register() error: we previously assumed 'arch_pwrdm' could be null (see line 105) So, fix the unchecked dereference of arch_pwrdm. Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Acked-by: Nishanth Menon <nm@ti.com> Signed-off-by: Rajendra Nayak <rnayak@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
2013-12-02ARM: dts: omap3-beagle: Add omap-twl4030 audio supportJarkko Nikula1-0/+14
This adds typical McBSP2-TWL4030 audio description to the legacy Beagle Board. Signed-off-by: Jarkko Nikula <jarkko.nikula@bitmer.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
2013-12-02ARM: dts: omap4-sdp: Fix pin muxing for wl12xxBalaji T K1-6/+6
Mux mode for wlan/sdmmc5 should be MODE0 in pinmux_wl12xx_pins and Enable Pull up on sdmmc5_clk to detect SDIO card. This fixes WLAN on omap4-sdp that got broken in v3.10 when we moved omap4 to boot using device tree only as I did not have the WL12XX card in my omap4 SDP to test with. The commit that attempted to make WL12XX working on omap4 SDP was 775d2418f309 (ARM: dts: Fix muxing and regulator for wl12xx on the SDIO bus for blaze). Signed-off-by: Balaji T K <balajitk@ti.com> [tony@atomide.com: updated comments for the regression] Signed-off-by: Tony Lindgren <tony@atomide.com>
2013-12-02ARM: dts: omap4-panda-common: Fix pin muxing for wl12xxBalaji T K1-10/+10
pin mux wl12xx_gpio and wl12xx_pins should be part of omap4_pmx_core and not omap4_pmx_wkup. So, move wl12xx_* to omap4_pmx_core. Fix the following error message: pinctrl-single 4a31e040.pinmux: mux offset out of range: 0x38 (0x38) pinctrl-single 4a31e040.pinmux: could not add functions for pinmux_wl12xx_pins 56x SDIO card is not detected after moving pin mux to omap4_pmx_core since sdmmc5_clk pull is disabled. Enable Pull up on sdmmc5_clk to detect SDIO card. This fixes a regression where WLAN did not work after a warm reset or after one up/down cycle that happened when we move omap4 to boot using device tree only. For reference, the kernel bug is described at: https://bugzilla.kernel.org/show_bug.cgi?id=63821 Cc: stable@vger.kernel.org # v3.10+ Signed-off-by: Balaji T K <balajitk@ti.com> [tony@atomide.com: update comments to describe the regression] Signed-off-by: Tony Lindgren <tony@atomide.com>
2013-12-02[SCSI] enclosure: fix WARN_ON in dual path device removingJames Bottomley1-0/+7
Bug report from: wenxiong@linux.vnet.ibm.com The issue is happened in dual controller configuration. We got the sysfs warnings when rmmod the ipr module. enclosure_unregister() in drivers/msic/enclosure.c, call device_unregister() for each componment deivce, device_unregister() ->device_del()->kobject_del() ->sysfs_remove_dir(). In sysfs_remove_dir(), set kobj->sd = NULL. For each componment device, enclosure_component_release()->enclosure_remove_links()->sysfs_remove_link() in which checking kobj->sd again, it has been set as NULL when doing device_unregister. So we saw all these sysfs WARNING. Tested-by: wenxiong@linux.vnet.ibm.com Cc: stable@vger.kernel.org Signed-off-by: James Bottomley <JBottomley@Parallels.com>
2013-12-02[SCSI] pm80xx: Tasklets synchronization fix.Nikith Ganigarakoppal2-41/+58
When multiple vectors are used, the vector variable is over written, resulting in unhandled operation for those vectors. This fix prevents the problem by maitaining HBA instance and vector values for each irq. [jejb: checkpatch fixes] Signed-off-by: Nikith.Ganigarakoppal@pmcs.com Signed-off-by: Anandkumar.Santhanam@pmcs.com Reviewed-by: Jack Wang <jinpu.wang@profitbricks.com> Signed-off-by: James Bottomley <JBottomley@Parallels.com>
2013-12-02[SCSI] pm80xx: Resetting the phy state.Nikith Ganigarakoppal4-0/+10
Setting the phy state for hard reset response. After sending hard reset for a device ,phy down event sets the phy state to zero but for phy up event it will not set the phy state again.This will cause problem to successive hard resets. Signed-off-by: Nikith.Ganigarakoppal@pmcs.com Signed-off-by: Anandkumar.Santhanam@pmcs.com Reviewed-by: Jack Wang <jinpu.wang@profitbricks.com> Signed-off-by: James Bottomley <JBottomley@Parallels.com>
2013-12-02[SCSI] pm80xx: Fix for direct attached device.Nikith Ganigarakoppal1-1/+3
In case of direct attached SATA device delay is not enough. It will give crash for set device state command response and wait_for_completion is the best solution for this. Signed-off-by: Nikith.Ganigarakoppal@pmcs.com Signed-off-by: Anandkumar.Santhanam@pmcs.com Reviewed-by: Jack Wang <jinpu.wang@profitbricks.com> Signed-off-by: James Bottomley <JBottomley@Parallels.com>
2013-12-02[SCSI] pm80xx: Module author additionNikith Ganigarakoppal1-0/+1
Signed-off-by: Nikith.Ganigarakoppal@pmcs.com Signed-off-by: Anandkumar.Santhanam@pmcs.com Reviewed-by: Jack Wang <jinpu.wang@profitbricks.com> Signed-off-by: James Bottomley <JBottomley@Parallels.com>
2013-12-02Merge branch 'irq-urgent-for-linus' of ↵Linus Torvalds3-6/+7
git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull irq fixes from Thomas Gleixner: - Correction of fuzzy and fragile IRQ_RETVAL macro - IRQ related resume fix affecting only XEN - ARM/GIC fix for chained GIC controllers * 'irq-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: irqchip: Gic: fix boot for chained gics irq: Enable all irqs unconditionally in irq_resume genirq: Correct fuzzy and fragile IRQ_RETVAL() definition
2013-12-02Merge branch 'sched-urgent-for-linus' of ↵Linus Torvalds4-11/+29
git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull scheduler fixes from Ingo Molnar: "Various smaller fixlets, all over the place" * 'sched-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: sched/doc: Fix generation of device-drivers sched: Expose preempt_schedule_irq() sched: Fix a trivial typo in comments sched: Remove unused variable in 'struct sched_domain' sched: Avoid NULL dereference on sd_busy sched: Check sched_domain before computing group power MAINTAINERS: Update file patterns in the lockdep and scheduler entries
2013-12-02Merge branch 'perf-urgent-for-linus' of ↵Linus Torvalds9-20/+76
git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull perf fixes from Ingo Molnar: "Misc kernel and tooling fixes" * 'perf-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: tools lib traceevent: Fix conversion of pointer to integer of different size perf/trace: Properly use u64 to hold event_id perf: Remove fragile swevent hlist optimization ftrace, perf: Avoid infinite event generation loop tools lib traceevent: Fix use of multiple options in processing field perf header: Fix possible memory leaks in process_group_desc() perf header: Fix bogus group name perf tools: Tag thread comm as overriden
2013-12-02Merge tag 'stable/for-linus-3.13-rc2-tag' of ↵Linus Torvalds3-4/+12
git://git.kernel.org/pub/scm/linux/kernel/git/xen/tip Pull Xen bug-fixes from Konrad Rzeszutek Wilk: "Fixes to patches that went in this merge window along with a latent bug: - Fix lazy flushing in case m2p override fails. - Fix module compile issues with ARM/Xen - Add missing call to DMA map page for Xen SWIOTLB for ARM" * tag 'stable/for-linus-3.13-rc2-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/xen/tip: xen/gnttab: leave lazy MMU mode in the case of a m2p override failure xen/arm: p2m_init and p2m_lock should be static arm/xen: Export phys_to_mach to fix Xen module link errors swiotlb-xen: add missing xen_dma_map_page call
2013-12-02Merge tag 'spi-v3.13-rc2' of ↵Linus Torvalds9-12/+31
git://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi Pull spi fixes from Mark Brown: "A smattering of driver specific fixes here, including a bunch for a long standing common pattern in the error handling paths, and a fix for an embarrassing thinko in the new devm master registration code" * tag 'spi-v3.13-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi: spi/pxa2xx: Restore private register bits. spi/qspi: Fix qspi remove path. spi/qspi: cleanup pm_runtime error check. spi/qspi: set correct platform drvdata in ti_qspi_probe() spi/pxa2xx: add new ACPI IDs spi: core: invert success test in devm_spi_register_master spi: spi-mxs: fix reference leak to master in mxs_spi_remove() spi: bcm63xx: fix reference leak to master in bcm63xx_spi_remove() spi: txx9: fix reference leak to master in txx9spi_remove() spi: mpc512x: fix reference leak to master in mpc512x_psc_spi_do_remove() spi: rspi: use platform drvdata correctly in rspi_remove() spi: bcm2835: fix reference leak to master in bcm2835_spi_remove()
2013-12-02Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/netLinus Torvalds70-344/+491
Pull networking updates from David Miller: "Here is a pile of bug fixes that accumulated while I was in Europe" 1) In fixing kernel leaks to userspace during copying of socket addresses, we broke a case that used to work, namely the user providing a buffer larger than the in-kernel generic socket address structure. This broke Ruby amongst other things. Fix from Dan Carpenter. 2) Fix regression added by byte queue limit support in 8139cp driver, from Yang Yingliang. 3) The addition of MSG_SENDPAGE_NOTLAST buggered up a few sendpage implementations, they should just treat it the same as MSG_MORE. Fix from Richard Weinberger and Shawn Landden. 4) Handle icmpv4 errors received on ipv6 SIT tunnels correctly, from Oussama Ghorbel. In particular we should send an ICMPv6 unreachable in such situations. 5) Fix some regressions in the recent genetlink fixes, in particular get the pmcraid driver to use the new safer interfaces correctly. From Johannes Berg. 6) macvtap was converted to use a per-cpu set of statistics, but some code was still bumping tx_dropped elsewhere. From Jason Wang. 7) Fix build failure of xen-netback due to missing include on some architectures, from Andy Whitecroft. 8) macvtap double counts received packets in statistics, fix from Vlad Yasevich. 9) Fix various cases of using *_STATS_BH() when *_STATS() is more appropriate. From Eric Dumazet and Hannes Frederic Sowa. 10) Pktgen ipsec mode doesn't update the ipv4 header length and checksum properly after encapsulation. Fix from Fan Du. * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net: (61 commits) net/mlx4_en: Remove selftest TX queues empty condition {pktgen, xfrm} Update IPv4 header total len and checksum after tranformation virtio_net: make all RX paths handle erors consistently virtio_net: fix error handling for mergeable buffers virtio_net: Fixed a trivial typo (fitler --> filter) netem: fix gemodel loss generator netem: fix loss 4 state model netem: missing break in ge loss generator net/hsr: Support iproute print_opt ('ip -details ...') net/hsr: Very small fix of comment style. MAINTAINERS: Added net/hsr/ maintainer ipv6: fix possible seqlock deadlock in ip6_finish_output2 ixgbe: Make ixgbe_identify_qsfp_module_generic static ixgbe: turn NETIF_F_HW_L2FW_DOFFLOAD off by default ixgbe: ixgbe_fwd_ring_down needs to be static e1000: fix possible reset_task running after adapter down e1000: fix lockdep warning in e1000_reset_task e1000: prevent oops when adapter is being closed and reset simultaneously igb: Fixed Wake On LAN support inet: fix possible seqlock deadlocks ...
2013-12-02vfs: fix subtle use-after-free of pipe_inode_infoLinus Torvalds1-20/+19
The pipe code was trying (and failing) to be very careful about freeing the pipe info only after the last access, with a pattern like: spin_lock(&inode->i_lock); if (!--pipe->files) { inode->i_pipe = NULL; kill = 1; } spin_unlock(&inode->i_lock); __pipe_unlock(pipe); if (kill) free_pipe_info(pipe); where the final freeing is done last. HOWEVER. The above is actually broken, because while the freeing is done at the end, if we have two racing processes releasing the pipe inode info, the one that *doesn't* free it will decrement the ->files count, and unlock the inode i_lock, but then still use the "pipe_inode_info" afterwards when it does the "__pipe_unlock(pipe)". This is *very* hard to trigger in practice, since the race window is very small, and adding debug options seems to just hide it by slowing things down. Simon originally reported this way back in July as an Oops in kmem_cache_allocate due to a single bit corruption (due to the final "spin_unlock(pipe->mutex.wait_lock)" incrementing a field in a different allocation that had re-used the free'd pipe-info), it's taken this long to figure out. Since the 'pipe->files' accesses aren't even protected by the pipe lock (we very much use the inode lock for that), the simple solution is to just drop the pipe lock early. And since there were two users of this pattern, create a helper function for it. Introduced commit ba5bb147330a ("pipe: take allocation and freeing of pipe_inode_info out of ->i_mutex"). Reported-by: Simon Kirby <sim@hostway.ca> Reported-by: Ian Applegate <ia@cloudflare.com> Acked-by: Al Viro <viro@zeniv.linux.org.uk> Cc: stable@kernel.org # v3.10+ Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2013-12-02ALSA: hda - Use always amps for auto-mute on AD1986A codecTakashi Iwai1-0/+3
It seems that AD1986A cannot manage the dynamic pin on/off for auto-muting, but rather gets confused. Since each output has own amp, let's use it instead. Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=64971 Cc: <stable@vger.kernel.org> [v3.11+] Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-12-02ALSA: hda/analog - Handle inverted EAPD properly in vmaster hookTakashi Iwai1-0/+2
ad_vmaster_eapd_hook() needs to handle the inverted EAPD case properly, too. Otherwise the output gets broken on Lenovo N100 with AD1986A codec. Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=64971 Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-12-02ALSA: hda - Another fixup for ASUS laptop with ALC660 codecTakashi Iwai1-0/+1
ASUS Z35HL laptop also needs the very same fix as the previous one that was applied to ASUS W7J. Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=66231 Cc: <stable@vger.kernel.org> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-12-02ALSA: atmel: Fix possible array overflowTakashi Iwai1-1/+2
The static checker found a possible array overflow in atmel/abdac.c: static checker warning: "sound/atmel/abdac.c:373 set_sample_rates() error: buffer overflow 'dac->rates' 6 <= 6" This patch papers over the buggy point, by ensuring that dac->rates[] update not overflowing the actual array size. Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-12-02drm/exynos: release unhandled page flip events at postclose.Inki Dae1-13/+22
This patch resolves a dead lock issue that could be incurred when exynos_drm_crtc_dpms function was called. The exynos_drm_crtc_dpms function waits for the completion of pended page flip events. However, preclose callback - this releases all unhandled page flip events - is called prior to the exynos_drm_crtc_dpms function call when drm is closed. So at this time, this will make the exynos_drm_crtc_dpms to wait infiniately for the completion of the page flip events. This patch releases the unhandled page flip events at postclose instead of preclose so that exynos_drm_crtc_dpms function can be waked up. Changelog v2: - fix a memory leak when drm is closed. . it has a memory leak when a requeste page flip is handled after drm_events_release() is called and before drm_fb_release() is called. At this time, a drm_pending_event will not be freed. So also this chage releases the drm_pending_event at postclose(). And it calls drm_vblank_put() for pair if there is any unhandled page flip event. Signed-off-by: Inki Dae <inki.dae@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
2013-12-02drm/exynos: Fix trivial typo in exynos_drm_fimd.cSachin Kamat1-1/+1
Fixed a trivial typo. Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> Signed-off-by: Inki Dae <inki.dae@samsung.com>
2013-12-02ARM: at91: fixed unresolved symbol "at91_pm_set_standby" when built without ↵Brent Taylor1-0/+4
CONFIG_PM If CONFIG_PM is not defined, then arch/arm/mach-at91/pm.c is not compiled in. This patch creates an inline function that does nothing if CONFIG_PM is not defined. Signed-off-by: Brent Taylor <motobud@gmail.com> Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com>
2013-12-02ARM: at91: add usart3 alias to dtsiNicolas Ferre1-0/+4
Alias was missing for SoC of the at91sam9x5 familly that embed USART3. Reported-by: Jiri Prchal <jiri.prchal@aksignal.cz> [b.brezillon@overkiz.com: advised to place changes in at91sam9x5_usart3.dtsi] Acked-by: Boris BREZILLON <b.brezillon@overkiz.com> Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com>
2013-12-02ARM: at91: sama5d3: reduce TWI internal clock frequencyLudovic Desroches1-3/+3
With some devices, transfer hangs during I2C frame transmission. This issue disappears when reducing the internal frequency of the TWI IP. Even if it is indicated that internal clock max frequency is 66MHz, it seems we have oversampling on I2C signals making TWI believe that a transfer in progress is done. This fix has no impact on the I2C bus frequency. Cc: <stable@vger.kernel.org> #3.10+ Signed-off-by: Ludovic Desroches <ludovic.desroches@atmel.com> Acked-by: Wolfram Sang <wsa@the-dreams.de> Acked-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com>