16 Apr, 2012
2 commits
-
Use of "unsigned int" is preferred to bare "unsigned" in net tree.
Signed-off-by: Eric Dumazet
Signed-off-by: David S. Miller -
Fix checkpatch errors of the following type:
* ERROR: "foo * bar" should be "foo *bar"
* ERROR: "(foo*)" should be "(foo *)"Signed-off-by: Daniel Baluta
Signed-off-by: David S. Miller
15 Apr, 2012
12 commits
-
As hypervior does not have the knowledge of guest network configuration, it's
better to ask guest to send gratuitous packets when needed.This patch implements VIRTIO_NET_F_GUEST_ANNOUNCE feature: hypervisor would
notice the guest when it thinks it's time for guest to announce the link
presnece. Guest tests VIRTIO_NET_S_ANNOUNCE bit during config change interrupt
and woule send gratuitous packets through netif_notify_peers() and ack the
notification through ctrl vq.We need to make sure the atomicy of read and ack in guest otherwise we may ack
more times than being notified. This is done through handling the whole config
change interrupt in an non-reentrant workqueue.Signed-off-by: Jason Wang
Acked-by: Michael S. Tsirkin
Signed-off-by: David S. Miller -
This patch replaces the code for getting an number from a
userspace buffer by a simple call to kstroul_from_user.
This makes it easier to read and less error prone.Signed-off-by: Peter Huewe
Signed-off-by: David S. Miller -
Signed-off-by: David S. Miller
-
Correct spelling typo within drivers/net.
Signed-off-by: Masanari Iida
Signed-off-by: David S. Miller -
tcp_enter_quickack_mode() already calls tcp_incr_quickack() and sets
icsk->icsk_ack.ato to TCP_ATO_MIN. This patch removes the duplication.Signed-off-by: Vijay Subramanian
Reviewed-by: Flavio Leitner
Signed-off-by: David S. Miller -
We must try harder to get unique (addr, port) pairs when
doing port autoselection for sockets with SO_REUSEADDR
option set.We achieve this by adding a relaxation parameter to
inet_csk_bind_conflict. When 'relax' parameter is off
we return a conflict whenever the current searched
pair (addr, port) is not unique.This tries to address the problems reported in patch:
8d238b25b1ec22a73b1c2206f111df2faaff8285
Revert "tcp: bind() fix when many ports are bound"Tests where ran for creating and binding(0) many sockets
on 100 IPs. The results are, on average:* 60000 sockets, 600 ports / IP:
* 0.210 s, 620 (IP, port) duplicates without patch
* 0.219 s, no duplicates with patch
* 100000 sockets, 1000 ports / IP:
* 0.371 s, 1720 duplicates without patch
* 0.373 s, no duplicates with patch
* 200000 sockets, 2000 ports / IP:
* 0.766 s, 6900 duplicates without patch
* 0.768 s, no duplicates with patch
* 500000 sockets, 5000 ports / IP:
* 2.227 s, 41500 duplicates without patch
* 2.284 s, no duplicates with patchSigned-off-by: Alex Copot
Signed-off-by: Daniel Baluta
Signed-off-by: Eric Dumazet
Signed-off-by: David S. Miller -
There are two struct request_sock_ops providers, tcp and dccp.
inet_csk_reqsk_queue_prune() can avoid testing syn_ack_timeout being
NULL if we make it non NULL like syn_ack_timeoutSigned-off-by: Eric Dumazet
Cc: Gerrit Renker
Cc: dccp@vger.kernel.org
Signed-off-by: David S. Miller -
Updates some comments to track RFC6298
Signed-off-by: Eric Dumazet
Cc: H.K. Jerry Chu
Cc: Tom Herbert
Signed-off-by: David S. Miller -
This patch converts the drivers in drivers/net/wan/* to use
module_pci_driver() macro which makes the code smaller and a bit simpler.Signed-off-by: Axel Lin
Cc: Francois Romieu
Cc: "David S. Miller"
Signed-off-by: David S. Miller -
This patch converts the drivers in drivers/net/tokenring/* to use
module_pci_driver() macro which makes the code smaller and a bit simpler.Signed-off-by: Axel Lin
Cc: "David S. Miller"
Cc: David Howells
Signed-off-by: David S. Miller -
Convert the per-cpu statistics kept for GRE, IPIP, and SIT tunnels
to use 64 bit statistics.Signed-off-by: Stephen Hemminger
Signed-off-by: David S. Miller
14 Apr, 2012
22 commits
-
This patch adds support for I2C clock stretching which is required per
SFF-8636. Customers with passive DA cables implement clock stretching
would fail without this patch.Signed-off-by: Don Skidmore
Tested-by: Phil Schmitt
Signed-off-by: Jeff Kirsher -
Signed-off-by: Carolyn Wyborny
Tested-by: Jeff Pieper
Signed-off-by: Jeff Kirsher -
Replace occurrences of 'if ( == )' with
'if ([!])'Replace occurrences of ' = () ? true : false'
with ' = '.Replace occurrence of ' = ' with
' = !!'While the latter replacement is not really necessary, it is done here for
consistency and clarity. No functional changes.Signed-off-by: Bruce Allan
Tested-by: Aaron Brown
Signed-off-by: Jeff Kirsher -
Now that split strings generate checkpatch warnings (per Chapter 2 of
Documentation/CodingStyle to make it easier to grep the code for the
string) cleanup the remaining instances of them in the driver.Signed-off-by: Bruce Allan
Tested-by: Aaron Brown
Signed-off-by: Jeff Kirsher -
This patch enables software (and phy device) transmit time stamping.
Tested on an old PIII laptop with built in NIC.Signed-off-by: Richard Cochran
Tested-by: Aaron Brown
Signed-off-by: Jeff Kirsher -
Signed-off-by: Richard Cochran
Tested-by: Aaron Brown
Signed-off-by: Jeff Kirsher -
I missed this when fixing up the warning in the previous commit.
Signed-off-by: David S. Miller
-
net/core/rtnetlink.c: In function ‘rtnl_create_link’:
net/core/rtnetlink.c:1645:3: warning: passing argument 2 of ‘ops->get_tx_queues’ from incompatible pointer type [enabled by default]
net/core/rtnetlink.c:1645:3: note: expected ‘const struct nlattr **’ but argument is of type ‘struct nlattr **’Signed-off-by: David S. Miller
-
nokia.com MX does not cope well with kernel.org.
Signed-off-by: Rémi Denis-Courmont
Signed-off-by: David S. Miller -
Signed-off-by: Rémi Denis-Courmont
Signed-off-by: David S. Miller -
Signed-off-by: Rémi Denis-Courmont
Signed-off-by: David S. Miller -
neigh_table_init_no_netlink() is only used in net/core/neighbour.c file.
Signed-off-by: Hiroaki SHIMODA
Signed-off-by: David S. Miller -
Most machines dont use UDP encapsulation (L2TP)
Adds a static_key so that udp_queue_rcv_skb() doesnt have to perform a
test if L2TP never setup the encap_rcv on a socket.Idea of this patch came after Simon Horman proposal to add a hook on TCP
as well.If static_key is not yet enabled, the fast path does a single JMP .
When static_key is enabled, JMP destination is patched to reach the real
encap_type/encap_rcv logic, possibly adding cache misses.Signed-off-by: Eric Dumazet
Cc: Simon Horman
Cc: dev@openvswitch.org
Signed-off-by: David S. Miller -
This fixes possible null dereference in probe() function: when both
.mac_addr and .link_gpio are unknown, dev.platform_data may be NULLReported-by: Dan Carpenter
Signed-off-by: Mike Sinkovsky
Signed-off-by: David S. Miller -
Fix spelling and references in rtnetlink.
Signed-off-by: Stephen Hemminger
Signed-off-by: David S. Miller -
Change get_tx_queues, drop unsused arg/return value real_tx_queues,
and use return by value (with error) rather than call by reference.Probably bonding should just change to LLTX and the whole get_tx_queues
API could disappear!Signed-off-by: Stephen Hemminger
Signed-off-by: David S. Miller -
Signed-off-by: Jim Cromie
Signed-off-by: David S. Miller -
Signed-off-by: Jim Cromie
Signed-off-by: David S. Miller -
Signed-off-by: Jim Cromie
Signed-off-by: David S. Miller -
In ancient times it was necessary to manually initialize the bus field of an
spi_driver to spi_bus_type. These days this is done in spi_driver_register() so
we can drop the manual assignment.The patch was generated using the following coccinelle semantic patch:
//
@@
identifier _driver;
@@
struct spi_driver _driver = {
.driver = {
- .bus = &spi_bus_type,
},
};
//Signed-off-by: Lars-Peter Clausen
Cc: "David S. Miller"
Cc: Gabor Juhos
Cc: Frederic Lambert
Cc: netdev@vger.kernel.org
Acked-by: Gabor Juhos
Signed-off-by: David S. Miller -
The comparison operators were backwards in both garp_attr_lookup and
garp_attr_create, so the entire GID rbtree was in reverse order.
(There was no practical side effect to this though, except that PDUs
were sent with attributes listed in reverse order, which is still
valid by the protocol. This change is only for clarity.)Signed-off-by: David Ward
Signed-off-by: David S. Miller -
We discovered that PPPoATM has an excessively deep transmit queue. A
queue the size of the default socket send buffer (wmem_default) is
maintained between the PPP generic core and the ATM device.Fix it to queue a maximum of *two* packets. The one the ATM device is
currently working on, and one more for the ATM driver to process
immediately in its TX done interrupt handler. The PPP core is designed
to feed packets to the channel with minimal latency, so that really
ought to be enough to keep the ATM device busy.While we're at it, fix the fact that we were triggering the wakeup
tasklet on *every* pppoatm_pop() call. The comment saying "this is
inefficient, but doing it right is too hard" turns out to be overly
pessimistic... I think :)On machines like the Traverse Geos, with a slow Geode CPU and two
high-speed ADSL2+ interfaces, there were reports of extremely high CPU
usage which could partly be attributed to the extra wakeups.(The wakeup handling could actually be made a whole lot easier if we
stop checking sk->sk_sndbuf altogether. Given that we now only queue
*two* packets ever, one wonders what the point is. As it is, you could
already deadlock the thing by setting the sk_sndbuf to a value lower
than the MTU of the device, and it'd just block for ever.)Signed-off-by: David Woodhouse
Signed-off-by: David S. Miller
13 Apr, 2012
4 commits
-
Do the initialization of the HSI interface when the
interface is opened, instead of upon registration.
When the interface is closed the HSI interface is
de-initialized, allowing other modules to use the
HSI interface.Signed-off-by: Sjur Brændeland
Signed-off-by: David S. Miller -
CAIF HSI is currently a virtual device. Stopping/starting the
queues is wrong on a virtual device.Signed-off-by: Sjur Brændeland
Signed-off-by: David S. Miller -
Implement aggregation algorithm, combining more data into a single
HSI transfer. 4 different traffic categories are supported:
1. TC_PRIO_CONTROL .. TC_PRIO_MAX (CTL)
2. TC_PRIO_INTERACTIVE (VO)
3. TC_PRIO_INTERACTIVE_BULK (VI)
4. TC_PRIO_BESTEFFORT, TC_PRIO_BULK, TC_PRIO_FILLER (BEBK)Signed-off-by: Dmitry Tarnyagin
Signed-off-by: David S. Miller -
Set traffic class for CAIF packets, based on socket
priority, CAIF protocol type, or type of message.Traffic class mapping for different packet types:
- control: TC_PRIO_CONTROL;
- flow control: TC_PRIO_CONTROL;
- at: TC_PRIO_CONTROL;
- rfm: TC_PRIO_INTERACTIVE_BULK;
- other sockets: equals to socket's TC;
- network data: no change.Signed-off-by: Dmitry Tarnyagin
Signed-off-by: David S. Miller