summaryrefslogtreecommitdiff
path: root/sys/net
AgeCommit message (Collapse)Author
2017-01-23Kill unecessary splsoftnet()/splx() dances, what's protecting radixMartin Pieuchot
globals is the KERNEL_LOCK(). ok claudio@
2017-01-23i botched the copyout to ifr->ifr_data in SIOCGIFDATA.David Gwynne
this lets pflogd run again. rename if_data() to if_getdata() while here to make grepping for things less noisy. reported by jsg@ worked through with deraadt@
2017-01-23merge the ifnet and ifqueue stats together when userland wants them.David Gwynne
a new if_data() function takes a pointer to ifnet and merges its if_data and ifq statistics. it takes the ifq mutex around the reads of the ifq stats so they get a consistent copy. the ifnet and ifq stats are merged because some parts of the stack still update the ifnet counters. ok visa@ (on an earlier diff) mpi@ claudio@
2017-01-23Make the art interface a bit more generic by not depending on sockaddrClaudio Jeker
in the functions. This way it can be used for other trees as well. OK mpi@ phessler@
2017-01-23Add comment above rtm_type #define's.Kenneth R Westerback
2017-01-23Add comment above rtm_flags #define's.Kenneth R Westerback
2017-01-23Typo in comment. It's 'rtm_addrs', not 'rtm_addr'Kenneth R Westerback
2017-01-23Zap some bad whitespace.Kenneth R Westerback
2017-01-22move counting if_opackets next to counting if_obytes in if_enqueue.David Gwynne
this means packets are consistently counted in one place, unlike the many and various ways that drivers thought they should do it. ok mpi@ deraadt@
2017-01-22white space fixes. no functional change.David Gwynne
2017-01-22Cleanup error handling. Do not use 'goto flush' early on since the messageClaudio Jeker
is actually not syntactically valid, call 'goto fail' instead. Remove unneeded rtable_exists() exists checks since those have been done early on. OK mpi@
2017-01-22Zap some bad whitespace.Kenneth R Westerback
2017-01-22set the TOS/ECN field to Internetwork Control, since that is exactlyPeter Hessler
what we are doing
2017-01-21sockets tell us the size of their data. since we want one udp packet,Peter Hessler
just use that. uses one less soreceive() loop per packet received. hints from claudio@
2017-01-21be more explict with the size of bfd packets we send and receivePeter Hessler
2017-01-21remove some extra whitespace.David Gwynne
no functional change (unfortunately)
2017-01-21Change route_input to a non-variadic function and just pass the addressClaudio Jeker
family to it. Simplifies the code and disconnects route_input from protosw. The rouing socket is special so no need to try to work like other protos. With input from bluhm@, OK mpi@
2017-01-21Make the if_flags member unsigned. This was prompted by clangPatrick Wildt
complaining that assigning the MULTICAST flag, which sets the uppermost bit, would invert the meaning of MULTICAST flag's numeric value. ok claudio@ deraadt@ tom@ visa@
2017-01-20if a route is not valid, set down instead of admindownPeter Hessler
2017-01-20fix typoPeter Hessler
2017-01-20don't increase the error counter in the not-down case, in generalPeter Hessler
2017-01-20only increase the error counter if we are in a not-down statePeter Hessler
2017-01-20correctly set our rx timer to be the required minimum, not the barePeter Hessler
minimum the neighbor supports
2017-01-20use per-cpu counters for rtstat.David Gwynne
ok mpi@
2017-01-20Stop using pfsockaddr_union outside of pf so that we can remove its usageClaudio Jeker
inside pf later on. pfsync can use the one from ip_ipsp.h and bridge can have its own version for now. OK mpi@ phessler@
2017-01-20pfsync_update_net_tdb() is only called at IPL_SOFTNET, no need for aMartin Pieuchot
splsofnet()/splx() dance. Tested by Hrvoje Popovski, ok visa@
2017-01-20keep output packet counters on the ifq structure.David Gwynne
these copy what is counted on the output path on the ifnet struct, except ifq counts both packets and bytes when a packet is queued instead of just the bytes. all the counters are protected by the ifq mutex except for ifq_errors, which can be updated safely from inside a start routine because the ifq machinery serialises them. ok mpi@
2017-01-20No need to handle SIOCAIFADDR in drivers, it's never passed down toMartin Pieuchot
them. ok claudio@
2017-01-19add hooks so we can query the current state of a BFD sessionPeter Hessler
bfd session details are visible with "route -n get 192.0.2.1 -bfd" OK mpi@ deraadt@ claudio@
2017-01-19Do not return an error code for SIOCSIFFLAGS.Martin Pieuchot
This synchronize lo(4) with other pseudo-driver and fix a regression introduced by the refactoring of the UP/DOWN logic in if.c ok dlg@, claudio@
2017-01-19when parsing a BFD packet, avoid an uninitialized variable if thePeter Hessler
version check fails found by jsg@ with clang
2017-01-19make error handling a function, and use it in a few placesPeter Hessler
not all error handling is converted, some require a bit more thought
2017-01-19rtisvalid() checks for RTF_UP, so instead check for RTF_BFDPeter Hessler
2017-01-19when deconfiguring a BFD session, clear both the RTF_BFD flag on thePeter Hessler
route, and the pointer to the route bfd uses
2017-01-19remove the BFD flag on a route *before* we actually delete the routePeter Hessler
should fix a panic reported by Hrvoje Popovski
2017-01-19use a space instead of a tab, for consistancyPeter Hessler
requested by and OK mpi@
2017-01-18Allow changing of sender ip/port without switching address family.Florian Obser
With this regress tests pass again. OK benno
2017-01-18Allow changing of receiver ip/port without switching address family.Florian Obser
OK benno
2017-01-17Make switch(4) compile with debug again.Rafael Zalamena
2017-01-17Initialize swas_actions for set-field with the expected pointer to theRafael Zalamena
swpld_set_fields vector. This makes write-action work with set-field actions.
2017-01-17Fix a panic when set-field with VLAN is set, but no VLANs wereRafael Zalamena
classified in the packet.
2017-01-17Clean-up switch(4) device by removing excess prototypes, verbose debugsRafael Zalamena
and unused functions. ok reyk@
2017-01-17Add more action specific validations, unbreak instructions validationRafael Zalamena
with multiple actions and add more error reports with what went wrong.
2017-01-16Fix declaration: vsw_dev2sc has been renamed to switch_dev2sc.Reyk Floeter
2017-01-16spacingReyk Floeter
2017-01-16Add missing declarations found with -Wmissing-declarationsReyk Floeter
2017-01-16The term "pipline" is used in many places, rename it to pipeline.Reyk Floeter
It was either a typo or a funny abbreviation. OK rzalamena@
2017-01-16Removed unused function that is a leftover from the old debug code.Reyk Floeter
OK rzalamena@
2017-01-13Remove recursive splsoftnet() but use splsoftassert() instead.Martin Pieuchot
Tested by Hrvoje Popovski, ok bluhm@
2017-01-12Remove unneeded splsoftnet().Martin Pieuchot
Global data structures are protected by the KERNEL_LOCK() and route_input() already raises the IPL when it needs it. ok phessler@