summaryrefslogtreecommitdiff
path: root/sys/net/if_ppp.c
AgeCommit message (Collapse)Author
2010-05-02The line-discipline-specific ioctls return -1 to indicate thatStefan Sperling
the non-line-discipline-specific ioctl handler should be tried. So changing these to return ENOTTY was wrong. Noted on misc@ because of resulting pppd log spam (but it didn't break anything serious): http://marc.info/?l=openbsd-misc&m=127258856501621&w=2 ok sthen@, miod@
2010-05-01incomming -> incomingMichael Knudsen
The ones found in gnu/ left out by intention. ok jmc
2010-04-24Make if_ppp and if_sl ioctl handlers return ENOTTY for unsupportedStefan Sperling
ioctls, instead of -1 or EINVAL. ENOTTY audit suggested to me by uwe. ok dlg tedu
2009-11-03rtables are stacked on rdomains (it is possible to have multiple routingClaudio Jeker
tables on top of a rdomain) but until now our code was a crazy mix so that it was impossible to correctly use rtables in that case. Additionally pf(4) only knows about rtables and not about rdomains. This is especially bad when tracking (possibly conflicting) states in various domains. This diff fixes all or most of these issues. It adds a lookup function to get the rdomain id based on a rtable id. Makes pf understand rdomains and allows pf to move packets between rdomains (it is similar to NAT). Because pf states now track the rdomain id as well it is necessary to modify the pfsync wire format. So old and new systems will not sync up. A lot of help by dlg@, tested by sthen@, jsg@ and probably more OK dlg@, mpf@, deraadt@
2009-07-08Add the same routing domain assignments and checks into the not so usedClaudio Jeker
protocols as it is currently in if_ethersubr.c. OK reyk@
2009-03-15Introduce splsoftassert(), similar to splassert() but for soft interruptMiod Vallat
levels. This will allow for platforms where soft interrupt levels do not map to real hardware interrupt levels to have soft ipl values overlapping hard ipl values without breaking spl asserts.
2008-10-22#if INET => #ifdef INETMarco Pfatschbacher
#if INET6 => #ifdef INET6
2008-09-17remove dead stores and newly created unused variables.Charles Longeau
fix potential use of uninitialized value in trunk_port_ioctl() function. Found by LLVM/Clang Static Analyzer. ok mpf@ henning@
2007-09-15malloc sweep:Henning Brauer
-remove useless casts -MALLOC/FREE -> malloc/free -use M_ZERO where appropriate instead of seperate bzero feedback & ok krw, hshoexer
2007-05-26one extern seems to be better than 20 for ifqmaxlen; ok krwJason Wright
2007-04-11Don't use m_prepend() even if it is used mostly correct here.Claudio Jeker
m_prepend() should never be called directly, use M_PREPEND() instead. Doing so simplifies the code. Tested by fkr@ and Paul de Weerd. OK henning@
2006-12-28check if ifqueue has anything queued before doing the dance ofTheo de Raadt
splnet/IF_DEQUEUE/splx; ok various people
2006-03-25allow bpf(4) to ignore packets based on their direction (inbound orDamien Miller
outbound), using a new BIOCSDIRFILT ioctl; guidance, feedback and ok canacar@
2006-03-12remove BPF filter support if the bpfilter device is removed.Brad Smith
2006-03-04With the exception of two other small uncommited diffs this movesBrad Smith
the remainder of the network stack from splimp to splnet. ok miod@
2006-01-04Remove redundant calls to bpfdetach.Can Erkin Acar
ok brad@
2004-06-21First step towards more sane time handling in the kernel -- this changesThorsten Lockert
things such that code that only need a second-resolution uptime or wall time, and used to get that from time.tv_secs or mono_time.tv_secs now get this from separate time_t globals time_second and time_uptime. ok art@ niklas@ nordin@
2004-04-25check for input queue congestion on those as well and call if_congestion whenHenning Brauer
needed; these are slightly different so that we cannot use the new IF_INPUT_ENQUEUE macro deraadt ok
2003-12-16return error in ifc_destroy; ok deraadt, itojun, cedric, hshoexerMarkus Friedl
2003-12-13initial support ifconfig destroy; ok deraadt@Markus Friedl
2003-12-10de-register. deraadt okJun-ichiro itojun Hagino
2003-12-07support ifconfig create; ok deraadtMarkus Friedl
2003-08-15change arguments to suser. suser now takes the process, and a flagsTed Unangst
argument. old cred only calls user suser_ucred. this will allow future work to more flexibly implement the idea of a root process. looks like something i saw in freebsd, but a little different. use of suser_ucred vs suser in file system code should be looked at again, for the moment semantics remain unchanged. review and input from art@ testing and further review miod@
2003-06-02Remove the advertising clause in the UCB license which BerkeleyTodd C. Miller
rescinded 22 July 1999. Proofed by myself and Theo.
2003-05-03string fixes; tedu okTheo de Raadt
2003-02-12Remove commons; inspired by netbsd.Jason Wright
2003-01-07remove the altq classifier code which is replaced by pf and no longer used.Kenjiro Cho
ok henning@, deraadt@
2002-07-01license update of CMU parts. due to communication with wcw+@andrew.cmu.edu,Theo de Raadt
pushed for by tygs@netcologne.de. Apparently we also now known how to talk to the lawyers there, if we were so mad. Note that a few other copyright issues in pppd still remain, so this does not close this story.
2002-06-30allocate sockaddr_dl for ifnet in if_alloc_sadl(), as we don't always knowJun-ichiro itojun Hagino
the size of sockaddr_dl on if_attach() - for instance, see ether_ifattach(). from netbsd. fgs ok
2002-06-19this was derived from UCB if_sl. therefore, we can update the UCB if_slTheo de Raadt
copyright contained in this. a license problem remains, of course...
2002-06-11sprinkle splasserts where function comments tell us to.Artur Grabowski
2002-03-14First round of __P removal in sysTodd C. Miller
2002-02-13sync with KAME.Kenjiro Cho
make altq actually work with kernl ppp. add if_start for the altq case to kick transmission. don't call ppp_restart() to prevent useless interrupt loop under rate-limiting.
2001-09-16Add some missing lengths checks when passing data from userland toTodd C. Miller
kernel. From based on NetBSD patches.
2001-07-20use a variable, not it's default value from constantMichael Shalayeff
2001-06-27introduce the ALTQ queue macros into sys/net files.Kenjiro Cho
the new model removes direct references to the fields in ifp->if_snd, and defines the following macros to manipulate ifp->if_snd. IFQ_ENQUEUE(ifq, m, pktattr, err) IFQ_DEQUEUE(ifq, m) IFQ_POLL(ifq, m) IFQ_PURGE(ifq) IFQ_IS_EMPTY(ifq) the new model also enforces some rules regarding how to use these macros. details are descrined in http://www.csl.sony.co.jp/~kjc/software/altq-new-design.txt
2001-06-27Get rid of M_COPY_* macros; either use M_MOVE_* or M_DUP_*, dependingAngelos D. Keromytis
on how macros should be treated. Code by fgsch@, ok by me and itojun@
2001-06-25Move common post M_COPY_HDR manipulation to the macro itself; angelos@ ok.Federico G. Schwindt
2001-06-15change the meaning of ifnet.if_lastchange to meet RFC1573 ifLastChange.Jun-ichiro itojun Hagino
follows BSD/OS practice and ucd-snmp code (FreeBSD does it for specific interfaces only). was: if_lastchange get updated on every packet transmission/receipt. now: if_lastchange get updated when IFF_UP is changed.
2001-05-28Copy the packet header only if the original mbuf had a packet headerAngelos D. Keromytis
(just general paranoia).
2001-05-27Fixup tags on old mbuf chain head.Angelos D. Keromytis
2001-05-16No need to check M_WAIT/M_WAITOK malloc return values. (art@ ok)Hakan Olsson
2000-03-21add SIOCGIFMTU/SIOCSIFMTU; remediate redundant code of tun, ppp, sppp; chris@ okMichael Shalayeff
1999-12-08bring in KAME IPv6 code, dated 19991208.Jun-ichiro itojun Hagino
replaces NRL IPv6 layer. reuses NRL pcb layer. no IPsec-on-v6 support. see sys/netinet6/{TODO,IMPLEMENTATION} for more details. GENERIC configuration should work fine as before. GENERIC.v6 works fine as well, but you'll need KAME userland tools to play with IPv6 (will be bringed into soon).
1998-07-12Remove the NPMODE_KEEPLAST defs; they're not really necessary. Also,Angelos D. Keromytis
sync with NetBSD (the recent splhigh->splimp changes).
1998-07-01Add NPMODE_KEEPLAST conditions; not supported yet (act like NPMODE_QUEUE).Angelos D. Keromytis
1998-05-08Add support for RFC-comliant deflate protocolTodd C. Miller
1997-09-05Minor changes from ppp 2.3.1Todd C. Miller
1997-01-02PPP_BSDCOMP not PPP_BSD_COMPMichael Shalayeff
1996-12-19sync to 2.3b3Michael Shalayeff