summaryrefslogtreecommitdiffstats
path: root/sys/net
Commit message (Collapse)AuthorAgeFilesLines
* Don't make_dev() in bpfopen() unless we need to.phk2000-10-091-2/+3
|
* make sure we have root priv on SIOCSIFPHY*. from thorpej@netbsditojun2000-10-041-0/+5
|
* Properly setup link level header length for 802.2 and SNAP frames.bp2000-09-302-6/+9
|
* Handle slip options in the usual way (generate a dummy options file inbde2000-09-261-2/+1
| | | | | | the module Makefile and don't clutter the sources with ifdefs). Fixed nearby formatting bugs.
* Removed unused includes (garbage left over/created by the SMPng megacommit).bde2000-09-261-6/+0
|
* In theory, m_dup should not be necessary, as m_copypacket should bensayer2000-09-251-3/+3
| | | | | | | | | | | | sifficient. But somewhere (I believe in the UDP stuff), someone is overwriting an mbuf without calling m_pullup() first. This results in broad- and multi-cast traffic that is passed through the bridge getting corrupted. This should be backed out when there is some assurance that the upper layers (and I suppose all of the device drivers) are fixed. Suggested by: archie
* Get rid of a panic that occurs in ether_demux() by dereferencing a NULL mbufbmilekic2000-09-242-1/+12
| | | | | | | | | pointer, when bridging and bridge_ipfw are enabled, and when bdg_forward() happens to free the packet and make our pointer NULL. There may be more similar problems like this one with calls to bdg_forward(). PR: Related to kern/19551 Reviewed by: jlemon
* Rename lminor() to dev2unit(). This function gives a linear unit numberphk2000-09-193-7/+9
| | | | | | | | | | | | which hides the 'hole' in the minor bits. Introduce unit2minor() to do the reverse operation. Fix some some make_dev() calls which didn't use UID_* or GID_* macros. Kill the v_hashchain alias macro, it hides the real relationship. Introduce experimental SI_CHEAPCLONE flag set it on cloned bpfs.
* Call bpfattach() correctly from if_ppp.cbrian2000-09-161-0/+5
| | | | | Submitted by: Andy Adams <ala@merit.edu> PR: 18506
* Follow BSD/OS and NetBSD, keep the ip_id field in network order all the time.ru2000-09-141-2/+0
| | | | Requested by: wollman
* Major update to the way synchronization is done in the kernel. Highlightsjasone2000-09-071-21/+2
| | | | | | | | | | | | | | | include: * Mutual exclusion is used instead of spl*(). See mutex(9). (Note: The alpha port is still in transition and currently uses both.) * Per-CPU idle processes. * Interrupts are run in their own separate kernel threads and can be preempted (i386 only). Partially contributed by: BSDi (BSD/OS) Submissions by (at least): cp, dfr, dillon, grog, jake, jhb, sheldonh
* o Add missing "\n" to warning output in netinet/if_loop.c, when anrwatson2000-09-041-1/+1
| | | | | | | | | unsupported address family is used on localhost interface. looutput: af=0 unexpected Speculation as to the reasons for my seeing this error are welcome, of course. :-)
* Avoid the modules madness I inadvertently introduced by making thephk2000-09-022-27/+4
| | | | | | | | | | | | | | | | | | cloning infrastructure standard in kern_conf. Modules are now the same with or without devfs support. If you need to detect if devfs is present, in modules or elsewhere, check the integer variable "devfs_present". This happily removes an ugly hack from kern/vfs_conf.c. This forces a rename of the eventhandler and the standard clone helper function. Include <sys/eventhandler.h> in <sys/conf.h>: it's a helper #include like <sys/queue.h> Remove all #includes of opt_devfs.h they no longer matter.
* Remove all traces of Julians DEVFS (incl from kern/subr_diskslice.c)phk2000-08-202-0/+66
| | | | | | | | | | | | | | | | | | | | | | | | | | | Remove old DEVFS support fields from dev_t. Make uid, gid & mode members of dev_t and set them in make_dev(). Use correct uid, gid & mode in make_dev in disk minilayer. Add support for registering alias names for a dev_t using the new function make_dev_alias(). These will show up as symlinks in DEVFS. Use makedev() rather than make_dev() for MFSs magic devices to prevent DEVFS from noticing this abuse. Add a field for DEVFS inode number in dev_t. Add new DEVFS in fs/devfs. Add devfs cloning to: disk minilayer (ie: ad(4), sd(4), cd(4) etc etc) md(4), tun(4), bpf(4), fd(4) If DEVFS add -d flag to /sbin/inits args to make it mount devfs. Add commented out DEVFS to GENERIC
* The slip driver used to allocate a mbuf cluster without attachingdwmalone2000-08-182-9/+22
| | | | | | | | | | it to a mbuf. This patch makes it attach it to mbuf. This patch is in preperation for Bosko Milekic's mbuf external reference counting patches. PR: 19866 (first stage) Submitted by: Ian Dowse <iedowse@maths.tcd.ie> Reviewed by: alfred
* repair endianness issue in IN_MULTICAST().itojun2000-08-152-3/+7
| | | | | | again, *BSD difference... From: Nick Sayer <nsayer@quack.kfu.com>
* Export the functionality of SIOCSIFLLADDR with if_setlladdr()archie2000-08-152-25/+51
| | | | | | and add some more rigorous sanity checking in the process. Reviewed by: freebsd-net
* Change the argument for SIOCG80211NWID/SIOCS80211NWID to include theonoe2000-08-141-3/+25
| | | | | | | length of NWID. This breaks binary compatibility but only the awi driver refers this ioctl; no userland tools refers it. Add WEP stuff. Obtained from: NetBSD current
* Replace nonexistent !defined(_LKM) by !defined(KLD_MODULE)ache2000-08-011-1/+1
|
* Check IPFILTER (options IPFILTER generates) instead of NIPFILTERache2000-08-011-2/+2
|
* Nonexistent "ipfilter.h" -> "opt_ipfilter.h"ache2000-07-311-1/+1
| | | | Kernel 'make depend' fails otherwise
* Make the bridge_refresh operation automatic when ethernet interfacesnsayer2000-07-293-1/+14
| | | | are attached or detached.
* Fix if_types.h as per the IANA assignments with regard to IPv6.asmodai2000-07-281-4/+8
| | | | | | | | | | | | | | | gif/faith/stf moved to 0xfN entries, since their previous location is allocated to some other interfaces. Also add the IFT_PVC, which is the ATM PVC subinterface from ALTQ. This also syncs us up a bit to NetBSD again. This change requires a total recompilation of all kmem users, as itojun told me. Next in line is synching to the IANI SMI list. Approved by: itojun
* Change to support vmware... SIOCSIFADDR on the character devicensayer2000-07-252-6/+8
| | | | | | sets the (notional) "remote" ethernet address. Submitted by: vsilyaev@mindspring.com
* Workaround to avoid panic during detach pccard nic.ume2000-07-251-1/+4
|
* Sundry changes to debugging code.nsayer2000-07-242-35/+75
| | | | | | | | Add spl/splx to various sensitive spots Change semantics of the vmnet version of the device to keep VMware happy (don't junk state when the device is closed) Submitted by: vsilyaev@mindspring.com
* When a connection is being dropped due to a listen queue overflow,jayanth2000-07-211-1/+1
| | | | | | | | | delete the cloned route that is associated with the connection. This does not exhaust the routing table memory when the system is under a SYN flood attack. The route entry is not deleted if there is any prior information cached in it. Reviewed by: Peter Wemm,asmodai
* Oops. SYSCTL_HANDLER_ARGS -> (SYSCTL_HANDLER_ARGS)nsayer2000-07-201-1/+1
|
* Add sysctl to perform bridge refresh. This is required if bridgednsayer2000-07-201-7/+29
| | | | | | | | configurations include loadable interfaces. After loading new interface drivers, perform a 'sysctl -w net.link.ether.bridge_refresh=1' and the bridge code will reinitialize itself. Submitted by: <vsilyaev@mindspring.com>
* Add the tap driver.nsayer2000-07-203-0/+919
| | | | | | | | | | | | | The tap driver is used to present a virtual Ethernet interface to the system. Packets presented by the network stack to the interface are made available to a character device in /dev. With tap and the bridge code, you can make remote bridge configurations where both sides of the bridge are separated by userland daemons. This driver also has a special naming hack to allow it to serve a similar purpose to the vmware port. Submitted by: myevmenkin@att.com, vsilyaev@mindspring.com
* Temporary hack for the benefit of the X-Bone projectkris2000-07-201-0/+2
| | | | | | (http://www.isi.edu/xbone). I expect this to go away in due course. Submitted by: Lars Eggert <larse@ISI.EDU>
* Const'ify parameters to ethers(3) routines as appropriate.archie2000-07-181-5/+5
|
* Initialise ifnet::if_typebrian2000-07-171-0/+2
| | | | | PR: 17873 Submitted by: Kensaku Masuda <greg@greg.rim.or.jp>
* improve route/nd cache cleanup on interface removal.itojun2000-07-161-12/+10
| | | | CAVEAT: haven't really tested it yet, please report
* Make all Ethernet drivers attach using ether_ifattach() and detach usingarchie2000-07-135-12/+31
| | | | | | | | | ether_ifdetach(). The former consolidates the operations of if_attach(), ng_ether_attach(), and bpfattach(). The latter consolidates the corresponding detach operations. Reviewed by: julian, freebsd-net
* repair IPV6_JOIN_GROUP to IPv6 all multi.itojun2000-07-091-0/+10
| | | | From: ume
* sync with kame tree as of july00. tons of bug fixes/improvements.itojun2000-07-0410-419/+1281
| | | | | | | API changes: - additional IPv6 ioctls - IPsec PF_KEY API was changed, it is mandatory to upgrade setkey(8). (also syntax change)
* Previous commit changing SYSCTL_HANDLER_ARGS violated KNF.phk2000-07-043-4/+4
| | | | Pointed out by: bde
* Style police catches up with rev 1.26 of src/sys/sys/sysctl.h:phk2000-07-033-4/+4
| | | | | | | | Sanitize SYSCTL_HANDLER_ARGS so that simplistic tools can grog our sources: -sysctl_vm_zone SYSCTL_HANDLER_ARGS +sysctl_vm_zone (SYSCTL_HANDLER_ARGS)
* Previous commit didn't work; this time really fix it.archie2000-06-301-14/+0
|
* Provide forward declarations for struct ifnet and struct mbufarchie2000-06-291-0/+3
| | | | to avoid compiler warnings.
* Fix kernel build breakage when 'device ether' was not included.archie2000-06-293-13/+3
|
* Make the ng_ether(4) node type dynamically loadable like the rest.archie2000-06-265-427/+126
| | | | | | | | | | | | | This means 'options NETGRAPH' is no longer necessary in order to get netgraph-enabled Ethernet interfaces. This supports loading/unloading the ng_ether.ko and attaching/detaching the Ethernet interface in any order. Add two new hooks 'upper' and 'lower' to allow access to the protocol demux engine and the raw device, respectively. This enables bridging to be defined as a netgraph node, if so desired. Reviewed by: freebsd-net@freebsd.org
* Implement SIOCSIFLLADDR, which allows you to change the link-levelwpaul2000-06-161-0/+30
| | | | | | | | | | | | | | | | | | | | | | | | | | address on an interface. This basically allows you to do what my little setmac module/utility does via ifconfig. This involves the following changes: socket.h: define SIOCSIFLLADDR if.c: add support for SIOCSIFLLADDR, which resets the values in the arpcom struct and sockaddr_dl for the specified interface. Note that if the interface is already up, we need to down/up it in order to program the underlying hardware's receive filter. ifconfig.c: add lladdr command ifconfig.8: document lladdr command You can now force the MAC address on any ethernet interface to be whatever you want. (The change is not sticky across reboots of course: we don't actually reprogram the EEPROM or anything.) Actually, you can reprogram the MAC address on other kinds of interfaces too; this shouldn't be ethernet-specific (though at the moment it's limited to 6 bytes of address data). Nobody ran up to me and said "this is the politically correct way to do this!" so I don't want to hear any complaints from people who think I could have done it more elegantly. Consider yourselves lucky I didn't do it by having ifconfig tread all over /dev/kmem.
* Do not perform any opeartion with mbuf after it placed intobp2000-06-143-9/+9
| | | | | | interface queue. Tested by: Bosko Milekic <bmilekic@dsuper.net>
* Unused include: #include "sl.h" - NSL is no longer used.peter2000-06-101-2/+0
|
* Don't try to apply ipfw filtering to non-IP packets.archie2000-06-021-0/+2
| | | | Reported-by: "Lachlan O'Dea" <lodea@vet.com.au>
* fix KASSERT usagemjacob2000-06-021-1/+1
|
* Don't panic if ifpromisc() returnes ENXIO, it's probably just an pccardphk2000-06-011-2/+7
| | | | which have been pulled.
* Make sl(4) SLIP devices dynamically expansible. Yay! =)green2000-05-302-116/+170
| | | | | PR: kern/17758 Submitted by: David Malone <dwmalone@maths.tcd.ie>
OpenPOWER on IntegriCloud