summaryrefslogtreecommitdiffstats
path: root/sys/net/if_atmsubr.c
Commit message (Collapse)AuthorAgeFilesLines
* clean up en atm driverkjc1999-05-081-289/+7
| | | | | | | | | | | | | o fix DDB support - include "opt_ddb.h" - fix Debugger() arg pointed out by bde o back out pvc shadow interface support - it is currently not used - to make it easier to merge another implementation o misc minor cleanup
* Examine all occurrences of sprintf(), strcat(), and str[n]cpy()archie1998-12-041-2/+4
| | | | | | | | | | | | | | for possible buffer overflow problems. Replaced most sprintf()'s with snprintf(); for others cases, added terminating NUL bytes where appropriate, replaced constants like "16" with sizeof(), etc. These changes include several bug fixes, but most changes are for maintainability's sake. Any instance where it wasn't "immediately obvious" that a buffer overflow could not occur was made safer. Reviewed by: Bruce Evans <bde@zeta.org.au> Reviewed by: Matthew Dillon <dillon@apollo.backplane.com> Reviewed by: Mike Spengler <mks@networkcs.com>
* update ATM driver. (base version: midway.c 1.67 --> 1.68)kjc1998-07-291-128/+355
| | | | | | | | | | | | | | | | | | | | | | | several new features are added: - support vc/vp shaping - support pvc shadow interface code cleanup: - remove WMAYBE related code. ENI WMAYBE DMA doen't work. - remove updating if_lastchange for every packet. - BPF related code is moved to midway.c as it should be. (bpfwrite should work if atm_pseudohdr and LLC/SNAP are prepended.) - BPF link type is changed to DLT_ATM_RFC1483. BPF now understands only LLC/SNAP!! (because bpf can't handle variable link header length.) It is recommended to use LLC/SNAP instead of NULL encapsulation for various reasons. (BPF, IPv6, interoperability, etc.) the code has been used for months in ALTQ and KAME IPv6. OKed by phk long time ago.
* Eradicate the variable "time" from the kernel, using various measures.phk1998-03-301-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | "time" wasn't a atomic variable, so splfoo() protection were needed around any access to it, unless you just wanted the seconds part. Most uses of time.tv_sec now uses the new variable time_second instead. gettime() changed to getmicrotime(0. Remove a couple of unneeded splfoo() protections, the new getmicrotime() is atomic, (until Bruce sets a breakpoint in it). A couple of places needed random data, so use read_random() instead of mucking about with time which isn't random. Add a new nfs_curusec() function. Mark a couple of bogosities involving the now disappeard time variable. Update ffs_update() to avoid the weird "== &time" checks, by fixing the one remaining call that passwd &time as args. Change profiling in ncr.c to use ticks instead of time. Resolution is the same. Add new function "tvtohz()" to avoid the bogus "splfoo(), add time, call hzto() which subtracts time" sequences. Reviewed by: bde
* Make POWERFAIL_NMI, PPS_SYNC and NATM new style options.eivind1998-01-311-0/+1
| | | | This also fixes a couple of defunct options; submitted by bde.
* Make INET a proper option.eivind1998-01-081-0/+2
| | | | | | | | | | | | This will not make any of object files that LINT create change; there might be differences with INET disabled, but hardly anything compiled before without INET anyway. Now the 'obvious' things will give a proper error if compiled without inet - ipx_ip, ipfw, tcp_debug. The only thing that _should_ work (but can't be made to compile reasonably easily) is sppp :-( This commit move struct arpcom from <netinet/if_ether.h> to <net/if_arp.h>.
* Use gettime() instead of assignment from `time'. (`time' is toobde1997-11-181-3/+2
| | | | | | | | volatile to use outside of splclock(). microtime() is probably too expensive to use for every i/o. However, setting ifi_lastchange for every i/o is just wrong according to the comment about ifi_lastchange in <net/if.h>. It is set then for atm, fddi and the latest version of ppp.)
* Removed unused #includes.bde1997-08-021-12/+0
|
* import Chuck Cranor's ATM driverkjc1997-05-091-0/+410
OpenPOWER on IntegriCloud