19 Feb, 2011
1 commit
-
This will be used to optimize __ip_dev_find() and friends.
With help from Eric Dumazet.
Signed-off-by: David S. Miller
18 Feb, 2011
20 commits
-
We believe that our earlier patch for supporting multiple hardware
receive queues per enic device requires more internal testing. At this
point, we think that it's best to disable the use of multiple receive
queues. The current patch provides an effective means for the same.Also, we continue to disallow multiple hardware transmit queues per
device. But change the way we enforce this in order to maintain
consistency with the way receive queues are handled.Signed-off-by: Christian Benvenuti
Signed-off-by: Danny Guo
Signed-off-by: Vasanthy Kolluri
Signed-off-by: Roopa Prabhu
Signed-off-by: David Wang
Signed-off-by: David S. Miller -
The only troublesome bit here is __mkroute_output which wants
to override res->fi and res->type, compute those in local
variables instead.Signed-off-by: David S. Miller
-
Signed-off-by: David S. Miller
-
GCC emits all kinds of crazy zero extensions when we go from signed
int, to unsigned short, etc. etc.This transformation has to be legal because:
1) In tkey_extract_bits() in mask_pfx(), the values are used to
perform shifts, on which negative values are undefined by C.2) In fib_table_lookup() we perform comparisons with unsigned
values, constants, and additions. None of which should
encounter negative values.Signed-off-by: David S. Miller
-
This allows avoiding multiple writes to the initial __refcnt.
The most simplest cases of wanting an initial reference of "1"
in ipv4 and ipv6 have been converted, the rest have been left
along and kept at the existing "0".Signed-off-by: David S. Miller
-
This also allows us to combine all the dst->flags settings and avoid
read/modify/write sequences to this struct member.Signed-off-by: David S. Miller
-
Simplifies tail of __ip_route_output_key().
Signed-off-by: David S. Miller
-
There's a lot of redundancy and unnecessary stack frames
in the output route creation path.1) Make __mkroute_output() return error pointers.
2) Eliminate ip_mkroute_output() entirely, made possible by #1.
3) Call __mkroute_output() directly and handling the returning error
pointers in ip_route_output_slow().Signed-off-by: David S. Miller
-
This also enables TSOv6, TSO-ECN, and UFO as loopback clearly can handle them.
Signed-off-by: Michał Mirosław
Signed-off-by: David S. Miller -
Introduce NETIF_F_RXCSUM to replace device-private flags for RX checksum
offload. Integrate it with ndo_fix_features.ethtool_op_get_rx_csum() is removed altogether as nothing in-tree uses it.
Signed-off-by: Michał Mirosław
Signed-off-by: David S. Miller -
Signed-off-by: Michał Mirosław
Signed-off-by: David S. Miller -
Signed-off-by: Michał Mirosław
Signed-off-by: David S. Miller -
This introduces a new framework to handle device features setting.
It consists of:
- new fields in struct net_device:
+ hw_features - features that hw/driver supports toggling
+ wanted_features - features that user wants enabled, when possible
- new netdev_ops:
+ feat = ndo_fix_features(dev, feat) - API checking constraints for
enabling features or their combinations
+ ndo_set_features(dev) - API updating hardware state to match
changed dev->features
- new ethtool commands:
+ ETHTOOL_GFEATURES/ETHTOOL_SFEATURES: get/set dev->wanted_features
and trigger device reconfiguration if resulting dev->features
changed
+ ETHTOOL_GSTRINGS(ETH_SS_FEATURES): get feature bits names (meaning)Signed-off-by: Michał Mirosław
Signed-off-by: David S. Miller -
This allows to enable GRO even if RX csum is disabled. GRO will not
be used for packets without hardware checksum anyway.Signed-off-by: Michał Mirosław
Signed-off-by: David S. Miller -
This is needed for unified offloads patch.
Signed-off-by: Michał Mirosław
Signed-off-by: David S. Miller -
Signed-off-by: Michał Mirosław
Signed-off-by: David S. Miller -
Signed-off-by: Michał Mirosław
Signed-off-by: David S. Miller -
Signed-off-by: Christian Benvenuti
Signed-off-by: Danny Guo
Signed-off-by: Vasanthy Kolluri
Signed-off-by: Roopa Prabhu
Signed-off-by: David Wang
Signed-off-by: David S. Miller -
During a device reset, clear the counter for the no. of unicast addresses registered.
Also, rename the routines that update unicast and multicast address lists.Signed-off-by: Christian Benvenuti
Signed-off-by: Danny Guo
Signed-off-by: Vasanthy Kolluri
Signed-off-by: Roopa Prabhu
Signed-off-by: David Wang
Signed-off-by: David S. Miller -
Support fetching and retrieving RX indirection table via ethtool.
Signed-off-by: Tom Herbert
Acked-by: Eric Dumazet
Acked-by: Eilon Greenstein
Signed-off-by: David S. Miller
16 Feb, 2011
6 commits
-
Implement the ndo_setup_tc() operation with 2 traffic classes.
Current Solarstorm controllers do not implement TX queue priority, but
they do allow queues to be 'paced' with an enforced delay between
packets. Paced and unpaced queues are scheduled in round-robin within
two separate hardware bins (paced queues with a large delay may be
placed into a third bin temporarily, but we won't use that). If there
are queues in both bins, the TX scheduler will alternate between them.If we make high-priority queues unpaced and best-effort queues paced,
and high-priority queues are mostly empty, a single high-priority queue
can then instantly take 50% of the packet rate regardless of how many
of the best-effort queues have descriptors outstanding.We do not actually want an enforced delay between packets on best-
effort queues, so we set the pace value to a reserved value that
actually results in a delay of 0.Signed-off-by: Ben Hutchings
-
efx_channel_get_{rx,tx}_queue() currently return NULL if the channel
isn't used for traffic in that direction. In most cases this is a
bug, but some callers rely on it as an existence test.Add existence test functions efx_channel_has_{rx_queue,tx_queues}()
and use them as appropriate.Change efx_channel_get_{rx,tx}_queue() to assert that the requested
queue exists.Remove now-redundant initialisation from efx_set_channels().
Signed-off-by: Ben Hutchings
-
efx_hard_start_xmit() needs to implement a mapping which is the
inverse of tx_queue::core_txq. Move the initialisation of
tx_queue::core_txq next to efx_hard_start_xmit() to make the
connection more obvious.Signed-off-by: Ben Hutchings
-
If the root qdisc for a net device is mqprio, and the driver's
ndo_setup_tc() operation dynamically adds and remvoes TX queues,
netif_set_real_num_tx_queues() will be called during device
unregistration to remove the extra TX queues when the qdisc is
destroyed. Currently this causes the corresponding kobjects
to be leaked, and the device's reference count never drops to 0.Signed-off-by: Ben Hutchings
15 Feb, 2011
13 commits
-
Also optimize not to reread the value written to FEC_R_CNTRL.
Signed-off-by: Uwe Kleine-König
-
Reported-by: Lothar Waßmann
Signed-off-by: Uwe Kleine-König -
This fixes warnings when CONFIG_DMA_API_DEBUG=y:
NULL NULL: DMA-API: device driver tries to free DMA memory it has not allocated [device address=0x000000004781a020] [size=64 bytes]
net eth0: DMA-API: device driver frees DMA memory with different size [device address=0x000000004781a020] [map size=2048 bytes] [unmap size=64 bytes]Moreover pass the platform device to dma_{,un}map_single which makes
more sense because the logical network device doesn't know anything
about dma.Passing the platform device was a suggestion by Lothar Waßmann.
Signed-off-by: Uwe Kleine-König
-
Signed-off-by: Uwe Kleine-König
-
A few of these were found and reported by Lothar Waßmann.
Signed-off-by: Uwe Kleine-König
-
A variable named "dev" usually (usually subjective) points to a struct
device.Signed-off-by: Uwe Kleine-König
-
This undoes the effects of phy_start in fec_enet_open.
Reported-by: Lothar Waßmann
Signed-off-by: Uwe Kleine-König -
Moreover stop listing all i.MX platforms featuring a FEC, and use
the platform's config symbol that selects registration of a fec device
instead. This might make it easier to add new platforms.Set default = y for ARMs having a fec to reduce defconfig sizes.
Signed-off-by: Uwe Kleine-König
-
Saving it first into struct net_device->base_addr (which is an unsigned
long) is pointless and only needs to use more casts than necessary.Reported-by: Lothar Waßmann
Signed-off-by: Uwe Kleine-König -
alloc_etherdev internally uses kzalloc, so the private data is already
zerod out.Reported-by: Lothar Waßmann
Signed-off-by: Uwe Kleine-König -
dev_set_drvdata is called unconditionally in the probe function and so
it cannot be NULL.Reported-by: Lothar Waßmann
Signed-off-by: Uwe Kleine-König -
Reported-by: Lothar Waßmann
Signed-off-by: Uwe Kleine-König -
Reported-by: Lothar Waßmann
Signed-off-by: Uwe Kleine-König