summaryrefslogtreecommitdiff
path: root/sys/dev/usb/if_rue.c
Commit message (Collapse)AuthorAgeFilesLines
* Move usb to a graveyard location under sys/legacy/dev, it is intended that theAndrew Thompson2009-02-231-1393/+0
| | | | | | | | | | new USB2 stack will fully replace this for 8.0. Remove kernel modules, a subsequent commit will update conf/files. Unhook usbdevs from the build. Notes: svn path=/head/; revision=188939
* When all the other drivers were converted to scheduling a taskqueue toWarner Losh2007-07-091-0/+18
| | | | | | | | | | | | | do the heavy lifting of the 'mii_tick' function, rue was left behind. Implement this in a naive way. Reports from the field show this makes the driver functional with some locking issues, as opposed to an instant panic. Those will be addressed in a later version of the driver. Approved by: re@ (bmah) Notes: svn path=/head/; revision=171327
* s/logprintf/printf/gWarner Losh2007-06-201-1/+1
| | | | | | | Approved by: re@ Notes: svn path=/head/; revision=170960
* Use device_foo_t to declare kobj methodsWarner Losh2007-06-181-9/+10
| | | | | | | Fix shutdown type to return int rather than void. Notes: svn path=/head/; revision=170935
* Remove USBGETSOFTC, USB_ATTACH_START, USB_DETACH_START andWarner Losh2007-06-171-4/+5
| | | | | | | USB_DECLARE_DRIVER_INIT from the usb network drivers. Notes: svn path=/head/; revision=170892
* Expand USB_MATCH_STARTWarner Losh2007-06-171-1/+1
| | | | Notes: svn path=/head/; revision=170886
* Expand USB_DETACH, USB_ATTACH and USB_MATCH inline. No functionalWarner Losh2007-06-131-2/+4
| | | | | | | change, and MD5's appear to be the same. Notes: svn path=/head/; revision=170655
* Expand USB_ATTACH_{ERROR,SUCCESS}_RETURN inline and eliminate fromWarner Losh2007-06-121-2/+2
| | | | | | | usb_port.h. They aren't needed, and are a legacy of this code's past. Notes: svn path=/head/; revision=170612
* Prefer device_printf to printfWarner Losh2007-06-111-44/+41
| | | | | | | | | Eliminate rue_unit from softc # saves ~200 bytes Notes: svn path=/head/; revision=170542
* The devinfo stuff has been moved up into the parent bus. There's noWarner Losh2007-06-091-12/+0
| | | | | | | | | | need to do it at all anymore. Remove it from here. Expand USB_ATTACH_SETUP inline now that it is one line and we're moving away from the compat macros. Remove some bzero calls that turn out not be be necessary. Notes: svn path=/head/; revision=170449
* Remove compat ifdefs for FreeBSD versions < 500014, makes the codeChristian Brueffer2007-05-121-21/+0
| | | | | | | | | | quite a bit easier to read. Approved by: rwatson (mentor) MFC after: 1 weeks Notes: svn path=/head/; revision=169489
* More removing compatibility macros.Warner Losh2006-09-071-2/+2
| | | | | | | | | md5 still the same. "Dave, stop. I feel my mind slipping away." -- hal Notes: svn path=/head/; revision=162097
* s/Static/static/gWarner Losh2006-09-061-70/+70
| | | | | | | | | | | | | s/device_ptr_t/device_t/g No md5 changes in the .o's # Note to the md5 tracking club: $FreeBSD$ changes md5 after every commit # so you need to checkout -kk to get $FreeBSD$ instead of the actual value # of the keyword. Notes: svn path=/head/; revision=162095
* Do not touch ifp->if_baudrate in miibus aware drivers.Gleb Smirnoff2006-02-141-1/+0
| | | | Notes: svn path=/head/; revision=155671
* - Store pointer to the link-level address right in "struct ifnet"Ruslan Ermilov2005-11-111-1/+1
| | | | | | | | | | | | | rather than in ifindex_table[]; all (except one) accesses are through ifp anyway. IF_LLADDR() works faster, and all (except one) ifaddr_byindex() users were converted to use ifp->if_addr. - Stop storing a (pointer to) Ethernet address in "struct arpcom", and drop the IFP2ENADDR() macro; all users have been converted to use IF_LLADDR() instead. Notes: svn path=/head/; revision=152315
* Replace FreeBSD 3.x syntax (controller miibus0) with 4.x syntaxWarner Losh2005-10-221-1/+1
| | | | | | | (device miibus) in time for 7.0 :-) Notes: svn path=/head/; revision=151545
* Add missing if_free() in rue_detach().Ruslan Ermilov2005-09-161-0/+1
| | | | Notes: svn path=/head/; revision=150210
* Add proper copyright attribution.David E. O'Brien2005-08-101-0/+1
| | | | Notes: svn path=/head/; revision=148911
* Propagate rename of IFF_OACTIVE and IFF_RUNNING to IFF_DRV_OACTIVE andRobert Watson2005-08-091-14/+14
| | | | | | | | | | | | | | | | | 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 MFC after: 7 days Notes: svn path=/head/; revision=148887
* Modify device drivers supporting multicast addresses to lock if_addr_mtxRobert Watson2005-08-031-0/+2
| | | | | | | | | | | 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> MFC after: 1 week Notes: svn path=/head/; revision=148654
* Stop embedding struct ifnet at the top of driver softcs. Instead theBrooks Davis2005-06-101-14/+20
| | | | | | | | | | | | | | | | | | | | | | | 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
* Comment out rue_miibus_statchg() function. Using trial-and-error approach IMaxim Sobolev2005-03-251-0/+12
| | | | | | | | | | | | | | | | | found it guilty in putting the card into unusable state after UP->DOWN->UP media status change. Looks like some of register writes in this functions mess up PHY interface. No visible regressions has been found after commenting this code out - the card properly handles forceful local mode changes and auto-detects changes made remotely (tested with Auto, 10HD, 10FD, 100HD, 100FD). Sponsored by: PBXpress Inc. MFC after: 3 days Notes: svn path=/head/; revision=144122
* Fix breakage in the previous commit caused by the last-minute change.Maxim Sobolev2005-03-251-3/+2
| | | | Notes: svn path=/head/; revision=144106
* Move Rx/Tx lists management routines into central location.Maxim Sobolev2005-03-251-124/+48
| | | | Notes: svn path=/head/; revision=144104
* Move xxx_newbuf() function, which was the same in all drivers into centralMaxim Sobolev2005-03-251-40/+5
| | | | | | | location. Notes: svn path=/head/; revision=144086
* Mark USB ethernet devices as IFF_NEEDSGIANT, since the USB frameworkRobert Watson2004-08-111-1/+2
| | | | | | | | | | | | if_start routines cannot currently be entered without Giant. When the kernel is running with debug.mpsafenet != 0, this will defer if_start execution to a task queue thread holding Giant, which may introduce additional latency, but avoid incorrect execution. Suggested by: dfr Notes: svn path=/head/; revision=133466
* MFp4: First batch of dev/usb/usbdevs.h -> usbdevs.h changes.Warner Losh2004-06-271-1/+1
| | | | Notes: svn path=/head/; revision=131187
* Replace handrolled CRC calculation with ether_crc32_[lb]e().Christian Weisgerber2004-06-091-29/+2
| | | | Notes: svn path=/head/; revision=130270
* Add missing <sys/module.h> includesPoul-Henning Kamp2004-05-301-0/+1
| | | | Notes: svn path=/head/; revision=129879
* 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
* Replace the static "qdat" structure with a per-instance softc fieldIan Dowse2004-05-231-5/+3
| | | | | | | | | | | | | | | | in all USB ethernet drivers. The qdat structure contains a pointer to the interface's struct ifnet and is used to process incoming packets, so simultaneous use of two similar devices caused crashes and confusion. The if_udav driver appeared in the tree since Daan's PR, so I made similar changes to that driver too. PR: kern/59290 Submitted by: Daan Vreeken <Danovitsch@Vitsch.net> Notes: svn path=/head/; revision=129607
* Use the correct flag for mbuf allocations (M_DONTWAIT, not M_NOWAIT).Ian Dowse2004-04-061-2/+2
| | | | Notes: svn path=/head/; revision=127956
* Announce ethernet MAC addresss in ether_ifattach().Matthew N. Dodd2004-03-141-3/+0
| | | | Notes: svn path=/head/; revision=126966
* Don't use caddr_t in mchash(). Also use C99 spellings over BSD ones.David E. O'Brien2003-12-081-6/+6
| | | | | | | Requested by: bde,imp Notes: svn path=/head/; revision=123289
* Try to create some sort of consistency in how the routings to find theDavid E. O'Brien2003-11-131-12/+10
| | | | | | | | | | multicast hash are written. There are still two distinct algorithms used, and there actually isn't any reason each driver should have its own copy of this function as they could all share one copy of it (if it grew an additional argument). Notes: svn path=/head/; revision=122625
* It is obivous this started out as a copy of a Bill Paul driver so he hasDavid E. O'Brien2003-11-131-0/+30
| | | | | | | | a copyright on this driver as well. Bill uses a 4-clause BSDL, so we need to add a complete copy of Bill's copyright. Notes: svn path=/head/; revision=122623
* Replace the if_name and if_unit members of struct ifnet with new membersBrooks Davis2003-10-311-2/+1
| | | | | | | | | | | | | | | | 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
* Make it easier to run this code on RELENG_4.Josef Karthauser2003-10-041-1/+23
| | | | | | | Submitted by: luoqi Notes: svn path=/head/; revision=120765
* Use __FBSDID().David E. O'Brien2003-08-241-1/+3
| | | | | | | Also some minor style cleanups. Notes: svn path=/head/; revision=119418
* add missing machine/bus.h headers that are now necessary because of theJohn-Mark Gurney2003-07-161-0/+1
| | | | | | | bus_dma addition. Notes: svn path=/head/; revision=117662
* Add RealTek RTL8150 USB to fast Ethernet controller driver.Shunsuke Akiyama2003-05-031-0/+1477
This driver now supports the Melco LUA-KTX and the GREEN HOUSE GH-USB100B. Reviewed by: imp MFC after: 2 weeks Notes: svn path=/head/; revision=114577