]> git.kernelconcepts.de Git - karo-tx-linux.git/log
karo-tx-linux.git
12 years agoMerge remote-tracking branch 'm68k/for-next'
Stephen Rothwell [Thu, 25 Aug 2011 01:17:08 +0000 (11:17 +1000)]
Merge remote-tracking branch 'm68k/for-next'

12 years agoMerge remote-tracking branch 'ia64/test'
Stephen Rothwell [Thu, 25 Aug 2011 01:15:55 +0000 (11:15 +1000)]
Merge remote-tracking branch 'ia64/test'

12 years agoMerge remote-tracking branch 'cris/for-next'
Stephen Rothwell [Thu, 25 Aug 2011 01:14:38 +0000 (11:14 +1000)]
Merge remote-tracking branch 'cris/for-next'

12 years agoMerge remote-tracking branch 'blackfin/for-linus'
Stephen Rothwell [Thu, 25 Aug 2011 01:13:27 +0000 (11:13 +1000)]
Merge remote-tracking branch 'blackfin/for-linus'

12 years agoMerge remote-tracking branch 's5p/for-next'
Stephen Rothwell [Thu, 25 Aug 2011 01:12:11 +0000 (11:12 +1000)]
Merge remote-tracking branch 's5p/for-next'

12 years agoMerge remote-tracking branch 'msm/for-next'
Stephen Rothwell [Thu, 25 Aug 2011 01:10:55 +0000 (11:10 +1000)]
Merge remote-tracking branch 'msm/for-next'

Conflicts:
arch/arm/mach-msm/io.c

12 years agoMerge remote-tracking branch 'arm-lpae/for-next'
Stephen Rothwell [Thu, 25 Aug 2011 01:09:35 +0000 (11:09 +1000)]
Merge remote-tracking branch 'arm-lpae/for-next'

Conflicts:
arch/arm/include/asm/pgalloc.h
arch/arm/include/asm/pgtable.h
arch/arm/include/asm/tlb.h
arch/arm/kernel/head.S
arch/arm/mm/dma-mapping.c
arch/arm/mm/mmu.c

12 years agoMerge remote-tracking branch 'arm/for-next'
Stephen Rothwell [Thu, 25 Aug 2011 01:00:53 +0000 (11:00 +1000)]
Merge remote-tracking branch 'arm/for-next'

12 years agoMerge remote-tracking branch 'fbdev-current/fbdev-fixes-for-linus'
Stephen Rothwell [Thu, 25 Aug 2011 00:58:47 +0000 (10:58 +1000)]
Merge remote-tracking branch 'fbdev-current/fbdev-fixes-for-linus'

12 years agoMerge remote-tracking branch 'rmobile-current/rmobile-fixes-for-linus'
Stephen Rothwell [Thu, 25 Aug 2011 00:58:45 +0000 (10:58 +1000)]
Merge remote-tracking branch 'rmobile-current/rmobile-fixes-for-linus'

12 years agoMerge remote-tracking branch 'sh-current/sh-fixes-for-linus'
Stephen Rothwell [Thu, 25 Aug 2011 00:58:44 +0000 (10:58 +1000)]
Merge remote-tracking branch 'sh-current/sh-fixes-for-linus'

12 years agoMerge remote-tracking branch 'staging.current/staging-linus'
Stephen Rothwell [Thu, 25 Aug 2011 00:58:33 +0000 (10:58 +1000)]
Merge remote-tracking branch 'staging.current/staging-linus'

12 years agoMerge remote-tracking branch 'usb.current/usb-linus'
Stephen Rothwell [Thu, 25 Aug 2011 00:58:32 +0000 (10:58 +1000)]
Merge remote-tracking branch 'usb.current/usb-linus'

12 years agoMerge remote-tracking branch 'tty.current/tty-linus'
Stephen Rothwell [Thu, 25 Aug 2011 00:58:31 +0000 (10:58 +1000)]
Merge remote-tracking branch 'tty.current/tty-linus'

12 years agoMerge remote-tracking branch 'driver-core.current/driver-core-linus'
Stephen Rothwell [Thu, 25 Aug 2011 00:58:30 +0000 (10:58 +1000)]
Merge remote-tracking branch 'driver-core.current/driver-core-linus'

12 years agoMerge remote-tracking branch 'wireless-current/master'
Stephen Rothwell [Thu, 25 Aug 2011 00:58:28 +0000 (10:58 +1000)]
Merge remote-tracking branch 'wireless-current/master'

12 years agoMerge remote-tracking branch 'scsi-rc-fixes/master'
Stephen Rothwell [Thu, 25 Aug 2011 00:58:27 +0000 (10:58 +1000)]
Merge remote-tracking branch 'scsi-rc-fixes/master'

12 years agofirmware loader: allow builtin firmware load even if usermodehelper is disabled
Linus Torvalds [Wed, 24 Aug 2011 22:55:30 +0000 (15:55 -0700)]
firmware loader: allow builtin firmware load even if usermodehelper is disabled

In commit a144c6a6c924 ("PM: Print a warning if firmware is requested
when tasks are frozen") we not only printed a warning if somebody tried
to load the firmware when tasks are frozen - we also failed the load.

But that check was done before the check for built-in firmware, and then
when we disallowed usermode helpers during bootup (commit 288d5abec831:
"Boot up with usermodehelper disabled"), that actually means that
built-in modules can no longer load their firmware even if the firmware
is built in too.  Which used to work, and some people depended on it for
the R100 driver.

So move the test for usermodehelper_is_disabled() down, to after
checking the built-in firmware.

This should fix:

https://bugzilla.kernel.org/show_bug.cgi?id=40952

Reported-by: James Cloos <cloos@hjcloos.com>
Bisected-by: Elimar Riesebieter <riesebie@lxtec.de>
Cc: Michel Dänzer <michel@daenzer.net>
Cc: Rafael Wysocki <rjw@sisk.pl>
Cc: Greg Kroah-Hartman <gregkh@suse.de>
Cc: Valdis Kletnieks <valdis.kletnieks@vt.edu>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
12 years agoMerge branch 'for-31-rc3/i2c-fixes' of git://git.fluff.org/bjdooks/linux
Linus Torvalds [Wed, 24 Aug 2011 22:54:30 +0000 (15:54 -0700)]
Merge branch 'for-31-rc3/i2c-fixes' of git://git.fluff.org/bjdooks/linux

* 'for-31-rc3/i2c-fixes' of git://git.fluff.org/bjdooks/linux:
  i2c-nomadik: fix kerneldoc warning
  Revert "i2c-omap: fix static suspend vs. runtime suspend"
  i2c-nomadik: Do not use _interruptible_ variant call

12 years agoi2c-nomadik: fix kerneldoc warning
Linus Walleij [Tue, 9 Aug 2011 18:17:29 +0000 (20:17 +0200)]
i2c-nomadik: fix kerneldoc warning

There was a missing struct item in the kerneldoc, add it and fix
another pretty-printing formatting issue with a missing space.

Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
12 years agostaging: tidspbridge: fix compilation on dsp clock functions
Omar Ramirez Luna [Wed, 24 Aug 2011 20:07:04 +0000 (15:07 -0500)]
staging: tidspbridge: fix compilation on dsp clock functions

Seen on v3.1-rc3, patch:

omap: mcbsp: Drop in-driver transfer support
bafe2721a0fbd1cc1af04384133684f660f3658e

Removed code that now cause tidspbridge to break while compiling.

Signed-off-by: Omar Ramirez Luna <omar.ramirez@ti.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agoMerge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/hid
Linus Torvalds [Wed, 24 Aug 2011 18:25:08 +0000 (11:25 -0700)]
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/hid

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/hid:
  HID: wiimote: Add status and return request handlers
  HID: wiimote: Add drm request
  HID: wiimote: Register led class devices
  HID: wiimote: Correctly call HID open/close callbacks
  HID: wiimote: Simplify synchronization
  HID: usbhid: Add support for SiGma Micro chip
  HID: add support for new revision of Apple aluminum keyboard

12 years agoath9k: Fix PS wrappers in ath9k_set_coverage_class
Mohammed Shafi Shajakhan [Wed, 24 Aug 2011 16:08:07 +0000 (21:38 +0530)]
ath9k: Fix PS wrappers in ath9k_set_coverage_class

this callback is called during suspend/resume and also via iw command.
it configures parameters like sifs, slottime, acktimeout in
ath9k_hw_init_global_settings where few REG_READ, REG_RMW are also done
and hence the need for PS wrappers

Cc: stable@kernel.org
Signed-off-by: Mohammed Shafi Shajakhan <mohammed@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agocarl9170: Fix mismatch in carl9170_op_set_key mutex lock-unlock
Alexey Khoroshilov [Tue, 23 Aug 2011 20:44:32 +0000 (00:44 +0400)]
carl9170: Fix mismatch in carl9170_op_set_key mutex lock-unlock

If is_main_vif(ar, vif) reports that we have to fall back
to software encryption, we goto err_softw; before locking ar->mutex.
As a result, we have unprotected call to carl9170_set_operating_mode
and unmatched mutex_unlock.

The patch fix the issue by adding mutex_lock before goto.

Found by Linux Driver Verification project (linuxtesting.org).

Signed-off-by: Alexey Khoroshilov <khoroshilov@ispras.ru>
Cc: <stable@kernel.org>
Acked-By: Christian Lamparter <chunkeey@googlemail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agoMerge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input
Linus Torvalds [Wed, 24 Aug 2011 16:19:03 +0000 (09:19 -0700)]
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input:
  Input: ad714x - read the interrupt status registers in a row
  Input: ad714x - use DMA-safe buffers for spi_write()
  Input: ad714x - fix endianness issues
  Input: ad714xx-spi - force SPI bus into the default 8-bit mode
  Input: ep93xx_keypad - add missing include of linux/module.h
  Input: tnetv107x-ts - add missing include of linux/module.h
  Input: max11801_ts - correct license statement
  Input: atmel_mxt_ts - report pressure information from the driver
  Input: bcm5974 - Add support for newer MacBookPro8,2
  Input: wacom - report id 3 returns 4 bytes of data
  Input: wacom - add WAC_MSG_RETRIES define
  Input: wacom - add support for the Wacom Bamboo Pen (CTL-660/K)
  Input: tegra-kbc - correct call to input_free_device
  Input: mpu3050 - correct call to input_free_device
  Input: bcm5974 - add support for touchpads found in MacBookAir4,2
  Input: mma8450 - fix module device table type
  Input: remove CLOCK_TICK_RATE from analog joystick driver

12 years agoMerge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi...
Linus Torvalds [Wed, 24 Aug 2011 16:14:42 +0000 (09:14 -0700)]
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/fuse

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/fuse:
  fuse: check size of FUSE_NOTIFY_INVAL_ENTRY message
  fuse: mark pages accessed when written to
  fuse: delete dead .write_begin and .write_end aops
  fuse: fix flock
  fuse: fix non-ANSI void function notation

12 years agoMerge git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc
Linus Torvalds [Wed, 24 Aug 2011 16:13:40 +0000 (09:13 -0700)]
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc

* git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc:
  sparc: Allow handling signals when stack is corrupted.

12 years agoMerge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
Linus Torvalds [Wed, 24 Aug 2011 16:11:08 +0000 (09:11 -0700)]
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net

* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net: (29 commits)
  bridge: fix a possible net_device leak
  net: Documentation: RFC 2553bis is now RFC 3493
  atm: br2684: Fix oops due to skb->dev being NULL
  ipv6: Fix ipv6_getsockopt for IPV6_2292PKTOPTIONS
  net: netdev-features.txt update to Documentation/networking/00-INDEX
  vlan: reset headers on accel emulation path
  forcedeth: call vlan_mode only if hw supports vlans
  via-velocity: remove non-tagged packet filtering
  bonding:reset backup and inactive flag of slave
  net_sched: fix port mirror/redirect stats reporting
  sit tunnels: propagate IPv6 transport class to IPv4 Type of Service
  gianfar: reduce stack usage in gianfar_ethtool.c
  net: minor update to Documentation/networking/scaling.txt
  net: add missing entries to Documentation/networking/00-INDEX
  gianfar: prevent buggy hw rx vlan tagging
  net: sh_eth: Fix build by forgot including linux/interrupt.h
  drivers/net/can/sja1000/plx_pci.c: eliminate double free
  usbnet/cdc_ncm: Don't use stack variables for DMA
  vmxnet3: Don't enable vlan filters in promiscuous mode.
  iwlagn: sysfs couldn't find the priv pointer
  ...

12 years agoMerge branches 'wiimote' and 'upstream-fixes' into for-linus
Jiri Kosina [Wed, 24 Aug 2011 14:41:52 +0000 (16:41 +0200)]
Merge branches 'wiimote' and 'upstream-fixes' into for-linus

12 years agofuse: check size of FUSE_NOTIFY_INVAL_ENTRY message
Miklos Szeredi [Wed, 24 Aug 2011 08:20:17 +0000 (10:20 +0200)]
fuse: check size of FUSE_NOTIFY_INVAL_ENTRY message

FUSE_NOTIFY_INVAL_ENTRY didn't check the length of the write so the
message processing could overrun and result in a "kernel BUG at
fs/fuse/dev.c:629!"

Reported-by: Han-Wen Nienhuys <hanwenn@gmail.com>
Signed-off-by: Miklos Szeredi <mszeredi@suse.cz>
CC: stable@kernel.org
12 years agoMerge branch 'devel-stable' into for-next
Russell King [Wed, 24 Aug 2011 07:14:37 +0000 (08:14 +0100)]
Merge branch 'devel-stable' into for-next

Conflicts:
arch/arm/mach-imx/mach-cpuimx27.c
arch/arm/mach-msm/board-msm7x30.c
arch/arm/mm/dma-mapping.c

12 years agoMerge branches 'amba', 'fixes', 'gpio', 'io' (early part), 'misc', 'p2v' and 'pgt...
Russell King [Wed, 24 Aug 2011 07:14:17 +0000 (08:14 +0100)]
Merge branches 'amba', 'fixes', 'gpio', 'io' (early part), 'misc', 'p2v' and 'pgt' into for-next

12 years agoPM: add runtime PM support to MMCI
Russell King [Sun, 14 Aug 2011 08:17:05 +0000 (09:17 +0100)]
PM: add runtime PM support to MMCI

Add runtime PM support to the MMCI primecell driver, making use of
the core primecell bus runtime PM support.

Tested-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
12 years agoPM: add runtime PM support to core Primecell driver
Russell King [Sun, 14 Aug 2011 08:13:48 +0000 (09:13 +0100)]
PM: add runtime PM support to core Primecell driver

Add runtime PM support to the core Primecell driver, following the PCI
model of how this is done.

Rather than having every driver fiddle about with enabling runtime PM,
that's dealt with in the core and instead, drivers just do a put() in
their probe and a balancing get() in their remove function to activate
runtime PM for the device.

As we're dealing with enabling runtime PM in the core, fix up spi-pl022
as it must not enable and disable runtime PM itself anymore.

Tested-by: Linus Walleij <linus.walleij@linaro.org>
Acked-by: Rafael J. Wysocki <rjw@sisk.pl>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
12 years ago[SCSI] isci: add version number
Dan Williams [Sat, 30 Jul 2011 00:17:21 +0000 (17:17 -0700)]
[SCSI] isci: add version number

Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Signed-off-by: James Bottomley <JBottomley@Parallels.com>
12 years ago[SCSI] isci: fix event-get pointer increment
Dan Williams [Sat, 30 Jul 2011 00:17:16 +0000 (17:17 -0700)]
[SCSI] isci: fix event-get pointer increment

Hardware only increments the put pointer on event types >= 4.  Do not
increment the get pointer for event type 3.

Reported-by: Kapil Karkra <kapil.karkra@intel.com>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Signed-off-by: James Bottomley <JBottomley@Parallels.com>
12 years ago[SCSI] isci: dynamic interrupt coalescing
Dan Williams [Sat, 30 Jul 2011 00:17:10 +0000 (17:17 -0700)]
[SCSI] isci: dynamic interrupt coalescing

Hardware allows both an outstanding number commands and a timeout value
(whichever occurs first) as a gate to the next interrupt generation.  This
scheme at completion time looks at the remaining number of outstanding tasks
and sets the timeout to maximize small transaction operation.  If transactions
are large (take more than a few 10s of microseconds to complete) then
performance is not interrupt processing bound, so the small timeouts this
scheme generates are overridden by the time it takes for a completion to
arrive.

Tested-by: Dave Jiang <dave.jiang@intel.com>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Signed-off-by: James Bottomley <JBottomley@Parallels.com>
12 years ago[SCSI] isci: Leave requests alone if already terminating.
Jeff Skirvin [Sat, 30 Jul 2011 00:17:05 +0000 (17:17 -0700)]
[SCSI] isci: Leave requests alone if already terminating.

Instead of immediately completing any request that has a second
termination call made on it, wait for the TC done/abort HW event.

Signed-off-by: Jeff Skirvin <jeffrey.d.skirvin@intel.com>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Signed-off-by: James Bottomley <JBottomley@Parallels.com>
12 years ago[SCSI] isci: Adding documentation to API change and fixup sysfs registration
Dave Jiang [Sat, 30 Jul 2011 00:17:00 +0000 (17:17 -0700)]
[SCSI] isci: Adding documentation to API change and fixup sysfs registration

Adding API update for adding isci_id entry scsi_host sysfs entry.
Also fixing up the sysfs registration to the scsi_host template

Signed-off-by: Dave Jiang <dave.jiang@intel.com>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Signed-off-by: James Bottomley <JBottomley@Parallels.com>
12 years ago[SCSI] isci: Update MAINTAINERS entry for the isci driver
Dave Jiang [Sat, 30 Jul 2011 00:16:55 +0000 (17:16 -0700)]
[SCSI] isci: Update MAINTAINERS entry for the isci driver

Signed-off-by: Dave Jiang <dave.jiang@intel.com>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Signed-off-by: James Bottomley <JBottomley@Parallels.com>
12 years ago[SCSI] isci: change sas phy timeouts from 54us to 59us
Marcin Tomczak [Sat, 30 Jul 2011 00:16:50 +0000 (17:16 -0700)]
[SCSI] isci: change sas phy timeouts from 54us to 59us

Need the following workaround in the driver for interoperability with
the older Intel SSD drives and any other SATA drive that may exhibit the
same behavior. This is a corner case where SCU speed is limited to
either 3G or 1.5G and the drive has a period of DC idle when it switches
speed during SATA speed negotiation. Workaround :change PHYTOV[31:24]
from 0x36 to 0x3B.

Signed-off-by: Marcin Tomczak <marcin.tomczak@intel.com>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Signed-off-by: James Bottomley <JBottomley@Parallels.com>
12 years ago[SCSI] isci: fix 32-bit operation when CONFIG_HIGHMEM64G=n
Dan Williams [Sat, 30 Jul 2011 00:16:45 +0000 (17:16 -0700)]
[SCSI] isci: fix 32-bit operation when CONFIG_HIGHMEM64G=n

The unsolicited frame control infrastructure requires a table of dma
addresses for the hardware to lookup the frame buffer location by an
index.  The hardware expects the elements of this table to be 64-bit
quantities, so we cannot reference these elements as dma_addr_t.  All
unsolicited frame protocols are affected, particularly SATA-PIO and SMP
which prevented direct-attached SATA drives and expander-attached drives
to not be discovered.

Cc: <stable@kernel.org>
Reported-by: Jacek Danecki <jacek.danecki@intel.com>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Signed-off-by: James Bottomley <JBottomley@Parallels.com>
12 years ago[SCSI] isci: fix sata response handling
Dan Williams [Sat, 30 Jul 2011 00:16:40 +0000 (17:16 -0700)]
[SCSI] isci: fix sata response handling

A bug (likely copy/paste) that has been carried from the original
implementation.  The unsolicited frame handling structure returns the
d2h fis in the isci_request.stp.rsp buffer.

Cc: <stable@kernel.org>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Signed-off-by: James Bottomley <JBottomley@Parallels.com>
12 years agoMerge branch 'x86-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel...
Linus Torvalds [Wed, 24 Aug 2011 01:09:08 +0000 (18:09 -0700)]
Merge branch 'x86-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip

* 'x86-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
  x86-32, vdso: On system call restart after SYSENTER, use int $0x80
  x86, UV: Remove UV delay in starting slave cpus
  x86, olpc: Wait for last byte of EC command to be accepted

12 years agox86-32, vdso: On system call restart after SYSENTER, use int $0x80
H. Peter Anvin [Mon, 22 Aug 2011 20:27:06 +0000 (13:27 -0700)]
x86-32, vdso: On system call restart after SYSENTER, use int $0x80

When we enter a 32-bit system call via SYSENTER or SYSCALL, we shuffle
the arguments to match the int $0x80 calling convention.  This was
probably a design mistake, but it's what it is now.  This causes
errors if the system call as to be restarted.

For SYSENTER, we have to invoke the instruction from the vdso as the
return address is hardcoded.  Accordingly, we can simply replace the
jump in the vdso with an int $0x80 instruction and use the slower
entry point for a post-restart.

Suggested-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
Link: http://lkml.kernel.org/r/CA%2B55aFztZ=r5wa0x26KJQxvZOaQq8s2v3u50wCyJcA-Sc4g8gQ@mail.gmail.com
Cc: <stable@kernel.org>
12 years agostaging: octeon-ethernet: Add missing #includes.
David Daney [Tue, 16 Aug 2011 17:10:56 +0000 (10:10 -0700)]
staging: octeon-ethernet: Add missing #includes.

I looks like something used to implicitly include linux/interrupt.h,
and no longer does.  Fix the resulting build error by explicitly
including it.

Signed-off-by: David Daney <david.daney@cavium.com>
Cc: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agoStaging: zcache: signedness bug in tmem_get()
Dan Carpenter [Tue, 9 Aug 2011 18:01:33 +0000 (21:01 +0300)]
Staging: zcache: signedness bug in tmem_get()

"ret" needs to be signed for the error handling to work properly.

Signed-off-by: Dan Carpenter <error27@gmail.com>
Acked-by: Dan Magenheimer <dan.magenheimer@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: zcache: fix crash on high memory swap
Seth Jennings [Wed, 10 Aug 2011 17:56:49 +0000 (12:56 -0500)]
staging: zcache: fix crash on high memory swap

zcache_put_page() was modified to pass page_address(page) instead of the
actual page structure. In combination with the function signature changes
to tmem_put() and zcache_pampd_create(), zcache_pampd_create() tries to
(re)derive the page structure from the virtual address.  However, if the
original page is a high memory page (or any unmapped page), this
virt_to_page() fails because the page_address() in zcache_put_page()
returned NULL.

This patch changes zcache_put_page() and zcache_get_page() to pass
the page structure instead of the page's virtual address, which
may or may not exist.

Signed-off-by: Seth Jennings <sjenning@linux.vnet.ibm.com>
Acked-by: Dan Magenheimer <dan.magenheimer@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agom68k: fix __page_to_pfn for a const struct page argument
Ian Campbell [Thu, 18 Aug 2011 08:37:02 +0000 (09:37 +0100)]
m68k: fix __page_to_pfn for a const struct page argument

Fixes fallout due to the removal of the cast in commit aa462abe8aaf
("mm: fix __page_to_pfn for a const struct page argument")

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Cc: Andrew Morton <akpm@linux-foundation.org>
Acked-by: Geert Uytterhoeven <geert@linux-m68k.org>
Cc: linux-m68k@lists.linux-m68k.org
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
12 years agoPull misc-3.2 into test branch
Tony Luck [Tue, 23 Aug 2011 20:32:59 +0000 (13:32 -0700)]
Pull misc-3.2 into test branch

12 years ago[IA64] agp/hp-agp: Allow binding user memory to the AGP GART
Émeric Maschino [Tue, 23 Aug 2011 19:48:23 +0000 (21:48 +0200)]
[IA64] agp/hp-agp: Allow binding user memory to the AGP GART

dmesg reports:
[ Â  29.365973] [TTM] AGP Bind memory failed.
[ Â  29.366015] radeon 0000:80:00.0: object_init failed for (4096, 0x00000002)
[ Â  29.366052] radeon 0000:80:00.0: (-22) create WB bo failed
[ Â  29.366087] radeon 0000:80:00.0: Disabling GPU acceleration
[ Â  29.366124] [drm] radeon: cp finalized
[ Â  29.366168] [drm] radeon: cp finalized
[ Â  29.366210] [TTM] Finalizing pool allocator.
[ Â  29.366924] [TTM] Zone Â kernel: Used memory at exit: 0 kiB.
[ Â  29.366961] [TTM] Zone Â  dma32: Used memory at exit: 0 kiB.
[ Â  29.366996] [drm] radeon: ttm finalized
[ Â  29.367030] [drm] Forcing AGP to PCI mode

This patch allows binding user memory to the AGP GART on zx1-based
systems. dmesg thus no more complains about AGP bind memory failure,
disabled GPU acceleration or AGP mode forced to PCI.

Original work from Francisco Jerez in agp/amd-k7
(https://lkml.org/lkml/2010/10/15/469).

Tested-by: Émeric Maschino <emeric.maschino@gmail.com>
Signed-off-by: Tony Luck <tony.luck@intel.com>
12 years agostaging: brcm80211: SPARC build error fix
Pieter-Paul Giesberts [Mon, 8 Aug 2011 13:59:03 +0000 (15:59 +0200)]
staging: brcm80211: SPARC build error fix

Due to missing memset function declaration.

Reviewed-by: Roland Vossen <rvossen@broadcom.com>
Signed-off-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: brcm80211: fix compile error on non-x86 archs since 3.0 kernel
Arend Van Spriel [Mon, 8 Aug 2011 13:57:45 +0000 (15:57 +0200)]
staging: brcm80211: fix compile error on non-x86 archs since 3.0 kernel

Since the arrival of kernel version 3.0 in the staging tree it
turns out compile error occurs for sparc64, powerpc, and arm
platforms. This patch fixes that issue.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Henry Ptasinski <henryp@broadcom.com>
Signed-off-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agowl12xx: add max_sched_scan_ssids value to the hw description
Luciano Coelho [Tue, 23 Aug 2011 08:42:25 +0000 (11:42 +0300)]
wl12xx: add max_sched_scan_ssids value to the hw description

After commit 5a865ba, we require a separate value to indicate the
number of supported SSIDs in scheduled scans.  This patch adds a
proper value to the wl12xx driver.

This fixes a regression in 3.1-rc3 where scheduled scans were not
working properly with the wl12xx driver.

Signed-off-by: Luciano Coelho <coelho@ti.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agowl12xx: Fix validation of pm_runtime_get_sync return value
Ido Yariv [Mon, 22 Aug 2011 20:19:49 +0000 (23:19 +0300)]
wl12xx: Fix validation of pm_runtime_get_sync return value

wl1271_sdio_power_on checks if the return value of pm_runtime_get_sync
is non-zero, and if so bails out.
However, pm_runtime_get_sync can return a positive number which does not
suggest an error has occurred. This is problematic for two reasons:

1. The function will needlessly bail out without decrementing back the
   runtime PM reference counter.
2. wl1271_power_on only checks if wl1271_power_on return value is
   negative. This means that wl1271_power_on will continue even if
   wl1271_sdio_power_on bailed out. As a result, sdio transactions will
   be initiated without properly enabling the sdio function and claiming
   the host. This could even lead to a kernel panic.

Fix this by only checking that the return value of pm_runtime_get_sync
is non-negative.

Signed-off-by: Ido Yariv <ido@wizery.com>
Acked-by: Luciano Coelho <coelho@ti.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agowl12xx: Remove obsolete testmode NVS push command
Ido Yariv [Mon, 22 Aug 2011 20:19:48 +0000 (23:19 +0300)]
wl12xx: Remove obsolete testmode NVS push command

The testmode NVS push command is no longer in use. In addition, it has
several implementation issues that prevent it from working correctly:

1. wl1271_tm_cmd_configure relies on wl->chip.id being set. However,
   since the device was not necessarily booted by the time the function
   is called, wl->chip.id will be initialized to 0.
2. The NVS file is fetched by calling request_firmware() before it is
   possible to push an NVS file.
3. The maximum allowed size of nl binary payloads is not sufficient for
   pushing NVS files.
4. Pushing 128x NVS files will always fail due to a bug in the
   validation code.
5. In case the pushed NVS file is found invalid, the mutex will be kept
   locked and the nvs member will become a dangling pointer.

Since this feature is not being used, remove it completely instead of
fixing it.

Signed-off-by: Ido Yariv <ido@wizery.com>
Acked-by: Luciano Coelho <coelho@ti.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12 years agoRevert "i2c-omap: fix static suspend vs. runtime suspend"
Kevin Hilman [Thu, 4 Aug 2011 14:53:02 +0000 (07:53 -0700)]
Revert "i2c-omap: fix static suspend vs. runtime suspend"

This reverts commit adf6e07922255937c8bfeea777d19502b4c9a2be.

Remove system PM methods which can race with runtime PM methods.

Also, as of v3.1, the PM domain level code for OMAP handles device
power state transistions automatically for devices, so drivers no
longer need to specifically call the bus/pm_domain methods themselves.

Signed-off-by: Kevin Hilman <khilman@ti.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
12 years agoi2c-nomadik: Do not use _interruptible_ variant call
srinidhi kasagar [Tue, 9 Aug 2011 18:17:22 +0000 (20:17 +0200)]
i2c-nomadik: Do not use _interruptible_ variant call

If there is a signal pending and wait_for_completion_interruptible_timeout
exited because of the -ERESTARTSYS error we are unable to send any more
i2c messages.

So, deprecate this _interruptible_ variant call.

Signed-off-by: Srinidhi Kasagar <srinidhi.kasagar@stericsson.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
12 years agoMerge branch 'for-linus' of git://oss.sgi.com/xfs/xfs
Linus Torvalds [Tue, 23 Aug 2011 18:41:44 +0000 (11:41 -0700)]
Merge branch 'for-linus' of git://oss.sgi.com/xfs/xfs

* 'for-linus' of git://oss.sgi.com/xfs/xfs:
  xfs: fix tracing builds inside the source tree
  xfs: remove subdirectories
  xfs: don't expect xfs headers to be in subdirectories

12 years agoomap-serial: Allow IXON and IXOFF to be disabled.
Nick Pelly [Fri, 15 Jul 2011 20:53:08 +0000 (13:53 -0700)]
omap-serial: Allow IXON and IXOFF to be disabled.

Fixes logic bug that software flow control cannot be disabled, because
serial_omap_configure_xonxoff() is not called if both IXON and IXOFF bits
are cleared.

Signed-off-by: Nick Pelly <npelly@google.com>
Acked-by: Govindraj.R <govindraj.raja@ti.com>
Tested-by: Govindraj.R <govindraj.raja@ti.com>
Cc: stable <stable@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agoMerge git://git.infradead.org/users/cbou/battery-3.1
Linus Torvalds [Tue, 23 Aug 2011 17:46:56 +0000 (10:46 -0700)]
Merge git://git.infradead.org/users/cbou/battery-3.1

* git://git.infradead.org/users/cbou/battery-3.1:
  s3c-adc-battery: Fix compilation error due to missing header (module.h)
  max8997_charger: Needs module.h
  max8998_charger: Needs module.h

12 years agoMerge branch 'drm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied...
Linus Torvalds [Tue, 23 Aug 2011 17:46:21 +0000 (10:46 -0700)]
Merge branch 'drm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6

* 'drm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6:
  drm/radeon: Extended DDC Probing for Toshiba L300D Radeon Mobility X1100 HDMI-A Connector
  drm/ttm: ensure ttm for new node is bound before calling move_notify()
  drm/ttm: unbind ttm before destroying node in accel move cleanup
  drm/ttm: fix ttm_bo_add_ttm(user) failure path
  drm/radeon: Make vramlimit parameter actually work.
  drm/radeon: Explicitly print GTT/VRAM offsets on test failure.
  drm/radeon: Take IH ring into account for test size calculation.
  drm/radeon/alpha: Add Alpha support to Radeon DRM code

12 years agoRevert "irq: Always set IRQF_ONESHOT if no primary handler is specified"
Linus Torvalds [Tue, 23 Aug 2011 17:36:51 +0000 (10:36 -0700)]
Revert "irq: Always set IRQF_ONESHOT if no primary handler is specified"

This reverts commit f3637a5f2e2eb391ff5757bc83fb5de8f9726464.

It turns out that this breaks several drivers, one example being OMAP
boards which use the on-board OMAP UARTs and the omap-serial driver that
will not boot to userspace after the commit.

Paul Walmsley reports that enabling CONFIG_DEBUG_SHIRQ reveals 'IRQ
handler type mismatch' errors:

  IRQ handler type mismatch for IRQ 74
  current handler: serial idle
  ...

and the reason is that setting IRQF_ONESHOT will now result in those
interrupt handlers having different IRQF flags, and thus being
unsharable.  So the commit log in the reverted commit:

                            "Since it is required for those users and
    there is no difference for others it makes sense to add this flag
    unconditionally."

is simply not true: there may not be any difference from a "actions at
irq time", but there is a *big* difference wrt this flag testing irq
management (see __setup_irq() in kernel/irq/manage.c).

One solution may be to stop verifying IRQF_ONESHOT in __setup_irq(), but
right now the safe course of action is to revert the change.  Let's
revisit this in a later merge window.

Reported-by: Paul Walmsley <paul@pwsan.com>
Cc: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Requested-by: Alan Cox <alan@lxorguk.ukuu.org.uk>
Acked-by: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
12 years agoTTY: serial, document ignoring of uart->ops->startup error
Jiri Slaby [Wed, 17 Aug 2011 11:48:15 +0000 (13:48 +0200)]
TTY: serial, document ignoring of uart->ops->startup error

When a user has SYS_ADMIN capabilities and uart->ops->startup returns
an error in uart_startup, we silently drop the error. We then return 0
and behave as if it didn't fail. (Not quite, since we set TTY_IO_ERROR
bit and leave ASYNC_INITIALIZED bit cleared.)

This all is to allow setserial to work with improperly configured or
unconfigured ports. User can thus set port properties and reconfigure
properly.

This patch only documents this behavior.

Signed-off-by: Jiri Slaby <jslaby@suse.cz>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Cc: Russel King <linux@arm.linux.org.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agoTTY: pty, fix pty counting
Jiri Slaby [Wed, 10 Aug 2011 12:59:28 +0000 (14:59 +0200)]
TTY: pty, fix pty counting

tty_operations->remove is normally called like:
queue_release_one_tty
 ->tty_shutdown
   ->tty_driver_remove_tty
     ->tty_operations->remove

However tty_shutdown() is called from queue_release_one_tty() only if
tty_operations->shutdown is NULL. But for pty, it is not.
pty_unix98_shutdown() is used there as ->shutdown.

So tty_operations->remove of pty (i.e. pty_unix98_remove()) is never
called. This results in invalid pty_count. I.e. what can be seen in
/proc/sys/kernel/pty/nr.

I see this was already reported at:
  https://lkml.org/lkml/2009/11/5/370
But it was not fixed since then.

This patch is kind of a hackish way. The problem lies in ->install. We
allocate there another tty (so-called tty->link). So ->install is
called once, but ->remove twice, for both tty and tty->link. The fix
here is to count both tty and tty->link and divide the count by 2 for
user.

And to have ->remove called, let's make tty_driver_remove_tty() global
and call that from pty_unix98_shutdown() (tty_operations->shutdown).

While at it, let's document that when ->shutdown is defined,
tty_shutdown() is not called.

Signed-off-by: Jiri Slaby <jslaby@suse.cz>
Cc: Alan Cox <alan@linux.intel.com>
Cc: "H. Peter Anvin" <hpa@zytor.com>
Cc: stable <stable@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years ago8250: Fix race condition in serial8250_backup_timeout().
Al Cooper [Mon, 25 Jul 2011 20:19:52 +0000 (16:19 -0400)]
8250: Fix race condition in serial8250_backup_timeout().

This is to fix an issue where output will suddenly become very slow.
The problem occurs on 8250 UARTS with the hardware bug UART_BUG_THRE.

BACKGROUND
For normal UARTs (without UART_BUG_THRE): When the serial core layer
gets new transmit data and the transmitter is idle, it buffers the
data and calls the 8250s' serial8250_start_tx() routine which will
simply enable the TX interrupt in the IER register and return. This
should immediately fire a THRE interrupt and begin transmitting the
data.
For buggy UARTs (with UART_BUG_THRE): merely enabling the TX interrupt
in IER does not necessarily generate a new THRE interrupt.
Therefore, a background timer periodically checks to see if there is
pending data, and starts transmission if that is the case.

The bug happens on SMP systems when the system has nothing to transmit,
the transmit interrupt is disabled and the following sequence occurs:
- CPU0: The background timer routine serial8250_backup_timeout()
  starts and saves the state of the interrupt enable register (IER)
  and then disables all interrupts in IER. NOTE: The transmit interrupt
  (TI) bit is saved as disabled.
- CPU1: The serial core gets data to transmit, grabs the port lock and
  calls serial8250_start_tx() which enables the TI in IER.
- CPU0: serial8250_backup_timeout() waits for the port lock.
- CPU1: finishes (with TI enabled) and releases the port lock.
- CPU0: serial8250_backup_timeout() calls the interrupt routine which
  will transmit the next fifo's worth of data and then restores the
  IER from the previously saved value (TI disabled).
At this point, as long as the serial core has more transmit data
buffered, it will not call serial8250_start_tx() again and the
background timer routine will slowly transmit the data.

The fix is to have serial8250_start_tx() get the port lock before
it saves the IER state and release it after restoring IER. This will
prevent serial8250_start_tx() from running in parallel.

Signed-off-by: Al Cooper <alcooperx@gmail.com>
Cc: stable <stable@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agoserial/8250_pci: delete duplicate data definition
Tomoya MORINAGA [Tue, 12 Jul 2011 07:08:49 +0000 (16:08 +0900)]
serial/8250_pci: delete duplicate data definition

Data definiton "VendorID=10DB, device_id=800D" is already defined.
This patch deletes the duplicate definition.

Signed-off-by: Tomoya MORINAGA <tomoya-linux@dsn.okisemi.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years ago8250_pci: add support for Rosewill RC-305 4x serial port card
Eric Smith [Tue, 12 Jul 2011 04:53:13 +0000 (22:53 -0600)]
8250_pci: add support for Rosewill RC-305 4x serial port card

This patch adds support for the Rosewill RC-305 four-port PCI serial
card, and probably any other four-port serial cards based on the
Moschip MCS9865 chip, assuming that the EEPROM on the card was
programmed in accordance with Table 6 of the MCS9865 EEPROM
Application Note version 0.3 dated 16-May-2008, available from the
Moschip web site (registration required).

This patch is based on an earlier patch [1] for the SYBA 6x serial
port card by Ira W. Snyder.

[1]: http://www.gossamer-threads.com/lists/linux/kernel/1162435

Signed-off-by: Eric Smith <eric@brouhaha.com>
Cc: stable <stable@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agotty: Add "spi:" prefix for spi modalias
Axel Lin [Mon, 1 Aug 2011 13:20:10 +0000 (21:20 +0800)]
tty: Add "spi:" prefix for spi modalias

Since commit e0626e38 (spi: prefix modalias with "spi:"),
the spi modalias is prefixed with "spi:".

This patch adds "spi:" prefix and removes "-spi" suffix in the modalias.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Cc: stable <stable@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agoARM: pgtable: switch to use pgtable-nopud.h
Russell King [Sun, 21 Nov 2010 16:37:42 +0000 (16:37 +0000)]
ARM: pgtable: switch to use pgtable-nopud.h

Nick Piggin noted upon introducing 4level-fixup.h:

| Add a temporary "fallback" header so architectures can run with
| the 4level pagetables patch without modification. All architectures
| should be converted to use the folding headers (include/asm-generic/
| pgtable-nop?d.h) as soon as possible, and the fallback header removed.

This makes ARM compliant with this statement.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
12 years agoARM: 7059/1: LPAE: Use PMD_(SHIFT|SIZE|MASK) instead of PGDIR_*
Catalin Marinas [Tue, 23 Aug 2011 13:07:23 +0000 (14:07 +0100)]
ARM: 7059/1: LPAE: Use PMD_(SHIFT|SIZE|MASK) instead of PGDIR_*

PGDIR_SHIFT and PMD_SHIFT for the classic 2-level page table format have
the same value (21). This patch converts the PGDIR_* uses in the kernel
to the PMD_* equivalent so that LPAE builds can reuse the same code.

Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
12 years agoARM: 7058/1: LPAE: Cast the dma_addr_t argument to unsigned long in dma_to_virt
Catalin Marinas [Tue, 23 Aug 2011 12:59:14 +0000 (13:59 +0100)]
ARM: 7058/1: LPAE: Cast the dma_addr_t argument to unsigned long in dma_to_virt

This is to avoid a compiler warning when invoking the __bus_to_virt()
macro. The dma_to_virt() function gets addresses within the 32-bit
range.

Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
12 years agoARM: 7057/1: mach-pnx4008: rename GPIO header
Linus Walleij [Tue, 23 Aug 2011 11:51:24 +0000 (12:51 +0100)]
ARM: 7057/1: mach-pnx4008: rename GPIO header

The PNX4008 header file is using the generic gpio and gpiolib
namespace in <mach/gpio.h> yet the GPIO interface is not generic
at all so rename it to <mach/gpio-pnx4008.h>

This fixes a build failure in current -next: the includes were
changed from <mach/gpio.h> to <linux/gpio.h> but since this
platform isn't using generic gpio <linux/gpio.h> did not include
<mach/gpio.h> and things broke apart.

Acked-by: Vitaly Wool <vitalywool@gmail.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
12 years agoARM: 7056/1: plat-nomadik: kill off <plat/gpio.h>
Linus Walleij [Tue, 23 Aug 2011 11:50:50 +0000 (12:50 +0100)]
ARM: 7056/1: plat-nomadik: kill off <plat/gpio.h>

After recent consolidations the Nomadik <plat/gpio.h> is entirely
superfluous, so get rid of it.

Reported-by: Russell King <linux@arm.linux.org.uk>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
12 years agofixup! ARM: pgtable: switch to use pgtable-nopud.h
Catalin Marinas [Mon, 8 Aug 2011 16:47:42 +0000 (17:47 +0100)]
fixup! ARM: pgtable: switch to use pgtable-nopud.h

Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
12 years agoARM: LPAE: Add the Kconfig entries
Catalin Marinas [Mon, 31 Jan 2011 13:50:46 +0000 (13:50 +0000)]
ARM: LPAE: Add the Kconfig entries

This patch adds the ARM_LPAE and ARCH_PHYS_ADDR_T_64BIT Kconfig entries
allowing LPAE support to be compiled into the kernel.

Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
12 years agoARM: LPAE: add support for ATAG_MEM64
Will Deacon [Mon, 31 Jan 2011 13:50:46 +0000 (13:50 +0000)]
ARM: LPAE: add support for ATAG_MEM64

LPAE provides support for memory banks with physical addresses of up
to 40 bits.

This patch adds a new atag, ATAG_MEM64, so that the Kernel can be
informed about memory that exists above the 4GB boundary.

Signed-off-by: Will Deacon <will.deacon@arm.com>
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
12 years agoARM: LPAE: mark memory banks with start > ULONG_MAX as highmem
Will Deacon [Mon, 31 Jan 2011 13:50:46 +0000 (13:50 +0000)]
ARM: LPAE: mark memory banks with start > ULONG_MAX as highmem

Memory banks living outside of the 32-bit physical address
space do not have a 1:1 pa <-> va mapping and therefore the
__va macro may wrap.

This patch ensures that such banks are marked as highmem so
that the Kernel doesn't try to split them up when it sees that
the wrapped virtual address overlaps the vmalloc space.

Signed-off-by: Will Deacon <will.deacon@arm.com>
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
12 years agoARM: LPAE: Add identity mapping support for the 3-level page table format
Catalin Marinas [Mon, 31 Jan 2011 13:50:44 +0000 (13:50 +0000)]
ARM: LPAE: Add identity mapping support for the 3-level page table format

With LPAE, the pgd is a separate page table with entries pointing to the
pmd. The identity_mapping_add() function needs to ensure that the pgd is
populated before populating the pmd level. The do..while blocks now loop
over the pmd in order to have the same implementation for the two page
table formats. The pmd_addr_end() definition has been removed and the
generic one used instead. The pmd clean-up is done in the pgd_free()
function.

Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
12 years agoARM: LPAE: Add context switching support
Catalin Marinas [Mon, 31 Jan 2011 13:50:44 +0000 (13:50 +0000)]
ARM: LPAE: Add context switching support

With LPAE, TTBRx registers are 64-bit. The ASID is stored in TTBR0
rather than a separate Context ID register. This patch makes the
necessary changes to handle context switching on LPAE.

Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
12 years agoARM: LPAE: Add fault handling support
Catalin Marinas [Mon, 31 Jan 2011 13:50:43 +0000 (13:50 +0000)]
ARM: LPAE: Add fault handling support

The DFSR and IFSR register format is different when LPAE is enabled. In
addition, DFSR and IFSR have the similar definitions for the fault type.
This modifies modifies the fault code to correctly handle the new
format.

Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
12 years agoARM: LPAE: Invalidate the TLB before freeing the PMD
Catalin Marinas [Tue, 10 May 2011 16:48:36 +0000 (17:48 +0100)]
ARM: LPAE: Invalidate the TLB before freeing the PMD

Similar to the PTE freeing, this patch introduced __pmd_free_tlb() which
invalidates the TLB before freeing a PMD page. This is needed because on
newer processors the entry in the upper page table may be cached by the
TLB and point to random data after the PMD has been freed.

Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
12 years agoARM: LPAE: MMU setup for the 3-level page table format
Catalin Marinas [Mon, 31 Jan 2011 13:50:43 +0000 (13:50 +0000)]
ARM: LPAE: MMU setup for the 3-level page table format

This patch adds the MMU initialisation for the LPAE page table format.
The swapper_pg_dir size with LPAE is 5 rather than 4 pages. A new
proc-v7lpae.S file contains the initialisation, context switch and
save/restore code for ARMv7 with the LPAE. The TTBRx split is based on
the PAGE_OFFSET with TTBR1 used for the kernel mappings. The 36-bit
mappings (supersections) and a few other memory types in mmu.c are
conditionally compiled.

Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
12 years agoARM: LPAE: Page table maintenance for the 3-level format
Catalin Marinas [Mon, 31 Jan 2011 13:50:42 +0000 (13:50 +0000)]
ARM: LPAE: Page table maintenance for the 3-level format

This patch modifies the pgd/pmd/pte manipulation functions to support
the 3-level page table format. Since there is no need for an 'ext'
argument to cpu_set_pte_ext(), this patch conditionally defines a
different prototype for this function when CONFIG_ARM_LPAE.

The patch also introduces the L_PGD_SWAPPER flag to mark pgd entries
pointing to pmd tables pre-allocated in the swapper_pg_dir and avoid
trying to free them at run-time. This flag is 0 with the classic page
table format.

Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
12 years agoARM: LPAE: Introduce the 3-level page table format definitions
Catalin Marinas [Mon, 31 Jan 2011 13:50:41 +0000 (13:50 +0000)]
ARM: LPAE: Introduce the 3-level page table format definitions

This patch introduces the pgtable-3level*.h files with definitions
specific to the LPAE page table format (3 levels of page tables).

Each table is 4KB and has 512 64-bit entries. An entry can point to a
40-bit physical address. The young, write and exec software bits share
the corresponding hardware bits (negated). Other software bits use spare
bits in the PTE.

The patch also changes some variable types from unsigned long or int to
pteval_t or pgprot_t.

Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
12 years agoARM: LPAE: Use a mask for physical addresses in page table entries
Catalin Marinas [Mon, 31 Jan 2011 13:50:41 +0000 (13:50 +0000)]
ARM: LPAE: Use a mask for physical addresses in page table entries

With LPAE, the physical address mask is 40-bit while the page table
entry is 64-bit. This patch introduces PHYS_MASK for the 2-level page
table format, defined as ~0UL.

Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
12 years agoARM: LPAE: Add (pte|pmd)val_t type definitions as u32
Catalin Marinas [Mon, 31 Jan 2011 13:50:40 +0000 (13:50 +0000)]
ARM: LPAE: Add (pte|pmd)val_t type definitions as u32

This patch defines the (pte|pmd)val_t as u32 and changes the page table
types to be based on these. The PMD bits are converted to the
corresponding type using the _AT macro.

The flush_pmd_entry/clean_pmd_entry argument was changed to (void *) to
allow them to be used with both PGD and PMD pointers and avoid code
duplication.

Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
12 years agoARM: LPAE: Factor out 2-level page table definitions into separate files
Catalin Marinas [Mon, 31 Jan 2011 13:50:39 +0000 (13:50 +0000)]
ARM: LPAE: Factor out 2-level page table definitions into separate files

This patch moves page table definitions from asm/page.h, asm/pgtable.h
and asm/ptgable-hwdef.h into corresponding *-2level* files.

Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
12 years agoARM: LPAE: Use PMD_(SHIFT|SIZE|MASK) instead of PGDIR_*
Catalin Marinas [Mon, 31 Jan 2011 13:50:39 +0000 (13:50 +0000)]
ARM: LPAE: Use PMD_(SHIFT|SIZE|MASK) instead of PGDIR_*

PGDIR_SHIFT and PMD_SHIFT for the classic 2-level page table format have
the same value (21). This patch converts the PGDIR_* uses in the kernel
to the PMD_* equivalent so that LPAE builds can reuse the same code.

Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
12 years agoARM: LPAE: Cast the dma_addr_t argument to unsigned long in dma_to_virt
Catalin Marinas [Tue, 9 Aug 2011 14:27:32 +0000 (15:27 +0100)]
ARM: LPAE: Cast the dma_addr_t argument to unsigned long in dma_to_virt

This is to avoid a compiler warning when invoking the __bus_to_virt()
macro. The dma_to_virt() function gets addresses within the 32-bit
range.

Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
12 years agoARM: LPAE: add ISBs around MMU enabling code
Will Deacon [Thu, 7 Apr 2011 15:29:22 +0000 (16:29 +0100)]
ARM: LPAE: add ISBs around MMU enabling code

Before we enable the MMU, we must ensure that the TTBR registers contain
sane values. After the MMU has been enabled, we jump to the *virtual*
address of the following function, so we also need to ensure that the
SCTLR write has taken effect.

This patch adds ISB instructions around the SCTLR write to ensure the
visibility of the above.

Signed-off-by: Will Deacon <will.deacon@arm.com>
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
12 years agoARM: pgtable: switch to use pgtable-nopud.h
Russell King [Sun, 21 Nov 2010 16:37:42 +0000 (16:37 +0000)]
ARM: pgtable: switch to use pgtable-nopud.h

Nick Piggin noted upon introducing 4level-fixup.h:

| Add a temporary "fallback" header so architectures can run with
| the 4level pagetables patch without modification. All architectures
| should be converted to use the folding headers (include/asm-generic/
| pgtable-nop?d.h) as soon as possible, and the fallback header removed.

This makes ARM compliant with this statement.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
12 years agodrm/radeon: Extended DDC Probing for Toshiba L300D Radeon Mobility X1100 HDMI-A Connector
Thomas Reim [Wed, 17 Aug 2011 09:03:32 +0000 (09:03 +0000)]
drm/radeon: Extended DDC Probing for Toshiba L300D Radeon Mobility X1100 HDMI-A Connector

Toshiba Satellite L300D with ATI Mobility Radeon X1100 sends data
   to i2c bus for a HDMI connector that is not implemented/existent
   on the notebook's board.

   Fix by applying extented DDC probing for this connector.

   Requires [PATCH] drm/radeon: Extended DDC Probing for Connectors
   with Improperly Wired DDC Lines

   Tested for kernel 2.6.38 on Toshiba Satellite L300D notebook

BugLink: http://bugs.launchpad.net/bugs/826677
Signed-off-by: Thomas Reim <reimth@gmail.com>
Acked-by: Chris Routh <routhy@gmail.com>
Cc: <stable@kernel.org>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
12 years agoMerge branch 'atag_offset' of git://git.linaro.org/people/nico/linux into devel-stable
Russell King [Tue, 23 Aug 2011 09:54:51 +0000 (10:54 +0100)]
Merge branch 'atag_offset' of git://git.linaro.org/people/nico/linux into devel-stable

12 years agoMerge branch 'dma-size' of git://git.yxit.co.uk/linux into devel-stable
Russell King [Tue, 23 Aug 2011 09:54:45 +0000 (10:54 +0100)]
Merge branch 'dma-size' of git://git.yxit.co.uk/linux into devel-stable

12 years agoHID: wiimote: Add status and return request handlers
David Herrmann [Wed, 17 Aug 2011 09:43:24 +0000 (11:43 +0200)]
HID: wiimote: Add status and return request handlers

The wiimote resets the current drm when an extension is plugged in.
Fortunately, it also sends a status report in this situation so we just
reset the drm on every status report to keep the drm consistent.

Also handle return reports from the wiimote which indicate success and
failure of requests that we've sent.

Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
12 years agoHID: wiimote: Add drm request
David Herrmann [Wed, 17 Aug 2011 09:43:23 +0000 (11:43 +0200)]
HID: wiimote: Add drm request

The wiimote reports data in several data reporting modes (DRM). The DRM
request makes the wiimote send data in the requested drm.

The DRM mode can be set explicitely or can be chosen by the driver. To let
the driver choose the DRM mode, pass WIIPROTO_REQ_NULL placeholder to it. This
is no valid request and is replaced with an appropriate DRM.

Currently, the driver always sets the basic DRM_K mode, but this will be
extended when further peripherals like accelerometer and IR are supported.

Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
12 years agoHID: wiimote: Register led class devices
David Herrmann [Wed, 17 Aug 2011 09:43:22 +0000 (11:43 +0200)]
HID: wiimote: Register led class devices

This registers 4 led devices to allow controlling the wiimote leds via standard
LED sysfs API. It removes the four sysfs attributes so we don't have two APIs
for one device.

Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
12 years agoHID: wiimote: Correctly call HID open/close callbacks
David Herrmann [Wed, 17 Aug 2011 09:43:21 +0000 (11:43 +0200)]
HID: wiimote: Correctly call HID open/close callbacks

Even though the bluetooth hid backend does not react on open/close callbacks, we
should call them to be consistent with other hid drivers.

Also the new input open/close handlers will be used in future to prepare the
wiimote device for IR/extension input.

Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
12 years agoHID: wiimote: Simplify synchronization
David Herrmann [Wed, 17 Aug 2011 09:43:20 +0000 (11:43 +0200)]
HID: wiimote: Simplify synchronization

The new locking scheme in HID core allows us to remove a bit of synchronization.
Since the HID layer acts synchronously we simply register input core last and
there are no synchonization issues anymore.
Also register sysfs files after that to simplify the code.

Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>