| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
ok dlg@ tobhe@
|
|
|
|
|
|
| |
"new" API.
ok dlg@ tobhe@
|
|
|
|
| |
ok mpi@
|
|
|
|
|
|
|
| |
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@
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
there are two things shared between the network stack and drivers
in the send path: the send queue and the IFF_OACTIVE flag. the send
queue is now protected by a mutex. this diff makes the oactive
functionality mpsafe too.
IFF_OACTIVE is part of if_flags. there are two problems with that.
firstly, if_flags is a short and we dont have any MI atomic operations
to manipulate a short. secondly, while we could make the IFF_OACTIVE
operates mpsafe, all changes to other flags would have to be made
safe at the same time, otherwise a read-modify-write cycle on their
updates could clobber the oactive change.
instead, this moves the oactive mark into struct ifqueue and provides
an API for changing it. there's ifq_set_oactive, ifq_clr_oactive,
and ifq_is_oactive. these are modelled on ifsq_set_oactive,
ifsq_clr_oactive, and ifsq_is_oactive in dragonflybsd.
this diff includes changes to all the drivers manipulating IFF_OACTIVE
to now use the ifsq_{set,clr_is}_oactive API too.
ok kettenis@ mpi@ jmatthew@ deraadt@
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
firstly, this checks for space in the tx ring before looking at the
send queue. if there's no space, then IFF_OACTIVE is set and break.
if there's space use IFQ_DEQUEUE to pull a packet off. if we fail
to encapsulate it, it gets dropped.
encap has been changed so the dmamaps the mbufs are loaded into are
created with 7 segments instead of 32. this means we detect when
the packet would overflow the tx descriptor at dmamap load time,
rather than after we've looped over the segments writing them into
the descriptor. we now use m_defrag to defrag the mbuf instead of
allocating a new one and using m_copydata.
now if we have any encap error on the first mbuf, we no longer set
IFF_OACTIVE and wait for an interrupt that never comes to clear it.
testing and (excellent) code review by richard proctor
|
|
|
|
|
|
| |
Because of the VLAN hacks in mpw(4) this file still contains the definition
of "struct ifvlan" which depends on <sys/refcnt.h> which in turns pull
<sys/atomic.h>...
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This changes numbers of the SIOCSIFMEDIA and SIOCGIFMEDIA ioctls and
grows struct ifmediareq.
Old ifconfig and dhclient binaries can still assign addresses, however
the 'media' subcommand stops working. Recompiling ifconfig and dhclient
with new headers before a reboot should not be necessary unless in very
special circumstances where non-default media settings must be used to
get link and console access is not available.
There may be some MD fallout but that will be cleared up later.
ok deraadt miod
with help and suggestions from several sharks attending l2k15
|
|
|
|
|
|
|
| |
Note that pseudo-drivers not using if_input() are not affected by this
conversion.
ok mikeb@, kettenis@, claudio@, dlg@
|
|
|
|
|
|
|
|
|
|
|
|
| |
there's no need to do it in m_devget(9).
Stop passing an ``ifp'' will help for upcoming interface pointer -> index
conversion.
While here remove unused ``ifp'' argument from m_clget(9) and kill two
birds^W layer violations in one commit.
ok henning@
|
|
|
|
| |
ok dlg@
|
|
|
|
|
|
|
| |
have any direct symbols used. Tested for indirect use by compiling
amd64/i386/sparc64 kernels.
ok tedu@ deraadt@
|
| |
|
| |
|
|
|
|
|
|
|
|
|
| |
alternative to bcopy since noone uses it.
while there use memcpy instead of bcopy because we know the memory cannot
overlap.
ok henning@ matthew@ mikeb@ deraadt@
|
|
|
|
|
| |
don't have to. Just remove these include lines.
Compiled on amd64 i386 sparc64; OK henning@ mikeb@
|
|
|
|
| |
ok sthen@
|
|
|
|
|
|
| |
Tested with PCI and PCIe vge(4).
ok sthen@
|
|
|
|
|
|
| |
necessarily correct, there might not even be a link when attaching.
ok mikeb@ reyk@
|
|
|
|
| |
OK reyk@ sthen@
|
| |
|
|
|
|
| |
ok claudio krw
|
|
|
|
| |
ok claudio@
|
|
|
|
| |
ok deraadt@ henning@ claudio@
|
|
|
|
|
|
|
| |
EEPROM exist (RouterBOARD RB600A) and reloading default values from the
EEPROM will fail on those decives.
ok deraadt@
|
|
|
|
| |
ok jsg@, deraadt@
|
|
|
|
|
|
| |
from the EEPROM.
ok miod@
|
|
|
|
| |
ok dlg@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
from the individual drivers now that ether_ioctl() handles this.
Shrinks the i386 kernels by..
RAMDISK - 2176 bytes
RAMDISKB - 1504 bytes
RAMDISKC - 736 bytes
Tested by naddy@/okan@/sthen@/brad@/todd@/jmc@ and lots of users.
Build tested on almost all archs by todd@/brad@
ok naddy@
|
|
|
|
|
|
|
|
|
| |
creates the VLAN encapsulation from the tag stored in the mbuf
header. Idea from FreeBSD, input from claudio@ and canacar@.
Switch all hardware VLAN enabled drivers to the new function.
ok claudio@
|
|
|
|
| |
Tested by Dawe <dawedawe at gmx dot de>
|
|
|
|
|
|
|
|
|
|
|
| |
now the offset into the first mbuf of the target chain before copying
the source data over. From FreeBSD.
Convert drivers' use of m_devget(). Mostly from thib@.
Update mbuf(9) man page.
ok claudio@, thib@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Move calling ether_ioctl() from the top of the ioctl function, which
at the moment does absolutely nothing, to the default switch case.
Thus allowing drivers to define their own ioctl handlers and then
falling back on ether_ioctl(). The only functional change this results
in at the moment is having all Ethernet drivers returning the proper
errno of ENOTTY instead of EINVAL/ENXIO when encountering unknown
ioctl's.
Shrinks the i386 kernels by..
RAMDISK - 1024 bytes
RAMDISKB - 1120 bytes
RAMDISKC - 832 bytes
Tested by martin@/jsing@/todd@/brad@
Build tested on almost all archs by todd@/brad@
ok jsing@
|
|
|
|
|
|
|
| |
Really just the low-hanging fruit of (hopefully) forthcoming timeout
conversions.
ok art@, krw@
|
|
|
|
| |
ok claudio
|
|
|
|
|
|
|
|
| |
state reporting code in the MII layer / em(4) and vge(4) will never
fall back to the point of only reporting the link as being UP without
the duplex setting being reported, so simplify the code a bit here.
ok dlg@
|
|
|
|
|
|
|
|
| |
- Remove setup of the HW VLAN stripping.
Issue reported by and fix tested by henric@
ok dlg@
|
|
|
|
| |
ok claudio@
|
|
|
|
| |
ok reyk@
|
|
|
|
| |
ok brad@
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
if the mbuf is coalesced in vge_encap(), the mbuf reference is no
longer valid. drop the mbuf in this case.
bug introduced in r1.28
tested by Frank Denis
fixes kernel/5291
"go for it" deraadt@
|
|
|
|
| |
ok jsg@
|
|
|
|
|
|
|
| |
use IFQ_POLL()/IFQ_DEQUEUE() logic instead as described in altq(4).
tested by jolan@ on macppc
"diffs look ok" brad@
|
|
|
|
| |
tested by jolan@, ok brad@
|
| |
|
|
|
|
|
|
| |
but it seems Jumbo support is broken, so disable Jumbos for now.
issue reported by jolan@
|