#
b272101a |
| 30-Oct-2023 |
Aaron LI <aly@aaronly.me> |
Various minor whitespace cleanups
Accumulated along the way.
|
#
410f8572 |
| 22-Dec-2023 |
Aaron LI <aly@aaronly.me> |
kernel: Replace the deprecated m_copy() with m_copym()
|
#
2539704b |
| 30-Mar-2023 |
Sascha Wildner <saw@online.de> |
kernel/ip6_mroute: Add missing opt_mrouting.h include to get at MROUTING.
|
Revision tags: v6.4.0, v6.4.0rc1, v6.5.0, v6.2.2, v6.2.1, v6.2.0, v6.3.0, v6.0.1, v6.0.0, v6.0.0rc1, v6.1.0, v5.8.3, v5.8.2, v5.8.1, v5.8.0, v5.9.0, v5.8.0rc1, v5.6.3, v5.6.2 |
|
#
7eaeff3d |
| 07-Aug-2019 |
Roy Marples <roy@marples.name> |
socket: introduce SO_RERROR to detect receive buffer overflow
kernel receive buffers are initially of a limited size and generally the network protocols that use them don't care if a packet gets los
socket: introduce SO_RERROR to detect receive buffer overflow
kernel receive buffers are initially of a limited size and generally the network protocols that use them don't care if a packet gets lost.
However some users do care about lost messages even if not baked into the protocol - such as consumers of route(4) to track state.
POSIX states that read(2) can return an error of ENOBUFS so return this error code when an overflow is detected. Guard this with socket option SO_RERROR so that existing applications which do not care can carry on not caring by default.
Taken-from: NetBSD Reviewed-by: sephe
show more ...
|
Revision tags: v5.6.1, v5.6.0, v5.6.0rc1, v5.7.0, v5.4.3, v5.4.2, v5.4.1, v5.4.0, v5.5.0, v5.4.0rc1, v5.2.2, v5.2.1 |
|
#
d41f11ec |
| 17-Apr-2018 |
Sepherosa Ziehau <sephe@dragonflybsd.org> |
inet6/pim: Return IPPROTO_DONE if the mbuf is freed.
This prevents the caller from using the freed mbuf.
Obtained-from: NetBSD via FreeBSD
|
Revision tags: v5.2.0, v5.3.0, v5.2.0rc, v5.0.2, v5.0.1, v5.0.0, v5.0.0rc2, v5.1.0, v5.0.0rc1 |
|
#
5204e13c |
| 07-Aug-2017 |
Sepherosa Ziehau <sephe@dragonflybsd.org> |
netisr: Simplify assertion related bits
|
Revision tags: v4.8.1, v4.8.0, v4.6.2, v4.9.0, v4.8.0rc |
|
#
1647c7bd |
| 16-Feb-2017 |
Sascha Wildner <saw@online.de> |
kernel: Fix the type of 'cmd' in various ioctl functions (int -> u_long).
These were all found by clang's -Wswitch option.
|
Revision tags: v4.6.1, v4.6.0, v4.6.0rc2, v4.6.0rc, v4.7.0, v4.4.3, v4.4.2 |
|
#
2c64e990 |
| 25-Jan-2016 |
zrj <rimvydas.jasinskas@gmail.com> |
Remove advertising header from sys/
Correct BSD License clause numbering from 1-2-4 to 1-2-3.
Some less clear cases taken as it was done of FreeBSD.
|
Revision tags: v4.4.1, v4.4.0, v4.5.0, v4.4.0rc |
|
#
736b6ebe |
| 15-Aug-2015 |
Sepherosa Ziehau <sephe@dragonflybsd.org> |
inet6: Dispatch mcast routing expire upcalls to netisr0 to run
|
#
416fd1c1 |
| 15-Aug-2015 |
Sepherosa Ziehau <sephe@dragonflybsd.org> |
inet6: Avoid excessive calling of in6_addr2zoneid()
Obtained-from: FreeBSD
|
#
cb3deea5 |
| 13-Aug-2015 |
Sepherosa Ziehau <sephe@dragonflybsd.org> |
inet6: Change scope to zone and use in6_clearscope() whenever possible
Obtained-from: KAME via FreeBSD
|
#
304e70d2 |
| 09-Aug-2015 |
Sepherosa Ziehau <sephe@dragonflybsd.org> |
inet6: Fix linkmtu handling
While I'm here, minor white space cleanup and remove unused code.
Obtained-from: KAME via FreeBSD
|
Revision tags: v4.2.4 |
|
#
1af953ac |
| 05-Aug-2015 |
Sepherosa Ziehau <sephe@dragonflybsd.org> |
inet6: Cosmetic clean up
No functional changes.
Obtained-from: KAME via FreeBSD
|
Revision tags: v4.3.1, v4.2.3, v4.2.1, v4.2.0, v4.0.6, v4.3.0, v4.2.0rc, v4.0.5, v4.0.4 |
|
#
b5523eac |
| 19-Feb-2015 |
Sascha Wildner <saw@online.de> |
kernel: Move us to using M_NOWAIT and M_WAITOK for mbuf functions.
The main reason is that our having to use the MB_WAIT and MB_DONTWAIT flags was a recurring issue when porting drivers from FreeBSD
kernel: Move us to using M_NOWAIT and M_WAITOK for mbuf functions.
The main reason is that our having to use the MB_WAIT and MB_DONTWAIT flags was a recurring issue when porting drivers from FreeBSD because it tended to get forgotten and the code would compile anyway with the wrong constants. And since MB_WAIT and MB_DONTWAIT ended up as ocflags for an objcache_get() or objcache_reclaimlist call (which use M_WAITOK and M_NOWAIT), it was just one big converting back and forth with some sanitization in between.
This commit allows M_* again for the mbuf functions and keeps the sanitizing as it was before: when M_WAITOK is among the passed flags, objcache functions will be called with M_WAITOK and when it is absent, they will be called with M_NOWAIT. All other flags are scrubbed by the MB_OCFLAG() macro which does the same as the former MBTOM().
Approved-by: dillon
show more ...
|
Revision tags: v4.0.3, v4.0.2, v4.0.1, v4.0.0, v4.0.0rc3, v4.0.0rc2, v4.0.0rc, v4.1.0, v3.8.2, v3.8.1, v3.6.3, v3.8.0, v3.8.0rc2, v3.9.0, v3.8.0rc |
|
#
72659ed0 |
| 13-May-2014 |
Sepherosa Ziehau <sephe@dragonflybsd.org> |
ifnet: Properly protect if_multiaddrs using ifnet serializers
- Protect ifnet.if_multiaddrs using ifnet serializers. Add some comment in the places, where only main serailizer is necessary. - Fix
ifnet: Properly protect if_multiaddrs using ifnet serializers
- Protect ifnet.if_multiaddrs using ifnet serializers. Add some comment in the places, where only main serailizer is necessary. - Fix if_delallmulti(). Using TAILQ_FOREACH_MUTABLE is incorrect for deleting an ifmultiaddr from ifnet.if_multiaddrs. Since deleting one ifmultiaddr may cause additional ifmultiaddr deletion (e.g. the AF_LINK ifmultiaddr for AF_INET ifmultiaddr). - Change IN_LOOKUP_MULTI and IN6_LOOKUP_MULTI macros into inline functions. - Redispatch multicast IP packets to netisr0 for further processing. Software based IP packet hash function is changed. And hash value fixup for multicast IP packets is added to the beginning of ip_input(); this is mainly for IP packets, whose hash is calculated by hardware. - For wlan's multicast hardware filter updating, we no longer need to release wlan serializer and mess up w/ the if_ioctl setting.
In netisr0, read and test ifma_refcount for AF_INET ifmultiaddr is MPSAFE w/o ifnet serializers, since its ifma_refcount is only altered in netisr0.
In netisr0, any operation on in_multi, which is obtained from the corresponding ifmuliaddr's ifma_protospec, is MPSAFE w/o ifnet serializers, since ifmultiaddr for AF_INET is only set and cleared in netisr0.
While I'm here also redispatch IP packets w/o hash to the proper netisrs, on ip_input() path. And unnecessary critical sections in in_{add,del}multi() are removed.
show more ...
|
Revision tags: v3.6.2, v3.6.1, v3.6.0, v3.7.1, v3.6.0rc, v3.7.0 |
|
#
de99dcea |
| 05-Oct-2013 |
Matthew Dillon <dillon@apollo.backplane.com> |
kernel - Fix minor ipv6 mbuf memory leak
* Fix a minor ipv6 mbuf memory leak.
Reported-by: logan bug 2593
|
#
cec73927 |
| 05-Sep-2013 |
Matthew Dillon <dillon@apollo.backplane.com> |
kernel - Change time_second to time_uptime for all expiration calculations
* Vet the entire kernel and change use cases for expiration calculations using time_second to use time_uptime instead.
*
kernel - Change time_second to time_uptime for all expiration calculations
* Vet the entire kernel and change use cases for expiration calculations using time_second to use time_uptime instead.
* Protects these expiration calculations from step changes in the wall time, particularly needed for route table entries.
* Probably requires further variable type adjustments but the use of time_uptime instead if time_second is highly unlikely to ever overrun any demotions to int still present.
show more ...
|
Revision tags: v3.4.3, v3.4.2, v3.4.0, v3.4.1, v3.4.0rc, v3.5.0 |
|
#
651d02c5 |
| 09-Feb-2013 |
Sepherosa Ziehau <sephe@dragonflybsd.org> |
ip6/mroute: Partly fix set-but-unused gcc47 warning
|
Revision tags: v3.2.2, v3.2.1, v3.2.0, v3.3.0, v3.0.3, v3.0.2, v3.0.1, v3.1.0, v3.0.0 |
|
#
86d7f5d3 |
| 26-Nov-2011 |
John Marino <draco@marino.st> |
Initial import of binutils 2.22 on the new vendor branch
Future versions of binutils will also reside on this branch rather than continuing to create new binutils branches for each new version.
|
Revision tags: v2.12.0, v2.13.0, v2.10.1, v2.11.0, v2.10.0, v2.9.1, v2.8.2, v2.8.1, v2.8.0, v2.9.0, v2.6.3, v2.7.3, v2.6.2, v2.7.2, v2.7.1, v2.6.1, v2.7.0, v2.6.0, v2.5.1, v2.4.1, v2.5.0, v2.4.0, v2.3.2, v2.3.1, v2.2.1 |
|
#
a3dd34d2 |
| 05-Apr-2009 |
Sepherosa Ziehau <sephe@dragonflybsd.org> |
Split ifnet serialize step 1/many: Add if_{serialize,deserialize,tryserialize}() function pointers to ifnet.
These three function pointers accept ifnet struct and ifnet_serialize enumeration.
The i
Split ifnet serialize step 1/many: Add if_{serialize,deserialize,tryserialize}() function pointers to ifnet.
These three function pointers accept ifnet struct and ifnet_serialize enumeration.
The ifnet_serialize enumeration indicates the serialization type: IFNET_SERIALIZE_ALL: All of the serializers should be held. Except for if_start and if_input, this enumeration must be used when call ifnet function pointers. IFNET_SERIALIZE_TX: Only transmit serializer should be held. This enumeration could be used when calling ifnet.if_start. IFNET_SERIALIZE_RX: Only receive serializer should be held. This enumeration could be used when calling ifnet.if_input.
If the NIC driver does not set these three function pointer, then if_attach() will set them to the default ones: only one serializer (if_serializer) is used and ifnet_serialize parameter is ignored.
Following several inline functions are added which are sheer wrappers of the three ifnet serialize function pointers: ifnet_serialize_{all,tx,rx}() ifnet_deserialize_{all,tx,rx}() ifnet_tryserialize_{all,tx,rx}()
All of the protocol layers and most of the pseudo drivers are converted.
Discussed-with: dillon@
show more ...
|
#
60233e58 |
| 05-Apr-2009 |
Sascha Wildner <saw@online.de> |
Generally use NULL instead of explicitly casting 0 to some pointer type.
|
Revision tags: v2.2.0, v2.3.0, v2.1.1, v2.0.1 |
|
#
6caa4804 |
| 21-Jun-2008 |
Aggelos Economopoulos <aggelos@dragonflybsd.org> |
More copy{in,out} removal for ctloutput routines
|
#
3641b7ca |
| 05-Jun-2008 |
Sascha Wildner <swildner@dragonflybsd.org> |
* Fix some cases where NULL was used but 0 was meant (and vice versa).
* Remove some bogus casts of NULL to (void *).
|
#
9db4b353 |
| 14-May-2008 |
Sepherosa Ziehau <sephe@dragonflybsd.org> |
Reduce ifnet.if_serializer contention on output path: - Push ifnet.if_serializer holding down into each ifnet.if_output implementation - Add a serializer into ifaltq, which is used to protect send qu
Reduce ifnet.if_serializer contention on output path: - Push ifnet.if_serializer holding down into each ifnet.if_output implementation - Add a serializer into ifaltq, which is used to protect send queue instead of its parent's if_serializer. This change has following implication: o On output path, enqueueing packets and calling ifnet.if_start are decoupled o In device drivers, poll->dev_encap_ok->dequeue operation sequence is no longer safe, instead dequeue->dev_encap_fail->prepend should be used This serializer will be held by using lwkt_serialize_adaptive_enter() - Add altq_started field into ifaltq, which is used to interlock the calling of its parent's if_start, to reduce ifnet.if_serializer contention. if_devstart(), a helper function which utilizes ifaltq.altq_started, is added to reduce code duplication in ethernet device drivers. - Add if_cpuid into ifnet. This field indicates on which CPU device driver's interrupt will happen. - Add ifq_dispatch(). This function will try to hold ifnet.if_serializer in order to call ifnet.if_start. If this attempt fails, this function will schedule ifnet.if_start to be called on CPU located by ifnet.if_start_cpuid if_start_nmsg, which is per-CPU netmsg, is added to ifnet to facilitate ifnet.if_start scheduling. ifq_dispatch() is called by ether_output_frame() currently - Use ifq_classic_ functions, if altq is not enabled - Fix various device drivers bugs in their if_start implementation - Add ktr for ifq classic enqueue and dequeue - Add ktr for ifnet.if_start
show more ...
|
#
6d49aa6f |
| 22-Apr-2007 |
Matthew Dillon <dillon@dragonflybsd.org> |
Give the sockbuf structure its own header file and supporting source file. Move all sockbuf-specific functions from kern/uipc_socket2.c into the new kern/uipc_sockbuf.c and move all the sockbuf-speci
Give the sockbuf structure its own header file and supporting source file. Move all sockbuf-specific functions from kern/uipc_socket2.c into the new kern/uipc_sockbuf.c and move all the sockbuf-specific structures from sys/socketvar.h to sys/sockbuf.h.
Change the sockbuf structure to only contain those fields required to properly management a chain of mbufs. Create a signalsockbuf structure to hold the remaining fields (e.g. selinfo, mbmax, etc).
Change the so_rcv and so_snd structures in the struct socket from a sockbuf to a signalsockbuf.
Remove the recently added sorecv_direct structure which was being used to provide a direct mbuf path to consumers for socket I/O. Use the newly revamped sockbuf base structure instead. This gives mbuf consumers direct access to the sockbuf API functions for use outside of a struct socket. This will also allow new API functions to be added to the sockbuf interface to ease the job of parsing data out of chained mbufs.
show more ...
|