27 May, 2009
29 commits
-
This patch optimises the IPv4 GRO code by using 32-bit loads
(instead of 16-bit ones) on the ID and length checks in the receive
function.Signed-off-by: Herbert Xu
Signed-off-by: David S. Miller -
For the overwhelming majority of cases, skb_gro_header's return
value cannot be NULL. Yet we must check it because of its current
form. This patch splits it up into multiple functions in order
to avoid this.Signed-off-by: Herbert Xu
Signed-off-by: David S. Miller -
By caching frag0_len, we can avoid checking both frag0 and the
length separately in skb_gro_header. This helps as skb_gro_header
is called four times per packet which amounts to a few million
times at 10Gb/s.Signed-off-by: Herbert Xu
Signed-off-by: David S. Miller -
Instead of checking len > mss || len == 0, we can accomplish
both by checking (len - 1) > mss using the unsigned wraparound.
At nearly a million times a second, this might just help.Signed-off-by: Herbert Xu
Signed-off-by: David S. Miller -
The window has already been checked as part of the flag word
so there is no need to check it explicitly.Signed-off-by: Herbert Xu
Signed-off-by: David S. Miller -
Instead of doing two 16-bit operations for the source/destination
ports, we can do one 32-bit operation to take care both.Signed-off-by: Herbert Xu
Signed-off-by: David S. Miller -
Currently skb_gro_header is used for packets which put the hardware
header in skb->data with the rest in frags. Since the drivers that
need this optimisation all provide completely non-linear packets,
we can gain extra optimisations by only performing the frag0
optimisation for completely non-linear packets.In particular, we can simply test frag0 (instead of skb_headlen)
to see whether the optimisation is in force.Signed-off-by: Herbert Xu
Signed-off-by: David S. Miller -
This patch stores the offset/headlen in local variables as they're
used repeatedly in skb_gro_offset.Signed-off-by: Herbert Xu
Signed-off-by: David S. Miller -
The function skb_gro_header is called four times per packet which
quickly adds up at 10Gb/s. This patch inlines it to allow better
optimisations.Some architectures perform multiplication for page_address, which
is done by each skb_gro_header invocation. This patch caches that
value in skb->cb to avoid the unnecessary multiplications.Signed-off-by: Herbert Xu
Signed-off-by: David S. Miller -
gcc does a poor job at generating code for the memcpy of the frags
array in skb_gro_receive, which is the primary purpose of that
function when merging frags. In particular, it can't utilise the
alignment information of the source and destination. This patch
open-codes the copy so we process words instead of bytes.Signed-off-by: Herbert Xu
Signed-off-by: David S. Miller -
This patch fixes a build warning due to an unused label.
Signed-off-by: Peter P Waskiewicz Jr
Signed-off-by: David S. Miller -
Just use the constant 20 to keep things working.
If someone is so motivated, this can be converted over to
dynamic strings. I tried and it's a lot of work.But for now this is good enough.
Signed-off-by: David S. Miller
-
It's going away. Just leave the constant "20" here so that
behavior doesn't change.Signed-off-by: David S. Miller
-
Signed-off-by: David S. Miller
-
Signed-off-by: David S. Miller
-
Use MII_BUS_ID_SIZE instead.
Signed-off-by: David S. Miller
-
BUS_ID_SIZE is really no more, and device names are dynamically
allocated and thus can be any necessary size.So remove the BUG check here making sure BUS_ID_SIZE is at least
as large as IFNAMSIZ.Signed-off-by: David S. Miller
-
The r8169 driver supports 3 different families of network chips
(RTL8169, RTL8168 and RTL8101). When an unknown version is found, the
driver currently always defaults to the RTL8169 variant. This has very
little chance to ever work for chips of the other families. So better
define a per-family default.Signed-off-by: Jean Delvare
Acked-by: Francois Romieu
Signed-off-by: David S. Miller -
Inspired by the patch for 8139too (bda6a15a).
Currently we can't set mac address on a running ucc_geth device.
But this is needed when you use this device as a bonding slave in
bonding device in balance-alb mode. So add this feature for ucc_geth
device.Signed-off-by: Kevin Hao
Signed-off-by: David S. Miller -
This patch is for supporting C10NEM. C10NEM is a switch module, which
has back-to-back XAUI link connected to blades.Signed-off-by: Tanli Chang
Signed-off-by: David S. Miller -
If we loaded the driver with out a SFP module plugged in it would
leave it in a state that make it later unable to link when a module
was plugged in. This patch corrects that by:ixgbe_probe() - moving the check for IXGBE_ERR_SFP_NOT_PRESENT from
after get_invariants() to after reset_hw() as now reset_hw() is
where this condition will be indentified.ixgbe_reset_hw_82598() - Enable this function to now return
IXGBE_ERR_SFP_NOT_PRESENT.ixgbe_identify_sfp_module_generic() - This where the lack of SFP
module is detected. Modifications are added to allow a different
return value for modules that just haven't been plugged in yet.Other functions were updated to allow correct logging.
Signed-off-by: Don Skidmore
Signed-off-by: Peter P Waskiewicz Jr
Signed-off-by: Jeff Kirsher
Signed-off-by: David S. Miller -
Device ID 0x10d8 is the default silicon device ID for 82599. However, the
device will not be functional without an EEPROM, so we want to prevent the
driver from loading on the device. Otherwise, the driver will load, but no
PHY setup or PCIe setup will occur, causing the device to be unusable. To
prevent users from encountering this, just remove the device ID.Signed-off-by: Peter P Waskiewicz Jr
Signed-off-by: Jeff Kirsher
Signed-off-by: David S. Miller -
The phy port status register has the MDI-X status bit on bit 11, not bit 3
as is currently setup in the define. This patch corrects that so the
correct bit is checked on igp PHY types.Signed-off-by: Alexander Duyck
Acked-by: Bruce Allan
Signed-off-by: Jeff Kirsher
Signed-off-by: David S. Miller -
Based on previous patch from Jesper Dangaard Brouer.
The RNBC (Receive No Buffers Count) register for the 82576, indicate
that frames were received when there were no available buffers in host
memory to store those frames (receive descriptor head and tail
pointers were equal). The packet is still received by the NIC if
there is space in the FIFO on the NIC.As the RNBC value is not a packet drop, the driver stores this value
in net_stats.rx_fifo_errors to indicate that there were no system
buffers available for the incoming packet. Actual dropped packets
are counted in the MPC value.Saving the stats in dev->net_stats makes it visible via
/proc/net/dev as "fifo", and thus viewable to ifconfig
as "overruns" and 'netstat -i' as "RX-OVR".The Receive No Buffers Count (RNBC) can already be queried by
ethtool -S as "rx_no_buffer_count".Signed-off-by: Jeff Kirsher
CC: Jesper Dangaard Brouer
Signed-off-by: David S. Miller -
Based on the previous patches from Jesper Dangaard Brouer
Implement reading the per queue drop stats register
RQDPC (Receive Queue Drop Packet Count). It counts the number of
packets dropped by a queue due to lack of descriptors available.Notice RQDPC (Receive Queue Drop Packet Count) stats only gets
incremented, if the DROP_EN bit it set (in the SRRCTL register
for that queue). If DROP_EN bit is NOT set, then the some what
equivalent count is stored in RNBC (not per queue basis).The RQDPC register is only 12 bit, thus the precision might
suffer due to overrun in-netween the watchdog polling interval.Signed-off-by: Jeff Kirsher
CC: Jesper Dangaard Brouer
Signed-off-by: David S. Miller -
Signed-off-by: Jeff Kirsher
Signed-off-by: David S. Miller -
Also convert DPRINTK to pr_debug and dev_printk to dev_.
Signed-off-by: Alexander Beregalov
Signed-off-by: David S. Miller -
Signed-off-by: Alexander Beregalov
Signed-off-by: David S. Miller -
Signed-off-by: Alexander Beregalov
Signed-off-by: David S. Miller
26 May, 2009
10 commits
-
Get rid of private struct net_device_stats in "struct atl1e_adapter",
and use one provided in struct net_device instead.Signed-off-by: Eric Dumazet
Signed-off-by: David S. Miller -
We would like to get rid of netdev->trans_start = jiffies; that about all net
drivers have to use in their start_xmit() function, and use txq->trans_start
instead.This can be done generically in core network, as suggested by David.
Some devices, (particularly loopback) dont need trans_start update, because
they dont have transmit watchdog. We could add a new device flag, or rely
on fact that txq->tran_start can be updated is txq->xmit_lock_owner is
different than -1. Use a helper function to hide our choice.Signed-off-by: Eric Dumazet
Signed-off-by: David S. Miller -
Signed-off-by: Yoshihiro Shimoda
Signed-off-by: Kuninori Morimoto
Signed-off-by: Nobuhiro Iwamatsu
Signed-off-by: David S. Miller -
This improves readability by collecting CPU dependency code.
Signed-off-by: Yoshihiro Shimoda
Signed-off-by: Nobuhiro Iwamatsu
Signed-off-by: David S. Miller -
Fix the problem that this driver not update rxdesc in sh_eth_rx.
Signed-off-by: Yoshihiro Shimoda
Signed-off-by: Nobuhiro Iwamatsu
Signed-off-by: David S. Miller -
Fix the probrem that TX/RX descirptor not set physical memory.
Signed-off-by: Yoshihiro Shimoda
Signed-off-by: Nobuhiro Iwamatsu
Signed-off-by: David S. Miller -
Fix the problem that may not work receive process by cache coherency issue.
Signed-off-by: Yoshihiro Shimoda
Signed-off-by: Nobuhiro Iwamatsu
Signed-off-by: David S. Miller -
Right-shifts of signed integers are implementation-defined so unportable.
With feedback from: Eric Dumazet
Signed-off-by: Jarek Poplawski
Signed-off-by: David S. Miller -
Signed-off-by: Gabriel Paubert
Signed-off-by: David S. Miller -
The patch makes iwmc3200wifi select CFG80211 instead of LIB80211.
This fixed module link error reported by Randy Dunlap
when compiling iwmc3200wifi without
cfg80211 selected. WIRELESS_EXT is also selected by iwmc3200wifi.Signed-off-by: Zhu Yi
Signed-off-by: David S. Miller
25 May, 2009
1 commit
-
All drivers are already converted to new net_device_ops API
and nobody uses old API anymore.Signed-off-by: Alexander Beregalov
Signed-off-by: David S. Miller