summaryrefslogtreecommitdiffstats
path: root/sys/pci
Commit message (Collapse)AuthorAgeFilesLines
* Make consistent; turn spaces into tabs where there is a mixture.markm2002-09-041-21/+21
|
* Add a device description for Intel 82801CA/CAM (ICH3) USB controllerjoe2002-08-281-0/+5
| | | | | | USB-C. PR: kern/41963
* Include <sys/lockmgr.h> for old lock interfaces instead of depending onbde2002-08-277-0/+7
| | | | namespace pollution in <sys/lock.h>.
* Replace various spelling with FALLTHROUGH which is lint()ablecharnier2002-08-252-8/+8
|
* o Retire vm_page_zero_fill() and vm_page_zero_fill_area(). Ever sincealc2002-08-252-2/+2
| | | | | | pmap_zero_page() and pmap_zero_page_area() were modified to accept a struct vm_page * instead of a physical address, vm_page_zero_fill() and vm_page_zero_fill_area() have served no purpose.
* style: put return types on a line by themselves.alfred2002-08-245-188/+376
|
* style:alfred2002-08-236-235/+466
| | | | | put return values on a line by themselves. fix some paste issues where whitespace was used instead of tabs.
* Put return values from functions on a line by themselves.alfred2002-08-231-36/+72
| | | | Ok'd previously by: wpaul
* Don't read the PCI config space during mii operations. Instead save whetherambrisko2002-08-192-3/+9
| | | | | | | | | or not we have to limit the PHY detection in the softc structure. Then just check the flag. Suggested by: jdp Reviewed by: jdp MFC after: 3 days
* Remove the SIS_LOCK/SIS_UNLOCK from sis_attach(). It makes WITNESSphk2002-08-191-3/+0
| | | | barf and there seem to be little room for contention during attach.
* Use uhci_pci_match to return the device description and rework thejoe2002-08-181-28/+22
| | | | vendor description code.
* Add a comment to remind that uhci_pci_match will never return NULL.joe2002-08-181-6/+11
| | | | | Don't display the "New UHCI DeviceId" message unless booting verbosely. Use a switch statement for the vendor match code.
* Increase size of ifnet.if_flags from 16 bits (short) to 32 bits (int). To avoidsobomax2002-08-183-9/+9
| | | | | | | breaking application ABI use unused ifreq.ifru_flags[1] for upper 16 bits in SIOCSIFFLAGS and SIOCGIFFLAGS ioctl's. Reviewed by: -hackers, -net
* Consolidate the device recognition code.joe2002-08-181-57/+4
|
* Revert change to detect multiply PHYs in mii code. There might be casesambrisko2002-08-161-0/+5
| | | | | | | | | when this is needed. Work around bogus second PHY in the DFE-580 card via a change in the if_ste.c driver. Suggested by: jdp Reviewed by: jdp MFC after: 3 days
* UHCI_DEBUG -> USB_DEBUG.joe2002-08-151-1/+1
|
* Improve handling of TX errors. Early reports indicate that thissilby2002-08-152-13/+28
| | | | | | | | | | elimiates the driver lockup problem reported by many. Concepts used were taken from Via's if_fet driver. Verification and implementation were done by Thomas Nystrom. Submitted by: Thomas Nystrom <thn@saeab.se> MFC after: 3 days
* o Use the VM_ALLOC_WIRED flag instead of calling vm_page_wire().alc2002-08-102-6/+3
|
* Fixes for the D-Link DFE-580 card.ambrisko2002-08-072-83/+111
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is pretty much fixes any issue I can find: - Watchdog timeouts were due to starting the TX DMA engine before we had a packet ready for it. So the first packet sent never got out only if we sent more then one packet at a time did the others make it out and not blow up. Of course reseting the chip then caused us not to transmit the first packet again ie. catch-22. This required logic changes. - Combine interrupts on TX packets being queued up. - Don't keep running around the RX ring since we might get out of sync so only go around once per receive - Let the RX engine recover via the poll interface which is similar to the TX interface. This way the chip wakes up with no effort when we read enough packets. - Do better hand-shaking on RX & TX packets so they don't start of to soon. - Force a duplex setting when the link comes up after an ste_init or it will default to half-duplex and be really slow. This only happens on subsequent ste_init. The first one worked. - Don't call stat_update for every overflow. We only monitor the collisions so the tick interval is good enough for that. Just read in the collision stats to minimize bus reads. - Don't read the miibus every tick since it uses delays and delays are not good for performance. - Tie link events directly to the miibus code so the port gets set correctly if someone changes the port settings. - Reduce the extreme number of {R,T}FD's. They would consume 130K of kernel memory for each NIC. - Set the TX_THRESH to wait for the DMA engine to complete before running the TX FIFO. This hurts peak TX performance but under bi-directional load the DMA engine can't keep up with the FIFO. Testing shows that we end up in the case anyways (a la dc(4) issues but worse since the RX engine hogs everything). - When stopping the card do a reset since the reset verifies the card has stopped. Otherwise on heavy RX load the RX DMA engine is still stuffing packets into memory. If that happens after we free the DMA area memory bits get scribled in memory and bad things happen. This card still has seemingly unfixable issues under heavy RX load in which the card takes over the PCI bus. Sponsored by: Vernier Networks MFC after: 1 week
* Use new interface for ether_input().luigi2002-08-071-13/+4
| | | | | | | Remove some unnecessary assignments to mbuf fields in sis_newbuf(), the "length" fields are of no use while the mbuf is in the receive ring. MFC after: 3 days
* Make sure to set the DMA transfer length register, plus onesilby2002-08-051-1/+6
| | | | | | small style fix. Submitted by: Thomas Nystrom <thn@saeab.se>
* Use m_getcl() to allocate mbuf+cluster for the receive ring.luigi2002-08-041-25/+9
| | | | | | | Remove the sis_quick variable, as it was there for testing purposes only. MFC after: 3 days
* Repond properly to NGM_TEXT_CONFIG messages.phk2002-08-041-0/+1
|
* Make sure to set both sets of registers which control the RX and TX buffersilby2002-07-312-0/+49
| | | | | | | | | | sizes. Previously, the end result was at the mercy of the card's default setting. This change will reduce the number of buffer underruns for some users. PR: kern/37929 Submitted by: Thomas Nystrom <thn@saeab.se> MFC after: 7 days
* If we get 0xffff back when reading the status register, assume the cardjhb2002-07-301-0/+5
| | | | | | | has gone away instead of spinning in the interrupt handler. This stops my machine from hanging when I eject a rl(4)-based cardbus card. Reviewed by: imp
* o If the page returned by vm_page_grab(VM_ALLOC_ZERO) isn't prezeroed,alc2002-07-212-0/+4
| | | | | | zero it. Reviewed by: dfr, peter
* Add PCI IDs for the A, B, and C UHCI controllers in the ICH4.jhb2002-07-191-0/+27
| | | | Sponsored by: The Weather Channel
* - Use more correct values to initialize the AGP controller during setup.jhb2002-07-171-6/+21
| | | | | | The value we use is still questionable for 440BX chipsets. - When flushing the TLB just toggle the bit in question instead of writing a magic value that could trash other unrelated bits.
* o Lock page queue accesses by vm_page_wire().alc2002-07-142-0/+4
|
* o Complete the locking of page queue accesses by vm_page_unwire().alc2002-07-132-0/+6
| | | | | | o Assert that the page queues lock is held in vm_page_unwire(). o Make vm_page_lock_queues() and vm_page_unlock_queues() visible to kernel loadable modules.
* Fix if_timer logic to make sure that there is always a timeoutluigi2002-06-302-10/+8
| | | | | | | | pending if there are packets queued for transmission. Several drivers still have the same problem. MFC after: 3 days
* Fix if_timer logic to make sure that there is always a timeoutluigi2002-06-301-6/+6
| | | | | | pending if there are packets queued for transmission. MFC after: 3 days
* Make sure that if_timer does not get reset if there are packetsluigi2002-06-302-19/+11
| | | | | | | | | | | still queued for transmission. This should solve the problem of the device stalling on transmissions if some link event prevents transmission. There are other drivers which have the same problem and need to be fixed in the same way. MFC after: 3 days
* catch up with mextfree callback change when TI_PRIVATE_JUMBOS is defined.alfred2002-06-291-2/+2
| | | | Pointed out by: kdm
* Remove a couple of __P() stragglers.peter2002-06-291-2/+2
|
* catch up with mextadd callback taking a void argument instead of a caddr_t.alfred2002-06-291-2/+2
|
* remove or replace caddr_t with void.alfred2002-06-281-2/+2
| | | | make the mbuf external free function take a void * rather than caddr_t.
* At long last, commit the zero copy sockets code.ken2002-06-264-5230/+6591
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | MAKEDEV: Add MAKEDEV glue for the ti(4) device nodes. ti.4: Update the ti(4) man page to include information on the TI_JUMBO_HDRSPLIT and TI_PRIVATE_JUMBOS kernel options, and also include information about the new character device interface and the associated ioctls. man9/Makefile: Add jumbo.9 and zero_copy.9 man pages and associated links. jumbo.9: New man page describing the jumbo buffer allocator interface and operation. zero_copy.9: New man page describing the general characteristics of the zero copy send and receive code, and what an application author should do to take advantage of the zero copy functionality. NOTES: Add entries for ZERO_COPY_SOCKETS, TI_PRIVATE_JUMBOS, TI_JUMBO_HDRSPLIT, MSIZE, and MCLSHIFT. conf/files: Add uipc_jumbo.c and uipc_cow.c. conf/options: Add the 5 options mentioned above. kern_subr.c: Receive side zero copy implementation. This takes "disposable" pages attached to an mbuf, gives them to a user process, and then recycles the user's page. This is only active when ZERO_COPY_SOCKETS is turned on and the kern.ipc.zero_copy.receive sysctl variable is set to 1. uipc_cow.c: Send side zero copy functions. Takes a page written by the user and maps it copy on write and assigns it kernel virtual address space. Removes copy on write mapping once the buffer has been freed by the network stack. uipc_jumbo.c: Jumbo disposable page allocator code. This allocates (optionally) disposable pages for network drivers that want to give the user the option of doing zero copy receive. uipc_socket.c: Add kern.ipc.zero_copy.{send,receive} sysctls that are enabled if ZERO_COPY_SOCKETS is turned on. Add zero copy send support to sosend() -- pages get mapped into the kernel instead of getting copied if they meet size and alignment restrictions. uipc_syscalls.c:Un-staticize some of the sf* functions so that they can be used elsewhere. (uipc_cow.c) if_media.c: In the SIOCGIFMEDIA ioctl in ifmedia_ioctl(), avoid calling malloc() with M_WAITOK. Return an error if the M_NOWAIT malloc fails. The ti(4) driver and the wi(4) driver, at least, call this with a mutex held. This causes witness warnings for 'ifconfig -a' with a wi(4) or ti(4) board in the system. (I've only verified for ti(4)). ip_output.c: Fragment large datagrams so that each segment contains a multiple of PAGE_SIZE amount of data plus headers. This allows the receiver to potentially do page flipping on receives. if_ti.c: Add zero copy receive support to the ti(4) driver. If TI_PRIVATE_JUMBOS is not defined, it now uses the jumbo(9) buffer allocator for jumbo receive buffers. Add a new character device interface for the ti(4) driver for the new debugging interface. This allows (a patched version of) gdb to talk to the Tigon board and debug the firmware. There are also a few additional debugging ioctls available through this interface. Add header splitting support to the ti(4) driver. Tweak some of the default interrupt coalescing parameters to more useful defaults. Add hooks for supporting transmit flow control, but leave it turned off with a comment describing why it is turned off. if_tireg.h: Change the firmware rev to 12.4.11, since we're really at 12.4.11 plus fixes from 12.4.13. Add defines needed for debugging. Remove the ti_stats structure, it is now defined in sys/tiio.h. ti_fw.h: 12.4.11 firmware. ti_fw2.h: 12.4.11 firmware, plus selected fixes from 12.4.13, and my header splitting patches. Revision 12.4.13 doesn't handle 10/100 negotiation properly. (This firmware is the same as what was in the tree previously, with the addition of header splitting support.) sys/jumbo.h: Jumbo buffer allocator interface. sys/mbuf.h: Add a new external mbuf type, EXT_DISPOSABLE, to indicate that the payload buffer can be thrown away / flipped to a userland process. socketvar.h: Add prototype for socow_setup. tiio.h: ioctl interface to the character portion of the ti(4) driver, plus associated structure/type definitions. uio.h: Change prototype for uiomoveco() so that we'll know whether the source page is disposable. ufs_readwrite.c:Update for new prototype of uiomoveco(). vm_fault.c: In vm_fault(), check to see whether we need to do a page based copy on write fault. vm_object.c: Add a new function, vm_object_allocate_wait(). This does the same thing that vm_object allocate does, except that it gives the caller the opportunity to specify whether it should wait on the uma_zalloc() of the object structre. This allows vm objects to be allocated while holding a mutex. (Without generating WITNESS warnings.) vm_object_allocate() is implemented as a call to vm_object_allocate_wait() with the malloc flag set to M_WAITOK. vm_object.h: Add prototype for vm_object_allocate_wait(). vm_page.c: Add page-based copy on write setup, clear and fault routines. vm_page.h: Add page based COW function prototypes and variable in the vm_page structure. Many thanks to Drew Gallatin, who wrote the zero copy send and receive code, and to all the other folks who have tested and reviewed this code over the years.
* Fix typo in the BSD copyright: s/withough/without/schweikh2002-06-023-3/+3
| | | | | Spotted and suggested by: des MFC after: 3 weeks
* Enhance the use of the watchdog timer in this driver so that it willsilby2002-05-151-4/+3
| | | | | | | | | | | | | | | | | | | | allow recovery from transmission lockups which occur in the middle of the descriptor list, rather than just at the beginning. For some unknown reason, Rhine II chips have a tendency to stop transmitting while under heavy load, possibly due to collisions. Whether this behavior is due to a hardware bug or a driver glitch is unknown as of now. In either case, this change allows the driver to gracefully recover from such situations. Special thanks go to The Anarcat <anarcat@anarcat.dyndns.org>, who bugged me into looking at this and to Dominic Marks <dominic_marks@btinternet.com>, who performed a great deal of testing to help characterize this problem. MFC after: 3 days
* Add support for the D-Link DFE-690TXD Cardbus card which has a RealTek 8139jhb2002-05-062-1/+9
| | | | with its own PCI ID.
* Add suspend/resume code mostly merged from fxp/rl driver.iwasaki2002-05-062-0/+88
| | | | | | | This is temporary hack, better and generalized solution probably should be implemented at lower layer(MII or PCI?). Tested by: shoko.araki@soliton.co.jp MFC after: 1 week
* Don't grab the lock until somewhat later in attach to avoid a lockphk2002-05-031-6/+7
| | | | reversal.
* Move us yet closer to IFM_* definitions in NetBSD.phk2002-04-291-6/+6
|
* Follow NetBSD and s/IFM_1000_TX/IFM_1000_T/phk2002-04-282-5/+5
|
* Move the new byte order function prototypes from <sys/param.h> tomike2002-04-261-0/+1
| | | | <sys/endian.h>. This puts us in line with NetBSD and OpenBSD.
* Redo the pps bit to avoid digging into the private bits of the timecounter.phk2002-04-261-4/+2
|
* Simplify the RFC2783 and PPS_SYNC timestamp collection API.phk2002-04-261-2/+8
|
* Move tx(4) driver to sys/dev/tx. BTW split hardware structures and constantssemenu2002-04-192-2334/+0
| | | | | | into if_txreg.h. MFC after: 1 week
* Add DEVICE_POLLING support to the "rl" driver.luigi2002-04-162-6/+73
| | | | | | The diffs are very similar to the ones for the "sis" driver. MFC After: 5 days
OpenPOWER on IntegriCloud