summaryrefslogtreecommitdiffstats
path: root/sys/pci/if_fxpvar.h
Commit message (Collapse)AuthorAgeFilesLines
* The fxp driver has lived in dev/fxp for some time, remove old files.jlemon2001-08-311-90/+0
|
* Change and clean the mutex lock interface.bmilekic2001-02-091-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | mtx_enter(lock, type) becomes: mtx_lock(lock) for sleep locks (MTX_DEF-initialized locks) mtx_lock_spin(lock) for spin locks (MTX_SPIN-initialized) similarily, for releasing a lock, we now have: mtx_unlock(lock) for MTX_DEF and mtx_unlock_spin(lock) for MTX_SPIN. We change the caller interface for the two different types of locks because the semantics are entirely different for each case, and this makes it explicitly clear and, at the same time, it rids us of the extra `type' argument. The enter->lock and exit->unlock change has been made with the idea that we're "locking data" and not "entering locked code" in mind. Further, remove all additional "flags" previously passed to the lock acquire/release routines with the exception of two: MTX_QUIET and MTX_NOSWITCH The functionality of these flags is preserved and they can be passed to the lock/unlock routines by calling the corresponding wrappers: mtx_{lock, unlock}_flags(lock, flag(s)) and mtx_{lock, unlock}_spin_flags(lock, flag(s)) for MTX_DEF and MTX_SPIN locks, respectively. Re-inline some lock acq/rel code; in the sleep lock case, we only inline the _obtain_lock()s in order to ensure that the inlined code fits into a cache line. In the spin lock case, we inline recursion and actually only perform a function call if we need to spin. This change has been made with the idea that we generally tend to avoid spin locks and that also the spin locks that we do have and are heavily used (i.e. sched_lock) do recurse, and therefore in an effort to reduce function call overhead for some architectures (such as alpha), we inline recursion for this case. Create a new malloc type for the witness code and retire from using the M_DEV type. The new type is called M_WITNESS and is only declared if WITNESS is enabled. Begin cleaning up some machdep/mutex.h code - specifically updated the "optimized" inlined code in alpha/mutex.h and wrote MTX_LOCK_SPIN and MTX_UNLOCK_SPIN asm macros for the i386/mutex.h as we presently need those. Finally, caught up to the interface changes in all sys code. Contributors: jake, jhb, jasone (in no particular order)
* Allow fxp to configure in I/O space if the user wants it and specifiesmjacob2001-01-231-0/+2
| | | | | | | | an override as a loader settable variable (fxp_iomap). fxp_iomap is a bitmap of fxp units that should be configured to use PCI I/O space in stead of PCI Memory space. Reviewed by: Kees Jan Koster <dutchman@tccn.cs.kun.nl>, dg@freebsd.org
* Removed NetBSD support, which bit-rotted long ago.dg2000-09-181-30/+3
| | | | Changed new SMP locking macros given the new situation.
* Added support for APM suspend/resume.dg2000-09-171-0/+6
| | | | | PR: 18756 Submitted by: mike ryan <msr@elision.org>, with modifications by me.
* Add locking to make able to run without the Giant lock being held. Thiscp2000-09-171-0/+7
| | | | | | | | is enabling as all entries are still called with Giant being held. Maintaining compatability with NetBSD makes what should be very simple kinda ugly. Reviewed by: Jason Evans
* Added support for cards and on-motherboard NICs that use an SEEPROMdg2000-03-281-0/+1
| | | | | | | | | | | | address size that is different than the standard 6bits. This fixes support for the Compaq NC3121 card, certain newer Intel Pro/100+ cards, and should also fix integrated NICs on SuperMicro and Compaq motherboards. The auto-sizing algorithm was taken from NetBSD (thanks!), which I think got it from Linux originally. Thanks also to Andrew Sparrow <spadger@best.com> and Joe Moore <jomor@ahpcns.com> for supplying me with unworking Compaq and Intel cards to develop and test the fixes with.
* Make the fxp driver work on alpha, rather than panic the machine on bootgallatin1999-09-301-18/+2
| | | | | | | | | | | | | | | | | | | and/or when using the card. o Convert the driver to using bus_space. This allows alphas with fxp's to boot, rather than panic'ing because rman_get_virtual() doesn't really return a virtual address on alphas. o Fix an alpha unaligned access error caused by some misfeature of gcc/egcs: if link_addr & rbd_addr in the fxp_rfa struct are 32 bit quantities, egcs will assume they are naturally aligned. So it will do a ldl & some shifty/masky to twiddle 16 bit values in fxp_lwcopy(). However, if they are 16-bit aligned, the ldl will actually be done on a 16-bit aligned value & we will panic with an unaligned access error... Changing their definition to an array of chars seems to fix this. I obtained this from NetBSD. I've tested this on both i386 & alpha.
* $Id$ -> $FreeBSD$peter1999-08-281-1/+1
|
* Bring the 'new-bus' to the i386. This extensively changes the way thepeter1999-04-161-1/+4
| | | | | | | | | | | | | | | | | | i386 platform boots, it is no longer ISA-centric, and is fully dynamic. Most old drivers compile and run without modification via 'compatability shims' to enable a smoother transition. eisa, isapnp and pccard* are not yet using the new resource manager. Once fully converted, all drivers will be loadable, including PCI and ISA. (Some other changes appear to have snuck in, including a port of Soren's ATA driver to the Alpha. Soren, back this out if you need to.) This is a checkpoint of work-in-progress, but is quite functional. The bulk of the work was done over the last few years by Doug Rabson and Garrett Wollman. Approved by: core
* Reordered fxp_softc for optimal cacheline behavior.dg1998-08-021-8/+10
|
* This commit fixes various 64bit portability problems required fordfr1998-06-071-2/+2
| | | | | | | | | | FreeBSD/alpha. The most significant item is to change the command argument to ioctl functions from int to u_long. This change brings us inline with various other BSD versions. Driver writers may like to use (__FreeBSD_version == 300003) to detect this change. The prototype FreeBSD/alpha machdep will follow in a couple of days time.
* Shuffle things a bit for better cacheline behavior.dg1997-11-291-6/+6
|
* Work around a bug in the 82557 NIC where the receiver will lock updg1997-09-291-1/+5
| | | | | | | | | | | | | | | | | | | | | | | if it is in 10Mbps mode and gets certain types of garbage prior to the packet header. The work-around involves reprogramming the multicast filter if nothing is received in some number of seconds (currently set at 15). As a side effect, implemented complete support for multicasting rather than the previous 'receive all multicasts' hack, since we now have the ability to program the filter table. Fixed a serious bug which crept in with the timeout() changes; the cookie was only saved on the first timeout() call in fxp_init() and wasn't updated in the most common place in fxp_stats_update() when the timeout was rescheduled. This bug would have resulted in an eventual panic if fxp_stop() was called (which happens when any interface flags are changed, for example). Fixed a bug in Alpha support that would have caused the TxCB descriptor chain to span a page boundry, causing serious problems if the pages didn't happen to be contiguous. Removed some gratuitous bit masking that was left over from an older implementation. Fixed a bug where too much was copied from the configuration template, spilling over into memory that followed it. Fixed handling of if_timer...it was cleared too early in some cases.
* Update for new callout interface.gibbs1997-09-211-1/+2
|
* Changes to support NetBSD and the new ifmedia extensions.dg1997-09-051-0/+107
Submitted by: Jason Thorpe <thorpej@netbsd.org>
OpenPOWER on IntegriCloud