9 years agoiwlagn: fix typo in ucode_bt_stats_read debugfs
Wey-Yi Guy [Sat, 31 Jul 2010 15:34:12 +0000]
iwlagn: fix typo in ucode_bt_stats_read debugfs

small typo fix in ucode_bt_stats_read debugfs file

Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>

9 years agoiwlwifi: BA scd_flow not match condition detected
Wey-Yi Guy [Sat, 31 Jul 2010 15:34:11 +0000]
iwlwifi: BA scd_flow not match condition detected

It is a uCode bug which cause the tx queue id not match scd_flow
in compressed block ack frame, and it need to be addressed in uCode.
Currently, driver will log the information when it happen.

Since it is possible happen very often and we do not want to fill the syslog,
so don't enable the logging by default.

Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>

9 years agoiwlwifi: fix compile warning
Johannes Berg [Sat, 31 Jul 2010 15:34:09 +0000]
iwlwifi: fix compile warning

When iwlwifi is compiled w/o debug, we get
this warning:
iwl-agn.c: In function ‘iwlagn_load_firmware’:
iwl-agn.c:2014: warning: passing argument 3 of ‘iwl_print_hex_dump’ discards qualifiers from pointer target type
iwl-debug.h:73: note: expected ‘void *’ but argument is of type ‘const u8 *’

because the const qualifier is missing in the
inline stub. Fix this.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>

9 years agoath9k_hw: fix a noise floor calibration related race condition
Felix Fietkau [Fri, 30 Jul 2010 22:12:01 +0000]
ath9k_hw: fix a noise floor calibration related race condition

On AR5008-AR9002, other forms of calibration must not be started while
the noise floor calibration is running, as this can create invalid
readings which were sometimes not even recoverable by any further
calibration attempts.

This patch also ensures that the result of noise floor measurements
are processed faster and also allows the result of the initial
calibration on reset to make it into the NF history buffer

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>

9 years agoath9k_hw: clean up per-channel calibration data
Felix Fietkau [Fri, 30 Jul 2010 22:12:00 +0000]
ath9k_hw: clean up per-channel calibration data

The noise floor history buffer is currently not kept per channel, which
can lead to problems when changing channels from a clean channel to a
noisy one. Also when switching from HT20 to HT40, the noise floor
history buffer is full of measurements, but none of them contain data
for the extension channel, which it needs quite a bit of time to recover
from.

This patch puts all the per-channel calibration data into a single data
structure, and gives the the driver control over whether that is used
per-channel or even not used for some channels.

For ath9k_htc, I decided to keep this per-channel in order to avoid
creating regressions.

For ath9k, the data is kept only for the operating channel, which saves
some space. ath9k_hw takes care of wiping old data when the operating
channel or its channel flags change.

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>

9 years agoath9k: prevent calibration during off-channel activity
Felix Fietkau [Fri, 30 Jul 2010 22:11:59 +0000]
ath9k: prevent calibration during off-channel activity

Previously the software scan callback was used to indicate to the hardware,
when it was safe to calibrate. This didn't really work properly, because it
depends on a specific order of software scan callbacks vs. channel changes.
Also, software scans are not the only thing that triggers off-channel
activity, so it's better to use the newly added indication from mac80211 for
this and not use the software scan callback for anything calibration related.

This fixes at least some of the invalid noise floor readings that I've seen
in AP mode on AR9160

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>

9 years agoath9k_hw: fix analog shift register writes on AR9003
Felix Fietkau [Fri, 30 Jul 2010 19:02:12 +0000]
ath9k_hw: fix analog shift register writes on AR9003

Writes to the analog shift registers, which are issues by the initval
programming function, require a 100 usec delay (similar to AR9002,
but in a different register range).

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Acked-by: Luis R. Rodriguez <lrodriguez@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>

9 years agoath9k: fix a crash in the PA predistortion apply function
Felix Fietkau [Fri, 30 Jul 2010 19:02:11 +0000]
ath9k: fix a crash in the PA predistortion apply function

When updating the PAPRD table in hardware, PAPRD itself needs to be
disabled first, otherwise the hardware can throw a data bus error,
which upsets at least some platforms.

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Acked-by: Luis R. Rodriguez <lrodriguez@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>

9 years agoath9k_hw: fix periodic noise floor calibration on AR9003
Felix Fietkau [Fri, 30 Jul 2010 19:02:10 +0000]
ath9k_hw: fix periodic noise floor calibration on AR9003

The periodic noise floor calibration is broken on this chip family, because
it keeps triggering a software-filtered noise floor calibration, but never
reads the result before uploading the history buffer value to the hardware.

Fix this with a call to ath9k_hw_getnf(), just like on AR9002.

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Acked-by: Luis R. Rodriguez <lrodriguez@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>

9 years agoath9k_hw: clean up and fix initial noise floor calibration
Felix Fietkau [Fri, 30 Jul 2010 19:02:09 +0000]
ath9k_hw: clean up and fix initial noise floor calibration

On AR9003 the initial noise floor calibration is currently triggered
at the end of the reset without allowing the hardware to update the
baseband settings. This could potentially make scans in noisy
environments a bit more unreliable, so use the same calibration
sequence that is used on AR9002.

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Acked-by: Luis R. Rodriguez <lrodriguez@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>

9 years agomac80211: fix scan locking wrt. hw scan
Johannes Berg [Fri, 30 Jul 2010 11:30:47 +0000]
mac80211: fix scan locking wrt. hw scan

Releasing the scan mutex while starting scans
can lead to unexpected things happening, so
we shouldn't do that. Fix that and hold the
mutex across the scan triggering.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>

9 years agoiwlwifi: fix possible recursive locking deadlock
Johannes Berg [Fri, 30 Jul 2010 11:30:46 +0000]
iwlwifi: fix possible recursive locking deadlock

commit f84b29ec0a1ab767679d3f2428877b65f94bc3ff
Author: Johannes Berg <johannes.berg@intel.com>
Date:   Tue May 18 02:29:13 2010 -0700

    iwlwifi: queue user-initiated scan when doing internal scan

introduced a potential deadlock because it calls
ieee80211_scan_completed() with the priv->mutex
held, but mac80211 may call back into iwlwifi
which would lead to recursive locking. Move this
out from under the mutex.

Cc: stable@kernel.org
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>

9 years agophy/marvell: add 88ec048 support
Cyril Chemparathy [Wed, 4 Aug 2010 02:36:06 +0000]
phy/marvell: add 88ec048 support

Marvell 88ec048 is a derivative of its 88e1121r device.  From the programmer's
perspective, the one major difference is the addition of an additional control
bit in Page 2 Register 16 - used to control the padding of odd nibble
preambles.

This patch adds support for this new device, while inheriting as much code as
possible from the existing 88e1121r implementation.

Signed-off-by: Cyril Chemparathy <cyril@ti.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agoigb: Program MDICNFG register prior to PHY init
Alexander Duyck [Tue, 3 Aug 2010 11:50:08 +0000]
igb: Program MDICNFG register prior to PHY init

This patch addresses an issue seen on 82580 in which the MDICNFG
register will be reset during a single function reset and as a
result we will be unable to communicate with the PHY.  To correct
the issue, added a call to reset_mdicnfg just prior to the first
access of the MDICNFG register in sgnii_uses_mdio.

Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com>
Tested-by: Jeff Pieper <jeffrey.e.pieper@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agoe1000e: correct MAC-PHY interconnect register offset for 82579
Bruce Allan [Tue, 3 Aug 2010 11:48:35 +0000]
e1000e: correct MAC-PHY interconnect register offset for 82579

The MAC-PHY interconnect register set on ICH/PCH parts is accessed through
a peephole mechanism by writing an offset to a CSR register.  The offset
for the interconnect's half-duplex control register (which is used in a
jumbo frame workaround for 82579) is incorrect.

Signed-off-by: Bruce Allan <bruce.w.allan@intel.com>
Tested-by: Jeff Pieper <jeffrey.e.pieper@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agohso: Add new product ID
Filip Aben [Tue, 3 Aug 2010 05:36:41 +0000]
hso: Add new product ID

This patch adds a new product ID to the hso driver.

Signed-off-by: Filip Aben <f.aben@option.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agocan: Add driver for esd CAN-USB/2 device
Matthias Fuchs [Tue, 3 Aug 2010 02:55:23 +0000]
can: Add driver for esd CAN-USB/2 device

This patch adds a driver for esd's USB high speed
CAN interface. The driver supports devices with
multiple CAN interfaces.

Signed-off-by: Matthias Fuchs <matthias.fuchs@esd.eu>
Acked-by: Wolfgang Grandegger <wg@grandegger.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agol2tp: fix export of header file for userspace
James Chapman [Tue, 3 Aug 2010 07:42:17 +0000]
l2tp: fix export of header file for userspace

The header file l2tp.h should be exported to the installed include/linux/
tree for userspace programs.

This patch fixes compilation errors in L2TP userspace apps which want to
use the new L2TP support introduced in 2.6.35.

Signed-off-by: James Chapman <jchapman@katalix.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agocan-raw: Fix skb_orphan_try handling
Oliver Hartkopp [Tue, 3 Aug 2010 07:31:48 +0000]
can-raw: Fix skb_orphan_try handling

Commit fc6055a5ba31e2c14e36e8939f9bf2b6d586a7f5 (net: Introduce
skb_orphan_try()) allows an early orphan of the skb and takes care on
tx timestamping, which needs the sk-reference in the skb on driver level.
So does the can-raw socket, which has not been taken into account here.

The patch below adds a 'prevent_sk_orphan' bit in the skb tx shared info,
which fixes the problem discovered by Matthias Fuchs here:

      http://marc.info/?t=128030411900003&r=1&w=2

Even if it's not a primary tx timestamp topic it fits well into some skb
shared tx context. Or should be find a different place for the information to
protect the sk reference until it reaches the driver level?

Signed-off-by: Oliver Hartkopp <socketcan@hartkopp.net>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agoRevert "net: remove zap_completion_queue"
David S. Miller [Tue, 3 Aug 2010 07:24:04 +0000]
Revert "net: remove zap_completion_queue"

This reverts commit 15e83ed78864d0625e87a85f09b297c0919a4797.

As explained by Johannes Berg, the optimization made here is
invalid.  Or, at best, incomplete.

Not only destructor invocation, but conntract entry releasing
must be executed outside of hw IRQ context.

So just checking "skb->destructor" is insufficient.

Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agonet: cleanup inclusion
Changli Gao [Tue, 3 Aug 2010 05:45:49 +0000]
net: cleanup inclusion

Commit ab95bfe01f9872459c8678572ccadbf646badad0 replaces bridge and macvlan
hooks in __netif_receive_skb(), so dev.c doesn't need to include their headers.

Signed-off-by: Changli Gao <xiaosuo@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agoMerge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
David S. Miller [Tue, 3 Aug 2010 05:22:46 +0000]
Merge branch 'master' of /linux/kernel/git/davem/net-2.6

Conflicts:
drivers/net/e1000e/hw.h
net/bridge/br_device.c
net/bridge/br_input.c

9 years agophy/marvell: add 88e1121 interface mode support
Cyril Chemparathy [Mon, 2 Aug 2010 09:44:53 +0000]
phy/marvell: add 88e1121 interface mode support

This patch adds support for RGMII RX/TX delay configuration on marvell 88e1121
and derivatives.  With this patch, PHY_INTERFACE_MODE_RGMII_*ID modes are now
supported on these devices.

Signed-off-by: Cyril Chemparathy <cyril@ti.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agou32: negative offset fix
stephen hemminger [Mon, 2 Aug 2010 13:44:13 +0000]
u32: negative offset fix

It was possible to use a negative offset in a u32 match to reference
the ethernet header or other parts of the link layer header.
This fixes the regression caused by:

commit fbc2e7d9cf49e0bf89b9e91fd60a06851a855c5d
Author: Changli Gao <xiaosuo@gmail.com>
Date:   Wed Jun 2 07:32:42 2010 -0700

    cls_u32: use skb_header_pointer() to dereference data safely

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agonet: Fix a typo from "dev" to "ndev"
Henrique Camargo [Mon, 2 Aug 2010 17:10:42 +0000]
net: Fix a typo from "dev" to "ndev"

The typo was causing compilation errors since "dev" was not defined.

Signed-off-by: Henrique Camargo <henrique.camargo@ensitec.com.br>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agoigb: Use irq_synchronize per vector when using MSI-X
Emil Tantilov [Mon, 2 Aug 2010 14:40:52 +0000]
igb: Use irq_synchronize per vector when using MSI-X

Synchronize all IRQs when using MSI-X. Similar to ixgbe.
Issue was reported on e1000e, but the patch is also valid for igb.

CC: Jean Delvare <jdelvare@suse.de>
Signed-off-by: Emil Tantilov <emil.s.tantilov@intel.com>
Tested-by: Jeff Pieper <jeffrey.e.pieper@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agoixgbevf: fix null pointer dereference due to filter being set for VLAN 0
Alexander Duyck [Mon, 2 Aug 2010 14:59:04 +0000]
ixgbevf: fix null pointer dereference due to filter being set for VLAN 0

This change corrects an issue that resulted in a null pointer dereference
for the addition of VLAN 0 without any VLANs being registered.  Also this
code removes some unnecessary checks for defines and the unnecessary setting
of VLAN flags since that is now handled within the kernel via the
vlan_features.

Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com>
Tested-by: Emil Tantilov <emil.s.tantilov@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agoe1000e: Fix irq_synchronize in MSI-X case
Jeff Kirsher [Mon, 2 Aug 2010 14:27:23 +0000]
e1000e: Fix irq_synchronize in MSI-X case

Based on original patch/work from Jean Delvare <jdelvare@suse.de>
Synchronize all IRQs when in MSI-X IRQ mode.

Jean's original patch hard coded the sync with the 3 possible vectors,
this patch incorporates more flexibility for the future and aligns
with how igb stores the number of vectors into the adapter structure.

CC: Jean Delvare <jdelvare@suse.de>
Cc: Jesse Brandeburg <jesse.brandeburg@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Tested-by: Jeff Pieper <jeffrey.e.pieper@intel.com>
Acked-by: Bruce Allan <bruce.w.allan@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agoe1000e: register pm_qos request on hardware activation
Florian Mickler [Mon, 2 Aug 2010 14:27:00 +0000]
e1000e: register pm_qos request on hardware activation

The pm_qos_add_request call has to register the pm_qos request with the pm_qos
susbsystem before first use of the pm_qos request via
pm_qos_update_request.

As pm_qos changed to use plists there is no benefit in registering and
unregistering the pm_qos request on ifup/ifdown and thus we move the
registering into e1000_open and the unregistering in e1000_close.

This fixes the following warning:

[    1.786060] WARNING: at kernel/pm_qos_params.c:264
pm_qos_update_request+0x28/0x54()
[    1.786088] Hardware name: Latitude E6500
[    1.787045] pm_qos_update_request() called for unknown object
[    1.787966] Modules linked in:
[    1.788940] Pid: 1, comm: swapper Not tainted 2.6.35-rc5-mmotm0719 #1
[    1.790035] Call Trace:
[    1.791121]  [<ffffffff81037335>] warn_slowpath_common+0x80/0x98
[    1.792205]  [<ffffffff810373e1>] warn_slowpath_fmt+0x41/0x43
[    1.793279]  [<ffffffff81057c14>] pm_qos_update_request+0x28/0x54
[    1.794347]  [<ffffffff8134889e>] e1000_configure+0x421/0x459
[    1.795393]  [<ffffffff8134afbd>] e1000_open+0xbd/0x37c
[    1.796436]  [<ffffffff8105743a>] ? raw_notifier_call_chain+0xf/0x11
[    1.797491]  [<ffffffff8145f948>] __dev_open+0xae/0xe2
[    1.798547]  [<ffffffff8145f997>] dev_open+0x1b/0x49
[    1.799612]  [<ffffffff8146e36e>] netpoll_setup+0x84/0x259
[    1.800685]  [<ffffffff81b5037c>] init_netconsole+0xbc/0x21f
[    1.801744]  [<ffffffff81b5026c>] ? sir_wq_init+0x0/0x35
[    1.802793]  [<ffffffff81b502c0>] ? init_netconsole+0x0/0x21f
[    1.803845]  [<ffffffff810002ff>] do_one_initcall+0x7a/0x12f
[    1.804885]  [<ffffffff81b2ccae>] kernel_init+0x138/0x1c2
[    1.805915]  [<ffffffff81003554>] kernel_thread_helper+0x4/0x10
[    1.806937]  [<ffffffff81590e00>] ? restore_args+0x0/0x30
[    1.807955]  [<ffffffff81b2cb76>] ? kernel_init+0x0/0x1c2
[    1.808958]  [<ffffffff81003550>] ? kernel_thread_helper+0x0/0x10
[    1.809958] ---[ end trace 84b562a00a60539e ]---

Signed-off-by: Florian Mickler <florian@mickler.org>
Tested-by: Valdis Kletnieks <valdis.kletnieks@vt.edu>
Tested-by: Jeff Pieper <jeffrey.e.pieper@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agoip_fragment: fix subtracting PPPOE_SES_HLEN from mtu twice
Changli Gao [Sat, 31 Jul 2010 13:25:08 +0000]
ip_fragment: fix subtracting PPPOE_SES_HLEN from mtu twice

6c79bf0f2440fd250c8fce8d9b82fcf03d4e8350 subtracts PPPOE_SES_HLEN from mtu at
the front of ip_fragment(). So the later subtraction should be removed. The
MTU of 802.1q is also 1500, so MTU should not be changed.

Signed-off-by: Changli Gao <xiaosuo@gmail.com>
Signed-off-by: Bart De Schuymer <bdschuym@pandora.bo>
----
 net/ipv4/ip_output.c |    6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)
Signed-off-by: Bart De Schuymer <bdschuym@pandora.bo>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agonet: Add getsockopt support for TCP thin-streams
Josh Hunt [Fri, 30 Jul 2010 13:49:35 +0000]
net: Add getsockopt support for TCP thin-streams

Initial TCP thin-stream commit did not add getsockopt support for the new
socket options: TCP_THIN_LINEAR_TIMEOUTS and TCP_THIN_DUPACK. This adds support
for them.

Signed-off-by: Josh Hunt <johunt@akamai.com>
Tested-by: Andreas Petlund <apetlund@simula.no>
Acked-by: Andreas Petlund <apetlund@simula.no>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agocxgb4: update driver version
Dimitris Michailidis [Mon, 2 Aug 2010 13:19:24 +0000]
cxgb4: update driver version

Signed-off-by: Dimitris Michailidis <dm@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agocxgb4: add new PCI IDs
Dimitris Michailidis [Mon, 2 Aug 2010 13:19:23 +0000]
cxgb4: add new PCI IDs

Signed-off-by: Dimitris Michailidis <dm@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agocxgb4: fix wrong shift direction
Dimitris Michailidis [Mon, 2 Aug 2010 13:19:22 +0000]
cxgb4: fix wrong shift direction

Signed-off-by: Dimitris Michailidis <dm@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agocxgb4: support running the driver on PCI functions besides 0
Dimitris Michailidis [Mon, 2 Aug 2010 13:19:21 +0000]
cxgb4: support running the driver on PCI functions besides 0

Add support for running the driver on any PCI function.  Mostly this
entails replacing a constant 0 in a number of calls with the variable
function number.

Signed-off-by: Dimitris Michailidis <dm@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agocxgb4: advertise NETIF_F_TSO_ECN
Dimitris Michailidis [Mon, 2 Aug 2010 13:19:20 +0000]
cxgb4: advertise NETIF_F_TSO_ECN

The device supports TSO+ECN.

Signed-off-by: Dimitris Michailidis <dm@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agocxgb4: get on-chip queue info from FW and create a memory window for them
Dimitris Michailidis [Mon, 2 Aug 2010 13:19:19 +0000]
cxgb4: get on-chip queue info from FW and create a memory window for them

Get info about the availability of Tx on-chip queues from FW and if they
are supported set up a memory window for them.  iw_cxgb4 will be using them.
Move the existing window setup later in the init sequence, after we have
collected the new info.

Signed-off-by: Dimitris Michailidis <dm@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agocxgb4: fix TSO descriptors
Dimitris Michailidis [Mon, 2 Aug 2010 13:19:18 +0000]
cxgb4: fix TSO descriptors

Commit 1704d74894912b8ecc3e95cecd7bde336a0b1bf2 ("cxgb4vf: small changes
to message processing structures/macros") was incomplete and causes cxgb4
to write bad TSO descriptors.  Fix that up by reverting the offending part
of that commit and adjusting field accesses now that they are one level
deeper.

Signed-off-by: Dimitris Michailidis <dm@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agocxgb4: don't offload Rx checksums for IPv6 fragments
Dimitris Michailidis [Mon, 2 Aug 2010 13:19:17 +0000]
cxgb4: don't offload Rx checksums for IPv6 fragments

The checksum provided by the device doesn't include the L3 headers,
as IPv6 expects.

Signed-off-by: Dimitris Michailidis <dm@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agocxgb4: disable an interrupt that is neither used nor serviced
Dimitris Michailidis [Mon, 2 Aug 2010 13:19:16 +0000]
cxgb4: disable an interrupt that is neither used nor serviced

Signed-off-by: Dimitris Michailidis <dm@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agohp100: unmap memory on error path
Dan Carpenter [Mon, 2 Aug 2010 23:08:43 +0000]
hp100: unmap memory on error path

There was an error path where "mem_ptr_virt" didn't get unmapped.

Signed-off-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agoTulip: don't initialize SBE xT3E3 WAN ports.
Krzysztof Hałasa [Mon, 2 Aug 2010 23:03:29 +0000]
Tulip: don't initialize SBE xT3E3 WAN ports.

SBE 2T3E3 cards use DECchips 21143 but they need a different driver.
Don't even try to use a normal tulip driver with them.

Signed-off-by: Krzysztof Hałasa <khc@pm.waw.pl>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agodrivers/net/wan/farsync.c: Use standard pr_<level>
Joe Perches [Mon, 2 Aug 2010 23:01:35 +0000]
drivers/net/wan/farsync.c: Use standard pr_<level>

Remove locally defined equivalents

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agoMerge branch 'vhost-net-next' of git://git.kernel.org/pub/scm/linux/kernel/git/mst...
David S. Miller [Mon, 2 Aug 2010 22:54:07 +0000]
Merge branch 'vhost-net-next' of git://git./linux/kernel/git/mst/vhost

9 years agotg3: Update version to 3.113
Matt Carlson [Mon, 2 Aug 2010 11:26:08 +0000]
tg3: Update version to 3.113

This patch updates the tg3 version to 3.113.

Reviewed-by: Benjamin Li <benli@broadcom.com>
Reviewed-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: Matt Carlson <mcarlson@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agotg3: Migrate tg3_flags to phy_flags
Matt Carlson [Mon, 2 Aug 2010 11:26:07 +0000]
tg3: Migrate tg3_flags to phy_flags

This patch moves most of the phy related flag definitions over to the
phyflags member and changes the code accordingly.

Reviewed-by: Benjamin Li <benli@broadcom.com>
Reviewed-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: Matt Carlson <mcarlson@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agotg3: Create phy_flags and migrate phy_is_low_power
Matt Carlson [Mon, 2 Aug 2010 11:26:06 +0000]
tg3: Create phy_flags and migrate phy_is_low_power

This patch deletes the link_config.phy_is_low_power flag and creates a
new phy_flags device member to store all phy related settings.  All the
code is converted accordingly.

Reviewed-by: Benjamin Li <benli@broadcom.com>
Reviewed-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: Matt Carlson <mcarlson@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agotg3: Add phy-related preprocessor constants
Matt Carlson [Mon, 2 Aug 2010 11:26:05 +0000]
tg3: Add phy-related preprocessor constants

This patch replaces some instances of hardcoded phy register values with
preprocessor equivalents.

Reviewed-by: Benjamin Li <benli@broadcom.com>
Reviewed-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: Matt Carlson <mcarlson@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agotg3: Add error reporting to tg3_phydsp_write()
Matt Carlson [Mon, 2 Aug 2010 11:26:04 +0000]
tg3: Add error reporting to tg3_phydsp_write()

This patch adds error reporting to the tg3_phydsp_write() function and
converts a few more locations to use this function over the inlined
equivalent.

Reviewed-by: Benjamin Li <benli@broadcom.com>
Reviewed-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: Matt Carlson <mcarlson@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agotg3: Improve small packet performance
Matt Carlson [Mon, 2 Aug 2010 11:26:03 +0000]
tg3: Improve small packet performance

smp_mb() inside tg3_tx_avail() is used twice in the normal
tg3_start_xmit() path (see illustration below).  The full memory
barrier is only necessary during race conditions with tx completion.
We can speed up the tx path by replacing smp_mb() in tg3_tx_avail()
with a compiler barrier.  The compiler barrier is to force the
compiler to fetch the tx_prod and tx_cons from memory.

In the race condition between tg3_start_xmit() and tg3_tx(),
we have the following situation:

tg3_start_xmit()                       tg3_tx()
    if (!tg3_tx_avail())
        BUG();

    ...

    if (!tg3_tx_avail())
        netif_tx_stop_queue();         update_tx_index();
        smp_mb();                      smp_mb();
        if (tg3_tx_avail())            if (netif_tx_queue_stopped() &&
            netif_tx_wake_queue();         tg3_tx_avail())

With smp_mb() removed from tg3_tx_avail(), we need to add smp_mb() to
tg3_start_xmit() as shown above to properly order netif_tx_stop_queue()
and tg3_tx_avail() to check the ring index.  If it is not strictly
ordered, the tx queue can be stopped forever.

This improves performance by about 3% with 2 ports running
bi-directional 64-byte packets.

Reviewed-by: Benjamin Li <benli@broadcom.com>
Signed-off-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: Matt Carlson <mcarlson@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agotg3: Remove 5720, 5750, and 5750M
Matt Carlson [Mon, 2 Aug 2010 11:26:02 +0000]
tg3: Remove 5720, 5750, and 5750M

These devices were never released to the public.

Reviewed-by: Benjamin Li <benli@broadcom.com>
Reviewed-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: Matt Carlson <mcarlson@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agotg3: Detect APE firmware types
Matt Carlson [Mon, 2 Aug 2010 11:26:01 +0000]
tg3: Detect APE firmware types

This patch adds code to determine the APE firmware type and report this
along with the firmware version.

Reviewed-by: Benjamin Li <benli@broadcom.com>
Reviewed-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: Matt Carlson <mcarlson@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agotg3: Restrict ASPM workaround devlist
Matt Carlson [Mon, 2 Aug 2010 11:26:00 +0000]
tg3: Restrict ASPM workaround devlist

The ASPM workaround setting obtained from NVRAM only works with devices
older than 5717.  This patch enforces the restriction.

Reviewed-by: Benjamin Li <benli@broadcom.com>
Reviewed-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: Matt Carlson <mcarlson@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agotg3: Manage gphy power for CPMU-less devs only
Matt Carlson [Mon, 2 Aug 2010 11:25:59 +0000]
tg3: Manage gphy power for CPMU-less devs only

This patch changes the code to only manage the PCIe gphy power for
CPMU-less devices only.  The CPMU takes over management for newer
chips.

Reviewed-by: Benjamin Li <benli@broadcom.com>
Reviewed-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: Matt Carlson <mcarlson@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agotg3: Don't access phy test ctrl reg for 5717+
Matt Carlson [Mon, 2 Aug 2010 11:25:58 +0000]
tg3: Don't access phy test ctrl reg for 5717+

The phy test register location has been repurposed for 5717+ devices.
This patch changes the code to avoid this location for these devices.

Reviewed-by: Benjamin Li <benli@broadcom.com>
Reviewed-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: Matt Carlson <mcarlson@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agotg3: Create TG3_FLG3_5717_PLUS flag
Matt Carlson [Mon, 2 Aug 2010 11:25:57 +0000]
tg3: Create TG3_FLG3_5717_PLUS flag

This patch creates a TG3_FLG3_5717_PLUS flag to collectively describe
the set of changes in the ASIC that will apply to all future chip
revisions.

Signed-off-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: Matt Carlson <mcarlson@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agotg3: Disable TSS also during tg3_close()
Matt Carlson [Mon, 2 Aug 2010 11:25:56 +0000]
tg3: Disable TSS also during tg3_close()

The TSS flag needs to be turned off during tg3_close().  If the device
fails to allocate more than one MSI-X vector the next time the device is
brought up, transmits will fail.

Signed-off-by: Matt Carlson <mcarlson@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agotg3: Add 5784 ASIC rev to earlier PCIe MPS fix
Matt Carlson [Mon, 2 Aug 2010 11:25:55 +0000]
tg3: Add 5784 ASIC rev to earlier PCIe MPS fix

tg3 commit e7126997342560533317d8467e8516119ebcbd21 entitled
"tg3: Preserve PCIe MPS setting for new devs" attempted to ensure the
PCIe link negotiated Maximum Payload Size (MPS) setting was 128 bytes
for all devices that didn't support higher speeds.  The 5784 device was
mistakenly added to this list when it shouldn't have.  This patch
removes the 5784 ASIC rev devices from that list.

Reviewed-by: Benjamin Li <benli@broadcom.com>
Reviewed-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: Matt Carlson <mcarlson@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agoMerge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/kaber/nf-next-2.6
David S. Miller [Mon, 2 Aug 2010 22:07:58 +0000]
Merge branch 'master' of git://git./linux/kernel/git/kaber/nf-next-2.6

9 years agonetfilter: nf_conntrack_acct: use skb->len for accounting
Changli Gao [Mon, 2 Aug 2010 15:56:28 +0000]
netfilter: nf_conntrack_acct: use skb->len for accounting

use skb->len for accounting as xt_quota does. Since nf_conntrack works
at the network layer, skb_network_offset should always returns ZERO.

Signed-off-by: Changli Gao <xiaosuo@gmail.com>
Signed-off-by: Patrick McHardy <kaber@trash.net>

9 years agonetfilter: nf_nat: don't check if the tuple is unique when there isn't any other...
Changli Gao [Mon, 2 Aug 2010 15:35:49 +0000]
netfilter: nf_nat: don't check if the tuple is unique when there isn't any other choice

The tuple got from unique_tuple() doesn't need to be really unique, so the
check for the unique tuple isn't necessary, when there isn't any other
choice. Eliminating the unnecessary nf_nat_used_tuple() can save some CPU
cycles too.

Signed-off-by: Changli Gao <xiaosuo@gmail.com>
Signed-off-by: Patrick McHardy <kaber@trash.net>

9 years agonetfilter: nf_nat: make unique_tuple return void
Changli Gao [Mon, 2 Aug 2010 15:20:54 +0000]
netfilter: nf_nat: make unique_tuple return void

The only user of unique_tuple() get_unique_tuple() doesn't care about the
return value of unique_tuple(), so make unique_tuple() return void (nothing).

Signed-off-by: Changli Gao <xiaosuo@gmail.com>
Signed-off-by: Patrick McHardy <kaber@trash.net>

9 years agonetfilter: nf_nat: use local variable hdrlen
Changli Gao [Mon, 2 Aug 2010 15:15:30 +0000]
netfilter: nf_nat: use local variable hdrlen

Use local variable hdrlen instead of ip_hdrlen(skb).

Signed-off-by: Changli Gao <xiaosuo@gmail.com>
Signed-off-by: Patrick McHardy <kaber@trash.net>

9 years agoipvs: provide default ip_vs_conn_{in,out}_get_proto
Simon Horman [Mon, 2 Aug 2010 15:12:44 +0000]
ipvs: provide default ip_vs_conn_{in,out}_get_proto

This removes duplicate code by providing a default implementation
which is used by 3 of the 4 modules that provide these call.

Signed-off-by: Simon Horman <horms@verge.net.au>
Signed-off-by: Patrick McHardy <kaber@trash.net>

9 years agoipvs: remove EXPERIMENTAL tag
Simon Horman [Mon, 2 Aug 2010 15:08:11 +0000]
ipvs: remove EXPERIMENTAL tag

IPVS was merged into the kernel quite a long time ago and
has been seeing wide-spread production use for even longer.

It seems appropriate for it to be no longer tagged as EXPERIMENTAL

Signed-off-as: Simon Horman <horms@verge.net.au>
Signed-off-by: Patrick McHardy <kaber@trash.net>

9 years agonetfilter: nf_conntrack_extend: introduce __nf_ct_ext_exist()
Changli Gao [Mon, 2 Aug 2010 15:06:19 +0000]
netfilter: nf_conntrack_extend: introduce __nf_ct_ext_exist()

some users of nf_ct_ext_exist() know ct->ext isn't NULL. For these users, the
check for ct->ext isn't necessary, the function __nf_ct_ext_exist() can be
used instead.

the type of the return value of nf_ct_ext_exist() is changed to bool.

Signed-off-by: Changli Gao <xiaosuo@gmail.com>
Signed-off-by: Patrick McHardy <kaber@trash.net>

9 years agonetfilter: {ip,ip6,arp}_tables: dont block bottom half more than necessary
Eric Dumazet [Mon, 2 Aug 2010 14:49:01 +0000]
netfilter: {ip,ip6,arp}_tables: dont block bottom half more than necessary

We currently disable BH for the whole duration of get_counters()

On machines with a lot of cpus and large tables, this might be too long.

We can disable preemption during the whole function, and disable BH only
while fetching counters for the current cpu.

Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: Patrick McHardy <kaber@trash.net>

9 years agonet: ingress filter message limit
Stephen Hemminger [Sun, 1 Aug 2010 07:33:23 +0000]
net: ingress filter message limit

If user misconfigures ingress and causes a redirection loop, don't
overwhelm the log.  This is also a error case so make it unlikely.
Found by inspection, luckily not in real system.

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agonet/rose: Use GFP_ATOMIC
Julia Lawall [Fri, 30 Jul 2010 23:56:39 +0000]
net/rose: Use GFP_ATOMIC

The other calls to kmalloc in the same function use GFP_ATOMIC, and indeed
two locks are held within the body of the function.

The semantic match that finds this problem is as follows:
(http://coccinelle.lip6.fr/)

// <smpl>
@@ identifier f; @@

*f(...,GFP_ATOMIC,...)
... when != spin_unlock(...)
    when != read_unlock(...)
    when != write_unlock(...)
    when != read_unlock_irq(...)
    when != write_unlock_irq(...)
    when != read_unlock_irqrestore(...)
    when != write_unlock_irqrestore(...)
    when != spin_unlock_irq(...)
    when != spin_unlock_irqrestore(...)
*f(...,GFP_KERNEL,...)
// </smpl>

Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agoact_nat: the checksum of ICMP doesn't have pseudo header
Changli Gao [Thu, 29 Jul 2010 14:04:18 +0000]
act_nat: the checksum of ICMP doesn't have pseudo header

after updating the value of the ICMP payload, inet_proto_csum_replace4() should
be called with zero pseudohdr.

Signed-off-by: Changli Gao <xiaosuo@gmail.com>
Acked-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agoact_nat: fix wild pointer
Changli Gao [Thu, 29 Jul 2010 13:41:46 +0000]
act_nat: fix wild pointer

pskb_may_pull() may change skb pointers, so adjust icmph after pskb_may_pull().

Signed-off-by: Changli Gao <xiaosuo@gmail.com>
Acked-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agobe2net: fix to avoid sending get_stats request if one is already being processed.
Ajit Khaparde [Thu, 29 Jul 2010 06:18:58 +0000]
be2net: fix to avoid sending get_stats request if one is already being processed.

GET_STATS request uses the same memory region as the response.
If a new request for get stats is fired before the response for
the previous get_stats request is received, the response will
corrupt the new request, causing the f/w to misbehave.

Signed-off-by: Somnath K <somnathk@serverengines.com>
Signed-off-by: Ajit Khaparde <ajitk@serverengines.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agobe2net: change to show correct physical link status
Ajit Khaparde [Thu, 29 Jul 2010 06:17:17 +0000]
be2net: change to show correct physical link status

link status is wrongly displayed under certain circumstances.
This change fixes it.

Signed-off-by: Somnath K <somnathk@serverengines.com>
Signed-off-by: Ajit Khaparde <ajitk@serverengines.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agobe2net: add code to dump registers for debug
Ajit Khaparde [Thu, 29 Jul 2010 06:16:33 +0000]
be2net: add code to dump registers for debug

when the BE device becomes unresponsive, dump the registers to help debugging

Signed-off-by: Somnath K <somnathk@serverengines.com>
Signed-off-by: Ajit Khaparde <ajitk@serverengines.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agobe2net: fix to correctly know if driver needs to run for a VF or a PF
Ajit Khaparde [Thu, 29 Jul 2010 06:15:32 +0000]
be2net: fix to correctly know if driver needs to run for a VF or a PF

Move be_check_sriov_fn_type to appropriate place to correctly determine
if the be2net driver needs to work as a VF driver or a PF driver.

Signed-off-by: Ajit Khaparde <ajitk@serverengines.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agosky2: Code style fixes
Mike McCormack [Thu, 29 Jul 2010 03:34:52 +0000]
sky2: Code style fixes

Fix selected style problems reported by checkpatch.

Signed-off-by: Mike McCormack <mikem@ring3k.org>
Acked-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agoTI DaVinci EMAC: Fix incorrect reference to EMAC_CTRL registers.
Sriram [Thu, 29 Jul 2010 02:34:00 +0000]
TI DaVinci EMAC: Fix incorrect reference to EMAC_CTRL registers.

The EMAC modules control registers vary as per the version of the
EMAC module. EMAC_CTRL_EWCTL,EMAC_CTRL_EWINTTCNT are available
only on EMAC_VERSION_1. The emac_dump_regs() function accesses
these indiscriminately. This patch fixes the issue.

Signed-off-by: Sriramakrishnan <srk@ti.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agoTI DaVinci EMAC: Fix asymmetric handling of packets in NAPI Poll function.
Sriram [Thu, 29 Jul 2010 02:33:59 +0000]
TI DaVinci EMAC: Fix asymmetric handling of packets in NAPI Poll function.

The current implementation of NAPI poll function in the driver does not service
Rx packets, error condition even if a single Tx packet gets serviced in
the napi poll call. This behavior severely affects performance for specific use
cases. This patch modifies the poll function implementation to service tx/rx
packets in an identical manner.

Signed-off-by: Sriramakrishnan <srk@ti.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agoTI DaVinci EMAC : Implement interrupt pacing functionality.
Sriram [Thu, 29 Jul 2010 02:33:58 +0000]
TI DaVinci EMAC : Implement interrupt pacing functionality.

DaVinci EMAC module includes an interrupt pacing block that can
be programmed to throttle the rate at which interrupts are
generated. This patch implements interrupt pacing logic that can
be controlled through the ethtool interface(only rx_coalesce_usecs
param is honored)

Signed-off-by: Sriramakrishnan <srk@ti.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agobridge: Allow multicast snooping to be disabled before ifup
Herbert Xu [Thu, 29 Jul 2010 00:45:30 +0000]
bridge: Allow multicast snooping to be disabled before ifup

Currently you cannot disable multicast snooping while a device is
down.  There is no good reason for this restriction and this patch
removes it.

Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agobridge: Fix skb leak when multicast parsing fails on TX
Herbert Xu [Thu, 29 Jul 2010 01:12:31 +0000]
bridge: Fix skb leak when multicast parsing fails on TX

On the bridge TX path we're leaking an skb when br_multicast_rcv
returns an error.

Reported-by: David Lamparter <equinox@diac24.net>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agodnet: fixup error handling in initialization
Dan Carpenter [Wed, 28 Jul 2010 22:27:29 +0000]
dnet: fixup error handling in initialization

There were two problems here.  We returned success if dnet_mii_init()
failed and there was a release_mem_region() missing.

Signed-off-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agobonding: prevent sysfs from allowing arp monitoring with alb/tlb
Andy Gospodarek [Wed, 28 Jul 2010 15:13:56 +0000]
bonding: prevent sysfs from allowing arp monitoring with alb/tlb

When using module options arp monitoring and balance-alb/balance-tlb
are mutually exclusive options.  Anytime balance-alb/balance-tlb are
enabled mii monitoring is forced to 100ms if not set.  When configuring
via sysfs no checking is currently done.

Handling these cases with sysfs has to be done a bit differently because
we do not have all configuration information available at once.  This
patch will not allow a mode change to balance-alb/balance-tlb if
arp_interval is already non-zero.  It will also not allow the user to
set a non-zero arp_interval value if the mode is already set to
balance-alb/balance-tlb.  They are still mutually exclusive on a
first-come, first serve basis.

Tested with initscripts on Fedora and manual setting via sysfs.

Signed-off-by: Andy Gospodarek <gospo@redhat.com>
Signed-off-by: Jay Vosburgh <fubar@us.ibm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agodrivers/net/vxge/vxge-main.c: Use pr_<level> and netdev_<level>
Joe Perches [Tue, 27 Jul 2010 11:47:03 +0000]
drivers/net/vxge/vxge-main.c: Use pr_<level> and netdev_<level>

Use pr_fmt, pr_<level> and netdev_<level> where appropriate.

Signed-off-by: Joe Perches <joe@perches.com>
Acked-by: Jon Mason <jon.mason@exar.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agotcp: cookie transactions setsockopt memory leak
Dmitry Popov [Thu, 29 Jul 2010 01:59:36 +0000]
tcp: cookie transactions setsockopt memory leak

There is a bug in do_tcp_setsockopt(net/ipv4/tcp.c),
TCP_COOKIE_TRANSACTIONS case.
In some cases (when tp->cookie_values == NULL) new tcp_cookie_values
structure can be allocated (at cvp), but not bound to
tp->cookie_values. So a memory leak occurs.

Signed-off-by: Dmitry Popov <dp@highloadlab.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agonet: ks8842 depends on DMA_ENGINE
Randy Dunlap [Thu, 29 Jul 2010 07:14:27 +0000]
net: ks8842 depends on DMA_ENGINE

ks8842 uses dma channel functions, so it should depend on DMA_ENGINE.

ERROR: "__dma_request_channel" [drivers/net/ks8842.ko] undefined!
ERROR: "dma_release_channel" [drivers/net/ks8842.ko] undefined!

Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agoucc_geth: fix UCC device number in debug message
Sergey Matyukevich [Wed, 28 Jul 2010 08:05:21 +0000]
ucc_geth: fix UCC device number in debug message

This patch contains a fix for UCC device number in verbose debug message.

Signed-off-by: Sergey Matyukevich <geomatsi@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agotun: keep link (carrier) state up to date
Nolan Leake [Tue, 27 Jul 2010 13:53:43 +0000]
tun: keep link (carrier) state up to date

Currently, only ethtool can get accurate link state of a tap device.
With this patch, IFF_RUNNING and IF_OPER_UP/DOWN are kept up to date as
well.

Signed-off-by: Nolan Leake <nolan@cumulusnetworks.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

9 years agoMerge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wirel...
John W. Linville [Thu, 29 Jul 2010 18:47:07 +0000]
Merge branch 'master' of git://git./linux/kernel/git/linville/wireless-next-2.6 into for-davem

9 years agocfg80211: fix dev <-> wiphy typo
Christian Lamparter [Wed, 28 Jul 2010 23:28:46 +0000]
cfg80211: fix dev <-> wiphy typo

Cc: Joe Perches <joe@perches.com>
Signed-off-by: Christian Lamparter <chunkeey@googlemail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>

9 years agomac80211: allow drivers to request DTIM period
Johannes Berg [Thu, 29 Jul 2010 14:08:55 +0000]
mac80211: allow drivers to request DTIM period

Some features require knowing the DTIM period
before associating. This implements the ability
to wait for a beacon in mac80211 before assoc
to provide this value. It is optional since
most likely not all drivers will need this.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>

9 years agoiwlwifi: fix scan abort
Stanislaw Gruszka [Thu, 29 Jul 2010 09:37:41 +0000]
iwlwifi: fix scan abort

Fix possible double priv->mutex lock introduced by commit
a69b03e941abae00380fc6bc1877fb797a1b31e6
"iwlwifi: cancel scan watchdog in iwl_bg_abort_scan" .
We can not call cancel_delayed_work_sync(&priv->scan_check) with
priv->mutex locked because workqueue function iwl_bg_scan_check()
take that lock internally.

We do not need to synchronize when canceling priv->scan_check work.
We can avoid races (sending double abort command or send no
command at all) using STATUS_SCAN_ABORT bit. Moreover
current iwl_bg_scan_check() code seems to be broken, as
we should not send abort commands when currently aborting.

Signed-off-by: Stanislaw Gruszka <sgruszka@redhat.com>
CC: stable@kernel.org
Signed-off-by: John W. Linville <linville@tuxdriver.com>

9 years agomwl8k: change maintenance status
Lennert Buytenhek [Wed, 28 Jul 2010 23:47:04 +0000]
mwl8k: change maintenance status

The 8366 AP support in particular is still rather incomplete, but
this is unlikely to be addressed any time soon.

Signed-off-by: Lennert Buytenhek <buytenh@wantstofly.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>

9 years agowl1271: update hw/fw version info in wiphy struct
John W. Linville [Wed, 28 Jul 2010 21:09:41 +0000]
wl1271: update hw/fw version info in wiphy struct

This makes the information available through ethtool...

Signed-off-by: John W. Linville <linville@tuxdriver.com>
Acked-by: Juuso Oikarinen <juuso.oikarinen@nokia.com>

9 years agowl1251: update hw/fw version info in wiphy struct
John W. Linville [Wed, 28 Jul 2010 20:59:41 +0000]
wl1251: update hw/fw version info in wiphy struct

This makes the information available through ethtool...

Signed-off-by: John W. Linville <linville@tuxdriver.com>
Acked-by: Kalle Valo <kvalo@adurom.com>

9 years agowl1271: add get_survey callback in order to get channel noise
John W. Linville [Wed, 28 Jul 2010 20:41:06 +0000]
wl1271: add get_survey callback in order to get channel noise

Signed-off-by: John W. Linville <linville@tuxdriver.com>
Acked-by: Juuso Oikarinen <juuso.oikarinen@nokia.com>

9 years agolibertas_tf: add get_survey callback in order to get channel noise
John W. Linville [Wed, 28 Jul 2010 19:03:42 +0000]
libertas_tf: add get_survey callback in order to get channel noise

Signed-off-by: John W. Linville <linville@tuxdriver.com>

9 years agowl1251: add get_survey callback in order to get channel noise
John W. Linville [Wed, 28 Jul 2010 19:23:30 +0000]
wl1251: add get_survey callback in order to get channel noise

Signed-off-by: John W. Linville <linville@tuxdriver.com>
Acked-by: Kalle Valo <kvalo@adurom.com>

9 years agoar9170: add get_survey callback in order to get channel noise
John W. Linville [Wed, 28 Jul 2010 18:47:49 +0000]
ar9170: add get_survey callback in order to get channel noise

Signed-off-by: John W. Linville <linville@tuxdriver.com>
Acked-by: Christian Lamparter <chunkeey@googlemail.com>

9 years agomwl8k: add get_survey callback in order to get channel noise
John W. Linville [Wed, 28 Jul 2010 18:04:24 +0000]
mwl8k: add get_survey callback in order to get channel noise

Signed-off-by: John W. Linville <linville@tuxdriver.com>
Acked-by: Lennert Buytenhek <buytenh@wantstofly.org>