opnsense-src/sys
Bruce M Simpson 34e3ccb34b Disconnect a temporarily-connected UDP socket in out-of-mbufs case. This
fixes the problem of UDP sockets getting wedged in a connected state (and
bound to their destination) under heavy load.
Temporary bind/connect should probably be deleted in future
as an optimization, as described in "A Faster UDP" [Partridge/Pink 1993].

Notes:
 - INP_LOCK() is already held in udp_output(). The connection is in effect
   happening at a layer lower than the socket layer, therefore in theory
   socket locking should not be needed.
 - Inlining the in_pcbdisconnect() operation buys us nothing (in the case
   of the current state of the code), as laddr is not part of the
   inpcb hash or the udbinfo hash. Therefore there should be no need
   to rehash after restoring laddr in the error case (this was a
   concern of the original author of the patch).

PR:		kern/41765
Requested by:	gnn
Submitted by:	Jinmei Tatuya (with cleanups)
Tested by:	spray(8)
2004-06-16 05:41:00 +00:00
..
alpha Remove a stale comment. 2004-06-15 19:28:40 +00:00
amd64 Correct an error in the implementation of pmap_is_prefaultable(). When I 2004-06-16 03:11:24 +00:00
arm Remove filename+line number from panic messages. 2004-06-06 21:26:49 +00:00
boot Merge boot0 and boot0sio so they behave the same. 2004-06-11 09:45:18 +00:00
cam Reformat the comments for cam_hdr so that they can be read. 2004-06-07 19:12:44 +00:00
coda add missing #include <sys/module.h> 2004-05-30 20:27:19 +00:00
compat Add support for more linux ioctls. 2004-06-14 07:26:23 +00:00
conf Link ALTQ to the build and break with ABI for struct ifnet. Please recompile 2004-06-13 17:29:10 +00:00
contrib Disable "bulk dequeue" when enabling ALTQ so it does not irritate the 2004-06-15 23:59:37 +00:00
crypto Use __FBSDID(). 2004-06-14 00:38:54 +00:00
ddb Fixed DDB_NOKLDSYM on amd64's: 2004-05-18 05:30:06 +00:00
dev If a device is not ONLINE, do not attempt to submit any commands 2004-06-15 19:40:47 +00:00
fs Nice, is a property of a process as a whole.. 2004-06-16 00:26:31 +00:00
geom Fix several bugs related to subdisk drive_offset calculation. 2004-06-15 20:56:25 +00:00
gnu Remove advertising clause from University of California Regent's 2004-04-07 20:46:16 +00:00
i4b Link ALTQ to the build and break with ABI for struct ifnet. Please recompile 2004-06-13 17:29:10 +00:00
i386 Nice, is a property of a process as a whole.. 2004-06-16 00:26:31 +00:00
ia64 Neither pmap_enter() nor pmap_enter_quick() should create pv entries for 2004-06-11 20:11:41 +00:00
isa Remove atdevbase and replace it's remaining uses with direct references to 2004-06-10 20:31:00 +00:00
isofs/cd9660 Remove advertising clause from University of California Regent's 2004-04-07 20:46:16 +00:00
kern Nice, is a property of a process as a whole.. 2004-06-16 00:26:31 +00:00
libkern Import libkern arm specific bits. 2004-05-14 12:28:31 +00:00
modules Add a module directory for geom_vinum. 2004-06-12 21:18:40 +00:00
net Replace IF_HANDOFF with new IFQ_HANDOFF to enqueue with ALTQ once enabled on 2004-06-15 23:57:42 +00:00
net80211 Link ALTQ to the build and break with ABI for struct ifnet. Please recompile 2004-06-13 17:29:10 +00:00
netatalk Socket MAC labels so_label and so_peerlabel are now protected by 2004-06-13 02:50:07 +00:00
netatm The socket field so_state is used to hold a variety of socket related 2004-06-14 18:16:22 +00:00
netgraph The socket field so_state is used to hold a variety of socket related 2004-06-14 18:16:22 +00:00
netinet Disconnect a temporarily-connected UDP socket in out-of-mbufs case. This 2004-06-16 05:41:00 +00:00
netinet6 Link ALTQ to the build and break with ABI for struct ifnet. Please recompile 2004-06-13 17:29:10 +00:00
netipsec use correct address for SADB_EXT_ADDRESS_DST in key_do_allocsa_policy 2004-05-03 05:15:53 +00:00
netipx Grab the socket buffer send or receive mutex when performing a 2004-06-15 03:51:44 +00:00
netkey avoid duplicate free. 2004-01-25 17:18:12 +00:00
netnatm Extend coverage of SOCK_LOCK(so) to include so_count, the socket 2004-06-12 20:47:32 +00:00
netncp add missing #include <sys/module.h> 2004-05-30 20:27:19 +00:00
netsmb The socket field so_state is used to hold a variety of socket related 2004-06-14 18:16:22 +00:00
nfs Remove advertising clause from University of California Regent's 2004-04-07 05:00:01 +00:00
nfs4client Remove advertising clause from University of California Regent's 2004-04-07 20:46:16 +00:00
nfsclient Convert GIANT_REQUIRED to NET_ASSERT_GIANT where Giant is used to 2004-06-16 03:12:50 +00:00
nfsserver Giant wasn't dropped here if we have to return EBUSY. This is bad. 2004-05-31 20:21:06 +00:00
opencrypto add missing #include <sys/module.h> 2004-05-30 20:27:19 +00:00
pc98 Include vm/vm_param.h to pull in KERNBASE now. This should fix the 2004-06-13 20:17:44 +00:00
pccard Convert callers to the new bus_alloc_resource_any(9) API. 2004-03-17 17:50:55 +00:00
pci Use NG_FREE_MSG() instead of FREE(). 2004-06-13 17:15:05 +00:00
posix4 The sem_timedwait() and ksem_timedwait() functions both 2004-02-03 22:27:03 +00:00
powerpc Remove checks for curthread == NULL - it can't happen. 2004-06-03 10:22:47 +00:00
rpc Remove advertising clause from University of California Regent's 2004-04-07 05:00:01 +00:00
security Socket MAC labels so_label and so_peerlabel are now protected by 2004-06-13 02:50:07 +00:00
sparc64 Add esp to the sparc64 GENERIC 2004-06-10 05:24:34 +00:00
sys Nice, is a property of a process as a whole.. 2004-06-16 00:26:31 +00:00
tools devlist2h.awk is too generic a name for what it does. It really 2004-05-26 00:19:39 +00:00
ufs Nice, is a property of a process as a whole.. 2004-06-16 00:26:31 +00:00
vm Nice, is a property of a process as a whole.. 2004-06-16 00:26:31 +00:00
Makefile Try harder not to compile anything in sys/boot for arm. 2004-05-16 00:19:12 +00:00