summaryrefslogtreecommitdiffstats
path: root/sys/dev/bce
Commit message (Collapse)AuthorAgeFilesLines
* Add support for SERDES PHY configurations. These are commonly found indwhite2007-01-261-43/+13
| | | | | | | blade systems, such as the Dell 1955 and the Intel SBXD132. Development hardware for this work was provided by Broadcom and iXsystems. A SBXD132 blade for testing was provided by Iron Systems.
* The multicast hash table has 8 slots in the BCE hardware, not 4 slots likescottl2007-01-201-4/+4
| | | | | | | the BGE hardware. Adapt the driver for this. Submitted by: Mike Karels MFC After: 3 days
* - Add a locked variant of bce_ifmedia_upd() for use within the driver andjhb2007-01-131-7/+18
| | | | | | | | add missing locking to bce_ifmedia_upd(). - While I'm here, unexpand an instance of LIST_FOREACH(). MFC after: 2 weeks Reviewed by: scottl
* Space cleanup.delphij2007-01-111-1/+1
|
* - Instead of if_watchdog/if_timer interface use our own timerdelphij2007-01-112-29/+28
| | | | | | | | | that piggybacks on bce_tick() callout. - Instead of unconditionally resetting the controller, try to skip the reset in case we got a pause frame, like em(4) did. - Lock bce_tick() using callout_init_mtx(). Discussed with/Reviewed by: glebius, scottl, davidch
* Fix compile with BCE_DEBUG. The last one tripped up gcc 2.95 on 4.x evenjhb2006-12-061-4/+4
| | | | with BCE_DEBUG turned off.
* Due to an incorrect macro, it appears that this driver has always beenscottl2006-11-162-14/+18
| | | | | | | | | accidentally truncating off the VLAN tag field in the TX descriptor. Fix this by splitting up the vlan_tag and flags fields into separate fields, and handling them appropriately. Sponsored by: Ironport MFC After: 3 days
* In bce_start_locked, check the used_tx_bd count rather than thejdp2006-11-161-8/+8
| | | | | | | | | | | | | | | | | | | | descriptor's mbuf pointer to see if the transmit ring is full. The mbuf pointer is set only in the last descriptor of a multi-descriptor packet. By relying on the mbuf pointers of the earlier descriptors, the driver would sometimes overwrite a descriptor belonging to a packet that wasn't completed yet. Also, tx_chain_prod wasn't updated inside the loop, causing the wrong descriptor to be checked after the first iteration. The upshot of all this was the loss of some transmitted packets at medium to high packet rates. In bce_tx_encap, remove a couple of old statements that shuffled around the tx_mbuf_map pointers. These now correspond 1-to-1 with the transmit descriptors, and they are not supposed to be changed. Correct a couple of inaccurate comments. MFC after: 1 month
* Add MSI support to em(4), bce(4), and mpt(4). For now, we only supportjhb2006-11-151-3/+11
| | | | | devices that support a maximum of 1 message, and we use that 1 message instead of the INTx rid 0 IRQ with the same interrupt handler, etc.
* Fix a typo in the device ID table that prevented 5708S chips from beingscottl2006-10-311-2/+2
| | | | | | detected. Submitted by: pyun
* Refine the checksum hack a little. It appears that the chip can handle UDPscottl2006-10-241-3/+7
| | | | | | | and TCP checksum offloading fine, it only has a problem with IP checksums on IP fragments.. Barring a fix or workaround available from the hardware, the real solution would be to have finer grained control in the stack over what can and cannot be assisted in hardware.
* There seems to be a problem with txcsum and UDP. Turn it off until it isscottl2006-10-211-0/+5
| | | | understood better. This fixes timeout problems with NFS.
* Be more like the BGE driver. Ensure that at least 16 TX descriptors arescottl2006-10-211-8/+11
| | | | | | | | | | kept unused in the ring. This check should probably be moved up to bce_start_locked at some point, as it'll make the loop up there slightly more efficient, and will eliminate a costly set of busdma operations when the ring is full. But this works for now. This makes all of my UDP torture tests work. I'll cautiously say that it might even work for other users now. Feedback is appreciated.
* I can't find any reason why an 8 byte alignment should be enforced on rxscottl2006-10-191-3/+3
| | | | | and tx buffers. Fix it there, and also don't have it be overridden by the parent tag.
* Remove some spurious debugging, and use more complete error handling forscottl2006-10-191-10/+20
| | | | tx load and fragmentation problems.
* Overhaul the transmit and dma paths:scottl2006-10-152-219/+121
| | | | | | | | | | | | | | | | | | - Use bus_dmamap_load_mbuf_sg() to eliminate the need for the callback and all of the extra bookkeeping associated with it. - Eliminate the bce_dmamap_arg structure and streamline the memory allocation routines to not need it. This does change some of the debugging messages. - Refactor the loop that fills the buffer descriptor so that it can be done with a single set of logic in a single loop instead of two sets of logic. - Eliminate the need to cache and pass descriptor indexes between the start loop and the encap function. - Change the start loop to always check the ifnet sendq for more work. This significantly helps the driver withstand large UDP workloads, though it's still not perfect. I suspect the remaining work lies with handling the OACTIVE flag, and also in possibly streamlining the interrupt handler some. It is, however, nearly on par with the other popular gigabit drivers in terms of stability now.
* Simplify the arguments to bce_tx_encap.scottl2006-10-141-17/+14
|
* More small whitespace cleanupsscottl2006-10-141-4/+4
|
* Don't copy the bd_chain head pointers into temporary objects, they arescottl2006-10-142-7/+3
| | | | available globally.
* Fix some whitespacescottl2006-10-131-95/+95
|
* Add a new 'bce_mgmt_init_locked' function to enable the minimal partsambrisko2006-09-201-0/+44
| | | | | | | | | of the chip to let ASF/IPMI firmware to respond to IPMI after attaching and when the chip is down. David looked at it but could really say what they right minimal config. stuff would be. It's not documented. I figured this out via trial and error. Reviewed by: davidch
* Move ethernet VLAN tags from mtags to its own mbuf packet header fieldandre2006-09-171-7/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | m_pkthdr.ether_vlan. The presence of the M_VLANTAG flag on the mbuf signifies the presence and validity of its content. Drivers that support hardware VLAN tag stripping fill in the received VLAN tag (containing both vlan and priority information) into the ether_vtag mbuf packet header field: m->m_pkthdr.ether_vtag = vlan_id; /* ntohs()? */ m->m_flags |= M_VLANTAG; to mark the packet m with the specified VLAN tag. On output the driver should check the mbuf for the M_VLANTAG flag to see if a VLAN tag is present and valid: if (m->m_flags & M_VLANTAG) { ... = m->m_pkthdr.ether_vtag; /* htons()? */ ... pass tag to hardware ... } VLAN tags are stored in host byte order. Byte swapping may be necessary. (Note: This driver conversion was mechanic and did not add or remove any byte swapping in the drivers.) Remove zone_mtag_vlan UMA zone and MTAG_VLAN definition. No more tag memory allocation have to be done. Reviewed by: thompsa, yar Sponsored by: TCP/IP Optimization Fundraise 2005
* Remove extra '*/' comment close. In code not normally compiled but a bug ↵julian2006-08-151-1/+0
| | | | never the less.
* Expand locking coverage slightly to cover if_drv_flags in a few placesjhb2006-07-201-4/+8
| | | | | | | where it wasn't locked. MFC after: 3 days Reviewed by: davidch
* Fix ifconfig up when the HW was down. If the driver isn't runningambrisko2006-07-121-2/+7
| | | | | | | | | then we need to call init otherwise just start the rx. Interestingly dhclient seemed to work but ifconfig <IP> didn't for me. Reviewed by: jhb
* Log:davidch2006-06-081-13/+27
| | | | | | | | | | - Removed updates to if_ibytes, if_obytes, if_imcasts, and if_omcasts. These should not be handled by the driver. - Add code to handle excessively fragmented mbufs when mapping TX frames. Reviewed by: ps Approved by: ps (mentor) MFC after: 1 week
* Since DELAY() was moved, most <machine/clock.h> #includes have beenphk2006-05-161-1/+0
| | | | unnecessary.
* Gratuitous tag alignment. It bugged me.mjacob2006-05-041-1/+1
|
* Only use the low address for stats collection.ps2006-04-261-3/+1
|
* Fix half of the current i386 tinderbox failure. max_bus_addr should be ajhb2006-04-251-1/+1
| | | | bus_addr_t rather than a bus_size_t.
* Fix DEVICE_POLLING support (compile-only tested).ru2006-04-131-1/+5
|
* Hook bce up to the buildps2006-04-101-0/+2
|
* Add a driver for the Broadcom NetXtreme II (BCM5706/BCM5708)ps2006-04-103-0/+15209
PCI/PCIe Gigabit Ethernet adapeter. Submitted by: David Christensen
OpenPOWER on IntegriCloud