| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
| |
keyword. But it doesn't work. Two options.. make it no longer accept it,
or actually make it work.. I chose the 2nd..
Allow the tablearg to be used to specify a skipto destination.
This is actually a very powerful construct if used correctly, or a sink
of cpu cycles if used badly.
changes t teh man page will follow.
|
|
|
|
|
|
|
|
| |
TCP ECN support. Merge of my GSoC 2006 work for NetBSD.
TCP ECN is defined in RFC 3168.
Partly reviewed by: dwmalone, silby
Obtained from: NetBSD
|
|
|
|
|
|
| |
Fixes a refcount bug found in the process
Obtained from: With the help of Michael Tuexen
|
|
|
|
| |
MFC after: 1 week
|
|
|
|
|
|
|
| |
- Fix a initialization of last_tsn_used
- Fix handling of mapped IPv4 addresses
Obtained from: Michael Tuexen and I :-)
MFC after: 1 week
|
|
|
|
| |
There is no functional changes.
|
|
|
|
| |
It allows access it while list travercing holding only global pcbinfo lock.
|
|
|
|
|
| |
Previous value was chosen 10 years ago and not very effective now.
This change gives several percents speedup on 1000 L2TP mpd links.
|
|
|
|
|
| |
It allows access it while list travercing holding only global pcbinfo lock.
This relaxed locking noticably increses receive socket lookup performance.
|
|
|
|
|
|
|
| |
This gives significant performance improvements when many raw sockets used.
Benchmarks of mpd handeling 1000 simultaneous PPTP connections show up to 50%
performance boost. With higher number of connections benefit becomes even
bigger. PopTop snd others should also get some benefits.
|
|
|
|
|
|
|
|
| |
- removing 'const' qualifier from an input parameter to conform to the type
required by rw_assert();
- using in_addr->s_addr to retrive 32 bits address value.
Observed by: tinderbox
|
| |
|
|
|
|
|
|
| |
- calling sodisconnect after tcp_twstart is both gratuitous and unsafe - remove
Submitted by: rwatson
|
|
|
|
|
|
| |
acquisition the tcbinfo lock.
MFC after: 1 week
|
|
|
|
| |
syncache_add in a manner consistent with other bits intended for offload
|
|
|
|
| |
MFC after: 1 week
|
| |
|
|
|
|
| |
Reviewed by: rwatson
|
|
|
|
|
|
| |
in comparisons to make this more obvious.
MFC after: 5 days
|
| |
|
|
|
|
| |
whole first request is present before returning from accept.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
information from rip_input() to rip_append(). Instead, pass the source
address for an IP datagram to rip_append() using a stack-allocated
sockaddr_in, similar to udp_input() and udp_append().
Prior to the move to rwlocks for inpcbinfo, this was not a problem, as
use of the global was synchronized using the ripcbinfo mutex, but with
read-locking there is the potential for a race during concurrent
receive.
This problem is not present in the IPv6 raw IP socket code, which
already used a stack variable for the address.
Spotted by: mav
MFC after: 1 week (before inpcbinfo rwlock changes)
|
|
|
|
| |
MFC after: 3 weeks
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
completes the move to a fully parallel UDP transmit path by using
global read, rather than write, locking of inpcbinfo in further
semi-connected cases:
- Add macros to allow try-locking of inpcb and inpcbinfo.
- Always acquire an incpcb read lock in udp_output(), which stablizes the
local inpcb address and port bindings in order to determine what further
locking is required:
- If the inpcb is currently not bound (at all) and are implicitly
connecting, we require inpcbinfo and inpcb write locks, so drop the
read lock and re-acquire.
- If the inpcb is bound for at least one of the port or address, but an
explicit source or destination is requested, trylock the inpcbinfo
lock, and if that fails, drop the inpcb lock, lock the global lock,
and relock the inpcb lock.
- Otherwise, no further locking is required (common case).
- Update comments.
In practice, this means that the vast majority of consumers of UDP sockets
will not acquire any exclusive locks at the socket or UDP levels of the
network stack. This leads to a marked performance improvement in several
important workloads, including BIND, nsd, and memcached over UDP, as well
as significant improvements in pps microbenchmarks.
The plan is to MFC all of the rwlock changes to RELENG_7 once they have
settled for a weeks in the tree.
Tested by: ps, kris (older revision), bde
MFC after: 3 weeks
|
|
|
|
| |
M tcp_output.c
|
|
|
|
|
|
| |
Approved by: mlaier (mentor)
Reported by: Scott Ullrich
MFC after: 1 week
|
|
|
|
|
|
|
|
|
| |
udp_output() so that argument validation occurs before jail processing.
Add additional comments explaining what's going on when we process
addresses and binding during udp_output().
MFC after: 3 weeks
|
|
|
|
|
|
| |
prison checks.
Reviewed by: rwatson
|
|
|
|
|
|
| |
All callers either pass in an u_short or u_int16_t.
Reviewed by: rwatson
|
|
|
|
|
|
|
| |
processed, meaning that we avoid the cost of MAC label assignment if we're
going to drop the packet due to mbuf exhaustion, etc.
MFC after: 3 weeks
|
|
|
|
|
|
| |
pointer pcbinfo rather than inp->inp_pcbinfo.
MFC after: 3 weeks
|
|
|
|
|
|
|
|
|
|
|
|
| |
2) Adds some __UserSpace__ on some of the common defines that
the user space code needs
3) Fixes a bug when we send up data to a user that failed. We
need to a) trim off the data chunk headers, if present, and
b) make sure the frag bit is communicated properly for the
msgs coming off the stream queues... i.e. we see if some
of the msg has been taken.
Obtained from: jeli contributed the VIMAGE changes on this pass Thanks Julain!
|
|
|
|
|
|
|
| |
struct inpcb.
Prodded by: bz
MFC after: 3 days
|
|
|
|
|
|
|
|
|
| |
inpcb. When directly invoking udp_notify() from udp_ctlinput(), acquire
only a read lock; we may still see write locks in udp_notify() as the
in_pcbnotifyall() routine is shared with TCP and always uses a write lock
on the inpcb being notified.
MFC after: 1 month
|
|
|
|
|
|
|
|
| |
some code paths, global or inpcb write locks are required, but for other
code paths, read locks or no locking at all are sufficient for the data
structures.
MFC after: 1 month
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
source or a specific destination address is requested as part of a send
on a UDP socket, read lock the inpcb rather than write lock it. This
will allow fully parallel transmit down to the IP layer when sending
simultaneously from multiple threads on a connected UDP socket.
Parallel transmit for more complex cases, such as when sendto(2) is
invoked with an address and there's already a local binding, will
follow.
MFC after: 1 month
|
|
|
|
|
|
|
| |
UDP socket for a datagram; the inpcb read lock is sufficient to provide
inpcb stability during udp_append().
MFC after: 1 month
|
|
|
|
|
|
|
| |
for functions in the generic raw socket library (raw_cb.c, raw_usrreq.c),
and they are not used for IPv4 raw sockets.
MFC after: 3 days
|
| |
|
|
|
|
|
|
|
|
|
| |
possible to exhaust and garble stack with a packet that contains a couple
of hundreds nested encapsulation levels.
Submitted by: Ming Fu <fming@borderware.com>
Reviewed by: rwatson
PR: kern/85320
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
dispatched without Giant, and add NETISR_FORCEQUEUE, which allows specific
netisr handlers to always be dispatched via a queue (deferred). Mark the
usb and if_ppp netisr handlers as NETISR_FORCEQUEUE, and explicitly
acquire Giant in those handlers.
Previously, any netisr handler not marked NETISR_MPSAFE would necessarily
run deferred and with Giant acquired. This change removes Giant
scaffolding from the netisr infrastructure, but NETISR_FORCEQUEUE allows
non-MPSAFE handlers to continue to force deferred dispatch so as to avoid
lock order reversals between their acqusition of Giant and any calling
context.
It is likely we will be able to remove NETISR_FORCEQUEUE once
IFF_NEEDSGIANT is removed, as non-MPSAFE usb and if_ppp drivers will no
longer be supported.
Reviewed by: bz
MFC after: 1 month
X-MFC note: We can't remove NETISR_MPSAFE from stable/7 for KPI reasons,
but the rest can go back.
|
|
|
|
|
|
|
|
|
|
|
| |
generating an RTM_MISS for every IP packet forwarded making user space
routing daemons unhappy.
PR: kern/123621, kern/124540, kern/122338
Reported by: Paul <paul gtcomm.net>, Mike Tancsa <mike sentex.net> on net@
Tested by: Paul and Mike
Reviewed by: andre
MFC after: 3 days
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
datagram-only protocols, such as UDP. This version removes use of
sblock(), which is not required due to an inability to interlace data
improperly with datagrams, as well as avoiding some of the larger loops
and state management that don't apply on datagram sockets.
This is experimental code, so hook it up only for UDPv4 for testing; if
there are problems we may need to revise it or turn it off by default,
but it offers *significant* performance improvements for threaded UDP
applications such as BIND9, nsd, and memcached using UDP.
Tested by: kris, ps
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
rather than write locking: while we need to maintain a valid reference
to the inpcb and fix its state, no protocol layer state is modified
during an IPv4 UDP receive -- there are only changes at the socket
layer, which is separately protected by socket locking.
While parallel concurrent receive on a single UDP socket is currently
relatively unusual, introducing read locking in the transmit path,
allowing concurrent receive and transmit, will significantly improve
performance for loads such as BIND, memcached, etc.
MFC after: 2 months
Tested by: gnn, kris, ps
|
|
|
|
|
|
|
|
|
|
| |
in_ifaddrhashtbl in in_ifinit because error handler in in_control removes
entries only for AF_INET addresses. If in_ifinit is called for the cloned
inteface that has just been created its address family is not AF_INET and
therefor LIST_REMOVE is not called for respective LIST_INSERT_HEAD and
freed entries remain in in_ifaddrhashtbl and lead to memory corruption.
PR: kern/124384
|
|
|
|
|
| |
links so we should be aware of it and try to delete every link only once
or we will loop forever.
|
|
|
|
|
| |
PR: bin/54274
Submitted by: Nicolai Petri <nicolai@petri.cc>
|
|
|
|
|
|
|
| |
Use strncasecmp() instead of huge local implementation to reduce code size.
Check space presence after command/code.
PR: kern/73034
|
|
|
|
|
|
|
| |
declared a cookie as expired.
Reviewed by: andre@, silby@
Reported by: Yahoo!
|
|
|
|
|
|
|
|
|
|
|
| |
that arrive in the receive window instead of just on the left edge of the receive window.
This is needed for correct behavior when packets are lost or reordered.
PR: kern/123950
Reviewed by: andre@, silby@
Reported by: Yahoo!, Wang Jin
MFC after: 1 week
|