summaryrefslogtreecommitdiff
path: root/sys/dev/ex
Commit message (Collapse)AuthorAgeFilesLines
* This commit was manufactured by cvs2svn to create tagrelease/6.2.0_cvscvs2svn2007-01-115-5/+5
| | | | | | 'RELENG_6_2_0_RELEASE'. This commit was manufactured to restore the state of the 6.2-RELEASE image.
* MFC (by ru)Xin LI2005-10-091-1/+3
| | | | | | | | | | | | | | | | | | | | | Fix "struct ifnet" leaks when attach() fails in the middle. | | Revision Changes Path | 1.28 +4 -5 src/sys/dev/bfe/if_bfe.c | 1.95 +3 -2 src/sys/dev/bge/if_bge.c | 1.21 +2 -0 src/sys/dev/cnw/if_cnw.c | 1.261 +2 -1 src/sys/dev/ed/if_ed.c | 1.38 +9 -2 src/sys/dev/en/if_en_pci.c | 1.59 +3 -1 src/sys/dev/ex/if_ex.c | 1.26 +4 -3 src/sys/dev/hatm/if_hatm.c | 1.105 +2 -1 src/sys/dev/ie/if_ie.c | 1.17 +2 -1 src/sys/dev/vge/if_vge.c Approved by: re (scottl) Notes: svn path=/stable/6/; revision=151141
* Merge linux_ioctl.c:1.128 svr4_sockio.c:1.17 altq_cbq.c:1.3 if_oltr.c:1.38Robert Watson2005-08-251-9/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | if_pflog.c:1.14 if_pfsync.c:1.21 if_an.c:1.70 if_ar.c:1.72 if_arl.c:1.11 amrr.c:1.10 onoe.c:1.10 if_ath.c:1.101 awi.c:1.41 if_bfe.c:1.27 if_bge.c:1.93 if_cm_isa.c:1.7 smc90cx6.c:1.16 if_cnw.c:1.20 if_cp.c:1.25 if_cs.c:1.42 if_ct.c:1.26 if_cx.c:1.46 if_ed.c:1.256 if_em.c:1.68 if_en_pci.c:1.37 midway.c:1.66 if_ep.c:1.143 if_ex.c:1.58 if_fatm.c:1.20 if_fe.c:1.93 if_fwe.c:1.38 if_fwip.c:1.8 if_fxp.c:1.244 if_gem.c:1.33 if_hatm.c:1.25 if_hatm_intr.c:1.20 if_hatm_ioctl.c:1.13 if_hatm_rx.c:1.10 if_hatm_tx.c:1.14 if_hme.c:1.39 if_ie.c:1.104 if_ndis.c:1.101 if_ic.c:1.24 if_ipw.c:1.10 if_iwi.c:1.10 if_ixgb.c:1.13 if_lge.c:1.41 if_lnc.c:1.113 if_my.c:1.31 if_nge.c:1.77 if_nve.c:1.10 if_owi.c:1.12 if_patm.c:1.9 if_patm_intr.c:1.6 if_patm_ioctl.c:1.10 if_patm_tx.c:1.10 pdq_ifsubr.c:1.28 if_plip.c:1.38 if_ral.c:1.12 if_ral_pci.c:1.2 if_ray.c:1.81 if_rayvar.h:1.22 if_re.c:1.49 if_sbni.c:1.21 if_sbsh.c:1.14 if_sn.c:1.48 dp83932.c:1.21 if_snc_pccard.c:1.9 if_sr.c:1.70 if_tx.c:1.91 if_txp.c:1.33 if_aue.c:1.92 if_axe.c:1.32 if_cdce.c:1.8 if_cue.c:1.59 if_kue.c:1.66 if_rue.c:1.23 if_udav.c:1.16 if_ural.c:1.12 if_vge.c:1.16 if_vx.c:1.58 if_wi.c:1.185 if_wi_pci.c:1.26 if_wl.c:1.68 if_xe.c:1.60 if_xe_pccard.c:1.30 if_el.c:1.68 i4b_ipr.c:1.35 i4b_isppp.c:1.31 kern_poll.c:1.20 bridge.c:1.94 bridgestp.c:1.4 if_arcsubr.c:1.27 if_atm.h:1.24 if_atmsubr.c:1.40 if_bridge.c:1.16 if_ef.c:1.35 if_ethersubr.c:1.196 if_faith.c:1.37 if_fddisubr.c:1.100 if_fwsubr.c:1.14 if_gif.c:1.54 if_gre.c:1.34 if_iso88025subr.c:1.70 if_loop.c:1.107 if_ppp.c:1.106 if_spppsubr.c:1.121 if_tap.c:1.57 if_tun.c:1.154 if_vlan.c:1.80 ppp_tty.c:1.67 ieee80211_ioctl.c:1.32 atm_if.c:1.31 ng_eiface.c:1.33 ng_ether.c:1.50 ng_fec.c:1.19 ng_iface.c:1.44 ng_sppp.c:1.9 ip_carp.c:1.30 ip_fastfwd.c:1.30 in6.c:1.53 nd6_nbr.c:1.31 natm.c:1.40 if_dc.c:1.162 if_de.c:1.168 if_pcn.c:1.72 if_rl.c:1.154 if_sf.c:1.84 if_sis.c:1.135 if_sk.c:1.108 if_ste.c:1.86 if_ti.c:1.109 if_tl.c:1.101 if_vr.c:1.106 if_wb.c:1.81 if_xl.c:1.194 from HEAD to RELENG_6: Propagate rename of IFF_OACTIVE and IFF_RUNNING to IFF_DRV_OACTIVE and IFF_DRV_RUNNING, as well as the move from ifnet.if_flags to ifnet.if_drv_flags. Device drivers are now responsible for synchronizing access to these flags, as they are in if_drv_flags. This helps prevent races between the network stack and device driver in maintaining the interface flags field. Many __FreeBSD__ and __FreeBSD_version checks maintained and continued; some less so. Reviewed by: pjd, bz Approved by: re (scottl) Notes: svn path=/stable/6/; revision=149443
* Merge if_ath.c:1.99 awi.c:1.39 if_bfe.c:1.26 if_bge.c:1.92 if_ed.c:1.255Robert Watson2005-08-241-1/+5
| | | | | | | | | | | | | | | | | | | | | | | | if_em.c:1.67 if_ex.c:1.57 if_fe.c:1.92 if_fxp.c:1.242 if_gem.c:1.32 if_hme.c:1.38 if_ie.c:1.103 if_ndis.c:1.100 if_ixgb.c:1.12 if_lge.c:1.40 if_lnc.c:1.112 if_my.c:1.30 if_nge.c:1.76 if_nve.c:1.9 if_owi.c:1.11 pdq_ifsubr.c:1.27 if_ray.c:1.80 if_re.c:1.47 if_sn.c:1.47 dp83932.c:1.20 if_tx.c:1.90 if_txp.c:1.32 if_aue.c:1.91 if_axe.c:1.31 if_cue.c:1.58 if_kue.c:1.65 if_rue.c:1.22 if_udav.c:1.15 if_vge.c:1.15 if_wi.c:1.182 if_wl.c:1.67 if_xe.c:1.58 if_dc.c:1.161 if_de.c:1.167 if_pcn.c:1.70 if_rl.c:1.153 if_sf.c:1.83 if_sis.c:1.134 if_sk.c:1.107 if_ste.c:1.85 if_ti.c:1.108 if_tl.c:1.100 if_vr.c:1.105 if_wb.c:1.80 if_xl.c:1.193 from HEAD to RELENG_6: Modify device drivers supporting multicast addresses to lock if_addr_mtx over iteration of their multicast address lists when synchronizing the hardware address filter with the network stack-maintained list. Problem reported by: Ed Maste (emaste at phaedrus dot sandvine dot ca> Approved by: re (scottl) Notes: svn path=/stable/6/; revision=149422
* Eliminate unused argument in PCMCIA_CARD macro.Warner Losh2005-06-241-2/+2
| | | | | | | | | | | Provide a backwards compatible way to have the extra macro by defining PCCARD_API_LEVEL 5 before including pccarddevs for driver writers that want/need to have the same driver on 5 and 6 with pccard attachments. Approved by: re (dwhite) Notes: svn path=/head/; revision=147580
* Stop embedding struct ifnet at the top of driver softcs. Instead theBrooks Davis2005-06-104-14/+22
| | | | | | | | | | | | | | | | | | | | | | | struct ifnet or the layer 2 common structure it was embedded in have been replaced with a struct ifnet pointer to be filled by a call to the new function, if_alloc(). The layer 2 common structure is also allocated via if_alloc() based on the interface type. It is hung off the new struct ifnet member, if_l2com. This change removes the size of these structures from the kernel ABI and will allow us to better manage them as interfaces come and go. Other changes of note: - Struct arpcom is no longer referenced in normal interface code. Instead the Ethernet address is accessed via the IFP2ENADDR() macro. To enforce this ac_enaddr has been renamed to _ac_enaddr. - The second argument to ether_ifattach is now always the mac address from driver private storage rather than sometimes being ac_enaddr. Reviewed by: sobomax, sam Notes: svn path=/head/; revision=147256
* Include necessary declarationsWarner Losh2005-01-201-0/+3
| | | | Notes: svn path=/head/; revision=140527
* Only match ethernet functions. I've not seen any multifunction cardsWarner Losh2005-01-201-0/+7
| | | | | | | | | (from a PC Card sense), so this should be a nop. The pseudo-multifunction cards (eg Silicom ones) need a special driver anyway.. Notes: svn path=/head/; revision=140526
* Start each of the license/copyright comments with /*-, minor shuffle of linesWarner Losh2005-01-062-2/+2
| | | | Notes: svn path=/head/; revision=139749
* Use cluster if data >= MINCLSIZE.Gleb Smirnoff2004-10-171-1/+1
| | | | | | | | | Reviewed by: mdodd Approved by: julian (mentor) MFC after: 1 month Notes: svn path=/head/; revision=136625
* Since if_ex doesn't contain locking or run with INTR_MPSAFE, markRobert Watson2004-08-131-1/+2
| | | | | | | | | | the interface as IFF_NEEDSGIANT so if_start is run holding Giant. Note: there are locking macros in if_exreg.h, but they appear to be unused. Notes: svn path=/head/; revision=133684
* another format nitWarner Losh2004-06-281-1/+2
| | | | Notes: svn path=/head/; revision=131248
* casting for printf happinessWarner Losh2004-06-281-4/+4
| | | | Notes: svn path=/head/; revision=131247
* MFp4:Warner Losh2004-06-274-255/+349
| | | | | | | | | Use bus space rather than direct inb/outb. Minor style changes while I'm here. Extremely preliminary support for siliconix ethernet cards (but more work is required). Notes: svn path=/head/; revision=131192
* Fix disordering of pccarddevs.h noticed by bde. Also remove a fewWarner Losh2004-05-271-1/+1
| | | | | | | | | redundant includes and fix some of the include disordering. Submitted by: bde Notes: svn path=/head/; revision=129764
* Move to generating pccarddevs.h on the fly, both for the kernel andWarner Losh2004-05-261-1/+1
| | | | | | | | | | the modules. Also generate usbdevs.h automatically now, but a non-kernel file is stopping that at the moment. Notes: svn path=/head/; revision=129740
* We don't need to initialize if_output, ether_ifattach() does itMaxime Henrion2004-05-231-1/+0
| | | | | | | for us. Notes: svn path=/head/; revision=129616
* Remove improper use of if_addrhead in device drivers to checkLuigi Rizzo2004-04-151-3/+0
| | | | | | | | | | | | | | | if the link-level address has been initialized already. The majority of modern drivers never does this and works fine, which makes me think that the check is totally unnecessary and a residue of cut&paste from other drivers. This change is done to simplify locking because now almost none of the drivers uses this field. The exceptions are "ct" "ctau" and "cx" where i am not sure if i can remove that part. Notes: svn path=/head/; revision=128293
* Convert callers to the new bus_alloc_resource_any(9) API.Nate Lawson2004-03-171-4/+4
| | | | | | | | Submitted by: Mark Santcroos <marks@ripe.net> Reviewed by: imp, dfr, bde Notes: svn path=/head/; revision=127135
* Announce ethernet MAC addresss in ether_ifattach().Matthew N. Dodd2004-03-141-3/+0
| | | | Notes: svn path=/head/; revision=126966
* Replace the if_name and if_unit members of struct ifnet with new membersBrooks Davis2003-10-311-9/+7
| | | | | | | | | | | | | | | | if_xname, if_dname, and if_dunit. if_xname is the name of the interface and if_dname/unit are the driver name and instance. This change paves the way for interface renaming and enhanced pseudo device creation and configuration symantics. Approved By: re (in principle) Reviewed By: njl, imp Tested On: i386, amd64, sparc64 Obtained From: NetBSD (if_xname) Notes: svn path=/head/; revision=121816
* add newcard support to exWarner Losh2003-10-261-2/+28
| | | | Notes: svn path=/head/; revision=121565
* Use __FBSDID().David E. O'Brien2003-08-243-3/+9
| | | | | | | Also some minor style cleanups. Notes: svn path=/head/; revision=119418
* - Declare ex_devclass in if_ex.cMatthew N. Dodd2003-03-294-8/+8
| | | | | | | - Rename module datastructures in if_ex_isa.c to be more standard. Notes: svn path=/head/; revision=112801
* - Move ex_pccard_detach() to if_ex.c and rename it to ex_detach().Matthew N. Dodd2003-03-294-15/+22
| | | | | | | - Add detach method to ISA front end. Notes: svn path=/head/; revision=112800
* Reformat for readability.Matthew N. Dodd2003-03-291-96/+98
| | | | Notes: svn path=/head/; revision=112799
* Don't panic if we aren't plugged into a hub.Matthew N. Dodd2003-03-291-5/+18
| | | | Notes: svn path=/head/; revision=112764
* Multicast support, gleaned from NetBSD's if_iy driver.Matthew N. Dodd2003-03-282-5/+103
| | | | | | | Submitted by: Craig Boston <craig@xfoil.gank.org> Notes: svn path=/head/; revision=112731
* Back out M_* changes, per decision of the TRB.Warner Losh2003-02-191-3/+3
| | | | | | | Approved by: trb Notes: svn path=/head/; revision=111119
* Remove M_TRYWAIT/M_WAITOK/M_WAIT. Callers should use 0.Alfred Perlstein2003-01-211-3/+3
| | | | | | | Merge M_NOWAIT/M_DONTWAIT into a single flag M_NOWAIT. Notes: svn path=/head/; revision=109623
* network interface driver changes:Sam Leffler2002-11-141-6/+3
| | | | | | | | | | | | | | | | | o don't strip the Ethernet header from inbound packets; pass packets up the stack intact (required significant changes to some drivers) o reference common definitions in net/ethernet.h (e.g. ETHER_ALIGN) o track ether_ifattach/ether_ifdetach API changes o track bpf changes (use BPF_TAP and BPF_MTAP) o track vlan changes (ifnet capabilities, revised processing scheme, etc.) o use if_input to pass packets "up" o call ether_ioctl for default handling of ioctls Reviewed by: many Approved by: re Notes: svn path=/head/; revision=106937
* Remove __P.Alfred Perlstein2002-03-203-16/+16
| | | | Notes: svn path=/head/; revision=92739
* Mechanical change to use <sys/queue.h> macro API instead ofPoul-Henning Kamp2001-02-041-1/+1
| | | | | | | | | | fondling implementation details. Created with: sed(1) Reviewed by: md5(1) Notes: svn path=/head/; revision=71999
* Warning police:John Baldwin2001-01-192-2/+2
| | | | | | | | - Share the ex_stop() prototype in if_exvar.h - Remove an unused local variable. Notes: svn path=/head/; revision=71235
* Remove unneeded #include <machine/clock.h>Poul-Henning Kamp2000-10-153-3/+0
| | | | Notes: svn path=/head/; revision=67164
* Add support for pccard attachments of the ex driver. It supports theWarner Losh2000-09-293-3/+166
| | | | | | | | | | Olicom OC-2220 card, and maybe others. Submitted by: iwasaki Reviewed by: mdodd Notes: svn path=/head/; revision=66440
* Make all Ethernet drivers attach using ether_ifattach() and detach usingArchie Cobbs2000-07-131-6/+1
| | | | | | | | | | | | 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 Notes: svn path=/head/; revision=63090
* Unused include: #include "ex.h"Peter Wemm2000-06-101-2/+0
| | | | Notes: svn path=/head/; revision=61488
* Move code to handle BPF and bridging for incoming Ethernet packets outArchie Cobbs2000-05-141-17/+0
| | | | | | | | | | | | | | | | | | of the individual drivers and into the common routine ether_input(). Also, remove the (incomplete) hack for matching ethernet headers in the ip_fw code. The good news: net result of 1016 lines removed, and this should make bridging now work with *all* Ethernet drivers. The bad news: it's nearly impossible to test every driver, especially for bridging, and I was unable to get much testing help on the mailing lists. Reviewed by: freebsd-net Notes: svn path=/head/; revision=60536
* Split out the ISA bus front end code into its own file. PCCARD attachmentMatthew N. Dodd2000-05-014-297/+472
| | | | | | | | | coming later this week. Mitsuru IWASAKI provided a patch to -mobile which I used to make sure I was doing the right thing but only a small part of the actual patch was used. Notes: svn path=/head/; revision=59816
* Remove ~25 unneeded #include <sys/conf.h>Poul-Henning Kamp2000-04-191-1/+0
| | | | | | | Remove ~60 unneeded #include <sys/malloc.h> Notes: svn path=/head/; revision=59391
* Add 'bootverbose' debug messages to assist with tracking down problemsMatthew N. Dodd2000-03-131-5/+27
| | | | | | | some users have encountered. Notes: svn path=/head/; revision=57989
* Initial ifmedia support. Once I figure out autoselection I'll put theMatthew N. Dodd2000-03-132-15/+113
| | | | | | | | | | | | rest of the code in (so changing media actually works.) Add a few more register definitions for use with this and other new code. Print a few details in the probe message; this should be useful in bug reports and such but should not add to the clutter. Notes: svn path=/head/; revision=57987
* Pre 4.0 tidy up.Peter Wemm2000-01-141-1/+1
| | | | | | | | | | | | | | | Collect together the components of several drivers and export eisa from the i386-only area (It's not, it's on some alphas too). The code hasn't been updated to work on the Alpha yet, but that can come later. Repository copies were done a while ago. Moving these now keeps them in consistant place across the 4.x series as the newbusification progresses. Submitted by: mdodd Notes: svn path=/head/; revision=55953
* Cosmetic cleanups.Matthew N. Dodd2000-01-131-34/+23
| | | | Notes: svn path=/head/; revision=55883
* Implement a DEVICE_IDENTIFY method. I want to revisit some of this laterMatthew N. Dodd2000-01-131-22/+59
| | | | | | | but this is enough to get us going. Notes: svn path=/head/; revision=55882
* When I converted this driver to newbus I also cleaned up the codeMatthew N. Dodd2000-01-131-50/+51
| | | | | | | | | | | | | | | | | layout. It seems that I cleaned it up a bit too much and confused a few if () { if () { } else { } } statements in the obvious manner. This allows the driver to transmit packets again. *sigh* Notes: svn path=/head/; revision=55881
* Fix bus_setup_intr(); I changed exintr() to take a pointer to ex_softcMatthew N. Dodd1999-11-031-1/+1
| | | | | | | | | but didn't change bus_setup_intr() to pass the softc in. Submitted by: Warner Losh <imp@village.org> Notes: svn path=/head/; revision=52842
* - Convert this driver to newbus.Matthew N. Dodd1999-10-161-485/+723
| | | | | | | | | | | | | | | | | - Generally clean things up. - PnP now supported. Will convert to bus_space, ifmedia and add a DEVICE_IDENTIFY() method for autodetection. As it stands device ex0 at isa0 should find a card if one is present. I feel less dirty now. Notes: svn path=/head/; revision=52286
* Remove NBPF conditionality of bpf calls in most of our network drivers.Poul-Henning Kamp1999-09-251-9/+0
| | | | | | | | | | | | | | | This means that we will not have to have a bpf and a non-bpf version of our driver modules. This does not open any security hole, because the bpf core isn't loadable The drivers left unchanged are the "cross platform" drivers where the respective maintainers are urged to DTRT, whatever that may be. Add a couple of missing FreeBSD tags. Notes: svn path=/head/; revision=51646