summaryrefslogtreecommitdiffstats
path: root/sys/pci
Commit message (Collapse)AuthorAgeFilesLines
* Fix multicast and promiscuous mode handling for Yukon devices.wpaul2004-01-211-50/+101
| | | | Submitted by: Jung-uk Kim <jkim@niksun.com>
* Calculate the right register offset when clearing TX buffer pointerwpaul2004-01-211-1/+2
| | | | | | registers in rl_stop(). PR: kern/60250
* Replace calls to vm_page_alloc_contig() by calls to contigmalloc().alc2004-01-131-7/+6
| | | | | vm_page_alloc_contig() will be removed after the three remaining drivers that use it are also converted to contigmalloc().
* Some integrated Davicom cards in sparc64 boxes have an all zerosmux2004-01-081-0/+18
| | | | | | | | | | MAC address in the EEPROM, and we need to get it from OpenFirmware. This isn't very pretty but time is lacking to do this in a better way this near 5.2-RELEASE. This is a RELENG_5_2 candidate. Original version by: Marius Strobl <marius@alchemy.franken.de> Tested by: Pete Bentley <pete@sorted.org> Reviewed by: jake
* The transmit frame status is stored in the last transmit descriptor for thetruckman2004-01-082-3/+5
| | | | | | | | | | | | | | | | | | | | | frame, not the first. It is probably also not safe to free the mbuf chain as soon as the OWN bit is cleared on the first descriptor since the chip may not be done copying the frame into the transmit FIFO. Revert the part of of busdma conversion (if_dc.c rev 1.115) which changed dc_txeof() to look for the status in the first descriptor and free the mbuf chain when processing the first descriptor for the frame, and revert the matching changes elsewhere in the driver. This part of the busdma change caused the driver to report spurious collisions and output errors, even when running in full-duplex mode. Reverting the mbuf chain handling slightly complicates dc_dma_map_txbuf(), since it is responsible for setting the OWN bits on the descriptors, but does not normally have direct access to the mbuf chain. Tested by: Dejan Lesjak <dejan.lesjak at ijs.si> alpha/<Intel 21143 10/100BaseTX> "Xin LI" <delphij at frontfree.net> i386/<Macronix 98713 10/100BaseTX> Wiktor Niesiobedzki <bsd at w.evip.pl> i386/<3Com OfficeConnect 10/100B> Reviewed by: mux
* Fix detection of RealTek 8129 PCI cards. Apparently, these cardswpaul2004-01-021-1/+2
| | | | | | | | | | report a hardware rev of 0x00000000. Sadly, the 8169 gigE MAC also reports 0x00000000, so testing against this for exclusion results in both cards being skipped by rl_probe(). Make the 8169 test more specific by matching against both the hwrev and the PCI ID for this chip. PR: kern/60824
* Vastly improve performance of IRQ handling on stopped interfaces withphk2003-12-252-0/+5
| | | | | | | | | | | | | | | | this driver by introducing a flag saying we already stopped the device. On my Soekris net4801, this took a ping -i 0.001 from spending 80% of time in interrupt handling to 10% (approx numbers). This was a particular problem for the net4801 because the tree interfaces share the same interrupt, but it would be a problem for any configuration where an unused if_sis interface shares an interrupt with a busy device. Other drivers may have similar problems. Thanks to: Luigi
* Catch a few places where NULL (pointer) was used where 0 (integer) waspeter2003-12-231-1/+1
| | | | expected.
* Attempt to get the short cable fix to work better on the if_sis:phk2003-12-121-17/+26
| | | | | | | Only do short-cable on revisions that need it. Move generic initialization before short-cable fix, in order to not clobber short cable fix register setting.
* Don't use caddr_t in mchash(). Also use C99 spellings over BSD ones.obrien2003-12-0810-54/+56
| | | | Requested by: bde,imp
* Remote meteor driver. It hasn't compiled in over 3 years. If someoneimp2003-12-072-2375/+0
| | | | | makes it compile again, and can test it, we can restore the driver to the tree.
* Add support for ELECOM/Laneed CardBus FastEtherner Card(LD-CBL/TXA)sanpei2003-12-062-0/+3
| | | | | Submitted by: Masahiro Yamagishi <night@pluto.dti.ne.jp> Approved by: re (scottl)
* Fixed some minor indentation bugs.bde2003-12-021-12/+12
| | | | Approved by: re (scottl)
* Fixed breakage of the pci case of the cy driver by the new interruptbde2003-12-021-17/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | code. Both the driver and the new code were wrong. Driver interrupt handlers are supposed to take "void *vsc" arg, but some including all COMPAT_ISA drivers and the pci part of the cy driver want an "int unit" arg. They got this using bogus casts of function pointers which should have kept working despite their bogusness. However, the new interrupt code doesn't honor requests to pass an arg of ((void *)0), so things are very broken if the arg is actually a representation of unit 0. The fix is to use a normal "void *vsc" arg for the pci case and a wrapper for the COMPAT_ISA case (of the cy driver). This cleans up new-busification of the pci case but takes the COMPAT_ISA case a little further from new-bus. The corresponding bug for the COMPAT_ISA case has already been fixed similarly using a wrapper in compat_isa.c and we need another wrapper just to undo that. Fixed some directly related style bugs (mainly by removing compatibility cruft). cy.c: Fixed an indirectly related old bug in cyattach_common(). A wrong status was returned in the unlikely event that malloc() failed. Approved by: re (scottl)
* correct typo in interrupt handling for the 2nd port of 2-port cardssam2003-11-291-1/+1
| | | | | | Submitted by: luigi Reviewed by: checking original openbsd code Approved by: re (scottl)
* Sometimes cardbus attachments don't attach, so while we track downimp2003-11-283-0/+3
| | | | | | | | this problem put these lines back in. While they should be unnecessary, they appear to be sometimes necessary. Reviewed in concept: dfr Approved by: re (scottl@)
* Drop the driver lock around calls to if_input to avoid a LOR whensam2003-11-1424-1/+68
| | | | | | | | the packets are immediately returned for sending (e.g. when bridging or packet forwarding). There are more efficient ways to do this but for now use the least intrusive approach. Reviewed by: imp, rwatson
* Remove duplicate FBSDID's, move others to their right place.obrien2003-11-1410-41/+30
|
* reconst poisonimp2003-11-141-10/+10
| | | | re-de u_intXX_t
* Try to create some sort of consistency in how the routings to find theobrien2003-11-1311-122/+119
| | | | | | | 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).
* Add vendor ID to make Marvell chipset work. E.g. to be foundwilko2003-11-122-0/+10
| | | | | | | | on SMC9452TX it seems Submitted by: Jung-uk Kim <jkim@niksun.com> Tested by: <Radu Bogdan 'veedee' Rusu> veedee@c7.campus.utcluj.ro MFC after: 2 weeks
* - Disable AGP on ALI chipsets if aperture size is 0.anholt2003-11-112-0/+9
| | | | | | | | | - Fail in agp_alloc_gatt if the aperture size is 0 instead of panicing in contigmalloc. Reported by: Bjoern Fischer <bfischer@Techfak.Uni-Bielefeld.DE> Reviewed by: jhb MFC after: 1 week
* Ahh, the joys of badge engineering. Tell the sk driver that thepeter2003-11-072-0/+16
| | | | | Linksys EG1032 is yet another variation. It looks just like the 3c940 except it only has a Marvell logo and no 3com logo.
* s/driver/device/ for config file lineimp2003-11-061-1/+1
|
* Change config file syntax to be less FreeBSD 3.ximp2003-11-051-1/+1
|
* Free major#100phk2003-11-031-2/+0
|
* Remove explicit cardbus attachments from drivers where this is identicaldfr2003-11-033-3/+0
| | | | | | | to the pci attachment. Cardbus is a derived class of pci so all pci drivers are automatically available for matching against cardbus devices. Reviewed by: imp
* Correct the spelling of m_devget() in the sysctl variable description.ru2003-11-021-1/+1
|
* Replace the if_name and if_unit members of struct ifnet with new membersbrooks2003-10-3114-104/+93
| | | | | | | | | | | | | 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)
* mark interrupt handlers MPSAFEsam2003-10-291-1/+1
|
* Add simple support for AGP 3.0 including enabling 8x mode. The simplejhb2003-10-231-13/+108
| | | | | | | | part of the support is that it still assumes one master and one target where as AGP 3.0 actually supports multiple devices on the bus. Submitted by: Keith Whitwell <keith@tungstengraphics.com> Sponsored by: The Weather Channel
* Use a switch statement on the devid instead of if-else for determing whichjhb2003-10-231-6/+18
| | | | | | code to use to see if the onboard video has been disabled or not. Submitted by: Keith Whitwell <keith@tungstengraphics.com>
* Const poison crc routines (why these aren't centralized, I'm not sure).imp2003-10-231-9/+9
|
* Fix m_head handling in sis_encap so that the correct mbuf is always handedsilby2003-10-191-9/+8
| | | | to BPF_MTAP.
* Fix a problem where m_defrag would allocate a new mbuf to replace thesilby2003-10-191-8/+8
| | | | | | | chain passed into dc_encap, which dc_start was unaware of. This caused the old (now invalid) mbuf to be passed to BPF_MTAP. Spotted by: Kenjiro Cho <kjc@csl.sony.co.jp>
* Sanitize the code relating to the /dev/ti%d entries. In particular evictphk2003-10-101-68/+6
| | | | the evil vnode sniffing code and use destroy_dev() instead.
* Ignore CSR13, CSR14, CSR15 'Media Specific Data' registersmbr2003-10-052-12/+37
| | | | | | | | | | | | | | | for 21143 based cards which use SIA mode. This fixes 10mbit mode for ZNYX ZX346Q cards and other 21143 based cards. PR: 32118 Submitted by: Rene de Vries <rene@tunix.nl> Geert Jan de Groot <GeertJan.deGroot@tunix.nl> Obtained from: BSDI MFC after: 2 weeks
* Make the i810 AGP device create a "drmsub" child device. This will be attachedanholt2003-10-021-2/+31
| | | | | | to by the DRM for i8xx devices. Submitted by: Keith Whitwell <keith@tungstengraphics.com>
* Add a tiny bit more delay in the xl_mii_sync function; this is necessarysilby2003-09-291-0/+2
| | | | | | for proper intialization in certain 905B + old system combinations. Tested by: Jakub Miziolek <jxm@obta.uw.edu.pl>
* Add missing file, it is sorely needed to make if_sk.c compile again.wilko2003-09-201-0/+171
|
* Add support for SK-9521 V2.0 and 3COM 3C940.wilko2003-09-202-178/+812
| | | | | | | | | | Tested at 100Mbit only, using Asus P4P800 onboard 3C940. The -stable version of this patch I have in use for ~2 weeks now, and works just fine for me. Based on: Nathan L. Binkert's patch for OpenBSD Patch submitted by and thanks to: Jung-uk Kim <jkim@niksun.com> MFC after: 2 weeks
* Remove jumbo buffer #defines that I ended up not needing.wpaul2003-09-191-8/+0
|
* Fix a typo in r1.8: The GTLB enable/flush bit is 1<<7, not 1<<8.anholt2003-09-171-1/+1
| | | | | PR: kern/56297 Submitted by: Dan Angelescu <mrhsaacdoh@yahoo.com>
* Don't read the MAC address from a copy of the EEPROM in the softcmbr2003-09-161-4/+3
| | | | | | | | | | | | | | | that has been recorded earlier and overwrite it again later by reading it directly from the EEPROM again. Read the MAC address from the PAR0/PAR1 registers instead, which are autoloaded on reboot. Tested on AN985, AN983B. According to the datasheets, it should also work for the AL981 (I don't have such a chip on a card at home) PR: 52988 Submitted by: Andrew Gordon <arg-bsd@arg.me.uk> MFC after: 2 weeks
* - Avoid calling pci_get_device() more than once in a single function.mdodd2003-09-142-22/+40
| | | | | - Provide a mechanism to prevent the use of MMIO. - Prevent the use of MMIO for all 3c575 cardbus cards.
* Teach the re(4) driver about the CFG2 register, which tells us whetherwpaul2003-09-131-1/+15
| | | | | | | | | we're on a 32-bit/64-bit bus or not. Use this to decide if we should set the PCI dual-address cycle enable bit in the C+ command register. (Enabling DAC on a 32-bit bus seems to do bad things.) Also, initialize the C+ command register early in the re_init() routine. The documentation says this register should be configured first.
* - For the 8169 chips, read the station address by forcing an EEPROMwpaul2003-09-111-4/+6
| | | | | | | | | | | | | | | | | | | | | autoload and then copying the contends of the station address registers. For some reason, reading the EEPROM on the 8169S doesn't work right. This gets around the problem, and allows us to read the station address correctly on the 8169S. - Insert a delay after initiating packet transmition in re_diag() to allow lots of time for the frame to echo back to the host, and wait for both the 'RX complete' and 'timeout expired' bits in the ISR register to be set. - Deal more intelligently with the fact that the frame length field in the RX descriptor is a different width on the 8139C+ than it is on the 8169/8169S/8110S - For the 8169, you have to set bit 17 in the TX config register to enter digital loopback mode, but for the 8139C+, you have to set both bits 17 and 18. Take this into account so that re_diag() works properly for both types of chips.
* Re-enable VLAN_MTU capability for this driver. (Got reverted whenwpaul2003-09-111-0/+1
| | | | I pulled out the C+/8169 bits.)
* Add a PHY driver to support the built-in gigE PHY in the 8169S/8110Swpaul2003-09-112-2/+3
| | | | | | | | | | | | | | | | | | ethernet chips. This driver is pretty simple, however it contains special DSP initialization code which is needed in order to get the chip to negotiate a gigE link. (This special initialization may not be needed in subsequent chip revs.) Also: - Fix typo in if_rlreg.h (RL_GMEDIASTAT_1000MPS -> RL_GMEDIASTAT_1000MBPS) - Deal with shared interrupts in re_intr(): if interface isn't up, return. - Fix another bug in re_gmii_writereg() (properly apply data field mask) - Allow PHY driver to read the RL_GMEDIASTAT register via the re_gmii_readreg() register (this is register needed to determine real time link/media status).
* Teach rl(4) about new hwrev codes.wpaul2003-09-101-1/+2
|
OpenPOWER on IntegriCloud