dect
/
linux-2.6
Archived
13
0
Fork 0
Commit Graph

26965 Commits

Author SHA1 Message Date
John Fastabend aba70d5e6c ixgbe: DCB 82598 devices, tx_idx and rx_idx swapped
The tx_idx and rx_idx values are swapped on 82598 devices
with DCB enabled.

Signed-off-by: John Fastabend <john.r.fastabend@intel.com>
Tested-by: Ross Brattain <ross.b.brattain@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2011-06-21 01:20:40 -07:00
John Fastabend e901acd6fa ixgbe: DCB use existing TX and RX queues
The number of TX and RX queues allocated depends on the device
type, the current features set, online CPUs, and various
compile flags.

To enable DCB with multiple queues and allow it to coexist with
all the features currently implemented it has to setup a valid
queue count. This is done at init time using the FDIR and RSS
max queue counts and allowing each TC to allocate a queue per
CPU.

DCB will now use available queues up to (8 x TCs) this is somewhat
arbitrary cap but allows DCB to use up to 64 queues. Its easy to
increase this later if that is needed.

This is prep work to enable Flow Director with DCB. After this
DCB can easily coexist with existing features and no longer
needs its own DCB feature ring.

Signed-off-by: John Fastabend <john.r.fastabend@intel.com>
Tested-by: Ross Brattain <ross.b.brattain@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2011-06-21 01:20:13 -07:00
John Fastabend 8b1c0b24d9 ixgbe: configure minimal packet buffers to support TC
ixgbe devices support different numbers of packet buffers either
8 or 4. Here we only allocate the minimal number of packet
buffers required to implement the net_devices number of traffic
classes.

Fewer traffic classes allows for larger packet buffers in
hardware. Also more Tx/Rx queues can be given to each
traffic class.

This patch is mostly about propagating the number of traffic
classes through the init path. Specifically this adds the 4TC
cases to the MRQC and MTQC setup routines. Also ixgbe_setup_tc()
was sanitized to handle other traffic class value.

Finally changing the number of packet buffers in the hardware
requires the device to reinit. So this moves the reinit work
from DCB into the main ixgbe_setup_tc() routine to consolidate
the reset code. Now dcbnl_xxx ops call ixgbe_setup_tc() to
configure packet buffers if needed.

Signed-off-by: John Fastabend <john.r.fastabend@intel.com>
Tested-by: Ross Brattain <ross.b.brattain@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2011-06-21 01:19:54 -07:00
John Fastabend 72a32f1f3f ixgbe: consolidate MRQC and MTQC handling
The MRQC and MTQC registers are configured in the main
setup path but are also reconfigured in the DCB setup
path. The DCB path fixes the DCB configuration by configuring
the SECTXMINIFG gap which is required for DCB pause
to operate correctly.

This patch reduces the duplicate code and does all setup
in ixgbe_setup_mtqc() and ixgbe_setup_mrqc().

Additionally, this removes the IXGBE_QDE. This write never
set the WRITE bit in the register so the write was not
actually doing anything. Also this was to clear the register
but, it is never set and defaults to zero. If this is
needed for SRIOV it should be added correctly in a follow
up patch. But it's never been working so removing it here
should be OK.

Signed-off-by: John Fastabend <john.r.fastabend@intel.com>
Tested-by: Ross Brattain <ross.b.brattain@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2011-06-21 01:19:27 -07:00
John Fastabend 80605c6513 ixgbe: consolidate packet buffer allocation
Consolidate packet buffer allocation currently being
done in the DCB path and main path. This allows the
feature set and packet buffer requirements to be done
once.

This is prep work to allow DCB to coexist with other
features namely, flow director.

CC: Alexander Duyck <alexander.h.duyck@intel.com>
Signed-off-by: John Fastabend <john.r.fastabend@intel.com>
Tested-by: Ross Brattain <ross.b.brattain@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2011-06-21 01:18:55 -07:00
John Fastabend 1fcd86b511 ixgbe: dcbnl reduce duplicated code and indentation
Replace duplicated code in if/else branches with single
check and ixgbe_init_interrupt_scheme().

Signed-off-by: John Fastabend <john.r.fastabend@intel.com>
Tested-by: Ross Brattain <ross.b.brattain@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2011-06-21 01:18:47 -07:00
Stephen Hemminger c12db7695e ixgbevf: remove unnecessary ampersands
Use standard format for net_device_ops (without &)

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Acked-by: Greg Rose <Gregory.v.rose@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2011-06-21 01:18:12 -07:00
Greg Rose f416dfc0e0 ixgbevf: Fix bungled declaration of ixgbevf_mbx_ops
In two places storage for mbx_ops is misidentified as type
ixgbe_mac_operations.

Reported-by: Andi Kleen <ak@linux.intel.com>
Signed-off-by: Greg Rose <gregory.v.rose@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2011-06-21 01:15:34 -07:00
Michał Mirosław ac52caa31e igb: convert to ndo_fix_features
Private rx_csum flags are now duplicate of netdev->features & NETIF_F_RXCSUM.
Removing this needs deeper surgery.

Things noticed:
 - HW VLAN acceleration probably can be toggled, but it's left as is
 - the resets on RX csum offload change can probably be avoided
 - there is A LOT of copy-and-pasted code here

Signed-off-by: Michał Mirosław <mirq-linux@rere.qmqm.pl>
Tested-by:  Aaron Brown <aaron.f.brown@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2011-06-21 01:15:07 -07:00
Michał Mirosław e97d3207c5 e1000: convert to ndo_fix_features
Private rx_csum flags are now duplicate of netdev->features & NETIF_F_RXCSUM.
Removing this needs deeper surgery.

Things noticed:
 - RX csum disabled by default
 - HW VLAN acceleration probably can be toggled, but it's left as is
 - the resets on RX csum offload change can probably be avoided
 - there is A LOT of copy-and-pasted code here

Signed-off-by: Michał Mirosław <mirq-linux@rere.qmqm.pl>
Tested-by:  Aaron Brown <aaron.f.brown@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2011-06-21 01:14:33 -07:00
David S. Miller 9f6ec8d697 Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
Conflicts:
	drivers/net/wireless/iwlwifi/iwl-agn-rxon.c
	drivers/net/wireless/rtlwifi/pci.c
	net/netfilter/ipvs/ip_vs_core.c
2011-06-20 22:29:08 -07:00
Richard Cochran 384420409d pxa168_eth: fix race in transmit path.
Because the socket buffer is freed in the completion interrupt, it is not
safe to access it after submitting it to the hardware.

Cc: stable@kernel.org
Cc: Sachin Sanap <ssanap@marvell.com>
Cc: Zhangfei Gao <zgao6@marvell.com>
Cc: Philip Rakity <prakity@marvell.com>
Signed-off-by: Richard Cochran <richard.cochran@omicron.at>
Acked-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2011-06-20 14:02:07 -07:00
Sebastian Poehn 4aa3a71555 gianfar v5: implement nfc
This patch adds all missing functionalities for nfc except GRXFH. There is so much code because hardware has not a TCAM.
Further hardware rule space is very limited. So I had to extensively use
optimization features. Both reasons lead to the necessity to hold all
online flows in a linked-list.

Change-log:
# Some suggestions by Joe Perches applied (thanks!)
# Shorted some logs
# Use memcmp() for comparing

Signed-off-by: Sebastian Poehn <sebastian.poehn@belden.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2011-06-20 13:57:59 -07:00
Richard Cochran d13d6bffb4 ucc_geth: enable transmit time stamping.
This patch enables software (and phy device) transmit time stamping.
Compile tested only.

Cc: Shlomi Gridish <gridish@freescale.com>
Cc: Li Yang <leoli@freescale.com>
Signed-off-by: Richard Cochran <richard.cochran@omicron.at>
Signed-off-by: David S. Miller <davem@davemloft.net>
2011-06-20 13:56:55 -07:00
Richard Cochran 1f6e44a6dc pxa168_eth: enable transmit time stamping.
This patch enables software (and phy device) transmit time stamping
Compile tested only.

Cc: Sachin Sanap <ssanap@marvell.com>
Cc: Zhangfei Gao <zgao6@marvell.com>
Cc: Philip Rakity <prakity@marvell.com>
Cc: Mark Brown <markb@marvell.com>
Signed-off-by: Richard Cochran <richard.cochran@omicron.at>
Signed-off-by: David S. Miller <davem@davemloft.net>
2011-06-20 13:56:55 -07:00
Richard Cochran 8c0069ae3a smsc911x: enable transmit time stamping.
This patch enables software (and phy device) transmit time stamping.
Compile tested only.

Cc: Steve Glendinning <steve.glendinning@smsc.com>
Signed-off-by: Richard Cochran <richard.cochran@omicron.at>
Signed-off-by: David S. Miller <davem@davemloft.net>
2011-06-20 13:56:54 -07:00
Richard Cochran e309721159 fs_enet: enable transmit time stamping.
This patch enables software (and phy device) transmit time stamping.
Compile tested only.

Cc: Pantelis Antoniou <pantelis.antoniou@gmail.com>
Cc: Vitaly Bordug <vbordug@ru.mvista.com>
Signed-off-by: Richard Cochran <richard.cochran@omicron.at>
Signed-off-by: David S. Miller <davem@davemloft.net>
2011-06-20 13:56:54 -07:00
Richard Cochran e072092fc7 macb: enable transmit time stamping.
This patch enables software (and phy device) transmit time stamping
Compile tested only.

Cc: Nicolas Ferre <nicolas.ferre@atmel.com>
Signed-off-by: Richard Cochran <richard.cochran@omicron.at>
Signed-off-by: David S. Miller <davem@davemloft.net>
2011-06-20 13:56:54 -07:00
Richard Cochran d6cf07327e fec_mpc52xx: enable transmit and receive time stamping.
This patch enables software (and phy device) time stamping. Software
time stamping using the SO_TIMESTAMPING API was tested and found to be
working on the LITE5200B board.

Cc: Grant Likely <grant.likely@secretlab.ca>
Signed-off-by: Richard Cochran <richard.cochran@omicron.at>
Signed-off-by: David S. Miller <davem@davemloft.net>
2011-06-20 13:56:54 -07:00
Richard Cochran 93e0ed158c ll_temac: enable transmit and receive time stamping.
This patch enables software (and phy device) time stamping. Since this MAC
is based on phylib, adding the hooks makes hardware time stamping in the
phy possible.

Compile tested only.

Cc: Grant Likely <grant.likely@secretlab.ca>
Signed-off-by: Richard Cochran <richard.cochran@omicron.at>
Signed-off-by: David S. Miller <davem@davemloft.net>
2011-06-20 13:56:54 -07:00
Richard Cochran 570773c580 emaclite: enable transmit and receive time stamping.
This patch enables software (and phy device) time stamping. Since this
MAC uses phylib, adding the hooks make hardware time stamping in the phy
possible.

Compile tested only.

Cc: John Linn <john.linn@xilinx.com>
Signed-off-by: Richard Cochran <richard.cochran@omicron.at>
Signed-off-by: David S. Miller <davem@davemloft.net>
2011-06-20 13:56:53 -07:00
Richard Cochran d76b7e2faa lib8390: enable transmit and receive time stamping.
This patch enables software (and phy device) time stamping. This file is
included by drivers/net/ax88796.c, which is based on phylib. So, this
patch makes hardware time stamping in the PHY possible.

Compile tested only.

Signed-off-by: Richard Cochran <richard.cochran@omicron.at>
Signed-off-by: David S. Miller <davem@davemloft.net>
2011-06-20 13:56:53 -07:00
Eric Dumazet c82b9d7fe7 netxen: fix race in skb->len access
As soon as skb is given to hardware, TX completion can free skb under
us.
Therefore, we should update dev stats before kicking the device.

Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
CC: Amit Kumar Salecha <amit.salecha@qlogic.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2011-06-20 13:04:12 -07:00
Eric Dumazet 306ff6eb8e myricom: remove stats_lock
stats_lock is non useless, lets remove it.

Also, ndo_get_stats64() doesnt have to clear the stats, caller takes
care of this.

Note: folding 32bit fields in 64bit one is problematic when one of 32bit
values wraps : SNMP reader will see a ~2^32 back change in a 64bit
value. A future patch should fix this.

Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
CC: Stephen Hemminger <shemminger@vyatta.com>
CC: Andrew Gallatin <gallatin@myri.com>
CC: Brice Goglin <brice@myri.com>
Acked-by: Jon Mason <mason@myri.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2011-06-20 13:02:36 -07:00
Jon Mason 1b9c4134c1 myri_sbus: remove driver
Remove the myri_sbus driver. Why?
* There is no possibility of ethernet mode on this adapter, so it's
  Myrinet only.
* It won't inter-op with modern versions of Myrinet, and thus can only
  work with legacy adapters.
* There are no in-kernel Linux drivers for the PCI version of this
  adapter, so it only can work on ~15 year old Sun hardware.

It's long in the tooth, let's take it to the knackers.

Signed-off-by: Jon Mason <mason@myri.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2011-06-20 12:51:22 -07:00
Mike McCormack e10542c447 rtlwifi: rtl8192{c,ce,cu,se}: Remove comparisons of booleans with true
These are a potential source of confusion, as most C code treats all
non-zero values as true.

Signed-off-by: Mike McCormack <mikem@ring3k.org>
Acked-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-06-20 15:47:43 -04:00
Mike McCormack 4b9d8d67b4 rtlwifi: rtl8192cu: Remove unused parameter
rtl_ps_set_rf_state's protect_or_not parameter is not set to
true anywhere, except for commented out code.

It enables some legacy locking code, which is no longer used,
so delete the parameter and the old locking code.

Signed-off-by: Mike McCormack <mikem@ring3k.org>
Acked-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-06-20 15:47:43 -04:00
Mike McCormack 9c05044037 rtlwifi: Fix typo in variable name
offchan_deley should be offchan_delay

Signed-off-by: Mike McCormack <mikem@ring3k.org>
Acked-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-06-20 15:47:42 -04:00
Pavel Roskin 536e5189ff ath5k: add missing ieee80211_free_hw() on unload in AHB code
Signed-off-by: Pavel Roskin <proski@gnu.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-06-20 15:34:19 -04:00
John W. Linville 0e8d1602b2 ath5k: free sc->ah in ath5k_deinit_softc
Nothing else is freeing it, and this mirrors the error handling path
already in ath5k_init_softc.

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

Signed-off-by: John W. Linville <linville@tuxdriver.com>
Reported-by: Tsyvarev Andrey <tsyvarev@ispras.ru>
2011-06-20 15:34:19 -04:00
Mohammed Shafi Shajakhan 0e44d48cbb ath9k_hw: make sure PAPRD training is properly done
checking the status of PAPRD_AGC2_POWER(Log(ADC_power) measured after
last gain-change in dB) field suggests whether the PAPRD is completely/properly
done. This is an additional check apart from polling for PAPRD done bit being set.
        Susinder suggests that the ideal power range value should be
0xf0 to 0xfe. With AR9382 we do have the values in this range. to have a
common check for all platforms we take agc2_power should be atleast greater
than 0xe0

Cc: susinder@qca.qualcomm.com
Cc: senthilb@qca.qualcomm.com
Cc: kmuthusa@qca.qualcomm.com
Signed-off-by: Mohammed Shafi Shajakhan <mohammed@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-06-20 15:34:18 -04:00
Mohammed Shafi Shajakhan 81dc67601a ath9k: Fix a corner case failure in sending PAPRD frames in HT40
when the AP is configured with HT40/2.4GHz and when PAPRD is enabled in station
we have PAPRD training frames never sent out because of the following
failure "PAPRD target power delta out of range". This consistently happens
in channel 10,11 in Over The Air testing and rarely in channel 6 under wired
setup.
        the reason behind this issue is all the HT40 rates target power
are 0 when we operate in channel 10/11 at 2.4GHz

Signed-off-by: Mohammed Shafi Shajakhan <mshajakhan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-06-20 15:34:18 -04:00
John W. Linville 6392cb387c Merge branch 'wireless-next-2.6' of git://git.kernel.org/pub/scm/linux/kernel/git/iwlwifi/iwlwifi-2.6 2011-06-20 15:28:44 -04:00
Kalle Valo 0521ecf335 rtlwifi: include mac80211.h from core.h
core.h references ieee80211_ops but doesn't include mac80211.h, which issues
a warning once mac80211-compat.h is taken into use.

Acked-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Kalle Valo <kvalo@adurom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-06-20 15:16:32 -04:00
Kalle Valo 9a0669681c zd1211rw: include mac80211.h from zd_chip.h
zd_chip.h contains one function with a pointer to ieee80211_hw but doesn't
include mac80211.h. As a temporary solution include mac80211.h to avoid
a warning.

Signed-off-by: Kalle Valo <kvalo@adurom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-06-20 15:16:32 -04:00
Kalle Valo 47751b0fbf iwlwifi: fix stop/wake queue hacks
The hacks break once mac80211-compat.h is taken into use. Fix it by adding
an ifdef check.

Signed-off-by: Kalle Valo <kvalo@adurom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-06-20 15:16:32 -04:00
Kalle Valo 2055403ded iwlegacy: fix stop/wake queue hacks
The hacks break once mac80211-compat.h is taken into use. Fix it by adding
an ifdef check.

Signed-off-by: Kalle Valo <kvalo@adurom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-06-20 15:16:31 -04:00
Eric Dumazet cf05c700cf veth: fix 64bit stats on 32bit arches
Using 64bit stats on 32bit arches must use a synchronization or readers
can get transient values.

Fixes bug introduced in commit 6311cc44a2 (veth: convert to 64 bit
statistics)

Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2011-06-19 22:48:34 -07:00
Richard Cochran 5bf0c19134 davinci_emac: fix race in transmit time stamping.
Signed-off-by: Richard Cochran <richard.cochran@omicron.at>
Signed-off-by: David S. Miller <davem@davemloft.net>
2011-06-19 16:35:31 -07:00
Richard Cochran 6241207253 smsc9420: fix race in transmit time stamping.
Signed-off-by: Richard Cochran <richard.cochran@omicron.at>
Signed-off-by: David S. Miller <davem@davemloft.net>
2011-06-19 16:35:31 -07:00
Richard Cochran 52f64faeb0 stmmac: fix race in transmit time stamping.
Signed-off-by: Richard Cochran <richard.cochran@omicron.at>
Signed-off-by: David S. Miller <davem@davemloft.net>
2011-06-19 16:35:30 -07:00
Richard Cochran 2aa8f4c9d0 r6040: fix race in transmit time stamping.
Signed-off-by: Richard Cochran <richard.cochran@omicron.at>
Signed-off-by: David S. Miller <davem@davemloft.net>
2011-06-19 16:35:30 -07:00
Richard Cochran d515b450bf tg3: fix race in transmit time stamping.
Signed-off-by: Richard Cochran <richard.cochran@omicron.at>
Signed-off-by: David S. Miller <davem@davemloft.net>
2011-06-19 16:35:30 -07:00
Richard Cochran a0087a3619 fec: fix race in transmit time stamping.
Signed-off-by: Richard Cochran <richard.cochran@omicron.at>
Signed-off-by: David S. Miller <davem@davemloft.net>
2011-06-19 16:35:30 -07:00
Eric Dumazet 658924dc9a hp100: fix an skb->len race
As soon as skb is given to hardware and spinlock released, TX completion
can free skb under us. Therefore, we should update netdev stats before
spinlock release.

Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2011-06-19 16:28:02 -07:00
David S. Miller 00ce2d5614 Merge branch 'davem.r8169' of git://git.kernel.org/pub/scm/linux/kernel/git/romieu/netdev-2.6 2011-06-19 16:26:46 -07:00
WANG Cong cefa9993f1 netpoll: copy dev name of slaves to struct netpoll
Otherwise we will not see the name of the slave dev in error
message:

[  388.469446] (null):  doesn't support polling, aborting.

Signed-off-by: WANG Cong <amwang@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2011-06-19 16:13:01 -07:00
Wey-Yi Guy 89434421d8 iwlagn: remove incorrect define
Remove unused and incorrect EEPROM define

Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
2011-06-18 08:24:07 -07:00
Wey-Yi Guy 86cb3b4e08 iwlagn: merge duplicate code into single function
Same operation needed by multiple devices, move to single function.

Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
2011-06-18 08:23:56 -07:00
Wey-Yi Guy 916b337310 iwlagn: code alignment
Code alignment, no functional changes.

Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
2011-06-18 08:23:47 -07:00
Wey-Yi Guy e1910cb319 iwlagn: add offset define for subsystem id
Add offset define for subsystem id in EEPROM

Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
2011-06-18 08:23:41 -07:00
Wey-Yi Guy f753816891 iwlagn: Add power_level module parameter
Add power_level module parameter to set the default power save level.
Power save level has range from 1 - 5, default power save level is 1.

Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
2011-06-18 08:23:30 -07:00
Wey-Yi Guy 0172b02926 iwlagn: add power_save module parameter
Add power_save module parameter to enable power management if needed
Default power management is disabled.

Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
2011-06-18 08:23:20 -07:00
Emmanuel Grumbach 705cd4513a iwlagn: store the irq number to iwl_bus just like dev
Since the irq number is just an unsigned int, store it inside iwl_bus
instead of calling the get_irq ops every time it is needed.

Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
2011-06-18 08:22:58 -07:00
Emmanuel Grumbach 4b55b07fc9 iwlagn: warn about nested SYNC commands
Since there is no protection around SYNC host command mechanism, at least WARN
when collision happens between two SYNC host comamnds. I am not sure there is a
real  issue (beyond the HCMD_ACTIVE flag maintenance) with having two SYNC host
commands at the same time, but at least now, we will know about it.

Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
2011-06-18 08:19:07 -07:00
Emmanuel Grumbach 807caf261c iwlagn: fix misplaced bracket
Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
2011-06-18 08:18:52 -07:00
Emmanuel Grumbach bcd4fe2f9e iwlagn: waterfall the bus level if prepare card failed
Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
2011-06-18 08:18:41 -07:00
Emmanuel Grumbach ea3aa93055 iwlagn: finally kill the pointer to pci_dev from iwl-dev.h
All pci related stuff is in iwl-pci.c.

Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
2011-06-18 08:18:32 -07:00
Emmanuel Grumbach 08321c062f iwlagn: add a get_irq method to iwl_bus_ops and use it
In order to remove a few more dereference to priv->pdev that will be killed
[Asoon, there is now a method to get the IRQ number.

Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
2011-06-18 08:18:17 -07:00
Emmanuel Grumbach 85aed7c481 iwlagn: don't read the PCI_REVISION_ID from iwl-agn.c
The PCI_REVISION_ID is read and printed in iwl_pci_probe anyway using pr_info

Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
2011-06-18 08:18:01 -07:00
Emmanuel Grumbach 19707bac16 iwlagn: add a method to get the HW ID description as a string to iwl_bus_ops
Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
2011-06-18 08:17:42 -07:00
Wey-Yi Guy d57fa99d91 iwlagn: move PCI power related functions to the PCI layer
Continue to popule the PCI layer and the iwl_bus_ops with the power related
stuff.

Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
2011-06-18 08:17:29 -07:00
Emmanuel Grumbach 795414db86 iwlagn: don't use the PCI wrappers for DMA operation
Get a pointer to the struct device during probe and get the rid of all the PCI
specific DMA wrappers.

Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
2011-06-18 08:16:16 -07:00
Emmanuel Grumbach 084dd79172 iwlagn: move PCI related operations from probe and remove to PCI layer
Since we have now a PCI layer, all the init and deinit code that is PCI
related should move to there.

Also move the IO functions: read8/read32/write32. They need hw_base which
is killed from priv.

Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
2011-06-18 08:07:14 -07:00
Emmanuel Grumbach 3599d39a85 iwlagn: add get_dev to iwl_bus_ops
Bus specific layer must know how to return the struct device* of the device.
Implement that as a callback of iwl_bus_ops and use that callback instead of
using the priv->pdev pointer which is meant to disappear soon.

Since the struct device * is needed in hot path, iwl_bus holds a pointer to it
instead of calling get_dev all the time.

Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
2011-06-18 08:06:24 -07:00
Emmanuel Grumbach a48709c5d0 iwlagn: introduce iwl_bus and iwl_bus_ops
iwl_bus will represent a bus, and iwl_bus_ops all the operations that can be
done on this bus.
For the moment only set_prv_data is implemented. More to come...

Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
2011-06-18 08:05:52 -07:00
Emmanuel Grumbach c6ca8bc46c iwlagn: remove uneeded include to pci.h and dma_mapping.h from a few files
Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
2011-06-18 08:05:40 -07:00
Emmanuel Grumbach 48d1a2110a iwlagn: add a iwl_pci.[ch] files that will contain all PCI specific code
Move some PCI functionality to the new iwl_pci.[ch] files:
* the PCI_DEVICE_TABLE
* the pci_driver struct definition
* the PCI probe / remove functions
* the PCI suspend / resume functions

All these functions are now split: the trigger comes from the PCI layer which
calls to the bus generic code located in the other files.

This is the beginning only. There are still a lot of PCI related code needs
to be gathered.

Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
2011-06-18 08:05:23 -07:00
Emmanuel Grumbach 7299751df3 iwlagn: don't disable interrupts after the NIC has been reset
It is superfluous to disable the interrupts after we reset the NIC. The only
entity that could enable the interrupts after the NIC is reset is the driver.
So remove this pointless action.

Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
2011-06-18 08:04:36 -07:00
Wey-Yi Guy ecdbe86eda iwlagn: Support flush queues for specified interface
Flush command can target specified interface or all interfaces

Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
2011-06-18 08:04:19 -07:00
Wey-Yi Guy f88e0ecc89 iwlagn: add PAN to tx flush
When issue tx flush, also consider PAN

Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
2011-06-18 08:04:08 -07:00
Wey-Yi Guy c68744fb93 iwlagn: Remove un-necessary indirect call
After driver split, no need to make indirect call to txfifo flush function

Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
2011-06-18 08:03:18 -07:00
Francois Romieu fd112f2e15 r8169: check firmware content sooner.
Firmware checking is only performed when the firmware is loaded
instead of each time the driver inits the phy.

Signed-off-by: Francois Romieu <romieu@fr.zoreil.com>
2011-06-18 11:40:48 +02:00
Hayes Wang 960aee6c7d r8169: support new firmware format.
The new firmware format adds versioning as firmware for a specific
chipset appears to be subject to change. Current "legacy" format is
still supported.

Signed-off-by: Hayes Wang <hayeswang@realtek.com>
Signed-off-by: Francois Romieu <romieu@fr.zoreil.com>
2011-06-18 11:40:33 +02:00
Francois Romieu 1c361efb22 r8169: explicit firmware format check.
Signed-off-by: Francois Romieu <romieu@fr.zoreil.com>
2011-06-18 11:34:32 +02:00
Francois Romieu b6ffd97f5b r8169: move the firmware down into the device private data.
No functional difference.

Signed-off-by: Francois Romieu <romieu@fr.zoreil.com>
2011-06-18 00:12:38 +02:00
Francois Romieu 3744100e05 r8169: fix static initializers.
Signed-off-by: Francois Romieu <romieu@fr.zoreil.com>
2011-06-17 22:58:54 +02:00
Pavel Shved d0fd64c1de farsync: add module_put to error path in fst_open()
The fst_open() function, after a successful try_module_get() may return
an error code if hdlc_open() returns it.  However, it does not put the
module on this error path.

This patch adds the necessary module_put() call.

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

Signed-off-by: Pavel Shved <shved@ispras.ru>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-17 15:27:32 -04:00
Clive Stubbings cab758ef30 fs_enet: fix freescale FCC ethernet dp buffer alignment
The RIPTR and TIPTR  (receive/transmit internal temporary data pointer),
used by microcode as a temporary buffer for data, must be 32-byte aligned
according to the RM for MPC8247.

Tested on mgcoge.

Signed-off-by: Clive Stubbings <clive.stubbings@xentech.co.uk>
Signed-off-by: Holger Brunck <holger.brunck@keymile.com>
cc: Pantelis Antoniou <pantelis.antoniou@gmail.com>
cc: Vitaly Bordug <vbordug@ru.mvista.com>
cc: netdev@vger.kernel.org
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-17 15:20:49 -04:00
Rafał Miłecki a8e827495a b43: HT-PHY: implement switching analog
Turning it on is always done between reading PHY version and radio
version, so it was easy to find it in MMIO dumps from ndiswrapper.
Turning off is done by writing different values to the same registers.

Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-06-17 14:22:28 -04:00
Rafał Miłecki 4cabd4254b b43: HT-PHY: implement radio ops
Every PHY has some specific bit used for reading radio regs. Analyze of
MMIO dumps from BCM4331 and ndiswrapper has shown it is 0x200 for HT.
 radio_read(0x037f) -> 0x0073
radio_write(0x017f) <- 0x0072

Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-06-17 14:22:27 -04:00
Pavel Roskin d816ab26f6 ath5k: annotate reg in ath5k_hw_nic_reset() as __iomem
Signed-off-by: Pavel Roskin <proski@gnu.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-06-17 14:22:27 -04:00
Pavel Roskin f5cbc8bac9 ath5k: minor cleanup
Move an extern variable declaration to a header file.  Prefix all
functions with "ath5k_".  Make ath5k_intr() static.  Remove unneeded
forward declarations.  Remove pointless "extern" in a function
declaration.

Signed-off-by: Pavel Roskin <proski@gnu.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-06-17 14:22:26 -04:00
Pavel Roskin e707549a80 ath9k: typo fix in a comment
Signed-off-by: Pavel Roskin <proski@gnu.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-06-17 14:22:25 -04:00
Pavel Roskin f6351d486d ath9k: use standard max(), remove A_MAX macro
Signed-off-by: Pavel Roskin <proski@gnu.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-06-17 14:22:25 -04:00
Mohammed Shafi Shajakhan d3af4396cf ath9k: remove a redundant call to pcipowersave
during suspend/resume ath9k_stop will always call ath_radio_disable
which will inturn call ath9k_hw_configpcipowersave, so no need to call
it explicitly in ath9k_stop

Signed-off-by: Mohammed Shafi Shajakhan <mshajakhan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-06-17 14:22:24 -04:00
Dan Carpenter a6f0f04887 iwlegacy: fix up brokenness caused by cleanup
Patch 7f1f974251 "iwlegacy: refactor iwl4965_mac_channel_switch"
reversed a test and also it changed a spin_lock_irq() to
spin_lock().  I assume the spin_lock change was a mistake because
the unlock was left as spin_unlock_irq().

Signed-off-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-06-17 14:22:24 -04:00
Mohammed Shafi Shajakhan d4bb17c4be ath9k: Add debug messages to track PAPRD failures
Add few debug messages for some of the possible scenarios
where we can detect PAPRD failures. this will help us to be
sure that we had really enabled PAPRD

Cc: susinder@qca.qualcomm.com
Cc: senthilb@qca.qualcomm.com
Signed-off-by: Mohammed Shafi Shajakhan <mshajakhan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-06-17 14:22:23 -04:00
Rafał Miłecki aec7ffdf4f b43: add Kconfig option for compiling SSB driver
It is always "y" for now, b43 will not compile without CONFIG_SSB yet.
This is just a first step of dropping SSB dependency.

Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-06-17 14:22:22 -04:00
Nikanth Karthikesan 545a8aa793 if_spi: Fix compilation warning - unused variable
if_spi: Fix compilation warning - unused variable 'spi'

drivers/net/wireless/libertas/if_spi.c: In function ‘if_spi_init_card’:
drivers/net/wireless/libertas/if_spi.c:1035: warning: unused variable ‘spi’

The variable is used only in a macro which uses the args only for DEBUG builds.
Remove the 'spi' variable completely.

Signed-off-by: Nikanth Karthikesan <nikanth@google.com>
Acked-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-06-17 14:22:21 -04:00
Rafał Miłecki d7520b1d2a b43: HT-PHY: add place for writing HT PHY support
This is totally broken plus we do not have specs for HT PHY yet. Just
introduce place for writing driver if we discover anything.

Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-06-17 14:22:20 -04:00
Rafał Miłecki 443c1a2471 b43: define new PHYs and radio regs for cores >= 24
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-06-17 14:22:19 -04:00
John W. Linville 82362ccbf2 Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-2.6 into for-davem 2011-06-17 12:40:36 -04:00
Sonic Zhang 118133e658 netdev: bfin_mac: fix memory leak when freeing dma descriptors
The size of the desc array is not the size of the desc structure, so
when we try to free up things, we leak some parts.

Reported-by: Regis Dargent <rdargent@edevice.com>
Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-17 00:19:09 -04:00
Greg Dietsche c4dc4d108a e1000: remove unnecessary code
Compile tested.
remove unnecessary code that matches this coccinelle pattern
	if (...)
		return ret;
	return ret;

Signed-off-by: Greg Dietsche <Gregory.Dietsche@cuw.edu>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-17 00:03:04 -04:00
Greg Dietsche 0a3f084179 net: icplus: remove unnecessary code
Compile tested.
remove unnecessary code that matches this coccinelle pattern
	if (...)
		return ret;
	return ret;

Signed-off-by: Greg Dietsche <Gregory.Dietsche@cuw.edu>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-17 00:03:04 -04:00
Neil Horman bebd097a0a tun: teach the tun/tap driver to support netpoll
Commit 8d8fc29d02 changed the behavior of slave
devices in regards to netpoll.  Specifically it created a mutually exclusive
relationship between being a slave and a netpoll-capable device.  This creates
problems for KVM because guests relied on needing netconsole active on a slave
device to a bridge.  Ideally libvirtd could just attach netconsole to the bridge
device instead, but thats currently infeasible, because while the bridge device
supports netpoll, it requires that all slave interface also support it, but the
tun/tap driver currently does not.  The most direct solution is to teach tun/tap
to support netpoll, which is implemented by the patch below.

I've not tested this yet, but its pretty straightforward.

Signed-off-by: Neil Horman <nhorman@tuxdriver.com>
Reported-by: Rik van Riel <riel@redhat.com>
CC: Rik van Riel <riel@redhat.com>
CC: Maxim Krasnyansky <maxk@qualcomm.com>
CC: Cong Wang <amwang@redhat.com>
CC: "David S. Miller" <davem@davemloft.net>
Reviewed-by: Rik van Riel <riel@redhat.com>
Tested-by: Rik van Riel <riel@redhat.com>
Reviewed-by: WANG Cong <amwang@redhat.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-16 23:53:10 -04:00
Richard Cochran ae6e86b7fb dp83640: drop PHY status frames in the driver.
The dp83640 PHY provides time stamp and other information via special
PHY status frames. Previously, the driver decoded the frames and then
let the network stack drop them. This works fine when the PTP messages
come over UDP.

However, when receiving PTP messages via L2 packets, this creates a
problem. The status frames use the official PTP destination MAC address,
and so they are delivered to user space along with the "real" frames,
causing confusion for applications.

This commit fixes the issue by simply dropping the PHY status frames
in the driver.

Signed-off-by: Richard Cochran <richard.cochran@omicron.at>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-16 23:48:12 -04:00
Richard Cochran 2331038a96 dp83640: fix phy status frame event parsing
If two eternal time stamp events occur at nearly the same time, the
phyter will add an extra word into the status frame. This commit fixes
the parsing code to recognize and skip over the extra word.

Signed-off-by: Richard Cochran <richard.cochran@omicron.at>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-16 23:48:12 -04:00
Ralf Baechle f1dc045e68 phylib: Allow BCM63XX PHY to be selected only on BCM63XX.
This PHY is available integrated into BCM63xx series SOCs only.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>

 drivers/net/phy/Kconfig |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
Acked-by: Florian Fainelli <ffainelli@freebox.fr>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-16 23:45:01 -04:00
Changli Gao e6539e2b7a ppp: use PPP_TRANS instead of the magic number 0x20
Signed-off-by: Changli Gao <xiaosuo@gmail.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-16 23:43:55 -04:00
Joe Perches 59deab26c1 gianfar: Use pr_<level>, netdev_<level> and netif_<level>
Use the current logging styles.

Add #define DEBUG to get same output for <foo>_dbg messages.
Convert a few bare printks to pr_err.

Fix a likely copy/paste defect where a test was done with RX values:
        if (num_rx_qs > MAX_RX_QS) {
but TX limits were emitted:
        printk(KERN_ERR "num_rx_qs(=%d) greater than MAX_RX_QS(=%d)\n",
                              num_tx_qs, MAX_TX_QS);

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-16 23:35:30 -04:00
Sathya Perla 3c8def9776 be2net: support multiple TX queues
This patch provides support for multiple TX queues.

Signed-off-by: Sathya Perla <sathya.perla@emulex.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-16 23:02:04 -04:00
Marius B. Kotsbak d40261236e net/usb: Add Samsung Kalmia driver for Samsung GT-B3730
Introducing driver for the network port of Samsung Kalmia based USB LTE modems.
It has also an ACM interface that previous patches associates with the "option"
module. To access those interfaces, the modem must first be switched from modem
mode using a tool like usb_modeswitch.

As the proprietary protocol has been discovered by watching the MS Windows driver
behavior, there might be errors in the protocol handling, but stable and fast
connection has been established for hours with Norwegian operator NetCom that
distributes this modem with their LTE/4G subscription.

More and updated information about how to use this driver is available here:

http://www.draisberghof.de/usb_modeswitch/bb/viewtopic.php?t=465
https://github.com/mkotsbak/Samsung-GT-B3730-linux-driver

Signed-off-by: Marius B. Kotsbak <marius@kotsbak.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-16 21:57:49 -04:00
Matt Carlson 520b2756d9 tg3: Create funcs for power source switching
The power source switching code is about to get a little more complex.
This patch seeks to simplify future power source switching patches by
clarifying the existing code.

Signed-off-by: Matt Carlson <mcarlson@broadcom.com>
Reviewed-by: Michael Chan <mchan@broadcom.com>
Reviewed-by: Benjamin Li <benli@broadcom.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-15 11:11:58 -04:00
Matt Carlson 221c56373e tg3: Migrate phy preprocessor defs to system defs
This patch changes to code to use some of the preprocessor
definitions from mii.h over its homegrown equivalents.

Signed-off-by: Matt Carlson <mcarlson@broadcom.com>
Reviewed-by: Michael Chan <mchan@broadcom.com>
Reviewed-by: Benjamin Li <benli@broadcom.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-15 11:11:57 -04:00
Matt Carlson 5bb09778e2 tg3: Show flowctrl settings through get_settings()
This patch adds code to present the flow control advertisements through
the ethtool get_settings callback.

Signed-off-by: Matt Carlson <mcarlson@broadcom.com>
Reviewed-by: Michael Chan <mchan@broadcom.com>
Reviewed-by: Benjamin Li <benli@broadcom.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-15 11:11:57 -04:00
Matt Carlson ad0fad9eb2 tg3: Fix EEE debounce timer values
This patch fixes the EEE debounce timer values.

Signed-off-by: Matt Carlson <mcarlson@broadcom.com>
Reviewed-by: Michael Chan <mchan@broadcom.com>
Reviewed-by: Benjamin Li <benli@broadcom.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-15 11:11:56 -04:00
Matt Carlson 727a6d9f39 tg3: Add more selfboot formats to NVRAM selftest
This patch adds more selfboot formats to the NVRAM selftest.  It also
changes the code to return an error on an unsupported NVRAM format.

Signed-off-by: Matt Carlson <mcarlson@broadcom.com>
Reviewed-by: Michael Chan <mchan@broadcom.com>
Reviewed-by: Benjamin Li <benli@broadcom.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-15 11:11:56 -04:00
Matt Carlson eb69d564a3 tg3: Remove 4G_DMA_BNDRY_BUG flag
Now that all chips have this bug, the flag checks become useless code.
This patch removes the flag.

Signed-off-by: Matt Carlson <mcarlson@broadcom.com>
Reviewed-by: Michael Chan <mchan@broadcom.com>
Reviewed-by: Benjamin Li <benli@broadcom.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-15 11:11:56 -04:00
Matt Carlson daf9a55387 tg3: Remove 40BIT_DMA_LIMIT_BUG
This patch removes the 40BIT_DMA_LIMIT_BUG flag.  There already exists a
flag for this purpose (TG3_FLAG_40BIT_DMA_BUG) and was already being
used in the correct spot.

Signed-off-by: Matt Carlson <mcarlson@broadcom.com>
Reviewed-by: Michael Chan <mchan@broadcom.com>
Reviewed-by: Benjamin Li <benli@broadcom.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-15 11:11:56 -04:00
Matt Carlson 0e6cf6a9e3 tg3: Workaround tagged status update bug
On rare occasions, writing the tag to the interrupt mailbox does not
reenable interrupts.  This patch fixes the problem by reissuing the
mailbox update.

Signed-off-by: Matt Carlson <mcarlson@broadcom.com>
Signed-off-by: Michael Chan <mchan@broadcom.com>
Reviewed-by: Benjamin Li <benli@broadcom.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-15 11:11:55 -04:00
Vladislav Zolotarov b96368e936 bnx2x: Update date to 2011/06/13 and version to 1.70.00-0
Signed-off-by: Vladislav Zolotarov <vladz@broadcom.com>
Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-15 10:56:59 -04:00
Dmitry Kravkov d1976b2e64 bnx2x: PFC support for 578xx
Add supoprt for 3 COSes for 578xx devices.
Fix HW configuration for PFC feature according to new HSI in link layer.

Signed-off-by: Dmitry Kravkov <dmitry@broadcom.com>
Signed-off-by: Vladislav Zolotarov <vladz@broadcom.com>
Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-15 10:56:59 -04:00
Yaniv Rosner 60d2fe0312 bnx2x: Rename LASI registers to definitions in mdio.h
Signed-off-by: Yaniv Rosner <yanivr@broadcom.com>
Signed-off-by: Vladislav Zolotarov <vladz@broadcom.com>
Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-15 10:56:59 -04:00
Yaniv Rosner 3deb8167ea bnx2x: Add a periodic task for link PHY events
Signed-off-by: Yaniv Rosner <yanivr@broadcom.com>
Signed-off-by: Vladislav Zolotarov <vladz@broadcom.com>
Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-15 10:56:58 -04:00
Yaniv Rosner 0d40f0d425 bnx2x: Adjust BCM84833 to BCM578xx
Signed-off-by: Yaniv Rosner <yanivr@broadcom.com>
Signed-off-by: Vladislav Zolotarov <vladz@broadcom.com>
Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-15 10:56:57 -04:00
Yaniv Rosner 6c3218c6f7 bnx2x: Adjust ETS to 578xx
Signed-off-by: Yaniv Rosner <yanivr@broadcom.com>
Signed-off-by: Vladislav Zolotarov <vladz@broadcom.com>
Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-15 10:56:57 -04:00
Yaniv Rosner 6583e33bae bnx2x: Add new PHY 54616s
Signed-off-by: Yaniv Rosner <yanivr@broadcom.com>
Signed-off-by: Vladislav Zolotarov <vladz@broadcom.com>
Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-15 10:56:57 -04:00
Yaniv Rosner 3c9ada227c bnx2x: Add Warpcore support for 578xx
Signed-off-by: Yaniv Rosner <yanivr@broadcom.com>
Signed-off-by: Vladislav Zolotarov <vladz@broadcom.com>
Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-15 10:56:57 -04:00
Yaniv Rosner 9380bb9e88 bnx2x: Add new MAC support for 578xx
Signed-off-by: Yaniv Rosner <yanivr@broadcom.com>
Signed-off-by: Vladislav Zolotarov <vladz@broadcom.com>
Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-15 10:56:56 -04:00
Dmitry Kravkov 754a2f5220 bnx2x: Cosmetic changes.
Signed-off-by: Dmitry Kravkov <dmitry@broadcom.com>
Signed-off-by: Vladislav Zolotarov <vladz@broadcom.com>
Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-15 10:56:56 -04:00
Dmitry Kravkov ef01854e24 bnx2x: update DCB data during PMF migration
Signed-off-by: Dmitry Kravkov <dmitry@broadcom.com>
Signed-off-by: Vladislav Zolotarov <vladz@broadcom.com>
Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-15 10:56:56 -04:00
Vladislav Zolotarov c9ee920624 bnx2x: 57712 parity handling
- Added support for a parity error handling for a 57712 chip.
 - Changed the parity recovery scheme from per-chip to per-engine.

Signed-off-by: Vladislav Zolotarov <vladz@broadcom.com>
Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-15 10:56:55 -04:00
Vlad Zolotarov 619c5cb688 New 7.0 FW: bnx2x, cnic, bnx2i, bnx2fc
New FW/HSI (7.0):
 - Added support to 578xx chips
 - Improved HSI - much less driver's direct access to the FW internal
   memory needed.

New implementation of the HSI handling layer in the bnx2x (bnx2x_sp.c):
 - Introduced chip dependent objects that have chip independent interfaces
   for configuration of MACs, multicast addresses, Rx mode, indirection table,
   fast path queues and function initialization/cleanup.
 - Objects functionality is based on the private function pointers, which
   allows not only a per-chip but also PF/VF differentiation while still
   preserving the same interface towards the driver.
 - Objects interface is not influenced by the HSI changes which do not require
   providing new parameters keeping the code outside the bnx2x_sp.c invariant
   with regard to such HSI chnages.

Changes in a CNIC, bnx2fc and bnx2i modules due to the new HSI.

Signed-off-by: Vladislav Zolotarov <vladz@broadcom.com>
Signed-off-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: Bhanu Prakash Gollapudi <bprakash@broadcom.com>
Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-15 10:56:37 -04:00
Vladislav Zolotarov 042181f5aa bnx2x: Created bnx2x_sp
Moved the HSI dependent slow path code to a separate file.
Currently it contains the implementation of MACs, Rx mode,
multicast addresses, indirection table, fast path queue and function
configuration code.

Signed-off-by: Vladislav Zolotarov <vladz@broadcom.com>
Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-15 10:56:15 -04:00
Dmitry Kravkov 9ee3d37b05 bnx2x: removed unused variables
Signed-off-by: Dmitry Kravkov <dmitry@broadcom.com>
Signed-off-by: Vladislav Zolotarov <vladz@broadcom.com>
Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-15 10:56:14 -04:00
Dmitry Kravkov a9fccec79e bnx2x: use bnx2x_reload_if_running
Signed-off-by: Dmitry Kravkov <dmitry@broadcom.com>
Signed-off-by: Vladislav Zolotarov <vladz@broadcom.com>
Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-15 10:56:14 -04:00
Dmitry Kravkov 7a25cc7315 bnx2x: dump FW memory when appropriate msglvl is raised
Signed-off-by: Dmitry Kravkov <dmitry@broadcom.com>
Signed-off-by: Vladislav Zolotarov <vladz@broadcom.com>
Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-15 10:56:14 -04:00
Yaniv Rosner 361c391e23 bnx2x: do not call link update without HW notification
Signed-off-by: Yaniv Rosner <yanivr@broadcom.com>
Signed-off-by: Vladislav Zolotarov <vladz@broadcom.com>
Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-15 10:56:14 -04:00
Dmitry Kravkov 30ae438b12 bnx2x: disable fairness if ETS is enabled
Signed-off-by: Dmitry Kravkov <dmitry@broadcom.com>
Signed-off-by: Vladislav Zolotarov <vladz@broadcom.com>
Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-15 10:56:14 -04:00
Dmitry Kravkov ca92429f5f bnx2x: avoid release of unrequested irqs
Signed-off-by: Dmitry Kravkov <dmitry@broadcom.com>
Signed-off-by: Vladislav Zolotarov <vladz@broadcom.com>
Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-15 10:56:13 -04:00
Dmitry Kravkov 93ef5c02a4 bnx2x: put start bd csum in separate function
Signed-off-by: Dmitry Kravkov <dmitry@broadcom.com>
Signed-off-by: Vladislav Zolotarov <vladz@broadcom.com>
Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-15 10:56:13 -04:00
Dmitry Kravkov 4b7ed8978d bnx2x: remove references to intr_sem
It's not needed any more since device always operates in interrupt-driven mode

Signed-off-by: Dmitry Kravkov <dmitry@broadcom.com>
Signed-off-by: Vladislav Zolotarov <vladz@broadcom.com>
Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-15 10:56:13 -04:00
Dmitry Kravkov 8eef2af182 bnx2x: do not allocate FCoE ring if disabled
Signed-off-by: Dmitry Kravkov <dmitry@broadcom.com>
Signed-off-by: Vladislav Zolotarov <vladz@broadcom.com>
Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-15 10:56:12 -04:00
Michael Chan 59e5137357 cnic: Move indexing function pointers to struct kcq_info
The hardware indexing scheme for the FCoE kcq will change in the upcoming
firmware.  This patch will cope with the change easily.

Signed-off-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: Vladislav Zolotarov <vladz@broadcom.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-15 10:56:12 -04:00
Nishant Sarmukadam 3373b28e5a mwl8k: Tell firmware to generate CCMP header
Post commit e4eefec73e, the stack is
not generating the CCMP header for us anymore. This broke the CCMP
functionality since firmware was not doing this either. Set a flag
to tell the firmware to generate the CCMP header

Signed-off-by: Nishant Sarmukadam <nishants@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-06-15 08:13:03 -04:00
Yogesh Ashok Powar a7b21165c0 mwifiex: Fixing NULL pointer dereference
Following OOPS was seen when booting with card inserted

 BUG: unable to handle kernel NULL pointer dereference at 0000004c
 IP: [<f8b7718c>] cfg80211_get_drvinfo+0x21/0x115 [cfg80211]
 *pde = 00000000
 Oops: 0000 [#1] SMP
 Modules linked in: iwl3945 iwl_legacy mwifiex_sdio mac80211 11 sdhci_pci sdhci pl2303

'ethtool' on the mwifiex device returned this OOPS as
wiphy_dev() returned NULL.

Adding missing set_wiphy_dev() call to fix the problem.

Signed-off-by: Yogesh Ashok Powar <yogeshp@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-06-15 08:13:03 -04:00
Geert Uytterhoeven 9281b2a2e2 net/hplance: hplance_init() should be __devinit
WARNING: vmlinux.o(.devinit.text+0x253e): Section mismatch in reference from the function hplance_init_one() to the function .init.text:hplance_init()

The forward declaration had the correct attribute, but the actual function
definition hadn't.

Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-13 18:32:36 -04:00
Neil Horman b7c7deeb4c vmxnet3: remove unused variable
While doing some backporting I noticed that vmxnet3 had a variable that was set
but never used.  Get rid of it, and stop the compiler from griping

Signed-off-by: Neil Horman <nhorman@tuxdriver.com>
CC: "VMware, Inc." <pv-drivers@vmware.com>
CC: "David S. Miller" <davem@davemloft.net>
Signed-off-by: Bhavesh Davda <bhavesh@vmware.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-13 18:31:09 -04:00
Peter Pan(潘卫平) bf0239a98a bonding:delete a dereference before check
Dan Carpenter found that there was a dereference before a check,
added in 56d00c677de0(bonding:delete lacp_fast from ad_bond_info).

Signed-off-by: Weiping Pan <panweiping3@gmail.com>
Signed-off-by: Jay Vosburgh <fubar@us.ibm.com>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-13 18:29:41 -04:00
Ondrej Zary 1ffde03d2a 3c503: fix broken IRQ autoprobing
Fix broken IRQ autoprobing in 3c503 driver:
 - improper IRQ freeing (does not free IRQs causes WARN)
 - missing break when an working IRQ is found

The driver works with this patch.

Signed-off-by: Ondrej Zary <linux@rainbow-software.org>
Reviewed-by: Ben Hutchings <ben@decadent.org.uk>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-13 18:25:19 -04:00
Richard Cochran ec1d7c9a5e smsc9420: enable transmit time stamping.
This patch enables software (and phy device) transmit time stamping
for the smsc9420. Compile tested only.

Cc: Steve Glendinning <steve.glendinning@smsc.com>
Signed-off-by: Richard Cochran <richard.cochran@omicron.at>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-13 17:26:16 -04:00
Richard Cochran 3e82ce120c stmmac: enable transmit time stamping.
This patch enables software (and phy device) transmit time stamping
for the STMicroelectronics Ethernet driver. Compile tested only.

Cc: Giuseppe Cavallaro <peppe.cavallaro@st.com>
Signed-off-by: Richard Cochran <richard.cochran@omicron.at>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-13 17:26:16 -04:00
Richard Cochran 7c4bb9fcae r6040: enable transmit time stamping.
This patch enables software (and phy device) transmit time stamping
for the RDC R6040 Fast Ethernet MAC. Compile tested only.

Cc: Florian Fainelli <florian@openwrt.org>
Signed-off-by: Richard Cochran <richard.cochran@omicron.at>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-13 17:26:15 -04:00
Richard Cochran 68f5139407 ethoc: enable transmit time stamping.
This patch enables software (and phy device) transmit time stamping
for the OpenCores 10/100 MAC driver. Compile tested only.

Cc: Thierry Reding <thierry.reding@avionic-design.de>
Signed-off-by: Richard Cochran <richard.cochran@omicron.at>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-13 17:26:15 -04:00
Richard Cochran ff9b3078b9 dnet: enable transmit time stamping.
This patch enables software (and phy device) transmit time stamping
in the "Dave ethernet interface." Compile tested only.

Cc: Ilya Yanok <yanok@emcraft.com>
Signed-off-by: Richard Cochran <richard.cochran@omicron.at>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-13 17:26:15 -04:00
Richard Cochran 2669069aac tg3: enable transmit time stamping.
This patch enables software (and phy device) transmit time stamping
for the TIGON3 driver. Compile tested only.

Cc: Matt Carlson <mcarlson@broadcom.com>
Cc: Michael Chan <mchan@broadcom.com>
Signed-off-by: Richard Cochran <richard.cochran@omicron.at>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-13 17:26:15 -04:00
Richard Cochran 1ca9495f85 davinci_emac: enable transmit time stamping.
This patch enables software (and phy device) transmit time stamping
for the DaVinci EMAC driver. Tested together with the dp83640 PHY.

Cc: Anant Gole <anantgole@ti.com>
Cc: Kevin Hilman <khilman@deeprootsystems.com>
Signed-off-by: Richard Cochran <richard.cochran@omicron.at>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-13 17:26:15 -04:00
Richard Cochran fb290cdd43 davinci_emac: pass ioctls through to phy device.
The DaVinci EMAC driver does not implement any ioctls, but still it can
pass them through to the phy device. This makes it possible for a phy
to offer PHC capabilities.

Cc: Anant Gole <anantgole@ti.com>
Cc: Kevin Hilman <khilman@deeprootsystems.com>
Signed-off-by: Richard Cochran <richard.cochran@omicron.at>
Signed-off-by: David S. Miller <davem@conan.davemloft.net>
2011-06-13 17:26:14 -04:00