#
b272101a |
| 30-Oct-2023 |
Aaron LI <aly@aaronly.me> |
Various minor whitespace cleanups
Accumulated along the way.
|
#
fb1dde20 |
| 10-Nov-2023 |
Aaron LI <aly@aaronly.me> |
kernel: No need to handle mbuf allocation failures if use M_WAITOK
|
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, 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, v5.2.0, v5.3.0, v5.2.0rc |
|
#
8dedb1a7 |
| 04-Feb-2018 |
zrj <rimvydas.jasinskas@gmail.com> |
kernel/net: Remove use of "%b" format.
Switch to args safe "%pb%i" internal format.
Note: the if_nfe.c used 0x%4b format, while %b was not handling the width.
|
Revision tags: v5.0.2, v5.0.1, v5.0.0, v5.0.0rc2, v5.1.0, v5.0.0rc1, v4.8.1, v4.8.0, v4.6.2, v4.9.0, v4.8.0rc, v4.6.1, v4.6.0, v4.6.0rc2, v4.6.0rc, v4.7.0, v4.4.3, v4.4.2, v4.4.1, v4.4.0, v4.5.0, v4.4.0rc, v4.2.4, 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, v3.6.2, v3.6.1, v3.6.0, v3.7.1, v3.6.0rc, v3.7.0 |
|
#
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 |
|
#
d3c9c58e |
| 20-Feb-2013 |
Sascha Wildner <saw@online.de> |
kernel: Use DEVMETHOD_END in the drivers.
|
#
07e9f7c0 |
| 09-Jan-2013 |
Sascha Wildner <saw@online.de> |
kernel: Remove some more unused variables in the network drivers.
|
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 |
|
#
4090d6ff |
| 03-Jan-2012 |
Sascha Wildner <saw@online.de> |
kernel: Use NULL for pointers.
|
#
884717e1 |
| 06-Dec-2011 |
Sascha Wildner <saw@online.de> |
kernel: Replace all usage of MALLOC()/FREE() with kmalloc()/kfree().
|
#
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 |
|
#
aa2b9d05 |
| 24-Jun-2011 |
Sascha Wildner <saw@online.de> |
kernel: Use NULL for DRIVER_MODULE()'s evh & arg (which are pointers).
This is just cosmetics for easier reading.
|
Revision tags: 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, v2.2.0, v2.3.0, v2.1.1, v2.0.1 |
|
#
95893fe4 |
| 17-Aug-2008 |
Sepherosa Ziehau <sephe@dragonflybsd.org> |
Nuke INTR_NETSAFE
|
#
f15ba1a8 |
| 03-Jun-2007 |
Matthew Dillon <dillon@dragonflybsd.org> |
Catch up a bit with FreeBSD netgraph by replacing *LEN constants with *SIZ constants which already account space for trailing '\0's.
Submitted-by: "Nuno Antunes" <nuno.antunes@gmail.com> Obtained fr
Catch up a bit with FreeBSD netgraph by replacing *LEN constants with *SIZ constants which already account space for trailing '\0's.
Submitted-by: "Nuno Antunes" <nuno.antunes@gmail.com> Obtained from: FreeBSD (sorta).
show more ...
|
#
e3869ec7 |
| 22-Dec-2006 |
Sascha Wildner <swildner@dragonflybsd.org> |
Rename printf -> kprintf in sys/ and add some defines where necessary (files which are used in userland, too).
|
#
f8c7a42d |
| 20-Dec-2006 |
Matthew Dillon <dillon@dragonflybsd.org> |
Rename sprintf -> ksprintf Rename snprintf -> knsprintf
Make allowances for source files that are compiled for both userland and the kernel.
|
#
1f7ab7c9 |
| 25-Oct-2006 |
Matthew Dillon <dillon@dragonflybsd.org> |
Do a major clean-up of the BUSDMA architecture. A large number of essentially machine-independant drivers use the structures and definitions in machine-dependant directories that are really machine-
Do a major clean-up of the BUSDMA architecture. A large number of essentially machine-independant drivers use the structures and definitions in machine-dependant directories that are really machine-independant in nature.
Split <machine/bus_dma.h> into machine-depdendant and machine-independant parts and make the primary access run through <sys/bus_dma.h>.
Remove <machine/bus.h>, <machine/bus_memio.h> and <machine/bus_pio.h>. The optimizations related to bus_memio.h and bus_pio.h made a huge mess, introduced machine-specific knowledge into essentially machine-independant drivers, and required specific #include file orderings to do their job. They may be reintroduced in some other form later on.
Move <machine/resource.h> to <sys/bus_resource.h>. The contents of the file is machine-independant or can be made a superset across many platforms.
Make <sys/bus.h> include <sys/bus_dma.h> and <sys/bus_resource.h> and include <sys/bus.h> where necessary. Remove all #include's of <machine/resource.h> and <machine/bus.h>. That is, make the BUSDMA infrastructure integral to I/O-mapped and memory-mapped accesses to devices and remove a large chunk of machine-specific dependancies from drivers. bus_if.h and device_if.h are now required to be present when using <sys/bus.h>.
show more ...
|
#
77652cad |
| 05-Sep-2006 |
Matthew Dillon <dillon@dragonflybsd.org> |
Rename malloc->kmalloc, free->kfree, and realloc->krealloc. Pass 2
|
#
efda3bd0 |
| 05-Sep-2006 |
Matthew Dillon <dillon@dragonflybsd.org> |
Rename malloc->kmalloc, free->kfree, and realloc->krealloc. Pass 1
|
#
78195a76 |
| 28-Nov-2005 |
Matthew Dillon <dillon@dragonflybsd.org> |
Make all network interrupt service routines MPSAFE part 1/3.
Replace the critical section that was previously used to serialize access with the LWKT serializer. Integrate the serializer into the IF
Make all network interrupt service routines MPSAFE part 1/3.
Replace the critical section that was previously used to serialize access with the LWKT serializer. Integrate the serializer into the IFNET structure. Note that kern.intr_mpsafe must be set to 1 for network interrupts to actually run MPSAFE. Also note that any interrupts shared with othre non-MP drivers will cause all drivers on that interrupt to run with the Big Giant Lock.
Network interrupt - Each network driver then simply passes that serializer to bus_setup_intr() so only a single serializer is required to process the entire interrupt path. LWKT serialization support is already 100% integrated into the interrupt subsystem so it will already be held as of when the registered interrupt procedure is called.
Ioctl and if_* functions - All callers of if_* functions (such as if_start, if_ioctl, etc) now obtain the IFNET serializer before making the call. Thus all of these entry points into the driver will now be serialized.
if_input - All code that calls if_input now ensures that the serializer is held. It will either already be held (when called from a driver), or the serializer will be wrapped around the call. When packets are forwarded or bridged between interfaces, the target interface serializer will be dropped temporarily to avoid a deadlock.
Device Driver access - dev_* entry points into certain pseudo-network devices now obtain and release the serializer. This had to be done on a device-by-device basis (but there are only a few such devices).
Thanks to several people for helping test the patch, in particular Sepherosa Ziehau.
show more ...
|
#
ee61f228 |
| 12-Oct-2005 |
Matthew Dillon <dillon@dragonflybsd.org> |
Remove the INTR_TYPE_* flags. The interrupt type is no longer used to figure out which spl*() set an interrupt belongs to, because, well, spl's no longer exist.
|
#
e9cb6d99 |
| 24-May-2005 |
Matthew Dillon <dillon@dragonflybsd.org> |
Get rid of bus_{disable,enable}_intr(), it wasn't generic enough for our needs.
Implement some generic atomic.h functions to aid in the implementation of a low level mutex.
Implement a generic low
Get rid of bus_{disable,enable}_intr(), it wasn't generic enough for our needs.
Implement some generic atomic.h functions to aid in the implementation of a low level mutex.
Implement a generic low level sleep-mutex serializer, kern/lwkt_serialize.c. The serializer is designed to be a replacement for SPL calls but may also be used for other very low level work (e.g. lockmgr interlocks).
Add a serializer argument to BUS_SETUP_INTR(). When non-NULL, the interrupt handler will no longer be protected by an SPL so e.g. spl*() will no longer protect against that device's interrupts.
The IF queueing and dequeueing mechanisms may no longer depend on outside SPL state because network driver interrupt handlers are no longer required to enter splnet(). Use critical sections for the moment. The IFQ and IFF_OACTIVE interactions are not yet MP safe.
show more ...
|
#
4e6d744d |
| 24-May-2005 |
Joerg Sonnenberger <joerg@dragonflybsd.org> |
Use bus_alloc_resource_any when possible.
|
#
992380b8 |
| 14-Sep-2004 |
Joerg Sonnenberger <joerg@dragonflybsd.org> |
Remove dead code which depends on timeout interface.
|
#
74f1caca |
| 02-Jun-2004 |
Eirik Nygaard <eirikn@dragonflybsd.org> |
Change mbug allocation flags from M_ to MB_ to avoid confusion with malloc flags.
Requested by: Jeffrey Hsu
|
#
c5541aee |
| 07-Apr-2004 |
Matthew Dillon <dillon@dragonflybsd.org> |
General netif malloc() flags cleanup. Use M_INTWAIT or M_WAITOK instead of M_NOWAIT. Generally use M_WAITOK in the attach code or ioctl code typically called from userland, and M_INTWAIT for routin
General netif malloc() flags cleanup. Use M_INTWAIT or M_WAITOK instead of M_NOWAIT. Generally use M_WAITOK in the attach code or ioctl code typically called from userland, and M_INTWAIT for routines that might be called during non-boot operations. Since M*WAIT flags guarentee a non-NULL result, also remove now-unnecessary NULL checks.
show more ...
|