safe/jmp/linux-2.6
14 years agoUSB: usb_debug: use the generic kfifo-based write implementation
Johan Hovold [Wed, 17 Mar 2010 22:06:05 +0000 (23:06 +0100)]
USB: usb_debug: use the generic kfifo-based write implementation

Use the generic kfifo-based write implementation rather than allowing up
to 4000 8 byte urbs in the host stack queues.

Cc: Jason Wessel <jason.wessel@windriver.com>
Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: pl2303: use generic close
Johan Hovold [Wed, 17 Mar 2010 22:06:04 +0000 (23:06 +0100)]
USB: pl2303: use generic close

Use usb_serial_generic_close to kill the read and write urbs and to
reset the write fifo.

Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: pl2303: switch to generic write implementation
Johan Hovold [Wed, 17 Mar 2010 22:06:03 +0000 (23:06 +0100)]
USB: pl2303: switch to generic write implementation

Replace custom fifo-based write implementation with the generic
kfifo-based one.

Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: serial: clean up generic write start busy test
Johan Hovold [Wed, 17 Mar 2010 22:06:02 +0000 (23:06 +0100)]
USB: serial: clean up generic write start busy test

Submit write urb if it is not already in use and we have buffered data.

Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: serial: clean up some error and debug messages in generic driver
Johan Hovold [Wed, 17 Mar 2010 22:06:01 +0000 (23:06 +0100)]
USB: serial: clean up some error and debug messages in generic driver

Clean up error messages on usb_submit_urb failure.
Remove debug message on zero-length writes.

Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: ftdi_sio: switch to generic read implementation
Johan Hovold [Wed, 17 Mar 2010 22:06:00 +0000 (23:06 +0100)]
USB: ftdi_sio: switch to generic read implementation

Switch to generic read implementation and use process_read_urb to do
device specific processing (handle line status).

Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: serial: export generic throttle and unthrottle
Johan Hovold [Wed, 17 Mar 2010 22:05:59 +0000 (23:05 +0100)]
USB: serial: export generic throttle and unthrottle

Allow drivers to use the generic throttle and unthrottle implementation.
This makes sense for drivers using the generic read functionality.

Note that drivers need to set these explicitly in order to enable them
(i.e., we do not set them at port probe if not defined).

Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: pl2303: switch to generic read implementation
Johan Hovold [Wed, 17 Mar 2010 22:05:58 +0000 (23:05 +0100)]
USB: pl2303: switch to generic read implementation

Use generic read implementation and use process_read_urb to do device
specific processing (handle line status).

Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: serial: generalise generic read implementation
Johan Hovold [Wed, 17 Mar 2010 22:05:57 +0000 (23:05 +0100)]
USB: serial: generalise generic read implementation

Add process_read_urb to usb_serial_driver so that a driver can rely on
the generic read (and throttle) mechanism but still do device specific
processing of incoming data (such as adding tty_flags before pushing to
line discipline).

The default generic implementation handles sysrq for consoles but
otherwise simply pushes to tty.

Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: serial: clean up read processing in generic driver
Johan Hovold [Wed, 17 Mar 2010 22:05:56 +0000 (23:05 +0100)]
USB: serial: clean up read processing in generic driver

Always process and flush read urb, but only resubmit when not throttled.
The new tty-layer supply plenty of slack so there is really no need to
cache and delay processing of a single urb while throttled.

Note that unthrottle now submits using GFP_KERNEL as we are not in
atomic context (so there is no need to save irq state either).

Note also that the process_read_urb function could be added to
usb_serial_driver should any driver need to do any device specific
processing.

Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: cp210x: use generic submit_read_urb at open
Johan Hovold [Wed, 17 Mar 2010 22:05:55 +0000 (23:05 +0100)]
USB: cp210x: use generic submit_read_urb at open

There is no need to initialise the read urb as this is done at port
probe.

Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: serial: remove unnecessary re-initialisation of generic urbs
Johan Hovold [Wed, 17 Mar 2010 22:05:54 +0000 (23:05 +0100)]
USB: serial: remove unnecessary re-initialisation of generic urbs

The generic read and write bulk urbs are initialised when allocated in
usb_serial_probe. The only field that needs to be updated after that is
the transfer_buffer_length of the write urb.

Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: serial: refactor read urb submission in generic driver
Johan Hovold [Wed, 17 Mar 2010 22:05:53 +0000 (23:05 +0100)]
USB: serial: refactor read urb submission in generic driver

Use the already exported function for submitting the read urb associated
with a usb_serial_port.

Make sure it returns the result of usb_submit_urb and rename to the
more descriptive usb_serial_generic_submit_read_urb.

Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: serial: refactor generic close
Johan Hovold [Wed, 17 Mar 2010 22:00:45 +0000 (23:00 +0100)]
USB: serial: refactor generic close

Export usb_serial_generic_close so that drivers can easily kill the read
and write urb and make sure that the write fifo is reset.

Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: serial: clear fifo on close
Johan Hovold [Wed, 17 Mar 2010 22:00:44 +0000 (23:00 +0100)]
USB: serial: clear fifo on close

Make sure fifo is emptied on close.

Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: serial: fix missing locking on fifo in write callback
Johan Hovold [Wed, 17 Mar 2010 22:00:43 +0000 (23:00 +0100)]
USB: serial: fix missing locking on fifo in write callback

On errors the fifo was reset without any locking. This could race with
write which do kfifo_put and perhaps also chars_in_buffer and write_room.

Every other access to the fifo is protected using the port lock so
better add it to the error path as well.

Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: serial: fix generic chars_in_buffer
Johan Hovold [Wed, 17 Mar 2010 22:00:42 +0000 (23:00 +0100)]
USB: serial: fix generic chars_in_buffer

Make sure chars_in_buffer accounts also for data in host stack queues.

This fixes the problem with tty_wait_until_sent returning too soon at
close which could cause the final write urb to be cancelled.

Reported-by: Pete Zaitcev <zaitcev@redhat.com>
Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: pl2303: increase bulk-in buffer size to 256 byte
Johan Hovold [Wed, 17 Mar 2010 22:00:41 +0000 (23:00 +0100)]
USB: pl2303: increase bulk-in buffer size to 256 byte

The pl2303 requires a bulk-in buffer larger than endpoint size to keep
up at high baudrates without loosing data.

Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: pl2303: increase the bulk-out buffer size to 256 byte
Johan Hovold [Wed, 17 Mar 2010 22:00:40 +0000 (23:00 +0100)]
USB: pl2303: increase the bulk-out buffer size to 256 byte

Increase the bulk-out buffer size from 64 to 256 byte.

This gives a significant increase in throughput already at 1Mbaud as well
as lowered CPU usage. The buffer is big enough to keep up also at 3Mbaud
(128b would not suffice).

        64b         256b
921k:   640 KB/s    870 KB/s
3M:     640 KB/s    2520 KB/s

Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: cp210x: increase bulk-in buffer size to 256 byte
Johan Hovold [Wed, 17 Mar 2010 22:00:39 +0000 (23:00 +0100)]
USB: cp210x: increase bulk-in buffer size to 256 byte

The cp210x requires a bulk-in buffer larger than endpoint size to keep
up at high baudrates without loosing data.

Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: cp210x: increase the bulk-out buffer size to 256 byte
Johan Hovold [Wed, 17 Mar 2010 22:00:38 +0000 (23:00 +0100)]
USB: cp210x: increase the bulk-out buffer size to 256 byte

Increase the bulk-out buffer size from 64 to 256 byte.

This gives a significant increase in throughput already at 1Mbaud
(e.g. 710 instead of 640 KB/s) as well as lowered CPU usage.

Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: serial: allow drivers to define bulk buffer sizes
Johan Hovold [Wed, 17 Mar 2010 22:00:37 +0000 (23:00 +0100)]
USB: serial: allow drivers to define bulk buffer sizes

Allow drivers to define custom bulk in/out buffer sizes in struct
usb_serial_driver. If not set, fall back to the default buffer size
which matches the endpoint size.

Three drivers are currently freeing the pre-allocated buffers and
allocating larger ones to achieve this at port probe (ftdi_sio) or even
at port open (ipaq and iuu_phoenix), which needless to say is suboptimal.

Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: Add a new quirk: USB_QUIRK_HONOR_BNUMINTERFACES
Hans de Goede [Mon, 29 Mar 2010 10:03:17 +0000 (12:03 +0200)]
USB: Add a new quirk: USB_QUIRK_HONOR_BNUMINTERFACES

Add a new quirk USB_QUIRK_HONOR_BNUMINTERFACES, when this quirk is
set and a device has more interface descriptors in a configuration
then it claims to have in config->bNumInterfaces, ignore all additional
interfaces.

This is needed for devices which try to hide unused interfaces by only
lowering config->bNumInterfaces, and which can't handle if you try to talk
to the "hidden" interfaces.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Acked-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agousb: fix serial build when SYSRQ is disabled
Randy Dunlap [Thu, 25 Mar 2010 18:29:16 +0000 (11:29 -0700)]
usb: fix serial build when SYSRQ is disabled

Fix build error when CONFIG_MAGIC_SYSRQ is not enabled:

drivers/usb/serial/generic.c:566: error: implicit declaration of function 'handle_sysrq'

Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB Serial Driver: ZIO Motherboard
Vijay Kumar [Wed, 10 Mar 2010 15:47:56 +0000 (21:17 +0530)]
USB Serial Driver: ZIO Motherboard

Add ZIO Motherboard USB serial interface driver.

Signed-off-by: Vijay Kumar B. <vijaykumar@zilogic.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agousb-console: pass baud from console to the initial tty open
Jason Wessel [Tue, 16 Mar 2010 21:05:44 +0000 (16:05 -0500)]
usb-console: pass baud from console to the initial tty open

The usb console code has had a long standing problem of not being able
to pass the baud rate from the kernel argument console=ttyUSB0,BAUD
down to the initial tty open, unless you were willing to settle for
9600 baud.

The solution is to directly use tty_init_termios() in
usb_console_setup() as this will preserve any changes to the initial
termios setting on future opens.

CC: Alan Cox <alan@linux.intel.com>
CC: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Jason Wessel <jason.wessel@windriver.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: f_mass_storage: dynamic buffers for better alignment
Michal Nazarewicz [Mon, 15 Mar 2010 20:38:31 +0000 (21:38 +0100)]
USB: f_mass_storage: dynamic buffers for better alignment

"Static" buffers in fsg_buffhd structure (ie. fields which are arrays
rather then pointers to dynamically allocated memory) are not aligned
to any "big" power of two which may lead to poor DMA performance
(copying "by hand" of head or tail) or no DMA at all even if otherwise
hardware supports it.

Therefore, this patch makes mass storage function use kmalloc()ed
buffers which are (because of their size) page aligned (which should
be enough for any hardware).

Signed-off-by: Michal Nazarewicz <m.nazarewicz@samsung.com>
Cc: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agousb: musb: hsdma: use musb_read/writel
Felipe Balbi [Fri, 12 Mar 2010 08:29:13 +0000 (10:29 +0200)]
usb: musb: hsdma: use musb_read/writel

... and simplify the was we read/write from/to
DMA COUNT register.

Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agousb: musb: gadget: support musb-specific test modes
Felipe Balbi [Fri, 12 Mar 2010 08:29:12 +0000 (10:29 +0200)]
usb: musb: gadget: support musb-specific test modes

we can support the musb-specific test modes on the
vendor specific range of test selector as stated
on USB Specification Table 9-7 Test Mode Selectors.

Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agousb: musb: add debugfs support
Felipe Balbi [Fri, 12 Mar 2010 08:29:11 +0000 (10:29 +0200)]
usb: musb: add debugfs support

for now only a simple register dump entry (which can
be rather useful on debugging) and a way to start
test modes.

Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: musb: allow the Blackfin vrsel gpio to be active low
Cliff Cai [Fri, 12 Mar 2010 08:29:10 +0000 (10:29 +0200)]
USB: musb: allow the Blackfin vrsel gpio to be active low

Rather than hardcoding the gpio levels for vrsel, allow the platform
resources to handle this so boards can be active high or low.

Signed-off-by: Cliff Cai <cliff.cai@analog.com>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: MUSB: Add OMAP4 support in MUSB driver
Maulik Mankad [Fri, 12 Mar 2010 08:29:09 +0000 (10:29 +0200)]
USB: MUSB: Add OMAP4 support in MUSB driver

This patch adds CONFIG_ARCH_OMAP4 macro within
MUSB driver.

Signed-off-by: Maulik Mankad <x0082077@ti.com>
Cc: David Brownell <david-b@pacbell.net>
Cc: Sergei Shtylyov <sshtylyov@mvista.com>
Cc: Olof Johansson <olof@lixom.net>
Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: MUSB: Build MUSB driver for OMAP4
Maulik Mankad [Fri, 12 Mar 2010 08:29:08 +0000 (10:29 +0200)]
USB: MUSB: Build MUSB driver for OMAP4

This patch updates the Makefile to build the
MUSB driver for OMAP4. It also sets the Kconfig
options for OMAP4.

Signed-off-by: Maulik Mankad <x0082077@ti.com>
Cc: David Brownell <david-b@pacbell.net>
Cc: Sergei Shtylyov <sshtylyov@mvista.com>
Cc: Olof Johansson <olof@lixom.net>
Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agousb: musb: Set transceiver interface type
Maulik Mankad [Fri, 12 Mar 2010 08:29:07 +0000 (10:29 +0200)]
usb: musb: Set transceiver interface type

Program the OTG_INTERFSEL register based on
transcevier type passed from board file.

Adapt signature of musb_platform_init() function
for davinci, blackfin and tusb6010.

Signed-off-by: Maulik Mankad <x0082077@ti.com>
Cc: David Brownell <david-b@pacbell.net>
Cc: Sergei Shtylyov <sshtylyov@mvista.com>
Cc: Olof Johansson <olof@lixom.net>
Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agousb: musb: allow board to pass down fifo mode
Felipe Balbi [Fri, 12 Mar 2010 08:29:06 +0000 (10:29 +0200)]
usb: musb: allow board to pass down fifo mode

boards might want to optimize their fifo configuration
to the particular needs of that specific board. Allow
that by moving all related data structures to
<linux/usb/musb.h>

Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agousb-serial: Use tty_port version console instead of usb_serial_port
Jason Wessel [Tue, 9 Mar 2010 03:50:12 +0000 (21:50 -0600)]
usb-serial: Use tty_port version console instead of usb_serial_port

Replace all instances of using the console variable in struct
usb_serial_port with the struct tty_port version.

CC: Alan Cox <alan@linux.intel.com>
CC: Alan Stern <stern@rowland.harvard.edu>
CC: Oliver Neukum <oliver@neukum.org>
CC: Andrew Morton <akpm@linux-foundation.org>
CC: linux-usb@vger.kernel.org
CC: linux-kernel@vger.kernel.org
Signed-off-by: Jason Wessel <jason.wessel@windriver.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: ehci-au1xxx does not need EHCI IO watchdog
Manuel Lauss [Mon, 8 Mar 2010 19:43:32 +0000 (20:43 +0100)]
USB: ehci-au1xxx does not need EHCI IO watchdog

I've been running variations of this patch for well over a year now;
my usual zoo of test devices didn't trigger any ill effects even
under heavy load.  As a nice sideeffect idle-wakeups are reduced
from 20/s to about 2/s (EHCI hub with mouse and kbd).

Signed-off-by: Manuel Lauss <manuel.lauss@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: remove uses of URB_NO_SETUP_DMA_MAP
Alan Stern [Fri, 5 Mar 2010 20:10:17 +0000 (15:10 -0500)]
USB: remove uses of URB_NO_SETUP_DMA_MAP

This patch (as1350) removes all usages of coherent buffers for USB
control-request setup-packet buffers.  There's no good reason to
reserve coherent memory for these things; control requests are hardly
ever used in large quantity (the major exception is firmware
transfers, and they aren't time-critical).  Furthermore, only seven
drivers used it.  We might as well always use streaming DMA mappings
for setup-packet buffers, and remove some extra complexity from
usbcore.

The DMA-mapping portion of hcd.c is currently in flux.  A separate
patch will be submitted to remove support for URB_NO_SETUP_DMA_MAP
after everything else settles down.  The removal should go smoothly,
as by then nobody will be using it.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: straighten out port feature vs. port status usage
Alan Stern [Thu, 4 Mar 2010 22:05:08 +0000 (17:05 -0500)]
USB: straighten out port feature vs. port status usage

This patch (as1349b) clears up the confusion in many USB host
controller drivers between port features and port statuses.  In mosty
cases it's true that the status bit is in the position given by the
corresponding feature value, but that's not always true and it's not
guaranteed in the USB spec.

There's no functional change, just replacing expressions of the form
(1 << USB_PORT_FEAT_x) with USB_PORT_STAT_x, which has the same value.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: remove bogus USB_PORT_FEAT_*_SPEED symbols
Alan Stern [Thu, 4 Mar 2010 16:32:30 +0000 (11:32 -0500)]
USB: remove bogus USB_PORT_FEAT_*_SPEED symbols

This patch (as1348) removes the bogus
USB_PORT_FEAT_{HIGHSPEED,SUPERSPEED} symbols from ch11.h.  No such
features are defined by the USB spec.  (There is a PORT_LOWSPEED
feature, but the spec doesn't mention it except to say that host
software should never use it.)  The speed indicators are port
statuses, not port features.

As a temporary workaround for the xhci-hcd driver, a fictional
USB_PORT_STAT_SUPER_SPEED symbol is added.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
CC: Sarah Sharp <sarah.a.sharp@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: remove duplicated #include
Huang Weiyi [Thu, 4 Mar 2010 13:57:51 +0000 (21:57 +0800)]
USB: remove duplicated #include

Remove duplicated #include('s) in
  drivers/usb/core/hcd.c

Signed-off-by: Huang Weiyi <weiyi.huang@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: Remove large struct from the stack in USB storage isd200 driver
Ian Munsie [Wed, 3 Mar 2010 00:00:37 +0000 (11:00 +1100)]
USB: Remove large struct from the stack in USB storage isd200 driver

The compiler throws the following warning when compiling for a PowerPC 64
bit machine:

drivers/usb/storage/isd200.c:580: warning: the frame size of 2208 bytes is larger than 2048 bytes

There is a struct scsi_device which is placed on the stack and is
largely responsible for such wastage. The struct is just a dummy struct
filled with NULLs and set as the scsi_cmnd->device to make the
usb_stor_Bulk_transport function happy.

This patch makes the struct static, so that it is never placed onto the
stack and silences the compiler warning.

Signed-off-by: Ian Munsie <imunsie@au.ibm.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: cdc-acm: make bitfields unsigned
Randy Dunlap [Tue, 2 Mar 2010 22:52:33 +0000 (14:52 -0800)]
USB: cdc-acm: make bitfields unsigned

Fix usb/class sparse warnings:

drivers/usb/class/cdc-acm.h:128:34: error: dubious one-bit signed bitfield
drivers/usb/class/cdc-acm.h:129:24: error: dubious one-bit signed bitfield

Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: sisusbvga: Remove the BKL from ioctl
Alessio Igor Bogani [Mon, 1 Mar 2010 13:10:56 +0000 (14:10 +0100)]
USB: sisusbvga: Remove the BKL from ioctl

Seems to me that BKL is not needed here because necessary locking is already
provided by mutex sisusb->lock.

Also change the returned value to long.

Signed-off-by: Alessio Igor Bogani <abogani@texware.it>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: split hub.h into ch11.h and merge-in hcd.h
Eric Lescouet [Sat, 24 Apr 2010 21:38:17 +0000 (23:38 +0200)]
USB: split hub.h into ch11.h and merge-in hcd.h

Base on inputs from Alan Stern, split the hub.h header into:
- new ch11.h header (most of it) containing constants and
  structures from chapter 11 of the USB 2.0 spec.
- a small remaining part being merged into hcd.h.

Signed-of-by: Eric Lescouet <eric@lescouet.org>
Cc: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: make hub.h public (drivers dependency)
Eric Lescouet [Sat, 24 Apr 2010 21:34:27 +0000 (23:34 +0200)]
USB: make hub.h public (drivers dependency)

The usbcore headers: hcd.h and hub.h are shared between usbcore,
HCDs and a couple of other drivers (e.g. USBIP modules).
So, it makes sense to move them into a more public location and
to cleanup dependency of those modules on kernel internal headers.
This patch moves hub.h from drivers/usb/core into include/linux/usb/

Signed-of-by: Eric Lescouet <eric@lescouet.org>
Cc: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: make hcd.h public (drivers dependency)
Eric Lescouet [Sat, 24 Apr 2010 21:21:52 +0000 (23:21 +0200)]
USB: make hcd.h public (drivers dependency)

The usbcore headers: hcd.h and hub.h are shared between usbcore,
HCDs and a couple of other drivers (e.g. USBIP modules).
So, it makes sense to move them into a more public location and
to cleanup dependency of those modules on kernel internal headers.
This patch moves hcd.h from drivers/usb/core into include/linux/usb/

Signed-of-by: Eric Lescouet <eric@lescouet.org>
Cc: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: xhci: Fix check for room on the ring.
Sarah Sharp [Tue, 18 May 2010 23:05:26 +0000 (16:05 -0700)]
USB: xhci: Fix check for room on the ring.

The length of the scatter gather list a driver can enqueue is limited by
the bus' sg_tablesize to 62 entries.  Each entry will be described by at
least one transfer request block (TRB).  If the entry's buffer crosses a
64KB boundary, then that entry will have to be described by two or more
TRBs.  So even if the USB device driver respects sg_tablesize, the whole
scatter list may take more than 62 TRBs to describe, and won't fit on
the ring.

Don't assume that an empty ring means there is enough room on the
transfer ring.  The old code would unconditionally queue this too-large
transfer, and over write the beginning of the transfer.  This would mean
the cycle bit was unchanged in those overwritten transfers, causing the
hardware to think it didn't own the TRBs, and the host would seem to
hang.

Now drivers may see submit_urb() fail with -ENOMEM if the transfers are
too big to fit on the ring.

Signed-off-by: Sarah Sharp <sarah.a.sharp@linux.intel.com>
Cc: stable <stable@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: xhci: Limit bus sg_tablesize to 62 TRBs.
Sarah Sharp [Tue, 18 May 2010 23:05:21 +0000 (16:05 -0700)]
USB: xhci: Limit bus sg_tablesize to 62 TRBs.

When a scatter-gather list is enqueued to the xHCI driver, it translates
each entry into a transfer request block (TRB).  Only 63 TRBs can be
used per ring segment, and there must be one additional TRB reserved to
make sure the hardware does not think the ring is empty (so the enqueue
pointer doesn't equal the dequeue pointer).  Limit the bus sg_tablesize
to 62 TRBs.

Signed-off-by: Sarah Sharp <sarah.a.sharp@linux.intel.com>
Cc: stable <stable@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoUSB: xhci: Fix issue with set interface after stall.
Sarah Sharp [Thu, 6 May 2010 20:40:08 +0000 (13:40 -0700)]
USB: xhci: Fix issue with set interface after stall.

When the USB core installs a new interface, it unconditionally clears the
halts on all the endpoints on the new interface.  Usually the xHCI host
needs to know when an endpoint is reset, so it can change its internal
endpoint state.  In this case, it doesn't care, because the endpoints were
never halted in the first place.

To avoid issuing a redundant Reset Endpoint command, the xHCI driver looks
at xhci_virt_ep->stopped_td to determine if the endpoint was actually
halted.  However, the functions that handle the stall never set that
variable to NULL after it dealt with the stall.  So if an endpoint stalled
and a Reset Endpoint command completed, and then the class driver tried to
install a new alternate setting, the xHCI driver would access the old
xhci_virt_ep->stopped_td pointer.  A similar problem occurs if the
endpoint has been stopped to cancel a transfer.

Signed-off-by: Sarah Sharp <sarah.a.sharp@linux.intel.com>
Cc: stable <stable@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
14 years agoMerge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input
Linus Torvalds [Thu, 20 May 2010 17:33:06 +0000 (10:33 -0700)]
Merge branch 'for-linus' of git://git./linux/kernel/git/dtor/input

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input: (40 commits)
  Input: psmouse - small formatting changes to better follow coding style
  Input: synaptics - set dimensions as reported by firmware
  Input: elantech - relax signature checks
  Input: elantech - enforce common prefix on messages
  Input: wistron_btns - switch to using kmemdup()
  Input: usbtouchscreen - switch to using kmemdup()
  Input: do not force selecting i8042 on Moorestown
  Input: Documentation/sysrq.txt - update KEY_SYSRQ info
  Input: 88pm860x_onkey - remove invalid irq number assignment
  Input: i8042 - add a PNP entry to the aux device list
  Input: i8042 - add some extra PNP keyboard types
  Input: wm9712 - fix wm97xx_set_gpio() logic
  Input: add keypad driver for keys interfaced to TCA6416
  Input: remove obsolete {corgi,spitz,tosa}kbd.c
  Input: kbtab - do not advertise unsupported events
  Input: kbtab - simplify kbtab_disconnect()
  Input: kbtab - fix incorrect size parameter in usb_buffer_free
  Input: acecad - don't advertise mouse events
  Input: acecad - fix some formatting issues
  Input: acecad - simplify usb_acecad_disconnect()
  ...

Trivial conflict in Documentation/feature-removal-schedule.txt

14 years agoMerge branch 'acpica' of git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux...
Linus Torvalds [Thu, 20 May 2010 16:45:38 +0000 (09:45 -0700)]
Merge branch 'acpica' of git://git./linux/kernel/git/lenb/linux-acpi-2.6

* 'acpica' of git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux-acpi-2.6: (22 commits)
  ACPI: fix early DSDT dmi check warnings on ia64
  ACPICA: Update version to 20100428.
  ACPICA: Update/clarify some parameter names associated with acpi_handle
  ACPICA: Rename acpi_ex_system_do_suspend->acpi_ex_system_do_sleep
  ACPICA: Prevent possible allocation overrun during object copy
  ACPICA: Split large file, evgpeblk
  ACPICA: Add GPE support for dynamically loaded ACPI tables
  ACPICA: Clarify/rename some root table descriptor fields
  ACPICA: Update version to 20100331.
  ACPICA: Minimize the differences between linux GPE code and ACPICA code base
  ACPI: add boot option acpi=copy_dsdt to fix corrupt DSDT
  ACPICA: Update DSDT copy/detection.
  ACPICA: Add subsystem option to force copy of DSDT to local memory
  ACPICA: Add detection of corrupted/replaced DSDT
  ACPICA: Add write support for DataTable operation regions
  ACPICA: Fix for acpi_reallocate_root_table for incorrect root table copy
  ACPICA: Update comments/headers, no functional change
  ACPICA: Update version to 20100304
  ACPICA: Fix for possible fault in acpi_ex_release_mutex
  ACPICA: Standardize integer output for ACPICA warnings/errors
  ...

14 years agoMerge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6
Linus Torvalds [Thu, 20 May 2010 16:41:44 +0000 (09:41 -0700)]
Merge branch 'for-linus' of git://git./linux/kernel/git/tiwai/sound-2.6

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6: (250 commits)
  ALSA: hda: Storage class should be before const qualifier
  ASoC: tpa6130a2: Remove CPVSS and HPVdd supplies
  ASoC: tpa6130a2: Define output pins with SND_SOC_DAPM_OUTPUT
  ASoC: sdp4430 - add sdp4430 pcm ops to DAI.
  ASoC: TWL6040: Enable earphone path in codec
  ASoC: SDP4430: Add support for Earphone speaker
  ASoC: SDP4430: Add sdp4430 machine driver
  ASoC: tlv320dac33: Avoid powering off while in BIAS_OFF
  ASoC: tlv320dac33: Use dev_dbg in dac33_hard_power function
  ALSA: sound/pci/asihpi: Use kzalloc
  ALSA: hdmi - dont fail on extra nodes
  ALSA: intelhdmi - add id for the CougarPoint chipset
  ALSA: intelhdmi - user friendly codec name
  ALSA: intelhdmi - add dependency on SND_DYNAMIC_MINORS
  ALSA: asihpi: incorrect range check
  ALSA: asihpi: testing the wrong variable
  ALSA: es1688: add pedantic range checks
  ARM: McBSP: Add support for omap4 in McBSP driver
  ARM: McBSP: Fix request for irq in OMAP4
  OMAP: McBSP: Add 32-bit mode support
  ...

14 years agoMerge branch 'for-linus/i2c-2635' of git://git.fluff.org/bjdooks/linux
Linus Torvalds [Thu, 20 May 2010 16:41:17 +0000 (09:41 -0700)]
Merge branch 'for-linus/i2c-2635' of git://git.fluff.org/bjdooks/linux

* 'for-linus/i2c-2635' of git://git.fluff.org/bjdooks/linux: (21 commits)
  i2c-highlander: remover superflous variable
  i2c-ibm-iic: drop NO_IRQ
  i2c-cpm: drop NO_IRQ
  i2c-mpc: drop NO_IRQ
  MAINTAINERS: add i2c tree for embedded platforms
  i2c-pxa: only define 'blue_murder'-function if DEBUG is #defined
  i2c-pxa: remove unused macro
  i2c-nomadik: fix operator precedence warning
  i2c-nomadik: release region when removed
  OMAP3: I2C: Clean up Errata 1p153 handling
  OMAP2/3: I2C: Errata ID i207: Clear wrong RDR interrupt
  omap: i2c: add a timeout to the busy waiting
  omap: i2c: make errata 1.153 workaround a separate function
  i2c-omap: add mpu wake up latency constraint in i2c
  omap: i2c: Add i2c support on omap4 platform
  i2c-bfin-twi: return completion in interrupt for smbus quick transfers
  i2c-bfin-twi: remove redundant retry
  i2c-bfin-twi: fix lost interrupts at high speeds
  i2c-bfin-twi: add debug output for error status
  i2c-bfin-twi: integrate timeout timer with completion interface
  ...

14 years agoMerge branch 'v4l_for_2.6.35' of git://git.kernel.org/pub/scm/linux/kernel/git/mcheha...
Linus Torvalds [Thu, 20 May 2010 16:37:45 +0000 (09:37 -0700)]
Merge branch 'v4l_for_2.6.35' of git://git./linux/kernel/git/mchehab/linux-2.6

* 'v4l_for_2.6.35' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-2.6: (534 commits)
  V4L/DVB (13554a): v4l: Use the video_drvdata function in drivers
  V4L/DVB: vivi and mem2mem_testdev need slab.h to build
  V4L/DVB: tm6000: bugfix image position
  V4L/DVB: IR/imon: remove dead IMON_KEY_RELEASE_OFFSET
  V4L/DVB: tm6000: README - add vbi
  V4L/DVB: Fix unlock logic at medusa_video_init
  V4L/DVB: fix dvb frontend lockup
  V4L/DVB: s2255drv: remove dead code
  V4L/DVB: s2255drv: return if vdev not found
  V4L/DVB: ov511: cleanup: remove unneeded null check
  V4L/DVB: media/mem2mem: dereferencing free memory
  V4L/DVB: media/IR: Add missing include file to rc-map.c
  V4L/DVB: dvb/stv6110x: cleanup error handling
  V4L/DVB: ngene: Add lgdt3303 and mt2131 deps to Kconfig
  V4L/DVB: ngene: start separating out DVB functions into separate file
  V4L/DVB: ngene: split out card specific code into a separate file
  V4L/DVB: ngene: split out i2c code into a separate file
  V4L/DVB: ngene: add initial support for digital side of Avermedia m780
  V4L/DVB: ngene: properly support boards where channel 0 isn't a TS input
  V4L-DVB: ngene: make sure that tuner headers are included
  ...

14 years agoMerge branch 'upstream-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jgarzi...
Linus Torvalds [Thu, 20 May 2010 16:27:37 +0000 (09:27 -0700)]
Merge branch 'upstream-linus' of git://git./linux/kernel/git/jgarzik/libata-dev

* 'upstream-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jgarzik/libata-dev: (49 commits)
  libata-sff: separate out BMDMA qc_issue
  libata-sff: prd is BMDMA specific
  libata-sff: ata_sff_[dumb_]qc_prep are BMDMA specific
  libata-sff: separate out BMDMA EH
  libata-sff: port_task is SFF specific
  libata-sff: ap->[last_]ctl are SFF specific
  libata-sff: rename ap->ops->drain_fifo() to sff_drain_fifo()
  libata-sff: introduce ata_sff_init/exit() and ata_sff_port_init()
  libata-sff: clean up BMDMA initialization
  libata-sff: clean up inheritance in several drivers
  libata-sff: reorder SFF/BMDMA functions
  sata_inic162x: kill PORT_PRD_ADDR initialization
  libata: kill ATA_FLAG_DISABLED
  libata-sff: kill unused prototype and make ata_dev_select() static
  libata-sff: update bmdma host bus error handling
  sata_mv: remove unnecessary initialization
  sata_inic162x: inic162x is not dependent on CONFIG_ATA_SFF
  pata_sch: use ata_pci_sff_init_one()
  pata_sil680: Do our own exec_command posting
  libata: Remove excess delay in the tf_load path
  ...

14 years agoMerge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial
Linus Torvalds [Thu, 20 May 2010 16:20:59 +0000 (09:20 -0700)]
Merge branch 'for-linus' of git://git./linux/kernel/git/jikos/trivial

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial: (44 commits)
  vlynq: make whole Kconfig-menu dependant on architecture
  add descriptive comment for TIF_MEMDIE task flag declaration.
  EEPROM: max6875: Header file cleanup
  EEPROM: 93cx6: Header file cleanup
  EEPROM: Header file cleanup
  agp: use NULL instead of 0 when pointer is needed
  rtc-v3020: make bitfield unsigned
  PCI: make bitfield unsigned
  jbd2: use NULL instead of 0 when pointer is needed
  cciss: fix shadows sparse warning
  doc: inode uses a mutex instead of a semaphore.
  uml: i386: Avoid redefinition of NR_syscalls
  fix "seperate" typos in comments
  cocbalt_lcdfb: correct sections
  doc: Change urls for sparse
  Powerpc: wii: Fix typo in comment
  i2o: cleanup some exit paths
  Documentation/: it's -> its where appropriate
  UML: Fix compiler warning due to missing task_struct declaration
  UML: add kernel.h include to signal.c
  ...

14 years agoMerge git://git.kernel.org/pub/scm/linux/kernel/git/brodo/pcmcia-2.6
Linus Torvalds [Thu, 20 May 2010 16:09:46 +0000 (09:09 -0700)]
Merge git://git./linux/kernel/git/brodo/pcmcia-2.6

* git://git.kernel.org/pub/scm/linux/kernel/git/brodo/pcmcia-2.6: (29 commits)
  pcmcia: disable PCMCIA ioctl also for ARM
  drivers/staging/comedi: dev_node removal (quatech_daqp_cs)
  drivers/staging/comedi: dev_node removal (ni_mio_cs)
  drivers/staging/comedi: dev_node removal (ni_labpc_cs)
  drivers/staging/comedi: dev_node removal (ni_daq_dio24)
  drivers/staging/comedi: dev_node removal (ni_daq_700)
  drivers/staging/comedi: dev_node removal (das08_cs)
  drivers/staging/comedi: dev_node removal (cb_das16_cs)
  pata_pcmcia: get rid of extra indirection
  pcmcia: remove suspend-related comment from yenta_socket.c
  pcmcia: call pcmcia_{read,write}_cis_mem with ops_mutex held
  pcmcia: remove pcmcia_add_device_lock
  pcmcia: update gfp/slab.h includes
  pcmcia: remove unused mem_op.h
  pcmcia: do not autoadd root PCI bus resources
  pcmcia: clarify alloc_io_space, move it to resource handlers
  pcmcia: move all pcmcia_resource_ops providers into one module
  pcmcia: move high level CIS access code to separate file
  pcmcia: dev_node removal (core)
  pcmcia: dev_node removal (remaining drivers)
  ...

14 years agoMerge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael...
Linus Torvalds [Thu, 20 May 2010 16:03:55 +0000 (09:03 -0700)]
Merge branch 'for-linus' of git://git./linux/kernel/git/rafael/suspend-2.6

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/suspend-2.6:
  PM: PM QOS update fix
  Freezer / cgroup freezer: Update stale locking comments
  PM / platform_bus: Allow runtime PM by default
  i2c: Fix bus-level power management callbacks
  PM QOS update
  PM / Hibernate: Fix block_io.c printk warning
  PM / Hibernate: Group swap ops
  PM / Hibernate: Move the first_sector out of swsusp_write
  PM / Hibernate: Separate block_io
  PM / Hibernate: Snapshot cleanup
  FS / libfs: Implement simple_write_to_buffer
  PM / Hibernate: document open(/dev/snapshot) side effects
  PM / Runtime: Add sysfs debug files
  PM: Improve device power management document
  PM: Update device power management document
  PM: Allow runtime_suspend methods to call pm_schedule_suspend()
  PM: pm_wakeup - switch to using bool

14 years agoMerge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/wq
Linus Torvalds [Thu, 20 May 2010 16:03:02 +0000 (09:03 -0700)]
Merge branch 'for-linus' of git://git./linux/kernel/git/tj/wq

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/wq:
  workqueue: change cancel_work_sync() to clear work->data
  workqueue: warn about flush_scheduled_work()

14 years agoMerge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/percpu
Linus Torvalds [Thu, 20 May 2010 16:02:49 +0000 (09:02 -0700)]
Merge branch 'for-linus' of git://git./linux/kernel/git/tj/percpu

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/percpu:
  ia64: add sparse annotation to __ia64_per_cpu_var()
  percpu: implement kernel memory based chunk allocation
  percpu: move vmalloc based chunk management into percpu-vm.c
  percpu: misc preparations for nommu support
  percpu: reorganize chunk creation and destruction
  percpu: factor out pcpu_addr_in_first/reserved_chunk() and update per_cpu_ptr_to_phys()

14 years agoMerge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/roland...
Linus Torvalds [Thu, 20 May 2010 16:00:34 +0000 (09:00 -0700)]
Merge branch 'for-linus' of git://git./linux/kernel/git/roland/infiniband

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/roland/infiniband:
  IB/core: Use kmemdup() instead of kmalloc()+memcpy()
  IB/iser: Fix error flow in iser_create_ib_conn_res()
  IB/iser: Enhance disconnection logic for multi-pathing
  IB/iser: Remove buggy back-pointer setting
  IB/iser: Add asynchronous event handler
  MAINTAINERS: Add cxgb4 and iw_cxgb4 entries
  RDMA/cxgb3: Shrink .text with compile-time init of handlers arrays
  IPoIB: Allow disabling/enabling TSO on the fly through ethtool
  IB/mlx4: Add support for masked atomic operations
  IB/core: Add support for masked atomic operations
  RDMA/cma: Randomize local port allocation
  RDMA/nes: Make unnecessarily global functions static
  RDMA/nes: Make nesadapter->phy_lock usage consistent
  RDMA/cxgb4: Add driver for Chelsio T4 RNIC
  IB/mthca: Use the dma state API instead of pci equivalents
  RDMA/amso1100: Use the dma state API instead of pci equivalents
  RDMA/cxgb3: Don't free skbs on NET_XMIT_* indications from LLD
  RDMA/cxgb3: Use the dma state API instead of pci equivalents
  IB: Explicitly rule out llseek to avoid BKL in default_llseek()

14 years agoMerge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris...
Linus Torvalds [Thu, 20 May 2010 15:55:50 +0000 (08:55 -0700)]
Merge branch 'for-linus' of git://git./linux/kernel/git/jmorris/security-testing-2.6

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/security-testing-2.6: (61 commits)
  KEYS: Return more accurate error codes
  LSM: Add __init to fixup function.
  TOMOYO: Add pathname grouping support.
  ima: remove ACPI dependency
  TPM: ACPI/PNP dependency removal
  security/selinux/ss: Use kstrdup
  TOMOYO: Use stack memory for pending entry.
  Revert "ima: remove ACPI dependency"
  Revert "TPM: ACPI/PNP dependency removal"
  KEYS: Do preallocation for __key_link()
  TOMOYO: Use mutex_lock_interruptible.
  KEYS: Better handling of errors from construct_alloc_key()
  KEYS: keyring_serialise_link_sem is only needed for keyring->keyring links
  TOMOYO: Use GFP_NOFS rather than GFP_KERNEL.
  ima: remove ACPI dependency
  TPM: ACPI/PNP dependency removal
  selinux: generalize disabling of execmem for plt-in-heap archs
  LSM Audit: rename LSM_AUDIT_NO_AUDIT to LSM_AUDIT_DATA_NONE
  CRED: Holding a spinlock does not imply the holding of RCU read lock
  SMACK: Don't #include Ext2 headers
  ...

14 years agoMerge branch 'topic/asoc' into for-linus
Takashi Iwai [Thu, 20 May 2010 10:00:43 +0000 (12:00 +0200)]
Merge branch 'topic/asoc' into for-linus

Conflicts:
sound/soc/codecs/ad1938.c

14 years agoMerge branch 'topic/hda' into for-linus
Takashi Iwai [Thu, 20 May 2010 09:59:52 +0000 (11:59 +0200)]
Merge branch 'topic/hda' into for-linus

14 years agoMerge branch 'topic/usb' into for-linus
Takashi Iwai [Thu, 20 May 2010 09:59:43 +0000 (11:59 +0200)]
Merge branch 'topic/usb' into for-linus

14 years agoMerge branch 'topic/jack' into for-linus
Takashi Iwai [Thu, 20 May 2010 09:59:37 +0000 (11:59 +0200)]
Merge branch 'topic/jack' into for-linus

14 years agoMerge branch 'topic/misc' into for-linus
Takashi Iwai [Thu, 20 May 2010 09:59:29 +0000 (11:59 +0200)]
Merge branch 'topic/misc' into for-linus

14 years agoMerge branch 'topic/nomm' into for-linus
Takashi Iwai [Thu, 20 May 2010 09:59:09 +0000 (11:59 +0200)]
Merge branch 'topic/nomm' into for-linus

14 years agoMerge branch 'topic/core-cleanup' into for-linus
Takashi Iwai [Thu, 20 May 2010 09:58:57 +0000 (11:58 +0200)]
Merge branch 'topic/core-cleanup' into for-linus

14 years agoALSA: hda: Storage class should be before const qualifier
Tobias Klauser [Thu, 20 May 2010 08:40:55 +0000 (10:40 +0200)]
ALSA: hda: Storage class should be before const qualifier

The C99 specification states in section 6.11.5:

The placement of a storage-class specifier other than at the beginning
of the declaration specifiers in a declaration is an obsolescent
feature.

Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
14 years agoASoC: tpa6130a2: Remove CPVSS and HPVdd supplies
Jarkko Nikula [Wed, 19 May 2010 07:52:28 +0000 (10:52 +0300)]
ASoC: tpa6130a2: Remove CPVSS and HPVdd supplies

These pins are for decoupling capacitors for the internal charge pumps
in TPA6130A2 and TPA6140A2 and not for connecting external supply.

Thanks to Eduardo Valentin <eduardo.valentin@nokia.com> for pointing out the
issue with TPA6130A2 and Ilkka Koskinen <ilkka.koskinen@nokia.com> with
TPA6140A2.

Signed-off-by: Jarkko Nikula <jhnikula@gmail.com>
Acked-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Reviewed-by: Ilkka Koskinen <ilkka.koskinen@nokia.com>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
14 years agoACPI: fix early DSDT dmi check warnings on ia64
Lin Ming [Wed, 12 May 2010 01:26:48 +0000 (09:26 +0800)]
ACPI: fix early DSDT dmi check warnings on ia64

WARNING: at drivers/firmware/dmi_scan.c:423 dmi_matches+0x70/0x160()
dmi check: not initialized yet.

This is caused by commit aa2110c
(ACPI: add boot option acpi=copy_dsdt to fix corrupt DSDT).
DMI is not initialized yet in acpi_early_init on ia64.

The DSDT DMI check table is x86 specific, so make it empty on other archs.
And this fixes the warnings on ia64.

Reported-and-tested-by: Tony Luck <tony.luck@intel.com>
Signed-off-by: Lin Ming <ming.m.lin@intel.com>
Signed-off-by: Len Brown <len.brown@intel.com>
14 years agoMerge branch 'for-2.6.35' of git://linux-nfs.org/~bfields/linux
Linus Torvalds [Thu, 20 May 2010 00:24:54 +0000 (17:24 -0700)]
Merge branch 'for-2.6.35' of git://linux-nfs.org/~bfields/linux

* 'for-2.6.35' of git://linux-nfs.org/~bfields/linux: (45 commits)
  Revert "nfsd4: distinguish expired from stale stateids"
  nfsd: safer initialization order in find_file()
  nfs4: minor callback code simplification, comment
  NFSD: don't report compiled-out versions as present
  nfsd4: implement reclaim_complete
  nfsd4: nfsd4_destroy_session must set callback client under the state lock
  nfsd4: keep a reference count on client while in use
  nfsd4: mark_client_expired
  nfsd4: introduce nfs4_client.cl_refcount
  nfsd4: refactor expire_client
  nfsd4: extend the client_lock to cover cl_lru
  nfsd4: use list_move in move_to_confirmed
  nfsd4: fold release_session into expire_client
  nfsd4: rename sessionid_lock to client_lock
  nfsd4: fix bare destroy_session null dereference
  nfsd4: use local variable in nfs4svc_encode_compoundres
  nfsd: further comment typos
  sunrpc: centralise most calls to svc_xprt_received
  nfsd4: fix unlikely race in session replay case
  nfsd4: fix filehandle comment
  ...

14 years agoMerge branch 'nfs-for-2.6.35' of git://git.linux-nfs.org/projects/trondmy/nfs-2.6
Linus Torvalds [Thu, 20 May 2010 00:24:05 +0000 (17:24 -0700)]
Merge branch 'nfs-for-2.6.35' of git://git.linux-nfs.org/projects/trondmy/nfs-2.6

* 'nfs-for-2.6.35' of git://git.linux-nfs.org/projects/trondmy/nfs-2.6: (78 commits)
  SUNRPC: Don't spam gssd with upcall requests when the kerberos key expired
  SUNRPC: Reorder the struct rpc_task fields
  SUNRPC: Remove the 'tk_magic' debugging field
  SUNRPC: Move the task->tk_bytes_sent and tk_rtt to struct rpc_rqst
  NFS: Don't call iput() in nfs_access_cache_shrinker
  NFS: Clean up nfs_access_zap_cache()
  NFS: Don't run nfs_access_cache_shrinker() when the mask is GFP_NOFS
  SUNRPC: Ensure rpcauth_prune_expired() respects the nr_to_scan parameter
  SUNRPC: Ensure memory shrinker doesn't waste time in rpcauth_prune_expired()
  SUNRPC: Dont run rpcauth_cache_shrinker() when gfp_mask is GFP_NOFS
  NFS: Read requests can use GFP_KERNEL.
  NFS: Clean up nfs_create_request()
  NFS: Don't use GFP_KERNEL in rpcsec_gss downcalls
  NFSv4: Don't use GFP_KERNEL allocations in state recovery
  SUNRPC: Fix xs_setup_bc_tcp()
  SUNRPC: Replace jiffies-based metrics with ktime-based metrics
  ktime: introduce ktime_to_ms()
  SUNRPC: RPC metrics and RTT estimator should use same RTT value
  NFS: Calldata for nfs4_renew_done()
  NFS: Squelch compiler warning in nfs_add_server_stats()
  ...

14 years agoMerge branch 'bkl/procfs' of git://git.kernel.org/pub/scm/linux/kernel/git/frederic...
Linus Torvalds [Thu, 20 May 2010 00:23:28 +0000 (17:23 -0700)]
Merge branch 'bkl/procfs' of git://git./linux/kernel/git/frederic/random-tracing

* 'bkl/procfs' of git://git.kernel.org/pub/scm/linux/kernel/git/frederic/random-tracing:
  sunrpc: Include missing smp_lock.h
  procfs: Kill the bkl in ioctl
  procfs: Push down the bkl from ioctl
  procfs: Use generic_file_llseek in /proc/vmcore
  procfs: Use generic_file_llseek in /proc/kmsg
  procfs: Use generic_file_llseek in /proc/kcore
  procfs: Kill BKL in llseek on proc base

14 years agoMerge branch 'timers-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git...
Linus Torvalds [Thu, 20 May 2010 00:11:10 +0000 (17:11 -0700)]
Merge branch 'timers-for-linus' of git://git./linux/kernel/git/tip/linux-2.6-tip

* 'timers-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
  clocksource: Add clocksource_register_hz/khz interface
  posix-cpu-timers: Optimize run_posix_cpu_timers()
  time: Remove xtime_cache
  mqueue: Convert message queue timeout to use hrtimers
  hrtimers: Provide schedule_hrtimeout for CLOCK_REALTIME
  timers: Introduce the concept of timer slack for legacy timers
  ntp: Remove tickadj
  ntp: Make time_adjust static
  time: Add xtime, wall_to_monotonic to feature-removal-schedule
  timer: Try to survive timer callback preempt_count leak
  timer: Split out timer function call
  timer: Print function name for timer callbacks modifying preemption count
  time: Clean up warp_clock()
  cpu-timers: Avoid iterating over all threads in fastpath_timer_check()
  cpu-timers: Change SIGEV_NONE timer implementation
  cpu-timers: Return correct previous timer reload value
  cpu-timers: Cleanup arm_timer()
  cpu-timers: Simplify RLIMIT_CPU handling

14 years agoMerge branch 'timers-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel...
Linus Torvalds [Thu, 20 May 2010 00:10:57 +0000 (17:10 -0700)]
Merge branch 'timers-fixes-for-linus' of git://git./linux/kernel/git/tip/linux-2.6-tip

* 'timers-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
  cs5535-clockevt: Free timer in IRQ setup error path

14 years agoMerge branch 'timers-for-linus-hpet' of git://git.kernel.org/pub/scm/linux/kernel...
Linus Torvalds [Thu, 20 May 2010 00:10:24 +0000 (17:10 -0700)]
Merge branch 'timers-for-linus-hpet' of git://git./linux/kernel/git/tip/linux-2.6-tip

* 'timers-for-linus-hpet' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
  x86, hpet: Add reference to chipset erratum documentation for disable-hpet-msi-quirk
  x86, hpet: Restrict read back to affected ATI chipsets

14 years agoMerge branch 'timers-for-linus-cleanups' of git://git.kernel.org/pub/scm/linux/kernel...
Linus Torvalds [Thu, 20 May 2010 00:10:06 +0000 (17:10 -0700)]
Merge branch 'timers-for-linus-cleanups' of git://git./linux/kernel/git/tip/linux-2.6-tip

* 'timers-for-linus-cleanups' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
  avr32: Fix typo in read_persistent_clock()
  sparc: Convert sparc to use read/update_persistent_clock
  cris: Convert cris to use read/update_persistent_clock
  m68k: Convert m68k to use read/update_persistent_clock
  m32r: Convert m32r to use read/update_peristent_clock
  blackfin: Convert blackfin to use read/update_persistent_clock
  ia64: Convert ia64 to use read/update_persistent_clock
  avr32: Convert avr32 to use read/update_persistent_clock
  h8300: Convert h8300 to use read/update_persistent_clock
  frv: Convert frv to use read/update_persistent_clock
  mn10300: Convert mn10300 to use read/update_persistent_clock
  alpha: Convert alpha to use read/update_persistent_clock
  xtensa: Fix unnecessary setting of xtime
  time: Clean up direct xtime usage in xen

14 years agoMerge branch 'irq-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git...
Linus Torvalds [Thu, 20 May 2010 00:09:40 +0000 (17:09 -0700)]
Merge branch 'irq-core-for-linus' of git://git./linux/kernel/git/tip/linux-2.6-tip

* 'irq-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
  genirq: Clear CPU mask in affinity_hint when none is provided
  genirq: Add CPU mask affinity hint
  genirq: Remove IRQF_DISABLED from core code
  genirq: Run irq handlers with interrupts disabled
  genirq: Introduce request_any_context_irq()
  genirq: Expose irq_desc->node in proc/irq

Fixed up trivial conflicts in Documentation/feature-removal-schedule.txt

14 years agoi2c-highlander: remover superflous variable
Wolfram Sang [Tue, 2 Feb 2010 12:03:31 +0000 (13:03 +0100)]
i2c-highlander: remover superflous variable

When cppcheck found this flaw

[./i2c/busses/i2c-highlander.c:284]: (style) Warning - using char variable in bit operation

it was noted that the 'read'-variable could be simply removed as read_write can
only be 0 or 1 anyhow. So, we remove the flaw and simplify the code.

Reported-by: d binderman <dcb314@hotmail.com>
Signed-off-by: Wolfram Sang <w.sang@pengutronix.de>
Acked-by: Paul Mundt <lethal@linux-sh.org>
Acked-by: Jean Delvare <khali@linux-fr.org>
Cc: Ben Dooks <ben-linux@fluff.org>
14 years agoi2c-ibm-iic: drop NO_IRQ
Wolfram Sang [Sun, 4 Oct 2009 11:08:16 +0000 (13:08 +0200)]
i2c-ibm-iic: drop NO_IRQ

Drop NO_IRQ as 0 is the preferred way to describe 'no irq'
(http://lkml.org/lkml/2005/11/21/221). This change is safe, as the driver is
only used on powerpc, where NO_IRQ is 0 anyhow.

Signed-off-by: Wolfram Sang <w.sang@pengutronix.de>
Acked-by: Grant Likely <grant.likely@secretlab.ca>
Acked-by: Sean MacLennan <smaclennan@pikatech.com>
Cc: Ben Dooks <ben-linux@fluff.org>
14 years agoi2c-cpm: drop NO_IRQ
Wolfram Sang [Sun, 4 Oct 2009 11:08:16 +0000 (13:08 +0200)]
i2c-cpm: drop NO_IRQ

Drop NO_IRQ as 0 is the preferred way to describe 'no irq'
(http://lkml.org/lkml/2005/11/21/221). This change is safe, as the driver is
only used on powerpc, where NO_IRQ is 0 anyhow.

Signed-off-by: Wolfram Sang <w.sang@pengutronix.de>
Acked-by: Grant Likely <grant.likely@secretlab.ca>
Acked-by: Jochen Friedrich <jochen@scram.de>
Cc: Ben Dooks <ben-linux@fluff.org>
14 years agoi2c-mpc: drop NO_IRQ
Wolfram Sang [Sun, 4 Oct 2009 11:08:16 +0000 (13:08 +0200)]
i2c-mpc: drop NO_IRQ

Drop NO_IRQ as 0 is the preferred way to describe 'no irq'
(http://lkml.org/lkml/2005/11/21/221). This change is safe, as the driver is
only used on powerpc, where NO_IRQ is 0 anyhow.

Signed-off-by: Wolfram Sang <w.sang@pengutronix.de>
Acked-by: Grant Likely <grant.likely@secretlab.ca>
Cc: Ben Dooks <ben-linux@fluff.org>
14 years agoMAINTAINERS: add i2c tree for embedded platforms
Uwe Kleine-König [Mon, 25 Jan 2010 09:20:34 +0000 (10:20 +0100)]
MAINTAINERS: add i2c tree for embedded platforms

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Acked-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Wolfram Sang <w.sang@pengutronix.de>
14 years agoi2c-pxa: only define 'blue_murder'-function if DEBUG is #defined
Wolfram Sang [Tue, 3 Nov 2009 11:53:41 +0000 (12:53 +0100)]
i2c-pxa: only define 'blue_murder'-function if DEBUG is #defined

This talkative function is also called on timeouts. As timeouts can
happen on regular writes to EEPROMs (no error case), this creates false
positives.  Giving lots of details is interesting only for developers
anyhow, so just use the function if DEBUG is #defined.

Signed-off-by: Wolfram Sang <w.sang@pengutronix.de>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Cc: Russell King <rmk+kernel@arm.linux.org.uk>
Acked-by: Eric Miao <eric.y.miao@gmail.com>
Cc: Roel Kluin <roel.kluin@gmail.com>
Cc: Pavel Machek <pavel@ucw.cz>
14 years agoi2c-pxa: remove unused macro
Uwe Kleine-König [Tue, 3 Nov 2009 11:43:23 +0000 (12:43 +0100)]
i2c-pxa: remove unused macro

Commit

beea494 ([ARM] Remove EEPROM slave emulation from i2c-pxa driver.)

removed all uses of eedbg, so the definition can go, too.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Acked-by: Russell King <rmk+kernel@arm.linux.org.uk>
Cc: Eric Miao <eric.y.miao@gmail.com>
Cc: Roel Kluin <roel.kluin@gmail.com>
Acked-by: Pavel Machek <pavel@ucw.cz>
Signed-off-by: Wolfram Sang <w.sang@pengutronix.de>
14 years agoi2c-nomadik: fix operator precedence warning
Rabin Vincent [Tue, 27 Apr 2010 05:01:08 +0000 (10:31 +0530)]
i2c-nomadik: fix operator precedence warning

Fix this warning:
i2c-nomadik.c:707: warning: suggest parentheses around operand of '!' or change '&' to '&&' or '!' to '~'

Acked-by: Linus Walleij <linus.walleij@stericsson.com>
Acked-by: Srinidhi Kasagar <srinidhi.kasagar@stericsson.com>
Signed-off-by: Rabin Vincent <rabin.vincent@stericsson.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
14 years agoi2c-nomadik: release region when removed
Rabin Vincent [Tue, 27 Apr 2010 05:01:07 +0000 (10:31 +0530)]
i2c-nomadik: release region when removed

So that the module can be loaded again after an unload.

Acked-by: Linus Walleij <linus.walleij@stericsson.com>
Acked-by: Srinidhi Kasagar <srinidhi.kasagar@stericsson.com>
Signed-off-by: Rabin Vincent <rabin.vincent@stericsson.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
14 years agoOMAP3: I2C: Clean up Errata 1p153 handling
manjugk manjugk [Tue, 11 May 2010 18:35:23 +0000 (11:35 -0700)]
OMAP3: I2C: Clean up Errata 1p153 handling

Clean up existing Errata 1p153 handling to use generic
errata handling mechanism through dev flag.

Signed-off-by: Manjunatha GK <manjugk@ti.com>
Cc: Nishanth Menon <nm@ti.com>
Cc: Alexander Shishkin <virtuoso@slind.org>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
14 years agoOMAP2/3: I2C: Errata ID i207: Clear wrong RDR interrupt
manjugk manjugk [Tue, 11 May 2010 18:35:20 +0000 (11:35 -0700)]
OMAP2/3: I2C: Errata ID i207: Clear wrong RDR interrupt

Under certain rare conditions, I2C_STAT[13].RDR bit may be set
and the corresponding interrupt fire, even there is no data in
the receive FIFO, or the I2C data transfer is still ongoing.
These spurious RDR events must be ignored by the software.

This patch handles and ignores RDR spurious interrupts.

The below sequence is required in interrupt handler for
handling this errata:
1. If RDR is set to 1, clear RDR
2. Read I2C status register and check for BusBusy bit. If BusBusy
bit is set, skip remaining steps.
3. If BusBusy bit is not set, perform read operation on I2C status
register.
4. If RDR is set, clear the same. Check RDR again and clear if it sets
RDR bit again.
5. Perform I2C Data Read operation N number of times(where N is value
read from the register BUFSTAT-RXSTAT bit fields).

Note:
This errata is not applicable for omap2420 and omap4.
It is applicable for:
1. omap2430
2. omap34xx(including omap3630).

Signed-off-by: Manjunatha GK <manjugk@ti.com>
Cc: Hema Kalliguddi <hemahk@ti.com>
Cc: Nishanth Menon <nm@ti.com>
Cc: Aaro Koskinen <Aaro.Koskinen@nokia.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
14 years agoomap: i2c: add a timeout to the busy waiting
Alexander Shishkin [Tue, 11 May 2010 18:35:17 +0000 (11:35 -0700)]
omap: i2c: add a timeout to the busy waiting

The errata 1.153 workaround is busy waiting on XUDF bit in interrupt
context, which may lead to kernel hangs. The problem can be reproduced
by running the bus with wrong (too high) speed.

Signed-off-by: Alexander Shishkin <virtuoso@slind.org>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
14 years agoomap: i2c: make errata 1.153 workaround a separate function
Alexander Shishkin [Tue, 11 May 2010 18:35:14 +0000 (11:35 -0700)]
omap: i2c: make errata 1.153 workaround a separate function

This is to avoid insanely long lines and levels of indentation.

Signed-off-by: Alexander Shishkin <virtuoso@slind.org>
Cc: Nishant Menon <nm@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
14 years agoi2c-omap: add mpu wake up latency constraint in i2c
Kalle Jokiniemi [Tue, 11 May 2010 18:35:08 +0000 (11:35 -0700)]
i2c-omap: add mpu wake up latency constraint in i2c

While waiting for completion of the i2c transfer, the
MPU could hit OFF mode and cause several msecs of
delay that made i2c transfers fail more often. The
extra delays and subsequent re-trys cause i2c clocks
to be active more often. This has also an negative
effect on power consumption.

Created a mechanism for passing and using the
constraint setting function in driver code. The used
mpu wake up latency constraints are now set individually
per bus, and they are calculated based on clock rate
and fifo size.

Thanks to Jarkko Nikula, Moiz Sonasath, Paul Walmsley,
and Nishanth Menon for tuning out the details of
this patch.

Updates by Kevin as requested by Tony:

- Remove omap_set_i2c_constraint_func() in favor of conditionally
  adding the flag in omap_i2c_add_bus() in order to keep all the OMAP
  conditional checking in a single location.
- Update set_mpu_wkup_lat prototypes to match OMAP PM layer so
  OMAP PM function can be used directly in pdata.

Cc: Moiz Sonasath <m-sonasath@ti.com>
Cc: Jarkko Nikula <jhnikula@gmail.com>
Cc: Paul Walmsley <paul@pwsan.com>
Cc: Nishanth Menon <nm@ti.com>
Signed-off-by: Kalle Jokiniemi <kalle.jokiniemi@digia.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
14 years agoomap: i2c: Add i2c support on omap4 platform
Santosh Shilimkar [Tue, 11 May 2010 18:35:04 +0000 (11:35 -0700)]
omap: i2c: Add i2c support on omap4 platform

This patch is rebased version of earlier post to add I2C
driver support to OMAP4 platform. On OMAP4, all
I2C register address offsets are changed from OMAP1/2/3 I2C.
In order to not have #ifdef's at various places in code,
as well as to support multi-OMAP build, an array is created
to hold the register addresses with it's offset.

This patch was submitted, reviewed and acked on mailing list
already. For more details refer below link
http://www.mail-archive.com/linux-i2c@vger.kernel.org/msg02281.html

This updated verion has a depedancy on "Add support for 16-bit registers"
posted on linux-omap. Below is the patch-works link for the same

http://patchwork.kernel.org/patch/72295/

Signed-off-by: Syed Rafiuddin <rafiuddin.syed@ti.com>
Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com>
Acked-by: Kevin Hilman <khilman@deeprootsystems.com>
Reviewed-by: Paul Walmsley <paul@pwsan.com>
Cc: Cory Maccarrone <darkstar6262@gmail.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
14 years agoi2c-bfin-twi: return completion in interrupt for smbus quick transfers
Sonic Zhang [Mon, 22 Mar 2010 07:23:20 +0000 (03:23 -0400)]
i2c-bfin-twi: return completion in interrupt for smbus quick transfers

A smbus quick transfer has no data after the address byte.

Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
14 years agoi2c-bfin-twi: remove redundant retry
Sonic Zhang [Mon, 22 Mar 2010 07:23:19 +0000 (03:23 -0400)]
i2c-bfin-twi: remove redundant retry

Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
14 years agoi2c-bfin-twi: fix lost interrupts at high speeds
Sonic Zhang [Mon, 22 Mar 2010 07:23:18 +0000 (03:23 -0400)]
i2c-bfin-twi: fix lost interrupts at high speeds

i2c event of next read/write byte may trigger before current int state
is cleared in the interrupt handler. So, this should be done at the
beginning of interrupt handler to avoid losing new i2c events.

Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
14 years agoi2c-bfin-twi: add debug output for error status
Michael Hennerich [Mon, 22 Mar 2010 07:23:17 +0000 (03:23 -0400)]
i2c-bfin-twi: add debug output for error status

Add some debug() code to decode the error register.

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>