]> Pileus Git - ~andy/linux/log
~andy/linux
14 years agodrm/radeon/kms: read back register before writing in IIO.
Dave Airlie [Thu, 12 Nov 2009 05:53:44 +0000 (15:53 +1000)]
drm/radeon/kms: read back register before writing in IIO.

This fixes RH bugzilla #527874.

On resume the atom posting wasn't working, however vbe posting was
going fine, after 2 weeks over irc, and 8 hrs with the hardware,
I tracked it down to the memory device table and it access the MC
registers via IIO, it appears the rv515 atom iio table might not
be fully functional, so adding a readback before doing a write
either provides enough delay to make things resume correctly.

Thanks to Peng Huang at Red Hat for coming to Brisbane.

Signed-off-by: Dave Airlie <airlied@redhat.com>
14 years agodrm/radeon/kms: fix handling of d1/d2 vga
Dave Airlie [Wed, 11 Nov 2009 23:37:39 +0000 (09:37 +1000)]
drm/radeon/kms: fix handling of d1/d2 vga

An rv515 laptop I got wouldn't startup with a montior plugged in,
found the proper bug hopefully with us not turning off D2VGA
here when we should.

Signed-off-by: Dave Airlie <airlied@redhat.com>
14 years agodrm: work around EDIDs with bad htotal/vtotal values
Jesse Barnes [Thu, 5 Nov 2009 18:12:54 +0000 (10:12 -0800)]
drm: work around EDIDs with bad htotal/vtotal values

We did this on the userspace side, but we need a similar fix for the
kernel.

Fixes LP #460664.

Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
Cc: stable@kernel.org
Signed-off-by: Dave Airlie <airlied@redhat.com>
14 years agodrm/radeon/kms: resume AGP by calling init.
Dave Airlie [Thu, 5 Nov 2009 05:39:10 +0000 (15:39 +1000)]
drm/radeon/kms: resume AGP by calling init.

AGP resume was broken since we moved to the new init path,
because we never re-enabled AGP on these systems at resume time.

This patch just calls the AGP resume call which just does the reinit
at resume time like the old path did.

Since AGP is pretty much gpu independant I did it outside
the gpu specific code.

Signed-off-by: Dave Airlie <airlied@redhat.com>
14 years agosparc64: Fix definition of VMEMMAP_SIZE.
David S. Miller [Tue, 24 Nov 2009 00:38:56 +0000 (16:38 -0800)]
sparc64: Fix definition of VMEMMAP_SIZE.

This was the cause of various boot failures on V480, V880, etc.
systems.

Kernel image memory was being overwritten because the vmemmap[]
array was being sized to small.  So if you had physical memory
addresses past a certain point, the early bootup would spam
all over variables in the kernel data section.

The vmemmap mappings map page structs, not page struct pointers.
And that was the key thinko in the macro definition.

This was fixable thanks to the help, reports, and tireless patience
of Hermann Lauer.

Reported-by: Hermann Lauer <Hermann.Lauer@iwr.uni-heidelberg.de>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agomacvlan: fix gso_max_size setting
Patrick McHardy [Mon, 23 Nov 2009 22:18:53 +0000 (14:18 -0800)]
macvlan: fix gso_max_size setting

gso_max_size must be set based on the value of the underlying device to
support devices not using the full 64k.

Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agoMerge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wirel...
David S. Miller [Mon, 23 Nov 2009 22:01:47 +0000 (14:01 -0800)]
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-2.6

14 years agorfkill: fix miscdev ops
Johannes Berg [Mon, 23 Nov 2009 10:27:30 +0000 (11:27 +0100)]
rfkill: fix miscdev ops

The /dev/rfkill ops don't refer to the module,
so it is possible to unload the module while
file descriptors are open. Fix this oversight.

Reported-by: Maxim Levitsky <maximlevitsky@gmail.com>
Cc: stable@kernel.org
Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
14 years agoath9k: set ps_default as false
John W. Linville [Mon, 23 Nov 2009 21:15:19 +0000 (16:15 -0500)]
ath9k: set ps_default as false

Copied from original one-line patch here:

http://bugzilla.kernel.org/show_bug.cgi?id=14267#c26

Signed-off-by: John W. Linville <linville@tuxdriver.com>
14 years agoStaging: octeon-ethernet: Assign proper MAC addresses.
David Daney [Mon, 12 Oct 2009 19:04:32 +0000 (12:04 -0700)]
Staging: octeon-ethernet: Assign proper MAC addresses.

Allocate MAC addresses using the same method as the bootloader.  This
avoids changing the MAC between bootloader and kernel operation as
well as avoiding duplicates and use of addresses outside of the
assigned range.

Signed-off-by: David Daney <ddaney@caviumnetworks.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
14 years agoStaging: Octeon: Use symbolic values for irq numbers.
David Daney [Thu, 3 Sep 2009 23:10:47 +0000 (16:10 -0700)]
Staging: Octeon: Use symbolic values for irq numbers.

In addition to being magic numbers, the irq number passed to free_irq
is incorrect.  We need to use the correct symbolic value instead.

Signed-off-by: David Daney <ddaney@caviumnetworks.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
14 years agoMIPS: Octeon: Fix compile error in drivers/staging/octeon/ethernet-mdio.c
David Daney [Thu, 1 Oct 2009 23:47:39 +0000 (16:47 -0700)]
MIPS: Octeon: Fix compile error in drivers/staging/octeon/ethernet-mdio.c

Signed-off-by: David Daney <ddaney@caviumnetworks.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
14 years agohso: fix soft-lockup
Antti Kaijanmäki [Mon, 23 Nov 2009 18:54:47 +0000 (10:54 -0800)]
hso: fix soft-lockup

Fix soft-lockup in hso.c which is triggered on SMP machine when
modem is removed while file descriptor(s) under /dev are still open:

  old version called kref_put() too early which resulted in destroying
  hso_serial and hso_device objects which were still used later on.

Signed-off-by: Antti Kaijanmäki <antti.kaijanmaki@nomovok.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agohso: fix debug routines
Antti Kaijanmäki [Mon, 23 Nov 2009 18:54:24 +0000 (10:54 -0800)]
hso: fix debug routines

Signed-off-by: Antti Kaijanmäki <antti.kaijanmaki@nomovok.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agopktgen: Fix device name compares
Eric Dumazet [Mon, 23 Nov 2009 01:44:37 +0000 (01:44 +0000)]
pktgen: Fix device name compares

Commit e6fce5b916cd7f7f7 (pktgen: multiqueue etc.) tried to relax
the pktgen restriction of one device per kernel thread, adding a '@'
tag to device names.

Problem is we dont perform check on full pktgen device name.
This allows adding many time same 'device' to pktgen thread

 pgset "add_device eth0@0"

one session later :

 pgset "add_device eth0@0"

(This doesnt find previous device)

This consumes ~1.5 MBytes of vmalloc memory per round and also triggers
this warning :

[  673.186380] proc_dir_entry 'pktgen/eth0@0' already registered
[  673.186383] Modules linked in: pktgen ixgbe ehci_hcd psmouse mdio mousedev evdev [last unloaded: pktgen]
[  673.186406] Pid: 6219, comm: bash Tainted: G        W  2.6.32-rc7-03302-g41cec6f-dirty #16
[  673.186410] Call Trace:
[  673.186417]  [<ffffffff8104a29b>] warn_slowpath_common+0x7b/0xc0
[  673.186422]  [<ffffffff8104a341>] warn_slowpath_fmt+0x41/0x50
[  673.186426]  [<ffffffff8114e789>] proc_register+0x109/0x210
[  673.186433]  [<ffffffff8100bf2e>] ? apic_timer_interrupt+0xe/0x20
[  673.186438]  [<ffffffff8114e905>] proc_create_data+0x75/0xd0
[  673.186444]  [<ffffffffa006ad38>] pktgen_thread_write+0x568/0x640 [pktgen]
[  673.186449]  [<ffffffffa006a7d0>] ? pktgen_thread_write+0x0/0x640 [pktgen]
[  673.186453]  [<ffffffff81149144>] proc_reg_write+0x84/0xc0
[  673.186458]  [<ffffffff810f5a58>] vfs_write+0xb8/0x180
[  673.186463]  [<ffffffff810f5c11>] sys_write+0x51/0x90
[  673.186468]  [<ffffffff8100b51b>] system_call_fastpath+0x16/0x1b
[  673.186470] ---[ end trace ccbb991b0a8d994d ]---

Solution to this problem is to use a odevname field (includes @ tag and suffix),
instead of using netdevice name.

Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: Robert Olsson <robert.olsson@its.uu.se>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agostmmac: do not fail when the timer cannot be used.
Giuseppe CAVALLARO [Sun, 22 Nov 2009 22:59:56 +0000 (22:59 +0000)]
stmmac: do not fail when the timer cannot be used.

If the external timer cannot be used the driver
will continue to work without mitigation.

Signed-off-by: Giuseppe Cavallaro <peppe.cavallaro@st.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agostmmac: fixed a compilation error when use the external timer
Giuseppe CAVALLARO [Sun, 22 Nov 2009 22:58:40 +0000 (22:58 +0000)]
stmmac: fixed a compilation error when use the external timer

Signed-off-by: Giuseppe Cavallaro <peppe.cavallaro@st.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agoInput: polled device - do not start polling if interval is zero
Samu Onkalo [Mon, 23 Nov 2009 18:01:33 +0000 (10:01 -0800)]
Input: polled device - do not start polling if interval is zero

If the poll interval is set to 0 via new sysfs entry and device is
opened after that, polling is started with interval 0. This causes
huge CPU load. Same happens if the rate was 0 when the device was
closed and then reopened.

Signed-off-by: Samu Onkalo <samu.p.onkalo@nokia.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
14 years agoInput: polled device - schedule first poll immediately
Dmitry Torokhov [Thu, 19 Nov 2009 07:10:54 +0000 (23:10 -0800)]
Input: polled device - schedule first poll immediately

It does not make sense to wait poll_interval before performing first
read after opening the device, schedule the read immediately instead.

Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
14 years agoMerge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/kaber/nf-2.6
David S. Miller [Mon, 23 Nov 2009 17:52:51 +0000 (09:52 -0800)]
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/kaber/nf-2.6

14 years agoInput: add S3C24XX touchscreen driver
Arnaud Patard [Mon, 23 Nov 2009 17:47:12 +0000 (09:47 -0800)]
Input: add S3C24XX touchscreen driver

S3C24XX touchscreen driver, originally written by Arnaud Patard and
other contributors. The driver has had substantial testing as well as
a number of tidying up passes done by Ben Dooks, as noted:

- added kernel-doc comments to most of the routines
- removed old code from pre adc framework days
- updated device probe code to use platform id list matching
- cleaned up debug, since printk() now has timestamp feature
- ensure code uses dev_() reporting macros where necessary
- remove ABS_PRESSURE reporting, tslib can be fixed
- ensure timer is removed on driver exit
- move to using dev_pmops for power management

Signed-off-by: Arnaud Patard <arnaud.patard@rtp-net.org>
Signed-off-by: Ben Dooks <ben@simtec.co.uk>
Signed-off-by: Simtec Linux Team <linux@simtec.co.uk>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
14 years agoARM: 5793/1: ARM: Check put_user fail in do_signal when enable OABI_COMPAT
Jean PIHET [Mon, 23 Nov 2009 16:03:32 +0000 (17:03 +0100)]
ARM: 5793/1: ARM: Check put_user fail in do_signal when enable OABI_COMPAT

Using OABI, the call to put_user in do_signal can fail causing the
calling app to hang.

The solution is to check if put_user fails and force the app to
seg fault in that case.

Tested with multiple sleeping apps/threads (using the nanosleep syscall)
and suspend/resume.

Signed-off-by: janboe <janboe.ye at gmail.com>
Signed-off-by: Jean Pihet <jpihet@mvista.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
14 years agoInput: usbtouchscreen - add support for Zytronic capacitive touchscreen
Daniel Silverstone [Mon, 23 Nov 2009 16:38:16 +0000 (08:38 -0800)]
Input: usbtouchscreen - add support for Zytronic capacitive touchscreen

Zytronic USB-attached capacitive touchscreen support within the generic
USB touchscreen driver.

Signed-off-by: Daniel Silverstone <dsilvers@simtec.co.uk>
Signed-off-by: Vincent Sanders <vince@simtec.co.uk>
Signed-off-by: Simtec Linux Team <linux@simtec.co.uk>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
14 years agoInput: force feedback - fix function name in comment
Roger Quadros [Mon, 23 Nov 2009 16:30:18 +0000 (08:30 -0800)]
Input: force feedback - fix function name in comment

Function name is input_ff_destroy() and not input_ff_free()

Signed-off-by: Roger Quadros <roger.quadros@nokia.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
14 years agoInput: do not overwrite the first part of phys string
Márton Németh [Mon, 23 Nov 2009 16:26:38 +0000 (08:26 -0800)]
Input: do not overwrite the first part of phys string

Use strlcat() to append a string to the previously created first part.

Signed-off-by: Márton Németh <nm127@freemail.hu>
Acked-by: Jiri Kosina <jkosina@suse.cz>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
14 years agoInput: ads7846 - switch to using dev_vdbg()
Pavel Machek [Mon, 23 Nov 2009 16:25:17 +0000 (08:25 -0800)]
Input: ads7846 - switch to using dev_vdbg()

Signed-off-by: Pavel Machek <pavel@ucw.cz>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
14 years agoInput: ads7846 - fix pressure reporting
Pavel Machek [Mon, 23 Nov 2009 16:17:38 +0000 (08:17 -0800)]
Input: ads7846 - fix pressure reporting

On Zaurus, hx4700 and others pressure is reported inverted -- the lighter
the pressure, the bigger numerical value.

Signed-off-by: Pavel Machek <pavel@ucw.cz>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
14 years agoInput: usbtouchscreen - remove unneeded usb_kill_urb
Oliver Neukum [Mon, 23 Nov 2009 16:10:50 +0000 (08:10 -0800)]
Input: usbtouchscreen - remove unneeded usb_kill_urb

usb_kill_urb() in disconnect is not needed as unregistering will cause
close() to be called.

Signed-off-by: Oliver Neukum <oliver@neukum.org>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
14 years agoACPI: DMI init_set_sci_en_on_resume for HP-Compaq C700
Len Brown [Mon, 23 Nov 2009 16:44:12 +0000 (11:44 -0500)]
ACPI: DMI init_set_sci_en_on_resume for HP-Compaq C700

...else ACPI thermal controls fail after resume.

http://bugzilla.kernel.org/show_bug.cgi?id=13745

Signed-off-by: Len Brown <len.brown@intel.com>
14 years agoASoC: Fix suspend with active audio streams
Mark Brown [Mon, 23 Nov 2009 13:11:53 +0000 (13:11 +0000)]
ASoC: Fix suspend with active audio streams

When we get a stream suspend event force the power down since otherwise
the stream would remain marked as active.  In future we'll probably want
to make this stream-specific and add an interface to make the power down
of other widgets optional in order to support leaving bypass paths
active while suspending the processor.

Cc: stable@kernel.org
Reported-by: Joonyoung Shim <jy0922.shim@samsung.com>
Tested-by: Joonyoung Shim <jy0922.shim@samsung.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
14 years agonetfilter: xt_limit: fix invalid return code in limit_mt_check()
Patrick McHardy [Mon, 23 Nov 2009 12:37:23 +0000 (13:37 +0100)]
netfilter: xt_limit: fix invalid return code in limit_mt_check()

Commit acc738fe (netfilter: xtables: avoid pointer to self) introduced
an invalid return value in limit_mt_check().

Signed-off-by: Patrick McHardy <kaber@trash.net>
14 years agoAu1x00: fix crash when trying register_netdev()
Alexander Beregalov [Mon, 23 Nov 2009 04:40:52 +0000 (20:40 -0800)]
Au1x00: fix crash when trying register_netdev()

Andreas Lohre reported that the driver crashes when trying
to register_netdev(), he sugessted to move dev->netdev_ops initialization
before calling register_netdev(), it worked for him.

Reported-by: Andreas Lohre <alohre@gmail.com>
Signed-off-by: Alexander Beregalov <a.beregalov@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agoshdma: fix initialization error handling
Dan Williams [Sun, 22 Nov 2009 19:10:10 +0000 (12:10 -0700)]
shdma: fix initialization error handling

1/ Error handling code following a kzalloc should free the allocated data.
2/ Report an error when no platform data is detected

Both problems fixed by moving the platform data check before the allocation,
and allows a goto to be killed.

Reported-by: Julia Lawall <julia@diku.dk>
Acked-by: Julia Lawall <julia@diku.dk>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
14 years agoMAINTAINERS: add maintainer information for AMBA primecell drivers
Russell King [Sun, 22 Nov 2009 17:40:28 +0000 (17:40 +0000)]
MAINTAINERS: add maintainer information for AMBA primecell drivers

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
14 years agoMerge branch 'fix' of git://git.kernel.org/pub/scm/linux/kernel/git/ycmiao/pxa-linux-2.6
Russell King [Sun, 22 Nov 2009 17:11:06 +0000 (17:11 +0000)]
Merge branch 'fix' of git://git.kernel.org/pub/scm/linux/kernel/git/ycmiao/pxa-linux-2.6

14 years ago[ARM] pxa/spitz: fix compile regression on spitz
Pavel Machek [Wed, 18 Nov 2009 09:01:00 +0000 (10:01 +0100)]
[ARM] pxa/spitz: fix compile regression on spitz

If CONFIG_AKITA is not set, spitz fails to compile. It worked ok in
rc5. Fix is one more ifdef...

Signed-off-by: Pavel Machek <pavel@ucw.cz>
Acked-by: Stanislav Brabec <utx@penguin.cz>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
14 years agonetxen : fix BOND_MODE_TLB/ALB mode.
Narender Kumar [Fri, 20 Nov 2009 22:08:57 +0000 (22:08 +0000)]
netxen : fix BOND_MODE_TLB/ALB mode.

o Along with netdev->perm_addr, mac address will be
  maintained in device private structure.

o Device limitation: We need to set mac address when ever
  interface comes up.

In ALB/TAL mode, bonding driver calls set_mac for all slave with bond mac address.
But bonding driver set netdev->dev_addr field to its original value,
after enslaving interfaces.

When ever active slave changes, it swap dev_addr of inactive slave with active.
Yet it doesn't notify driver about change in netdev->dev_addr.

As netxen driver need to set mac addr when ever interface comes up,
it can't rely on netdev->dev_addr field. Specially in case of bonding mode ALB/TLB.

Signed-off-by: Narender Kumar <narender.kumar@qlogic.com>
Signed-off-by: Amit Kumar Salecha <amit.salecha@qlogic.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agonetxen: fix promisc for NX2031.
Narender Kumar [Fri, 20 Nov 2009 15:09:33 +0000 (15:09 +0000)]
netxen: fix promisc for NX2031.

Kernel crashes, if promisc mode set without disabling rx queue.
Before changing mode in NX2031 chip, wait till rx queue drains.

Signed-off-by: Narender Kumar <narender.kumar@qlogic.com>
Signed-off-by: Amit Kumar Salecha <amit.salecha@qlogic.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agonetxen: fix memory initialization
Amit Kumar Salecha [Fri, 20 Nov 2009 15:09:32 +0000 (15:09 +0000)]
netxen: fix memory initialization

Avoid resetting memory during initialization, skip this memory
block during driver probe.

Signed-off-by: Amit Kumar Salecha <amit@netxen.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agoARM: PNX4008: i2c-pnx: use the same dev_id for request_irq and free_irq
Russell King [Sat, 21 Nov 2009 16:00:28 +0000 (16:00 +0000)]
ARM: PNX4008: i2c-pnx: use the same dev_id for request_irq and free_irq

This allows i2c-pnx to free its interrupt handler when the module
is removed or if an error occurs; using the same dev_id for both
request_irq and free_irq is desirable.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Acked-by: Ben Dooks <ben-linux@fluff.org>
14 years agofirewire: ohci: pass correct iso xmit timestamps to core
Jay Fenlason [Fri, 20 Nov 2009 23:05:56 +0000 (00:05 +0100)]
firewire: ohci: pass correct iso xmit timestamps to core

Here is the final set of patches I used to get ffado to work with the
new firewire stack.  With these patches, I was able to start ardour
and record from and playback to my PreSonus Inspire1394 from a
(mostly) Fedora 12 system.

Signed-off-by: Jay Fenlason <fenlason@redhat.com>
Until now, firewire-ohci exposed only the transmit cycle of the last
transmitted packet at each isochronous transmit complete event.  This
made it impossible for FFADO (FireWire audio drivers in userspace) to
synchronize audio-out streams.  The fix is to store the timestamp of
each packet in the iso xmit event.  As a bonus, the transfer status is
stored too.

Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de>
14 years agoTI DaVinci EMAC: Minor macro related updates
chaithrika@ti.com [Thu, 1 Oct 2009 10:25:19 +0000 (10:25 +0000)]
TI DaVinci EMAC: Minor macro related updates

Use BIT for macro definitions wherever possible, remove
unused and redundant macros.

Signed-off-by: Chaithrika U S <chaithrika@ti.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agodrivers/net: ks8851_mll ethernet network driver -resubmit
David J. Choi [Thu, 19 Nov 2009 15:34:30 +0000 (15:34 +0000)]
drivers/net: ks8851_mll ethernet network driver -resubmit

Summary of Changes:

-Fix to receive multicast packets by setting the corresponding hardware
 bit during initialization.
-Fix to re-enable the interface [by interface up command(ifup)] while the
 interface is down.
-Fix to be able to down the interface by passing the last parameter
 correctly to request_irq().
-Remove to read 4 extra bytes from the receiving queue after reading a
 packet, even though it does not cause a predictable issue now.
-Remove occurrences of transmission done interrupt in order to tx
 throughput enhancement.
-Enable IP checksum for packet receiving by setting the corresponding
 hardware bit during initialization.
-Relocate ks_enable_int()/ks_disable_int() in order not to declare those
 functions at the beginning of the file.
-Rename ks_enable()/_disable() to ks_enable_qmu()/ks_disable_qmu() in
 order to give more meaningful names and relocate them not declaire
 those functions at the beginning of the file.

Signed-off-by: David J. Choi <david.choi@micrel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agonet: ETHOC should depend on HAS_DMA
Geert Uytterhoeven [Fri, 20 Nov 2009 09:19:10 +0000 (09:19 +0000)]
net: ETHOC should depend on HAS_DMA

When building for Sun 3:

drivers/net/ethoc.c:1091: undefined reference to `dma_free_coherent'
drivers/built-in.o: In function `ethoc_probe':
drivers/net/ethoc.c:965: undefined reference to `dma_alloc_coherent'
drivers/net/ethoc.c:1063: undefined reference to `dma_free_coherent'

Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agoe1000e: do not initiate autonegotiation during OEM configuration
Bruce Allan [Thu, 19 Nov 2009 14:17:30 +0000 (14:17 +0000)]
e1000e: do not initiate autonegotiation during OEM configuration

When configuring the OEM bits in the PHY on 82577/82578, do not restart
autonegotiation if the firmware is blocking it (e.g. when an IDE-R session
is active) because the link must not go down.

Signed-off-by: Bruce Allan <bruce.w.allan@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agoe1000e: remove unnecessary 82577 workaround causing link issues
Bruce Allan [Thu, 19 Nov 2009 12:36:04 +0000 (12:36 +0000)]
e1000e: remove unnecessary 82577 workaround causing link issues

A workaround for pre-release versions of 82577 is causing link issues on
some switches.  The workaround is no longer needed on production parts so
remove it.

Signed-off-by: Bruce Allan <bruce.w.allan@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agoe1000e: flow control thresholds not correct when changing mtu
Bruce Allan [Thu, 19 Nov 2009 12:35:45 +0000 (12:35 +0000)]
e1000e: flow control thresholds not correct when changing mtu

When changing MTU, save it off prior to resetting otherwise the flow control
thresholds may be miscalculated.

Signed-off-by: Bruce Allan <bruce.w.allan@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agoe1000e: add Tx timeout factor for 100Mbps
Bruce Allan [Thu, 19 Nov 2009 12:35:26 +0000 (12:35 +0000)]
e1000e: add Tx timeout factor for 100Mbps

On some devices (e.g. 82578) not having a Tx timeout factor when linked at
100Mbps can cause false reports of hardware hangs on busy hubs.

Signed-off-by: Bruce Allan <bruce.w.allan@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agoe1000e: set flow control thresholds properly after enabling/disabling pause
Bruce Allan [Thu, 19 Nov 2009 12:35:08 +0000 (12:35 +0000)]
e1000e: set flow control thresholds properly after enabling/disabling pause

When flow control (pause) parameters were changed via ethtool (i.e. enabled
or disabled), the newly calculated thresholds were not being written to the
device for non-fiber media.

Signed-off-by: Bruce Allan <bruce.w.allan@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agoe1000e: read of PHY register may access wrong page on 82578
Bruce Allan [Thu, 19 Nov 2009 12:34:40 +0000 (12:34 +0000)]
e1000e: read of PHY register may access wrong page on 82578

Remove unnecessary workaround that mistakenly does not perform a page
select operation for PHY registers 29 and 30 (assuming these are the PHY
debug port address and data registers) on 82578 which can cause reads
of the Transmit with No Carrier Sense statistics register on page 778 to be
read from an incorrect page.  Also error out if the page select operation
fails.

Signed-off-by: Bruce Allan <bruce.w.allan@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agoe1000e: partial revert of 3ec2a2b8 plus FC workraround for 82577/8
Bruce Allan [Thu, 19 Nov 2009 12:34:20 +0000 (12:34 +0000)]
e1000e: partial revert of 3ec2a2b8 plus FC workraround for 82577/8

Commit 3ec2a2b80f3eb53851fe4cef9e65b5d33376ef89 broke Tx/Rx when using
jumbo frames on certain parts (i.e. only PAUSE frames could be exchanged
once the high water mark was reached preventing normal packet traffic).
This patch reverts the breakage and sets appropriate high and low water
marks of the Rx FIFO for 82577/82578 which require a workaround due to a
flow control issue in hardware.

Signed-off-by: Bruce Allan <bruce.w.allan@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agoFS-Cache: Provide nop fscache_stat_d() if CONFIG_FSCACHE_STATS=n
David Howells [Fri, 20 Nov 2009 21:50:44 +0000 (21:50 +0000)]
FS-Cache: Provide nop fscache_stat_d() if CONFIG_FSCACHE_STATS=n

Provide nop fscache_stat_d() macro if CONFIG_FSCACHE_STATS=n lest errors like
the following occur:

fs/fscache/cache.c: In function 'fscache_withdraw_cache':
fs/fscache/cache.c:386: error: implicit declaration of function 'fscache_stat_d'
fs/fscache/cache.c:386: error: 'fscache_n_cop_sync_cache' undeclared (first use in this function)
fs/fscache/cache.c:386: error: (Each undeclared identifier is reported only once
fs/fscache/cache.c:386: error: for each function it appears in.)
fs/fscache/cache.c:392: error: 'fscache_n_cop_dissociate_pages' undeclared (first use in this function)

Signed-off-by: David Howells <dhowells@redhat.com>
14 years agoSLOW_WORK: Fix GFS2 to #include <linux/module.h> before using THIS_MODULE
David Howells [Fri, 20 Nov 2009 21:50:40 +0000 (21:50 +0000)]
SLOW_WORK: Fix GFS2 to #include <linux/module.h> before using THIS_MODULE

GFS2 has been altered to pass THIS_MODULE to slow_work_register_user(), but
hasn't been altered to #include <linux/module.h> to provide it, resulting in
the following error:

fs/gfs2/recovery.c:596: error: 'THIS_MODULE' undeclared here (not in a function)

Add the missing #include.

Signed-off-by: David Howells <dhowells@redhat.com>
14 years agoSLOW_WORK: Fix CIFS to pass THIS_MODULE to slow_work_register_user()
David Howells [Fri, 20 Nov 2009 21:50:36 +0000 (21:50 +0000)]
SLOW_WORK: Fix CIFS to pass THIS_MODULE to slow_work_register_user()

As of the patch:

SLOW_WORK: Wait for outstanding work items belonging to a module to clear

Wait for outstanding slow work items belonging to a module to clear
when unregistering that module as a user of the facility.  This
prevents the put_ref code of a work item from being taken away before
it returns.

slow_work_register_user() takes a module pointer as an argument.  CIFS must now
pass THIS_MODULE as that argument, lest the following error be observed:

fs/cifs/cifsfs.c: In function 'init_cifs':
fs/cifs/cifsfs.c:1040: error: too few arguments to function 'slow_work_register_user'

Signed-off-by: David Howells <dhowells@redhat.com>
14 years agoixgbe: move tc variable to CONFIG_IXGBE_DCB
Jaswinder Singh Rajput [Fri, 20 Nov 2009 04:02:27 +0000 (04:02 +0000)]
ixgbe: move tc variable to CONFIG_IXGBE_DCB

tc is required by CONFIG_IXGBE_DCB.
This also fixes compilation warning:

 drivers/net/ixgbe/ixgbe_main.c: In function ‘ixgbe_tx_is_paused’:
 drivers/net/ixgbe/ixgbe_main.c:245: warning: unused variable ‘tc’

Signed-off-by: Jaswinder Singh Rajput <jaswinderrajput@gmail.com>
Acked-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years ago[ARM] pxa/cpufreq: fix index assignments for end marker
Daniel Mack [Fri, 20 Nov 2009 16:50:34 +0000 (17:50 +0100)]
[ARM] pxa/cpufreq: fix index assignments for end marker

I stumbled over two small things regarding the .index field assignment
in the dynamically created cpu frequency tables for pxa2xx and pxa3xx.

Even though that doesn't currently cause any problem, it should still be
fixed in case the logic in the CPUFREQ core changes.

Signed-off-by: Daniel Mack <daniel@caiaq.de>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
14 years agokconfig: Fix make O=<dir> local{mod,yes}config
Steven Rostedt [Fri, 20 Nov 2009 14:21:12 +0000 (09:21 -0500)]
kconfig: Fix make O=<dir> local{mod,yes}config

When the output directory is something other than the kernel source,
the streamline_config script gets confused. This patch passes in the
source directory to the script so that it can find the proper files.

Reported-by: Peter Zijlstra <peterz@infradead.org>
Tested-by: Peter Zijlstra <peterz@infradead.org>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
14 years agoARM: PNX4008: fix watchdog device driver name
Russell King [Fri, 20 Nov 2009 13:07:57 +0000 (13:07 +0000)]
ARM: PNX4008: fix watchdog device driver name

The PNX core code calls the device 'pnx4008-watchdog' not 'watchdog'

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Acked-by: Wim Van Sebroeck <wim@iguana.be>
14 years ago[ARM] kmap: fix build errors with DEBUG_HIGHMEM enabled
Russell King [Wed, 18 Nov 2009 18:03:19 +0000 (18:03 +0000)]
[ARM] kmap: fix build errors with DEBUG_HIGHMEM enabled

d451564 broke ARM by requiring KM_IRQ_PTE, KM_NMI and KM_NMI_PTE to
always be defined.  Solve this by providing invalid definitions for
these constants, but only if CONFIG_DEBUG_HIGHMEM is enabled.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
14 years agoAT91: add touchscreen support for at91sam9g45ekes
Nicolas Ferre [Thu, 19 Nov 2009 17:32:52 +0000 (09:32 -0800)]
AT91: add touchscreen support for at91sam9g45ekes

New at91sam9g45ekes board provides a LCD with resistive touchscreen.
This is the support of this feature by atmel_tsadcc driver. This also
sets up platform parameters to be passed to the driver.

Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com>
Acked-by: Andrew Victor <linux@maxim.org.za>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
14 years agoAT91: add platform parameters for atmel_tsadcc in at91sam9rlek
Nicolas Ferre [Thu, 19 Nov 2009 17:31:20 +0000 (09:31 -0800)]
AT91: add platform parameters for atmel_tsadcc in at91sam9rlek

Setup platform parameters in at91sam9rl-ek board to be passed to
atmel_tsadcc touchscreen.

Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com>
Acked-by: Andrew Victor <linux@maxim.org.za>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
14 years agoInput: atmel_tsadcc - use platform parameters
Nicolas Ferre [Thu, 19 Nov 2009 17:29:32 +0000 (09:29 -0800)]
Input: atmel_tsadcc - use platform parameters

Add a number of plafrom dependent parameters to atmel_tsadcc.  The
touchscreeen driver can now take into account the slight differences
that exist between IPs included in diferent products.  This will also
allow to adapt its behaivior to the caracteristics of the resistive
panel used.

Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
14 years agoInput: atmel_tsadcc - rework setting touchscreen capabilities
Nicolas Ferre [Thu, 19 Nov 2009 17:28:25 +0000 (09:28 -0800)]
Input: atmel_tsadcc - rework setting touchscreen capabilities

Tiny patch for setting capabilities using input API function.

Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
14 years agoInput: keyboard - fix theoretical race on vt switch
Alan Jenkins [Wed, 18 Nov 2009 08:40:48 +0000 (00:40 -0800)]
Input: keyboard - fix theoretical race on vt switch

A VT switch can theoretically change fg_console between

        vc = vc_cons[fg_console].d
and
        kbd = kbd_table + fg_console

Fix it by replacing the second fg_console with vc->vc_num.

Signed-off-by: Alan Jenkins <alan-jenkins@tuffmail.co.uk>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
14 years agoInput: ALPS - add support for touchpads with 4-directional button
Maxim Levitsky [Tue, 17 Nov 2009 06:12:22 +0000 (22:12 -0800)]
Input: ALPS - add support for touchpads with 4-directional button

The touchpad on Acer Aspire 5720, 5520 and some other Aspire models
(signature 0x73, 0x02, 0x50) has a button that can be rocked in 4
different directions. Make the driver to generate BTN_0..BTN_3 events
in response. The Synaptics driver by default maps BTN_0 and BTN_1 to
up and down, so there should be no visible changes with the old setup
that generated BTN_FORWARD and BTN_BACK (also mapped to up and down).

Signed-off-by: Maxim Levitsky <maximlevitsky@gmail.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
14 years agoInput: psmouse - rework setting of BTN_MIDDLE capability
Dmitry Torokhov [Tue, 17 Nov 2009 06:12:21 +0000 (22:12 -0800)]
Input: psmouse - rework setting of BTN_MIDDLE capability

Do not start protocol detection assuming that middle mouse is present,
instead let individual protocols explicitly set this capability.
This fixes issue with Synaptics touchpads pretending that they have
middle button when hardware clearly reports otherwise.

Reported-and-tested-by: Andrey Borzenkov <arvidjaar@mail.ru>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
14 years agoInput: lifebook - do not advertise unsupported buttons
Dmitry Torokhov [Tue, 17 Nov 2009 06:12:21 +0000 (22:12 -0800)]
Input: lifebook - do not advertise unsupported buttons

The main input device of Lifebook touchscreens does not generate
left/right/middle button events and therefore should not be advertising
them in its capabilities.

Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
14 years agoInput: elantech - do not advertise relative events
Dmitry Torokhov [Tue, 17 Nov 2009 06:12:21 +0000 (22:12 -0800)]
Input: elantech - do not advertise relative events

Elantech touchpads work in absolute mode and do not generate relative
events so they should not be advertising them.

Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
14 years agoInput: touchkit_ps2 - do not advertise unsupported buttons
Dmitry Torokhov [Tue, 17 Nov 2009 06:12:21 +0000 (22:12 -0800)]
Input: touchkit_ps2 - do not advertise unsupported buttons

Touchkit PS/2 touchscreen does not have left/right/middle buttons and
should not be advertising as capable of generating these events.

Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
14 years agoInput: input-polldev, matrix-keypad - include in kernel doc
Dmitry Torokhov [Tue, 17 Nov 2009 06:12:20 +0000 (22:12 -0800)]
Input: input-polldev, matrix-keypad - include in kernel doc

Make sure that polled input device and matrix keypad APIs are included
with the rest of input API when generating kernel documentation. Also
description of absres was missing as well.

Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
14 years agoInput: input-polldev - add sysfs interface for controlling poll interval
Samu Onkalo [Sat, 14 Nov 2009 05:13:22 +0000 (21:13 -0800)]
Input: input-polldev - add sysfs interface for controlling poll interval

Sysfs entry for reading and setting of the polling interval. If the
interval is set to 0, polling is stopped. Polling is restarted when
interval is changed to non-zero.

sysfs entries:
poll = current polling interval in msec (RW)
max = max allowed polling interval (RO)
min = min allowed polling interval (RO)

Minimum and maximum limit for interval can be set while setting up the
device.

Interval can be adjusted even if the input device is not currently open.

[dtor@mail.ru: add kernel doc markup for the new fields]
Signed-off-by: Samu Onkalo <samu.p.onkalo@nokia.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
14 years agoInput: gpio_keys - seperate individual button setup to make code neater
Ben Dooks [Wed, 11 Nov 2009 05:01:31 +0000 (21:01 -0800)]
Input: gpio_keys - seperate individual button setup to make code neater

Move the code that deals with setting up each individual button out into
a new function to reduce the indentation and allow us to common up some
of the error recovery code.

Signed-off-by: Ben Dooks <ben@simtec.co.uk>
Signed-off-by: Simtec Linux Team <linux@simtec.co.uk>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
14 years agoInput: gpio_keys - use <linux/gpio.h> instead of <asm/gpio.h>
Ben Dooks [Wed, 11 Nov 2009 05:01:31 +0000 (21:01 -0800)]
Input: gpio_keys - use <linux/gpio.h> instead of <asm/gpio.h>

The gpio keys driver should be using <linux/gpio.h> instead
of <asm/gpio.h>

Signed-off-by: Ben Dooks <ben@simtec.co.uk>
Signed-off-by: Simtec Linux Team <linux@simtec.co.uk>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
14 years agoInput: gpio_keys - use dev_ macros to report information
Ben Dooks [Wed, 11 Nov 2009 05:00:35 +0000 (21:00 -0800)]
Input: gpio_keys - use dev_ macros to report information

The gpio_keys driver is binding to a platform device but using pr_err()
to report errors. Change to using dev_err() so that all messages are
prefixed by the device name.

Signed-off-by: Ben Dooks <ben@simtec.co.uk>
Signed-off-by: Simtec Linux Team <linux@simtec.co.uk>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
14 years agoInput: ucb1400_ts - allow passing IRQ through platfrom_data
Marek Vasut [Mon, 9 Nov 2009 03:45:54 +0000 (19:45 -0800)]
Input: ucb1400_ts - allow passing IRQ through platfrom_data

This patch allows UCB1400 to get IRQ GPIO from platform data. In case
platform_data are not supplied or the IRQ supplied in the platform_data
is negative, fall back to the old IRQ detection algorithm.

Signed-off-by: Marek Vasut <marek.vasut@gmail.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
14 years agoioat3: fix pq completion versus channel deallocation race
Dan Williams [Fri, 20 Nov 2009 00:11:03 +0000 (17:11 -0700)]
ioat3: fix pq completion versus channel deallocation race

The completion of a pq operation is notified with a null descriptor
appended to the end of the chain.  This descriptor needs to be visible
to dma clients otherwise the client is precluded from ensuring all
operations are quiesced before freeing channel resources, i.e. due to
descriptor polling it may get the completion notification ahead of the
interrupt delivered by the null descriptor.

Signed-off-by: Dan Williams <dan.j.williams@intel.com>
14 years agoasync_tx: build-time toggling of async_{syndrome,xor}_val dma support
Dan Williams [Fri, 20 Nov 2009 00:10:37 +0000 (17:10 -0700)]
async_tx: build-time toggling of async_{syndrome,xor}_val dma support

ioat3.2 does not support asynchronous error notifications which makes
the driver experience latencies when non-zero pq validate results are
expected.  Provide a mechanism for turning off async_xor_val and
async_syndrome_val via Kconfig.  This approach is generally useful for
any driver that specifies ASYNC_TX_DISABLE_CHANNEL_SWITCH and would like
to force the async_tx api to fall back to the synchronous path for
certain operations.

Signed-off-by: Dan Williams <dan.j.williams@intel.com>
14 years agodmaengine: include xor/pq validate in device_has_all_tx_types()
Dan Williams [Fri, 20 Nov 2009 00:10:25 +0000 (17:10 -0700)]
dmaengine: include xor/pq validate in device_has_all_tx_types()

A channel must include these capabilities to satisfy
ASYNC_TX_DISABLE_CHANNEL_SWITCH.

Signed-off-by: Dan Williams <dan.j.williams@intel.com>
14 years agoioat2,3: report all uncorrectable errors
Dan Williams [Fri, 20 Nov 2009 00:10:07 +0000 (17:10 -0700)]
ioat2,3: report all uncorrectable errors

Modify is_ioat_bug() to catch all errors that are uncorrectable, or not
currently handled.

Signed-off-by: Dan Williams <dan.j.williams@intel.com>
14 years agoMerge branch 'i2c-pnx-fixes' of git://git.fluff.org/bjdooks/linux
Linus Torvalds [Fri, 20 Nov 2009 04:29:34 +0000 (20:29 -0800)]
Merge branch 'i2c-pnx-fixes' of git://git.fluff.org/bjdooks/linux

* 'i2c-pnx-fixes' of git://git.fluff.org/bjdooks/linux:
  i2c: i2c-pnx: Added missing mach/i2c.h and linux/io.h header file includes
  i2c: i2c-pnx: Made buf type unsigned to prevent sign extension
  i2c: i2c-pnx: Limit minimum jiffie timeout to 2

14 years agoMerge branch 'upstream-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jlbec...
Linus Torvalds [Fri, 20 Nov 2009 04:29:05 +0000 (20:29 -0800)]
Merge branch 'upstream-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jlbec/ocfs2

* 'upstream-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jlbec/ocfs2:
  ocfs2: Trivial cleanup of jbd compatibility layer removal
  ocfs2: Refresh documentation
  ocfs2: return f_fsid info in ocfs2_statfs()
  ocfs2: duplicate inline data properly during reflink.
  ocfs2: Move ocfs2_complete_reflink to the right place.
  ocfs2: Return -EINVAL when a device is not ocfs2.

14 years agoi2c: i2c-pnx: Added missing mach/i2c.h and linux/io.h header file includes
Kevin Wells [Wed, 11 Nov 2009 23:25:52 +0000 (00:25 +0100)]
i2c: i2c-pnx: Added missing mach/i2c.h and linux/io.h header file includes

Added missing mach/i2c.h and linux/io.h header file includes

Signed-off-by: Kevin Wells <kevin.wells@nxp.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
14 years agoi2c: i2c-pnx: Made buf type unsigned to prevent sign extension
Kevin Wells [Wed, 11 Nov 2009 23:23:00 +0000 (00:23 +0100)]
i2c: i2c-pnx: Made buf type unsigned to prevent sign extension

Made buf type unsigned to prevent sign extension

Signed-off-by: Kevin Wells <kevin.wells@nxp.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
14 years agoi2c: i2c-pnx: Limit minimum jiffie timeout to 2
Kevin Wells [Wed, 11 Nov 2009 23:28:13 +0000 (00:28 +0100)]
i2c: i2c-pnx: Limit minimum jiffie timeout to 2

Limit minimum jiffie timeout to 2 to prevent early timeout on systems
with low tick rates

Signed-off-by: Kevin Wells <kevin.wells@nxp.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
14 years agoioat3: specify valid address for disabled-Q or disabled-P
Dan Williams [Fri, 20 Nov 2009 00:08:45 +0000 (17:08 -0700)]
ioat3: specify valid address for disabled-Q or disabled-P

Although disabled, hardware still checks address validity, so duplicate
the known address.

Signed-off-by: Dan Williams <dan.j.williams@intel.com>
14 years agoioat2,3: disable asynchronous error notifications
Dan Williams [Fri, 20 Nov 2009 00:07:57 +0000 (17:07 -0700)]
ioat2,3: disable asynchronous error notifications

Error interrupts and error completions may cause channel hangs, so
poll the channel status register after a timeout.

Signed-off-by: Dan Williams <dan.j.williams@intel.com>
14 years agoioat3: dca and raid operations are incompatible
Dan Williams [Fri, 20 Nov 2009 00:07:10 +0000 (17:07 -0700)]
ioat3: dca and raid operations are incompatible

RAID operations cause a system hang on platforms with DCA
(Direct-Cache-Access) enabled.  So turn off RAID capabilities in this
case.

Signed-off-by: Dan Williams <dan.j.williams@intel.com>
14 years agosata_fsl: Split hard and soft reset
Jiang Yutang [Fri, 16 Oct 2009 16:44:36 +0000 (20:44 +0400)]
sata_fsl: Split hard and soft reset

Split sata_fsl_softreset() into hard and soft resets to make
error-handling more efficient & device and PMP detection more
reliable.

Also includes fix for PMP support, driver tested with Sil3726,
Sil4726 & Exar PMP controllers.

[AV: Also fixes resuming from deep sleep on MPC8315 CPUs]

Signed-off-by: Jiang Yutang <b14898@freescale.com>
Signed-off-by: Anton Vorontsov <avorontsov@ru.mvista.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
14 years agoLinux 2.6.32-rc8 v2.6.32-rc8
Linus Torvalds [Thu, 19 Nov 2009 22:32:38 +0000 (14:32 -0800)]
Linux 2.6.32-rc8

14 years agoMerge branch 'bugfixes' of git://git.linux-nfs.org/projects/trondmy/nfs-2.6
Linus Torvalds [Thu, 19 Nov 2009 21:43:19 +0000 (13:43 -0800)]
Merge branch 'bugfixes' of git://git.linux-nfs.org/projects/trondmy/nfs-2.6

* 'bugfixes' of git://git.linux-nfs.org/projects/trondmy/nfs-2.6:
  SUNRPC: Address buffer overrun in rpc_uaddr2sockaddr()
  NFSv4: Fix a cache validation bug which causes getcwd() to return ENOENT

14 years agovt: Fix use of "new" in a struct field
Alan Cox [Thu, 19 Nov 2009 13:30:36 +0000 (13:30 +0000)]
vt: Fix use of "new" in a struct field

As this struct is exposed to user space and the API was added for this
release it's a bit of a pain for the C++ world and we still have time to
fix it. Rename the fields before we end up with that pain in an actual
release.

Signed-off-by: Alan Cox <alan@linux.intel.com>
Reported-by: Olivier Goffart
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
14 years agoFix handling of the HP/Acer 'DMAR at zero' BIOS error for machines with <4GiB RAM.
David Woodhouse [Thu, 19 Nov 2009 02:18:44 +0000 (02:18 +0000)]
Fix handling of the HP/Acer 'DMAR at zero' BIOS error for machines with <4GiB RAM.

Commit 86cf898e1d0fca245173980e3897580db38569a8 ("intel-iommu: Check for
'DMAR at zero' BIOS error earlier.") was supposed to work by pretending
not to detect an IOMMU if it was actually being reported by the BIOS at
physical address zero.

However, the intel_iommu_init() function is called unconditionally, as
are the corresponding functions for other IOMMU hardware.

So the patch only worked if you have RAM above the 4GiB boundary. It
caused swiotlb to be initialised when no IOMMU was detected during early
boot, and thus the later IOMMU init would refuse to run.

But if you have less RAM than that, swiotlb wouldn't get set up and the
IOMMU _would_ still end up being initialised, even though we never
claimed to detect it.

This patch also sets the dmar_disabled flag when the error is detected
during the initial detection phase -- so that the later call to
intel_iommu_init() will return without doing anything, regardless of
whether swiotlb is used or not.

Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
14 years agonetfilter: nf_log: fix sleeping function called from invalid context in seq_show()
Patrick McHardy [Thu, 19 Nov 2009 04:59:05 +0000 (04:59 +0000)]
netfilter: nf_log: fix sleeping function called from invalid context in seq_show()

[  171.925285] BUG: sleeping function called from invalid context at kernel/mutex.c:280
[  171.925296] in_atomic(): 1, irqs_disabled(): 0, pid: 671, name: grep
[  171.925306] 2 locks held by grep/671:
[  171.925312]  #0:  (&p->lock){+.+.+.}, at: [<c10b8acd>] seq_read+0x25/0x36c
[  171.925340]  #1:  (rcu_read_lock){.+.+..}, at: [<c1391dac>] seq_start+0x0/0x44
[  171.925372] Pid: 671, comm: grep Not tainted 2.6.31.6-4-netbook #3
[  171.925380] Call Trace:
[  171.925398]  [<c105104e>] ? __debug_show_held_locks+0x1e/0x20
[  171.925414]  [<c10264ac>] __might_sleep+0xfb/0x102
[  171.925430]  [<c1461521>] mutex_lock_nested+0x1c/0x2ad
[  171.925444]  [<c1391c9e>] seq_show+0x74/0x127
[  171.925456]  [<c10b8c5c>] seq_read+0x1b4/0x36c
[  171.925469]  [<c10b8aa8>] ? seq_read+0x0/0x36c
[  171.925483]  [<c10d5c8e>] proc_reg_read+0x60/0x74
[  171.925496]  [<c10d5c2e>] ? proc_reg_read+0x0/0x74
[  171.925510]  [<c10a4468>] vfs_read+0x87/0x110
[  171.925523]  [<c10a458a>] sys_read+0x3b/0x60
[  171.925538]  [<c1002a49>] syscall_call+0x7/0xb

Fix it by replacing RCU with nf_log_mutex.

Reported-by: "Yin, Kangkai" <kangkai.yin@intel.com>
Signed-off-by: Wu Fengguang <fengguang.wu@intel.com>
Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agonetfilter: xt_osf: fix xt_osf_remove_callback() return value
Patrick McHardy [Thu, 19 Nov 2009 04:59:03 +0000 (04:59 +0000)]
netfilter: xt_osf: fix xt_osf_remove_callback() return value

Return a negative error value.

Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agoveth: Fix veth_get_stats()
Eric Dumazet [Wed, 18 Nov 2009 07:09:39 +0000 (07:09 +0000)]
veth: Fix veth_get_stats()

veth_get_stats() can be called in parallel on several cpus.

It's better to not reset dev->stats as it could give wrong result on
one cpu. Use temporary variables, then store the final results.

Also, we should loop on every possible cpus, not only online cpus,
or cpu hotplug can suddenly give wrong veth stats.

Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agoieee802154: dont leak skbs in ieee802154_fake_xmit()
Eric Dumazet [Thu, 19 Nov 2009 01:28:10 +0000 (01:28 +0000)]
ieee802154: dont leak skbs in ieee802154_fake_xmit()

ieee802154_fake_xmit() should free skbs since it returns NETDEV_TX_OK

Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
Acked-by: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agoCacheFiles: Don't log lookup/create failing with ENOBUFS
David Howells [Thu, 19 Nov 2009 18:12:08 +0000 (18:12 +0000)]
CacheFiles: Don't log lookup/create failing with ENOBUFS

Don't log the CacheFiles lookup/create object routined failing with ENOBUFS as
under high memory load or high cache load they can do this quite a lot.  This
error simply means that the requested object cannot be created on disk due to
lack of space, or due to failure of the backing filesystem to find sufficient
resources.

Signed-off-by: David Howells <dhowells@redhat.com>
14 years agoCacheFiles: Catch an overly long wait for an old active object
David Howells [Thu, 19 Nov 2009 18:12:05 +0000 (18:12 +0000)]
CacheFiles: Catch an overly long wait for an old active object

Catch an overly long wait for an old, dying active object when we want to
replace it with a new one.  The probability is that all the slow-work threads
are hogged, and the delete can't get a look in.

What we do instead is:

 (1) if there's nothing in the slow work queue, we sleep until either the dying
     object has finished dying or there is something in the slow work queue
     behind which we can queue our object.

 (2) if there is something in the slow work queue, we return ETIMEDOUT to
     fscache_lookup_object(), which then puts us back on the slow work queue,
     presumably behind the deletion that we're blocked by.  We are then
     deferred for a while until we work our way back through the queue -
     without blocking a slow-work thread unnecessarily.

A backtrace similar to the following may appear in the log without this patch:

INFO: task kslowd004:5711 blocked for more than 120 seconds.
"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
kslowd004     D 0000000000000000     0  5711      2 0x00000080
 ffff88000340bb80 0000000000000046 ffff88002550d000 0000000000000000
 ffff88002550d000 0000000000000007 ffff88000340bfd8 ffff88002550d2a8
 000000000000ddf0 00000000000118c0 00000000000118c0 ffff88002550d2a8
Call Trace:
 [<ffffffff81058e21>] ? trace_hardirqs_on+0xd/0xf
 [<ffffffffa011c4d8>] ? cachefiles_wait_bit+0x0/0xd [cachefiles]
 [<ffffffffa011c4e1>] cachefiles_wait_bit+0x9/0xd [cachefiles]
 [<ffffffff81353153>] __wait_on_bit+0x43/0x76
 [<ffffffff8111ae39>] ? ext3_xattr_get+0x1ec/0x270
 [<ffffffff813531ef>] out_of_line_wait_on_bit+0x69/0x74
 [<ffffffffa011c4d8>] ? cachefiles_wait_bit+0x0/0xd [cachefiles]
 [<ffffffff8104c125>] ? wake_bit_function+0x0/0x2e
 [<ffffffffa011bc79>] cachefiles_mark_object_active+0x203/0x23b [cachefiles]
 [<ffffffffa011c209>] cachefiles_walk_to_object+0x558/0x827 [cachefiles]
 [<ffffffffa011a429>] cachefiles_lookup_object+0xac/0x12a [cachefiles]
 [<ffffffffa00aa1e9>] fscache_lookup_object+0x1c7/0x214 [fscache]
 [<ffffffffa00aafc5>] fscache_object_state_machine+0xa5/0x52d [fscache]
 [<ffffffffa00ab4ac>] fscache_object_slow_work_execute+0x5f/0xa0 [fscache]
 [<ffffffff81082093>] slow_work_execute+0x18f/0x2d1
 [<ffffffff8108239a>] slow_work_thread+0x1c5/0x308
 [<ffffffff8104c0f1>] ? autoremove_wake_function+0x0/0x34
 [<ffffffff810821d5>] ? slow_work_thread+0x0/0x308
 [<ffffffff8104be91>] kthread+0x7a/0x82
 [<ffffffff8100beda>] child_rip+0xa/0x20
 [<ffffffff8100b87c>] ? restore_args+0x0/0x30
 [<ffffffff8104be17>] ? kthread+0x0/0x82
 [<ffffffff8100bed0>] ? child_rip+0x0/0x20
1 lock held by kslowd004/5711:
 #0:  (&sb->s_type->i_mutex_key#7/1){+.+.+.}, at: [<ffffffffa011be64>] cachefiles_walk_to_object+0x1b3/0x827 [cachefiles]

Signed-off-by: David Howells <dhowells@redhat.com>
14 years agoCacheFiles: Better showing of debugging information in active object problems
David Howells [Thu, 19 Nov 2009 18:12:02 +0000 (18:12 +0000)]
CacheFiles: Better showing of debugging information in active object problems

Show more debugging information if cachefiles_mark_object_active() is asked to
activate an active object.

This may happen, for instance, if the netfs tries to register an object with
the same key multiple times.

The code is changed to (a) get the appropriate object lock to protect the
cookie pointer whilst we dereference it, and (b) get and display the cookie key
if available.

Signed-off-by: David Howells <dhowells@redhat.com>
14 years agoCacheFiles: Mark parent directory locks as I_MUTEX_PARENT to keep lockdep happy
David Howells [Thu, 19 Nov 2009 18:11:58 +0000 (18:11 +0000)]
CacheFiles: Mark parent directory locks as I_MUTEX_PARENT to keep lockdep happy

Mark parent directory locks as I_MUTEX_PARENT in the callers of
cachefiles_bury_object() so that lockdep doesn't complain when that invokes
vfs_unlink():

=============================================
[ INFO: possible recursive locking detected ]
2.6.32-rc6-cachefs #47
---------------------------------------------
kslowd002/3089 is trying to acquire lock:
 (&sb->s_type->i_mutex_key#7){+.+.+.}, at: [<ffffffff810bbf72>] vfs_unlink+0x8b/0x128

but task is already holding lock:
 (&sb->s_type->i_mutex_key#7){+.+.+.}, at: [<ffffffffa00e4e61>] cachefiles_walk_to_object+0x1b0/0x831 [cachefiles]

other info that might help us debug this:
1 lock held by kslowd002/3089:
 #0:  (&sb->s_type->i_mutex_key#7){+.+.+.}, at: [<ffffffffa00e4e61>] cachefiles_walk_to_object+0x1b0/0x831 [cachefiles]

stack backtrace:
Pid: 3089, comm: kslowd002 Not tainted 2.6.32-rc6-cachefs #47
Call Trace:
 [<ffffffff8105ad7b>] __lock_acquire+0x1649/0x16e3
 [<ffffffff8118170e>] ? inode_has_perm+0x5f/0x61
 [<ffffffff8105ae6c>] lock_acquire+0x57/0x6d
 [<ffffffff810bbf72>] ? vfs_unlink+0x8b/0x128
 [<ffffffff81353ac3>] mutex_lock_nested+0x54/0x292
 [<ffffffff810bbf72>] ? vfs_unlink+0x8b/0x128
 [<ffffffff8118179e>] ? selinux_inode_permission+0x8e/0x90
 [<ffffffff8117e271>] ? security_inode_permission+0x1c/0x1e
 [<ffffffff810bb4fb>] ? inode_permission+0x99/0xa5
 [<ffffffff810bbf72>] vfs_unlink+0x8b/0x128
 [<ffffffff810adb19>] ? kfree+0xed/0xf9
 [<ffffffffa00e3f00>] cachefiles_bury_object+0xb6/0x420 [cachefiles]
 [<ffffffff81058e21>] ? trace_hardirqs_on+0xd/0xf
 [<ffffffffa00e7e24>] ? cachefiles_check_object_xattr+0x233/0x293 [cachefiles]
 [<ffffffffa00e51b0>] cachefiles_walk_to_object+0x4ff/0x831 [cachefiles]
 [<ffffffff81032238>] ? finish_task_switch+0x0/0xb2
 [<ffffffffa00e3429>] cachefiles_lookup_object+0xac/0x12a [cachefiles]
 [<ffffffffa00741e9>] fscache_lookup_object+0x1c7/0x214 [fscache]
 [<ffffffffa0074fc5>] fscache_object_state_machine+0xa5/0x52d [fscache]
 [<ffffffffa00754ac>] fscache_object_slow_work_execute+0x5f/0xa0 [fscache]
 [<ffffffff81082093>] slow_work_execute+0x18f/0x2d1
 [<ffffffff8108239a>] slow_work_thread+0x1c5/0x308
 [<ffffffff8104c0f1>] ? autoremove_wake_function+0x0/0x34
 [<ffffffff810821d5>] ? slow_work_thread+0x0/0x308
 [<ffffffff8104be91>] kthread+0x7a/0x82
 [<ffffffff8100beda>] child_rip+0xa/0x20
 [<ffffffff8100b87c>] ? restore_args+0x0/0x30
 [<ffffffff8104be17>] ? kthread+0x0/0x82
 [<ffffffff8100bed0>] ? child_rip+0x0/0x20

Signed-off-by: Daivd Howells <dhowells@redhat.com>