pandora-kernel.git
12 years agoLinux 3.1-rc10 v3.1-rc10
Linus Torvalds [Tue, 18 Oct 2011 04:06:23 +0000 (21:06 -0700)]
Linux 3.1-rc10

12 years agoMerge branch 'nf' of git://1984.lsi.us.es/net
David S. Miller [Mon, 17 Oct 2011 23:38:03 +0000 (19:38 -0400)]
Merge branch 'nf' of git://1984.lsi.us.es/net

12 years agox25: Prevent skb overreads when checking call user data
Matthew Daley [Fri, 14 Oct 2011 18:45:05 +0000 (18:45 +0000)]
x25: Prevent skb overreads when checking call user data

x25_find_listener does not check that the amount of call user data given
in the skb is big enough in per-socket comparisons, hence buffer
overreads may occur.  Fix this by adding a check.

Signed-off-by: Matthew Daley <mattjd@gmail.com>
Cc: Eric Dumazet <eric.dumazet@gmail.com>
Cc: Andrew Hendry <andrew.hendry@gmail.com>
Cc: stable <stable@kernel.org>
Acked-by: Andrew Hendry <andrew.hendry@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
12 years agox25: Handle undersized/fragmented skbs
Matthew Daley [Fri, 14 Oct 2011 18:45:04 +0000 (18:45 +0000)]
x25: Handle undersized/fragmented skbs

There are multiple locations in the X.25 packet layer where a skb is
assumed to be of at least a certain size and that all its data is
currently available at skb->data.  These assumptions are not checked,
hence buffer overreads may occur.  Use pskb_may_pull to check these
minimal size assumptions and ensure that data is available at skb->data
when necessary, as well as use skb_copy_bits where needed.

Signed-off-by: Matthew Daley <mattjd@gmail.com>
Cc: Eric Dumazet <eric.dumazet@gmail.com>
Cc: Andrew Hendry <andrew.hendry@gmail.com>
Cc: stable <stable@kernel.org>
Acked-by: Andrew Hendry <andrew.hendry@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
12 years agox25: Validate incoming call user data lengths
Matthew Daley [Fri, 14 Oct 2011 18:45:03 +0000 (18:45 +0000)]
x25: Validate incoming call user data lengths

X.25 call user data is being copied in its entirety from incoming messages
without consideration to the size of the destination buffers, leading to
possible buffer overflows. Validate incoming call user data lengths before
these copies are performed.

It appears this issue was noticed some time ago, however nothing seemed to
come of it: see http://www.spinics.net/lists/linux-x25/msg00043.html and
commit 8db09f26f912f7c90c764806e804b558da520d4f.

Signed-off-by: Matthew Daley <mattjd@gmail.com>
Acked-by: Eric Dumazet <eric.dumazet@gmail.com>
Tested-by: Andrew Hendry <andrew.hendry@gmail.com>
Cc: stable <stable@kernel.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
12 years agoudplite: fast-path computation of checksum coverage
Gerrit Renker [Mon, 17 Oct 2011 23:07:30 +0000 (19:07 -0400)]
udplite: fast-path computation of checksum coverage

Commit 903ab86d195cca295379699299c5fc10beba31c7 of 1 March this year ("udp: Add
lockless transmit path") introduced a new fast TX path that broke the checksum
coverage computation of UDP-lite, which so far depended on up->len (only set
if the socket is locked and 0 in the fast path).

Fixed by providing both fast- and slow-path computation of checksum coverage.
The latter can be removed when UDP(-lite)v6 also uses a lockless transmit path.

Reported-by: Thomas Volkert <thomas@homer-conferencing.com>
Signed-off-by: Gerrit Renker <gerrit@erg.abdn.ac.uk>
Signed-off-by: David S. Miller <davem@davemloft.net>
12 years agostaging: mei: clean the TODO file from done tasks.
Oren Weil [Mon, 17 Oct 2011 06:06:17 +0000 (08:06 +0200)]
staging: mei: clean the TODO file from done tasks.

1) We move the AMT Watchdog to use the kernel watchdog core.
the new code is still part of the MEI driver.
we didn't find any good reason to extract the the MEI driver watchdog code
from the MEI Driver to a new module.

2) Since the watchdog remains in the mei driver, exposing in-kernel
API just for AMTHI is unnecessary.

MEI new Watchdog Core Interface Patches set:
https://lkml.org/lkml/2011/9/7/26

3) Code cleanup (init and probe, bug_on usage, headers and etc) was
submitted in previous patches.

Patches:
https://lkml.org/lkml/2011/9/21/231
https://lkml.org/lkml/2011/6/15/358
https://lkml.org/lkml/2011/7/7/177
https://lkml.org/lkml/2011/9/7/38
https://lkml.org/lkml/2011/9/7/37
https://lkml.org/lkml/2011/9/7/28

4) mei.txt was updated with additional information.

Patch:
https://lkml.org/lkml/2011/10/16/52

Acked-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: Oren Weil <oren.jer.weil@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: vme_user: rename USER_BUS_MAX to VME_USER_BUS_MAX
Manohar Vanga [Mon, 26 Sep 2011 09:27:18 +0000 (11:27 +0200)]
staging: vme_user: rename USER_BUS_MAX to VME_USER_BUS_MAX

Signed-off-by: Manohar Vanga <manohar.vanga@cern.ch>
Cc: Martyn Welch <martyn.welch@ge.com>
Reviewed-by: Emilio G. Cota <cota@braap.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: vme: get rid of struct vme_device_id and slots
Manohar Vanga [Mon, 26 Sep 2011 09:27:17 +0000 (11:27 +0200)]
staging: vme: get rid of struct vme_device_id and slots

Previously, the device-driver matching mechanism depended on the
vme_device_id structure due to the need for a bind table per driver.
This method of matching is no longer used so this patch merges the
fields of struct vme_device_id into struct vme_dev. Since this also
renders the slot field meaningless, it has also been removed in this
patch.

Signed-off-by: Manohar Vanga <manohar.vanga@cern.ch>
Cc: Martyn Welch <martyn.welch@ge.com>
Reviewed-by: Emilio G. Cota <cota@braap.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: vme: make match() driver specific to improve non-VME64x support
Manohar Vanga [Mon, 26 Sep 2011 09:27:16 +0000 (11:27 +0200)]
staging: vme: make match() driver specific to improve non-VME64x support

For jumper based boards (non VME64x), there is no mechanism
for detecting the card that is plugged into a specific slot. This
leads to issues in non-autodiscovery crates/cards when a card is
plugged into a slot that is "claimed" by a different driver. In
reality, there is no problem, but the driver rejects such a
configuration due to its dependence on the concept of slots.

This patch makes the concept of slots less critical and pushes the
driver match() to individual drivers (similar to what happens in the
ISA bus in driver/base/isa.c). This allows drivers to register the
number of devices that they expect without any restrictions. Devices
in this new model are now formatted as $driver_name-$bus_id.$device_id
(as compared to the earlier vme-$bus_id.$slot_number).

This model also makes the device model more logical as devices
are only registered when they actually exist whereas earlier,
a set of devices were being created automatically regardless of
them actually being there.

Another change introduced in this patch is that devices are now created
within the VME driver structure rather than in the VME bridge structure.
This way, things don't go haywire if the bridge driver is removed while
a driver is using it.

Signed-off-by: Manohar Vanga <manohar.vanga@cern.ch>
Cc: Martyn Welch <martyn.welch@ge.com>
Reviewed-by: Emilio G. Cota <cota@braap.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: vme: add struct vme_dev for VME devices
Manohar Vanga [Mon, 26 Sep 2011 09:27:15 +0000 (11:27 +0200)]
staging: vme: add struct vme_dev for VME devices

Instead of using a vanilla 'struct device' for VME devices, add new
'struct vme_dev'. Modifications have been made to the VME framework
API as well as all in-tree VME drivers.

The new vme_dev structure has the following advantages from the
current model used by the driver:

    * Driver functions (probe, remove) now receive a VME device
      instead of a pointer to the bridge device (cleaner design)
    * It's easier to differenciate API calls as bridge-based or
      device-based (ie. cleaner interface).

Signed-off-by: Manohar Vanga <manohar.vanga@cern.ch>
Cc: Martyn Welch <martyn.welch@ge.com>
Reviewed-by: Emilio G. Cota <cota@braap.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging:iio:dummy Add buffered reading support
Jonathan Cameron [Fri, 14 Oct 2011 15:34:15 +0000 (16:34 +0100)]
staging:iio:dummy Add buffered reading support

Very simple buffered reading.  Did not provide a trigger as
the sysfs trigger already meets that requirement.

Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging:iio:dummy Add event support + fake event generator
Jonathan Cameron [Fri, 14 Oct 2011 15:34:14 +0000 (16:34 +0100)]
staging:iio:dummy Add event support + fake event generator

The event generator is not very pretty but does the job and
allows this driver to look a lot more like a normal driver
than it otherwise would.

Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging:iio:Documentation Simple dummy driver to explain the basics
Jonathan Cameron [Fri, 14 Oct 2011 15:34:13 +0000 (16:34 +0100)]
staging:iio:Documentation Simple dummy driver to explain the basics

The documenation explaining how to go about writing a driver is lagging
horribly, so here is another approach; an actual driver with
lots of explanatory comments.

Note it is currently minimal in that there are no events and no
buffer.  With care they can probably be added in additional files
without messing up the clarity of what we have here.

V2: Addressed some of Manuel Stahl's feedback.

Fixed up kernel doc.
Added more general description.

Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging:iio:adc:max1363 incorrect allocation of available_scanmasks
Jonathan Cameron [Fri, 14 Oct 2011 13:46:59 +0000 (14:46 +0100)]
staging:iio:adc:max1363 incorrect allocation of available_scanmasks

Longs are not known for being 8 bits.

Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging:iio: fix removal path to allow correct freeing.
Jonathan Cameron [Fri, 14 Oct 2011 13:46:58 +0000 (14:46 +0100)]
staging:iio: fix removal path to allow correct freeing.

Fix a dumb lack of consideration of the effect of combining
the iio_device_unregister and iio_free_device calls into
one.  There is no valid place to free some of the sysfs
array elements.

Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agoiio: adc: remove ADT75 driver - hwmon/lm75 will take over ADT75 support
Michael Hennerich [Fri, 14 Oct 2011 07:00:44 +0000 (09:00 +0200)]
iio: adc: remove ADT75 driver - hwmon/lm75 will take over ADT75 support

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Acked-by: Jonathan Cameron <jic23@cam.ac.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging:iio: gpio build dependency fixing
Jonathan Cameron [Wed, 12 Oct 2011 09:57:33 +0000 (10:57 +0100)]
staging:iio: gpio build dependency fixing

Numerous drivers either had pointless includes of gpio.h
or should have been dependent on GENERIC_GPIO and were not.
Conversion of ads1210 to use array registration triggered
build failures that highlighted all was not well.

Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk>
Reported-by: Randy Dunlap <rdunlap@xenotime.net>
Acked-by: Randy Dunlap <rdunlap@xenotime.net>
Acked-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agoStaging: hv: storvsc: Fix checkpatch warnings
K. Y. Srinivasan [Sat, 15 Oct 2011 04:31:57 +0000 (21:31 -0700)]
Staging: hv: storvsc: Fix checkpatch warnings

Fix checkpatch warnings.

Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agoStaging: hv: mousevsc: Fix a checkpatch warning
K. Y. Srinivasan [Sat, 15 Oct 2011 04:31:56 +0000 (21:31 -0700)]
Staging: hv: mousevsc: Fix a checkpatch warning

Fix a checkpatch warning.

Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: drop unused Kconfig symbols
Paul Bolle [Fri, 14 Oct 2011 12:30:58 +0000 (14:30 +0200)]
staging: drop unused Kconfig symbols

Signed-off-by: Paul Bolle <pebolle@tiscali.nl>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: zcache: remove zcache_direct_reclaim_lock
Seth Jennings [Wed, 12 Oct 2011 19:41:00 +0000 (14:41 -0500)]
staging: zcache: remove zcache_direct_reclaim_lock

zcache_do_preload() currently does a spin_trylock() on the
zcache_direct_reclaim_lock. Holding this lock intends to prevent
shrink_zcache_memory() from evicting zbud pages as a result
of a preload.

However, it also prevents two threads from
executing zcache_do_preload() at the same time.  The first
thread will obtain the lock and the second thread's spin_trylock()
will fail (an aborted preload) causing the page to be either lost
(cleancache) or pushed out to the swap device (frontswap). It
also doesn't ensure that the call to shrink_zcache_memory() is
on the same thread as the call to zcache_do_preload().

Additional, there is no need for this mechanism because all
zcache_do_preload() calls that come down from cleancache already
have PF_MEMALLOC set in the process flags which prevents
direct reclaim in the memory manager. If the zcache_do_preload()
call is done from the frontswap path, we _want_ reclaim to be
done (which it isn't right now).

This patch removes the zcache_direct_reclaim_lock and related
statistics in zcache.

Based on v3.1-rc8

Signed-off-by: Seth Jennings <sjenning@linux.vnet.ibm.com>
Reviewed-by: Dave Hansen <dave@linux.vnet.ibm.com>
Acked-by: Dan Magenheimer <dan.magenheimer@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging/nvec: fix compilation error in nvec.c
Marc Dietrich [Mon, 10 Oct 2011 09:35:45 +0000 (11:35 +0200)]
staging/nvec: fix compilation error in nvec.c

This fixes a compilation error in nvec.c due to the missing module.h include.

Signed-off-by: Marc Dietrich <marvin24@gmx.de>
Cc: Julian Andres Klode <jak@jak-linux.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging/easycap: kill timeval members of easycap struct
Tomas Winkler [Mon, 10 Oct 2011 06:36:38 +0000 (08:36 +0200)]
staging/easycap: kill timeval members of easycap struct

timeval[0-9] were not used or used in a ready only code
so we can remove them safely and so the code

Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: wlags49_h2: Fixup SIOCSIWGENIE
David Kilroy [Sun, 9 Oct 2011 11:11:37 +0000 (12:11 +0100)]
staging: wlags49_h2: Fixup SIOCSIWGENIE

Setting the key management scheme is done in SIOCSIWAUTH, so
no need to do anything in SIOCSIWGENIE.

Fix up function name.

Signed-off-by: David Kilroy <kilroyd@googlemail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: wlags49_h2: Fixup IW_AUTH handling
David Kilroy [Sun, 9 Oct 2011 11:11:36 +0000 (12:11 +0100)]
staging: wlags49_h2: Fixup IW_AUTH handling

Handle more cases in IW_AUTH.

Avoid reporting errors (invalid parameter) on operations that we
can't do anything with.

Return -EINPROGRESS from some operations to get wpa_supplicant to
batch and commit changes.

In other operations apply the changes immediately.

Avoid writing WEP keys from the commit handler when WEP is not
being used.

Accept WPA_VERSION_DISABLED, which is received from wpa_supplicant
during WEP.

Signed-off-by: David Kilroy <kilroyd@googlemail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: wlags49_h2: Make key setting more reliable
David Kilroy [Sun, 9 Oct 2011 11:11:35 +0000 (12:11 +0100)]
staging: wlags49_h2: Make key setting more reliable

Share logic between encodeext and encode, so that we can handle
subtle differences between them (implied set_tx), and clear the
appropriate keys if you attempt to switch straight from WPA to
WEP and vice versa.

Also reinstate the TX buffer flush, and ensure the key index is
written to the card little endian.

Signed-off-by: David Kilroy <kilroyd@googlemail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: wlags49_h2: Report WPA IE in scan results with IWEVGENIE
David Kilroy [Sun, 9 Oct 2011 11:11:34 +0000 (12:11 +0100)]
staging: wlags49_h2: Report WPA IE in scan results with IWEVGENIE

Report the IE using the appropriate event instead of a custom one.

Signed-off-by: David Kilroy <kilroyd@googlemail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: wlags49_h2: Remove useless IWE_STREAM_ADD_XXX defines
David Kilroy [Sun, 9 Oct 2011 11:11:33 +0000 (12:11 +0100)]
staging: wlags49_h2: Remove useless IWE_STREAM_ADD_XXX defines

These macros don't map to anything different. Just remove them.

Signed-off-by: David Kilroy <kilroyd@googlemail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: wlags49_h2: Enable WPA in the HCF
David Kilroy [Sun, 9 Oct 2011 11:11:32 +0000 (12:11 +0100)]
staging: wlags49_h2: Enable WPA in the HCF

WPA has been disabled in the HCF layer. The firmware does
support it (it is used on other platforms). Enable it so
we can work through the issues.

Note that we also enable this for the HERMES 2.5 non-WARP
firmware cards.

Signed-off-by: David Kilroy <kilroyd@googlemail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: wlags49_h2: Handle sysfs_create_group return correctly
David Kilroy [Sun, 9 Oct 2011 11:11:31 +0000 (12:11 +0100)]
staging: wlags49_h2: Handle sysfs_create_group return correctly

The function returns 0 on success and non-zero on error. So
correctly record the status so it is freed appropriately.

Signed-off-by: David Kilroy <kilroyd@googlemail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agodrivers: staging: rts_pstor fixed checkpatch warnings
Pelle Windestam [Mon, 10 Oct 2011 17:41:42 +0000 (19:41 +0200)]
drivers: staging: rts_pstor fixed checkpatch warnings

Fixed the checkpatch warnings in rtsx.c/.h, mostly braces and spaces
before tabs issues. Also fixed warning about not using
DEFINE_PCI_DEVICE_TABLE(...) macro.

Signed-off-by: Pelle Windestam <pelle@windestam.se>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging:rts_pstor:Fix SDIO issue
wwang [Mon, 10 Oct 2011 06:47:08 +0000 (14:47 +0800)]
staging:rts_pstor:Fix SDIO issue

Fix a bug that SDIO and SD normal card would appear simultaneously if a SDIO card inserted.

Signed-off-by: wwang <wei_wang@realsil.com.cn>
Acked-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agoStaging: comedi: fix brace coding style issue in ni_atmio.c
Jake Burton [Mon, 10 Oct 2011 16:02:24 +0000 (17:02 +0100)]
Staging: comedi: fix brace coding style issue in ni_atmio.c

This is a patch to the ni_atmio.c file which fixes a brace and whitespace warning found by the checkpatch.pl tool

Signed-off-by: Jake Burton <jake5991@live.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agoStaging: comedi: c6xdigio: fixed missing KERN_* in printk
Nasir Abed [Mon, 10 Oct 2011 10:09:52 +0000 (12:09 +0200)]
Staging: comedi: c6xdigio: fixed missing KERN_* in printk

Fixed missing KERN_* in printk statements.

Signed-off-by: Nasir Abed <nasirabed+kernel@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agoAvoid using variable-length arrays in kernel/sys.c
Linus Torvalds [Mon, 17 Oct 2011 15:24:24 +0000 (08:24 -0700)]
Avoid using variable-length arrays in kernel/sys.c

The size is always valid, but variable-length arrays generate worse code
for no good reason (unless the function happens to be inlined and the
compiler sees the length for the simple constant it is).

Also, there seems to be some code generation problem on POWER, where
Henrik Bakken reports that register r28 can get corrupted under some
subtle circumstances (interrupt happening at the wrong time?).  That all
indicates some seriously broken compiler issues, but since variable
length arrays are bad regardless, there's little point in trying to
chase it down.

"Just don't do that, then".

Reported-by: Henrik Grindal Bakken <henribak@cisco.com>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: stable@kernel.org
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
12 years agoMerge branch 'fixes' of http://ftp.arm.linux.org.uk/pub/linux/arm/kernel/git-cur...
Linus Torvalds [Sun, 16 Oct 2011 20:08:27 +0000 (13:08 -0700)]
Merge branch 'fixes' of ftp.arm.linux.org.uk/pub/linux/arm/kernel/git-cur/linux-2.6-arm

* 'fixes' of http://ftp.arm.linux.org.uk/pub/linux/arm/kernel/git-cur/linux-2.6-arm:
  ARM: 7128/1: vic: Don't write to the read-only register VIC_IRQ_STATUS
  ARM: 7122/1: localtimer: add header linux/errno.h explicitly
  ARM: 7117/1: perf: fix HW_CACHE_* events on Cortex-A9
  ARM: 7113/1: mm: Align bank start to MAX_ORDER_NR_PAGES

12 years agoARM: 7128/1: vic: Don't write to the read-only register VIC_IRQ_STATUS
Zoltan Devai [Mon, 10 Oct 2011 13:54:12 +0000 (14:54 +0100)]
ARM: 7128/1: vic: Don't write to the read-only register VIC_IRQ_STATUS

This is unneeded and causes an abort on the SPMP8000 platform.

Acked-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Zoltan Devai <zoss@devai.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
12 years agoARM: 7122/1: localtimer: add header linux/errno.h explicitly
Shawn Guo [Thu, 6 Oct 2011 13:57:24 +0000 (14:57 +0100)]
ARM: 7122/1: localtimer: add header linux/errno.h explicitly

Per the text in  Documentation/SubmitChecklist as below, we should
explicitly have header linux/errno.h in localtimer.h for ENXIO
reference.

1: If you use a facility then #include the file that defines/declares
   that facility.  Don't depend on other header files pulling in ones
   that you use.

Otherwise, we may run into some compiling error like the following one,
if any file includes localtimer.h without CONFIG_LOCAL_TIMERS defined.

  arch/arm/include/asm/localtimer.h: In function â€˜local_timer_setup’:
  arch/arm/include/asm/localtimer.h:53:10: error: â€˜ENXIO’ undeclared (first use in this function)

Signed-off-by: Shawn Guo <shawn.guo@linaro.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
12 years agoARM: 7117/1: perf: fix HW_CACHE_* events on Cortex-A9
Will Deacon [Mon, 3 Oct 2011 17:30:53 +0000 (18:30 +0100)]
ARM: 7117/1: perf: fix HW_CACHE_* events on Cortex-A9

Using COHERENT_LINE_{MISS,HIT} for cache misses and references
respectively is completely wrong. Instead, use the L1D events which
are a better and more useful approximation despite ignoring instruction
traffic.

Reported-by: Alasdair Grant <alasdair.grant@arm.com>
Reported-by: Matt Horsnell <matt.horsnell@arm.com>
Reported-by: Michael Williams <michael.williams@arm.com>
Cc: stable@kernel.org
Cc: Jean Pihet <j-pihet@ti.com>
Signed-off-by: Will Deacon <will.deacon@arm.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
12 years agoMerge branch 'hwmon-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/groec...
Linus Torvalds [Fri, 14 Oct 2011 20:29:09 +0000 (08:29 +1200)]
Merge branch 'hwmon-for-linus' of git://git./linux/kernel/git/groeck/linux-staging

* 'hwmon-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging:
  hwmon: (w83627ehf) Properly report thermal diode sensors

12 years agointel-iommu: Export a flag indicating that the IOMMU is used for iGFX.
David Woodhouse [Fri, 14 Oct 2011 19:59:46 +0000 (20:59 +0100)]
intel-iommu: Export a flag indicating that the IOMMU is used for iGFX.

We really don't want this to work in the general case; device drivers
*shouldn't* care whether they are behind an IOMMU or not. But the
integrated graphics is a special case, because the IOMMU and the GTT are
all kind of smashed into one and generally horrifically buggy, so it's
reasonable for the graphics driver to want to know when the IOMMU is
active for the graphics hardware.

Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
12 years agointel-iommu: Workaround IOTLB hang on Ironlake GPU
David Woodhouse [Mon, 26 Sep 2011 02:11:14 +0000 (19:11 -0700)]
intel-iommu: Workaround IOTLB hang on Ironlake GPU

To work around a hardware issue, we have to submit IOTLB flushes while
the graphics engine is idle. The graphics driver will (we hope) go to
great lengths to ensure that it gets that right on the affected
chipset(s)... so let's not screw it over by deferring the unmap and
doing it later. That wouldn't be very helpful.

Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
12 years agoMerge branch 'gpio/merge' of git://git.secretlab.ca/git/linux-2.6
Linus Torvalds [Fri, 14 Oct 2011 05:07:52 +0000 (17:07 +1200)]
Merge branch 'gpio/merge' of git://git.secretlab.ca/git/linux-2.6

* 'gpio/merge' of git://git.secretlab.ca/git/linux-2.6:
  gpio-pca953x: fix gpio_base
  gpio/omap: fix build error with certain OMAP1 configs

12 years agoMerge branch 'for-linus' of git://oss.sgi.com/xfs/xfs
Linus Torvalds [Fri, 14 Oct 2011 05:06:39 +0000 (17:06 +1200)]
Merge branch 'for-linus' of git://oss.sgi.com/xfs/xfs

* 'for-linus' of git://oss.sgi.com/xfs/xfs:
  xfs: revert to using a kthread for AIL pushing
  xfs: force the log if we encounter pinned buffers in .iop_pushbuf
  xfs: do not update xa_last_pushed_lsn for locked items

12 years agoMerge branch 'stable' of git://github.com/cmetcalf-tilera/linux-tile
Linus Torvalds [Fri, 14 Oct 2011 04:59:11 +0000 (16:59 +1200)]
Merge branch 'stable' of git://github.com/cmetcalf-tilera/linux-tile

* 'stable' of git://github.com/cmetcalf-tilera/linux-tile:
  tile: revert change from <asm/atomic.h> to <linux/atomic.h> in asm files

12 years agoMerge branch 'x86-urgent-for-linus' of git://tesla.tglx.de/git/linux-2.6-tip
Linus Torvalds [Fri, 14 Oct 2011 04:54:56 +0000 (16:54 +1200)]
Merge branch 'x86-urgent-for-linus' of git://tesla.tglx.de/git/linux-2.6-tip

* 'x86-urgent-for-linus' of git://tesla.tglx.de/git/linux-2.6-tip:
  x86: Default to vsyscall=native for now

12 years agox86, mrst: use a temporary variable for SFI irq
Mika Westerberg [Thu, 13 Oct 2011 09:04:20 +0000 (12:04 +0300)]
x86, mrst: use a temporary variable for SFI irq

SFI tables reside in RAM and should not be modified once they are
written.  Current code went to set pentry->irq to zero which causes
subsequent reads to fail with invalid SFI table checksum.  This will
break kexec as the second kernel fails to validate SFI tables.

To fix this we use temporary variable for irq number.

Signed-off-by: Mika Westerberg <mika.westerberg@linux.intel.com>
Reviewed-by: Kirill A. Shutemov <kirill.shutemov@linux.intel.com>
Cc: stable@kernel.org
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
12 years agohwmon: (w83627ehf) Properly report thermal diode sensors
Jean Delvare [Thu, 13 Oct 2011 19:49:08 +0000 (15:49 -0400)]
hwmon: (w83627ehf) Properly report thermal diode sensors

The w83627ehf driver is improperly reporting thermal diode sensors as
type 2, instead of 3. This caused "sensors" and possibly other
monitoring tools to report these sensors as "transistor" instead of
"thermal diode".

Furthermore, diode subtype selection (CPU vs. external) is only
supported by the original W83627EHF/EHG. All later models only support
CPU diode type, and some (NCT6776F) don't even have the register in
question so we should avoid reading from it.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Cc: stable@kernel.org
Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com>
12 years agogpio-pca953x: fix gpio_base
Hartmut Knaack [Mon, 10 Oct 2011 22:22:45 +0000 (00:22 +0200)]
gpio-pca953x: fix gpio_base

gpio_base was set to 0 if no system platform data or open firmware
platform data was provided. This led to conflicts, if any other gpiochip
with a gpiobase of 0 was instantiated already. Setting it to -1 will
automatically use the first one available.

Signed-off-by: Hartmut Knaack <knaack.h@gmx.de>
Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
12 years agogpio/omap: fix build error with certain OMAP1 configs
Janusz Krzysztofik [Tue, 23 Aug 2011 11:42:24 +0000 (13:42 +0200)]
gpio/omap: fix build error with certain OMAP1 configs

With commit f64ad1a0e21a, "gpio/omap: cleanup _set_gpio_wakeup(), remove
ifdefs", access to build time conditionally omitted 'suspend_wakeup'
member of the 'gpio_bank' structure has been placed unconditionally in
function _set_gpio_wakeup(), which is always built. This resulted in the
driver compilation broken for certain OMAP1, i.e., non-OMAP16xx,
configurations.

Really required or not in previously excluded cases, define this
structure member unconditionally as a fix.

Tested with a custom OMAP1510 only configuration.

Signed-off-by: Janusz Krzysztofik <jkrzyszt@tis.icnet.pl>
Acked-by: Kevin Hilman <khilman@ti.com>
Tested-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
12 years agotile: revert change from <asm/atomic.h> to <linux/atomic.h> in asm files
Chris Metcalf [Wed, 5 Oct 2011 21:09:29 +0000 (17:09 -0400)]
tile: revert change from <asm/atomic.h> to <linux/atomic.h> in asm files

The 32-bit TILEPro support uses some #defines in <asm/atomic_32.h>
for atomic support routines in assembly.  To make this more explicit,
I've turned those includes into includes of <asm/atomic_32.h>, which
should hopefully make it clear that they shouldn't be bombed into
<linux/atomic.h> in any cleanups.

Signed-off-by: Chris Metcalf <cmetcalf@tilera.com>
12 years agoMerge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
Linus Torvalds [Thu, 13 Oct 2011 06:25:45 +0000 (18:25 +1200)]
Merge git://git./linux/kernel/git/davem/net

* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net:
  mscan: too much data copied to CAN frame due to 16 bit accesses
  gro: refetch inet6_protos[] after pulling ext headers
  bnx2x: fix cl_id allocation for non-eth clients for NPAR mode
  mlx4_en: fix endianness with blue frame support

12 years agoide: Fix file references in drivers/ide/
Johann Felix Soden [Mon, 10 Oct 2011 18:37:00 +0000 (11:37 -0700)]
ide: Fix file references in drivers/ide/

Fix file references in drivers/ide/

There are a lot of file references to now moved or deleted files in the
whole tree, especially in documentation and Kconfig files.  This patch
fixes the references in drivers/ide/.

Signed-off-by: Johann Felix Soden <johfel@users.sourceforge.net>
Signed-off-by: Randy Dunlap <rdunlap@xenotime.net>
Acked-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
12 years agoMerge branch 'btrfs-3.0' of git://github.com/chrismason/linux
Linus Torvalds [Thu, 13 Oct 2011 06:20:40 +0000 (18:20 +1200)]
Merge branch 'btrfs-3.0' of git://github.com/chrismason/linux

* 'btrfs-3.0' of git://github.com/chrismason/linux:
  Btrfs: make sure not to defrag extents past i_size
  Btrfs: fix recursive auto-defrag

12 years agosparc: Avoid calling sigprocmask()
David S. Miller [Wed, 12 Oct 2011 19:27:35 +0000 (12:27 -0700)]
sparc: Avoid calling sigprocmask()

Use set_current_blocked() instead.

Signed-off-by: David S. Miller <davem@davemloft.net>
12 years agosparc: Use set_current_blocked()
Matt Fleming [Thu, 11 Aug 2011 13:57:02 +0000 (14:57 +0100)]
sparc: Use set_current_blocked()

As described in e6fa16ab ("signal: sigprocmask() should do
retarget_shared_pending()") the modification of current->blocked is
incorrect as we need to check whether the signal we're about to block
is pending in the shared queue.

Cc: Oleg Nesterov <oleg@redhat.com>
Cc: "David S. Miller" <davem@davemloft.net>
Signed-off-by: Matt Fleming <matt.fleming@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
12 years agoIPVS netns shutdown/startup dead-lock
Hans Schillstrom [Tue, 11 Oct 2011 01:54:35 +0000 (10:54 +0900)]
IPVS netns shutdown/startup dead-lock

ip_vs_mutext is used by both netns shutdown code and startup
and both implicit uses sk_lock-AF_INET mutex.

cleanup CPU-1         startup CPU-2
ip_vs_dst_event()     ip_vs_genl_set_cmd()
 sk_lock-AF_INET     __ip_vs_mutex
                     sk_lock-AF_INET
__ip_vs_mutex
* DEAD LOCK *

A new mutex placed in ip_vs netns struct called sync_mutex is added.

Comments from Julian and Simon added.
This patch has been running for more than 3 month now and it seems to work.

Ver. 3
    IP_VS_SO_GET_DAEMON in do_ip_vs_get_ctl protected by sync_mutex
    instead of __ip_vs_mutex as sugested by Julian.

Signed-off-by: Hans Schillstrom <hans@schillstrom.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
12 years agostaging: xgifb: clean up 2nd display state
Aaro Koskinen [Tue, 11 Oct 2011 18:47:37 +0000 (21:47 +0300)]
staging: xgifb: clean up 2nd display state

Convert the display type to enum and rename disp_state to display2.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: xgifb: delete CRT1 state
Aaro Koskinen [Tue, 11 Oct 2011 18:47:36 +0000 (21:47 +0300)]
staging: xgifb: delete CRT1 state

The driver does not need to manage CRT1 state.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: xgifb: make DAC tables const
Aaro Koskinen [Tue, 11 Oct 2011 18:47:35 +0000 (21:47 +0300)]
staging: xgifb: make DAC tables const

DAC tables are read-only and can be made const.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: xgifb: make RAM type tables const
Aaro Koskinen [Tue, 11 Oct 2011 18:47:34 +0000 (21:47 +0300)]
staging: xgifb: make RAM type tables const

RAM type tables are read-only and can be made const.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: xgifb: move XGINew_DataBusWidth into vb_device_info
Aaro Koskinen [Tue, 11 Oct 2011 18:47:33 +0000 (21:47 +0300)]
staging: xgifb: move XGINew_DataBusWidth into vb_device_info

Move the memory bus width info to vb_device_info.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: xgifb: move XGINew_ChannelAB into vb_device_info
Aaro Koskinen [Tue, 11 Oct 2011 18:47:32 +0000 (21:47 +0300)]
staging: xgifb: move XGINew_ChannelAB into vb_device_info

Move the memory channel info into vb_device_info.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: xgifb: move XGINew_RAMType into vb_device_info
Aaro Koskinen [Tue, 11 Oct 2011 18:47:31 +0000 (21:47 +0300)]
staging: xgifb: move XGINew_RAMType into vb_device_info

The RAM type is device specific, so move it into vb_device_info.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: xgifb: eliminate global XGI_Pr data
Aaro Koskinen [Tue, 11 Oct 2011 18:47:30 +0000 (21:47 +0300)]
staging: xgifb: eliminate global XGI_Pr data

Move vb_device_info into xgifb_video_info.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: xgifb: make XGIbios_mode const
Aaro Koskinen [Tue, 11 Oct 2011 18:47:29 +0000 (21:47 +0300)]
staging: xgifb: make XGIbios_mode const

Comments are wrong, the table is read-only and can be made const.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: xgifb: eliminate filter_tb global variable
Aaro Koskinen [Tue, 11 Oct 2011 18:47:28 +0000 (21:47 +0300)]
staging: xgifb: eliminate filter_tb global variable

filter_tb is only used inside a single function, and it does not need
to be static.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: xgifb: eliminate XGIfb_fix
Aaro Koskinen [Tue, 11 Oct 2011 18:47:27 +0000 (21:47 +0300)]
staging: xgifb: eliminate XGIfb_fix

Eliminate XGIfb_fix and initialize needed fields of fb_info->fix
in probe().

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: xgifb: eliminate default_var
Aaro Koskinen [Tue, 11 Oct 2011 18:47:26 +0000 (21:47 +0300)]
staging: xgifb: eliminate default_var

Eliminate default_var and initialize needed fields of fb_info->var
in probe().

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: xgifb: eliminate XGIfb_CRT2_write_enable variable
Aaro Koskinen [Tue, 11 Oct 2011 18:47:25 +0000 (21:47 +0300)]
staging: xgifb: eliminate XGIfb_CRT2_write_enable variable

Replace XGIfb_CRT2_write_enable with IND_XGI_CRT2_WRITE_ENABLE_315.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: xgifb: move pseudo_palette into xgifb_video_info
Aaro Koskinen [Tue, 11 Oct 2011 18:47:24 +0000 (21:47 +0300)]
staging: xgifb: move pseudo_palette into xgifb_video_info

pseudo_palette should be dynamically allocated for each fb.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: xgifb: move XGIfb_rate_idx into xgifb_video_info
Aaro Koskinen [Tue, 11 Oct 2011 18:47:23 +0000 (21:47 +0300)]
staging: xgifb: move XGIfb_rate_idx into xgifb_video_info

The current refresh rate index should be stored in the device-specific
data allocated in probe().

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: xgifb: move xgifb_mode_idx into xgifb_video_info
Aaro Koskinen [Tue, 11 Oct 2011 18:47:22 +0000 (21:47 +0300)]
staging: xgifb: move xgifb_mode_idx into xgifb_video_info

The current mode index should be stored in the device-specific data
allocated in probe().

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: xgifb: eliminate XGIfb_mode_no
Aaro Koskinen [Tue, 11 Oct 2011 18:47:21 +0000 (21:47 +0300)]
staging: xgifb: eliminate XGIfb_mode_no

We can get the information from the table with mode index.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: xgifb: dynamically allocate xgifb_video_info
Aaro Koskinen [Tue, 11 Oct 2011 18:47:20 +0000 (21:47 +0300)]
staging: xgifb: dynamically allocate xgifb_video_info

Delete global xgi_video_info and dynamically allocate the data.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: xgifb: avoid direct references xgi_video_info
Aaro Koskinen [Tue, 11 Oct 2011 18:47:19 +0000 (21:47 +0300)]
staging: xgifb: avoid direct references xgi_video_info

Avoid direct references to global xgi_video_info. This will help changing
the data from statically allocated to dynamically allocated.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: xgifb: rename struct video_info to xgifb_video_info
Aaro Koskinen [Tue, 11 Oct 2011 18:47:18 +0000 (21:47 +0300)]
staging: xgifb: rename struct video_info to xgifb_video_info

Rename struct video_info to xgifb_video_info.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: xgifb: add a global variable for the default refresh rate
Aaro Koskinen [Tue, 11 Oct 2011 18:47:17 +0000 (21:47 +0300)]
staging: xgifb: add a global variable for the default refresh rate

Add a global variable for the default refresh rate. This is done to
get rid of references to xgi_video_info before the probe routine, which
should allocate the xgi_video_info dynamically in the future.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: xgifb: inline XGIfb_query_VGA_config_space()
Aaro Koskinen [Tue, 11 Oct 2011 18:47:16 +0000 (21:47 +0300)]
staging: xgifb: inline XGIfb_query_VGA_config_space()

XGIfb_query_VGA_config_space() is used only once during the init and
can be replaced with a single PCI configuration space read.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: xgifb: eliminate global XGIhw_ext data
Aaro Koskinen [Tue, 11 Oct 2011 18:47:15 +0000 (21:47 +0300)]
staging: xgifb: eliminate global XGIhw_ext data

Move xgi_hw_device_info into xgi_video_info.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: xgifb: eliminate global fb_info variable
Aaro Koskinen [Tue, 11 Oct 2011 18:47:14 +0000 (21:47 +0300)]
staging: xgifb: eliminate global fb_info variable

Move fb_info into xgi_video_info.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: xgifb: use PCI drvdata
Aaro Koskinen [Tue, 11 Oct 2011 18:47:13 +0000 (21:47 +0300)]
staging: xgifb: use PCI drvdata

Don't access the global xgi_video_info directly in xgifb_remove().

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: zcache: reduce tmem bucket lock contention
Seth Jennings [Tue, 4 Oct 2011 13:21:32 +0000 (08:21 -0500)]
staging: zcache: reduce tmem bucket lock contention

tmem uses hash buckets each with their own rbtree and lock to
quickly lookup tmem objects.  tmem has TMEM_HASH_BUCKETS (256)
buckets per pool.  However, because of the way the tmem_oid is
generated for frontswap pages, only 16 unique tmem_oids are being
generated, resulting in only 16 of the 256 buckets being used.
This cause high lock contention for the per bucket locks.

This patch changes SWIZ_BITS to include more bits of the offset.
The result is that all 256 hash buckets are potentially used resulting in a
95% drop in hash bucket lock contention.

Signed-off-by: Seth Jennings <sjenning@linux.vnet.ibm.com>
Acked-by: Dan Magenheimer <dan.magenheimer@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: brcm80211: remove brcm80211 driver from the staging tree
Arend van Spriel [Fri, 7 Oct 2011 14:24:40 +0000 (16:24 +0200)]
staging: brcm80211: remove brcm80211 driver from the staging tree

With the mainline patch being applied to the wireless-next repository
by John Linville this driver is no longer needed under the staging
directory. This patch ends its life under the staging tree.

Cc: John W. Linville <linville@tuxdriver.com>
Signed-off-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agoStaging: bcm: Fix coding style issues in InterfaceMisc.c
Kevin McKinney [Tue, 11 Oct 2011 01:01:50 +0000 (21:01 -0400)]
Staging: bcm: Fix coding style issues in InterfaceMisc.c

This patch cleans up several code style issues found
in InterfaceMisc.c reported by checkpatch.pl.

Signed-off-by: Kevin McKinney <klmckinney1@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agoStaging: bcm: Remove assignment from if conditions reported by checkpatch.pl
Kevin McKinney [Tue, 11 Oct 2011 01:01:49 +0000 (21:01 -0400)]
Staging: bcm: Remove assignment from if conditions reported by checkpatch.pl

This patch removes an assignment from three if
conditions.  In all three cases, the line of code was
attempting to allocate memory, and check
if the memory was allocated in the if statement.
This issue was reported by checkpatch.pl.

Signed-off-by: Kevin McKinney <klmckinney1@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agoStaging: bcm: Fix coding style issues reported by checkpatch.pl
Kevin McKinney [Tue, 11 Oct 2011 01:01:48 +0000 (21:01 -0400)]
Staging: bcm: Fix coding style issues reported by checkpatch.pl

This patch cleans up several code style issues found
in InterfaceInit.c reported by checkpatch.pl.

Signed-off-by: Kevin McKinney <klmckinney1@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agoStaging: bcm: Fix assignment issue in if statement reported by checkpatch.pl.
Kevin McKinney [Fri, 7 Oct 2011 22:50:12 +0000 (18:50 -0400)]
Staging: bcm: Fix assignment issue in if statement reported by checkpatch.pl.

This patch fixes an error where an assignment "="
was being used in an if statement to determine if
Firmware was downloaded. This patch removes that
assignment, and places it above the if statement.
The if statement then evaluates the status to
verify if "0" successful, or != 0 failure.

Signed-off-by: Kevin McKinney <klmckinney1@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agoStaging: bcm: Remove assignment in if condition reported by checkpatch.pl
Kevin McKinney [Fri, 7 Oct 2011 22:50:11 +0000 (18:50 -0400)]
Staging: bcm: Remove assignment in if condition reported by checkpatch.pl

There is a case where an assignment was being done
in an if condition. This patch removes the assignment
from the if condition and places the assignment above
the if statement; thereby improving the readability of
the code.

Signed-off-by: Kevin McKinney <klmckinney1@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agoStaging: bcm: Replace dated variable __FUNCTION__ reported by checkpatch.pl
Kevin McKinney [Fri, 7 Oct 2011 22:50:10 +0000 (18:50 -0400)]
Staging: bcm: Replace dated variable __FUNCTION__ reported by checkpatch.pl

This patch replaces the obsolete variable, __FUNCTION__, that
holds the name of the current function with variable, __func__.

Signed-off-by: Kevin McKinney <klmckinney1@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agoStaging: bcm: Fix coding style issues reported by checkpatch.pl
Kevin McKinney [Fri, 7 Oct 2011 22:50:09 +0000 (18:50 -0400)]
Staging: bcm: Fix coding style issues reported by checkpatch.pl

This patch cleans up several hundred code style issues found
in Misc.c reported by checkpatch.pl.

Signed-off-by: Kevin McKinney <klmckinney1@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: et131x: Update TODO list
Mark Einon [Mon, 10 Oct 2011 15:22:32 +0000 (16:22 +0100)]
staging: et131x: Update TODO list

Added some more tasks to the TODO list, as highlighted by Francois
Romieu <romieu@fr.zoreil.com>.

Signed-off-by: Mark Einon <mark.einon@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: et131x: Remove unused mac defines
Mark Einon [Mon, 10 Oct 2011 15:22:09 +0000 (16:22 +0100)]
staging: et131x: Remove unused mac defines

Remove some unused defines from et1310_mac.c.

Signed-off-by: Mark Einon <mark.einon@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: et131x: Fix et131x smatch issues
Mark Einon [Mon, 10 Oct 2011 15:21:12 +0000 (16:21 +0100)]
staging: et131x: Fix et131x smatch issues

This fixes the following issues:

et131x_initpci.c +488 et131x_adjust_link(45) error: we previously assumed 'phydev' could be null.
et131x_initpci.c +504 et131x_adjust_link(61) warn: variable dereferenced before check 'phydev'

Signed-off-by: Mark Einon <mark.einon@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: et131x: Fix et131x sparse warnings
Mark Einon [Mon, 10 Oct 2011 15:21:11 +0000 (16:21 +0100)]
staging: et131x: Fix et131x sparse warnings

This fixes the following warnings:

et1310_mac.c:375:44: warning: incorrect type in initializer (different address spaces)
et1310_mac.c:382:28: warning: incorrect type in argument 2 (different address spaces)
et1310_mac.c:384:31: warning: incorrect type in argument 2 (different address spaces)
et131x_initpci.c:555:5: warning: symbol 'et131x_mii_probe' was not declared. Should it be static?
et131x_netdev.c:267:5: warning: symbol 'et131x_ioctl' was not declared. Should it be static?
et131x_netdev.c:285:5: warning: symbol 'et131x_set_packet_filter' was not declared. Should it be static?
et131x_netdev.c:347:6: warning: symbol 'et131x_multicast' was not declared. Should it be static?
et131x_netdev.c:420:5: warning: symbol 'et131x_tx' was not declared. Should it be static?
et131x_netdev.c:453:6: warning: symbol 'et131x_tx_timeout' was not declared. Should it be static?
et131x_netdev.c:511:5: warning: symbol 'et131x_change_mtu' was not declared. Should it be static?
et131x_netdev.c:564:5: warning: symbol 'et131x_set_mac_addr' was not declared. Should it be static?

Signed-off-by: Mark Einon <mark.einon@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: et131x: Remove file et131x_version.h
Mark Einon [Fri, 7 Oct 2011 21:53:56 +0000 (22:53 +0100)]
staging: et131x: Remove file et131x_version.h

Removed defines in et131x_version.h and replaced them by actual
strings where convinient, or moved them to et131x.h

Signed-off-by: Mark Einon <mark.einon@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: et131x: Move pm calls from pci device to driver device
Mark Einon [Fri, 7 Oct 2011 21:52:51 +0000 (22:52 +0100)]
staging: et131x: Move pm calls from pci device to driver device

Move the pci driver suspend/resume calls up to the driver.pm ops
structure, as they are not pci device specific.

Thanks to Francois Romieu <romieu@fr.zoreil.com> for pointing this out.

Signed-off-by: Mark Einon <mark.einon@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: et131x: Remove error path from suspend/resume code
Mark Einon [Fri, 7 Oct 2011 21:52:50 +0000 (22:52 +0100)]
staging: et131x: Remove error path from suspend/resume code

Removing an error path from et131x suspend/resume functions.

Also added a call to phy_stop() to complement the phy_start() call
during device start/stop routine.

Thanks to Francois Romieu <romieu@fr.zoreil.com> for pointing this out.

Signed-off-by: Mark Einon <mark.einon@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
12 years agostaging: et131x: Removing Olaf Hartmann's email as it bounces
Mark Einon [Fri, 7 Oct 2011 21:51:27 +0000 (22:51 +0100)]
staging: et131x: Removing Olaf Hartmann's email as it bounces

On 3 October 2011 18:51, Uwe Ranft <uwe.ranft@telozo.com> wrote:
> Hello,
> olaf is not more longer owner of this e-mailadress. he has left our
> company.
> Please remove olaf fron the mailing list!
> Best Regards
> Uwe

Signed-off-by: Mark Einon <mark.einon@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>