summaryrefslogtreecommitdiffstats
path: root/src/drivers
Commit message (Collapse)AuthorAgeFilesLines
...
* [thunderx] Fix compilation with older versions of gccMichael Brown2016-06-221-2/+2
| | | | | | | Remove redundant duplicate typedef which causes a build failure on older gcc versions. Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [smsc75xx] Allow up to 100ms for reset to completeMichael Brown2016-06-202-11/+16
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [virtio] Fix virtio-pci loggingLadi Prosek2016-06-201-7/+7
| | | | | | | | | iPXE debug logging doesn't support %u. This commit replaces it with %d in virtio-pci debug format strings. Signed-off-by: Ladi Prosek <lprosek@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [thunderx] Retrieve base MAC address via EFI_THUNDER_CONFIG_PROTOCOLMichael Brown2016-06-182-1/+250
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [intel] Add PCI device ID for another I219-LMChristian Nilsson2016-06-161-0/+1
| | | | | Tested-by: Kuniyasu Suzaki <k.suzaki@aist.go.jp> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [thunderx] Fix channel configuration for VNICs 1-7Michael Brown2016-06-151-1/+1
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [thunderx] Add driver for Cavium ThunderX SoC NICsMichael Brown2016-06-132-0/+2617
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [tg3] Add missing memory barrierLeendert van Doorn2016-06-131-0/+2
| | | | | | | | | ARM64 has a weaker memory order model than x86. The missing memory barrier caused phy initialization notification to be delayed beyond the link-wait timeout (15 secs). Signed-off-by: Leendert van Doorn <leendert@paramecium.org> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [tg3] Fix address truncation bug on 64-bit machinesLeendert van Doorn2016-06-102-2/+2
| | | | | Signed-off-by: Leendert van Doorn <leendert@paramecium.org> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [pci] Support systems with multiple PCI root bridgesMichael Brown2016-06-093-10/+12
| | | | | | | | | Extend the 16-bit PCI bus:dev.fn address to a 32-bit seg:bus:dev.fn address, assuming a segment value of zero in contexts where multiple segments are unsupported by the underlying data structures (e.g. in the iBFT or BOFM tables). Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [axge] Add driver for ASIX 10/100/1000 USB Ethernet NICsMichael Brown2016-05-262-0/+972
| | | | | | | Add driver for the AX88178A (USB2) and AX88179 (USB3) 10/100/1000 Ethernet NICs. Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [pci] Add support for PCI Enhanced AllocationMichael Brown2016-05-201-0/+149
| | | | | | | Some embedded devices have immovable BARs, which are described via a PCI Enhanced Allocation capability. Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [ath9k] Fix buffer overrun for ar9287Christian Hesse2016-05-121-4/+3Star
| | | | | | | | This backport is from linux kernel upstream commit 83d6f1f ("ath9k: fix buffer overrun for ar9287"). Signed-off-by: Christian Hesse <mail@eworm.de> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [efi] Guard against GetStatus() failing to return a NULL TX bufferMichael Brown2016-05-121-0/+1
| | | | | | | | | | | | | | | The UEFI specification requires the EFI_SIMPLE_NETWORK_PROTOCOL GetStatus() method to set TxBuf to NULL if there are no transmit buffers to recycle. Some implementations (observed with Lan9118Dxe in EDK2) fill in TxBuf only when there is a transmit buffer to recycle, which leads to large numbers of "spurious TX completion" errors. Work around this problem by initialising TxBuf to NULL before calling the GetStatus() method. Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [ath] Fix building with GCC 6Michael Brown2016-05-049-150/+101Star
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [golan] Fix building with GCC 6Michael Brown2016-05-042-6/+21
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [skge] Fix building with GCC 6Michael Brown2016-05-041-5/+0Star
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [sis190] Fix building with GCC 6Michael Brown2016-05-042-13/+0Star
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [tg3] Fix _tg3_flag() for 64-bit buildsMichael Brown2016-05-021-1/+1
| | | | | | | | | | | Commit 86f96a4 ("[tg3] Remove x86-specific inline assembly") introduced a regression in _tg3_flag() in 64-bit builds, since any flags in the upper 32 bits of a 64-bit unsigned long would be discarded when truncating to a 32-bit int. Debugged-by: Shane Thompson <shane.thompson@aeontech.com.au> Tested-by: Shane Thompson <shane.thompson@aeontech.com.au> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [virtio] Add virtio-net 1.0 supportLadi Prosek2016-04-151-11/+251
| | | | | | | | | | | | | | This commit makes virtio-net support devices with VEN 0x1af4 and DEV 0x1041, which is how non-transitional (modern-only) virtio-net devices are exposed on the PCI bus. Transitional devices supporting both the old 0.9.5 and new 1.0 version of the virtio spec are driven using the new protocol. Legacy devices are driven using the old protocol, same as before this commit. Signed-off-by: Ladi Prosek <lprosek@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [virtio] Add virtio 1.0 PCI supportLadi Prosek2016-04-153-11/+364
| | | | | | | | | | | | This commit adds support for driving virtio 1.0 PCI devices. In addition to various helpers, a number of vpm_ functions are introduced to be used instead of their legacy vp_ counterparts when accessing virtio 1.0 (aka modern) devices. Signed-off-by: Ladi Prosek <lprosek@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Modified-by: Michael Brown <mcb30@ipxe.org> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [virtio] Add virtio 1.0 constants and data structuresLadi Prosek2016-04-151-0/+16
| | | | | | | | | | Virtio 1.0 introduces new constants and data structures, common to all devices as well as specific to virtio-net. This commit adds a subset of these to be able to drive the virtio-net 1.0 network device. Signed-off-by: Ladi Prosek <lprosek@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [pci] Add pci_find_next_capability()Ladi Prosek2016-04-151-13/+41
| | | | | | | | | | | | | | | | | PCI devices may support more capabilities of the same type (for example PCI_CAP_ID_VNDR) and there was no way to discover all of them. This commit adds a new API pci_find_next_capability which provides this functionality. It would typically be used like so: for (pos = pci_find_capability(pci, PCI_CAP_ID_VNDR); pos > 0; pos = pci_find_next_capability(pci, pos, PCI_CAP_ID_VNDR)) { ... } Signed-off-by: Ladi Prosek <lprosek@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [golan] Add missing iounmap()Wissam Shoukair2016-04-121-1/+2
| | | | | Signed-off-by: Wissam Shoukair <wissams@mellanox.com> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [mlx_icmd] Fix compilation error in GCC versions newer than 4.6.4Wissam Shoukair2016-04-121-1/+1
| | | | | Signed-off-by: Wissam Shoukair <wissams@mellanox.com> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [qib7322] Validate payload lengthMichael Brown2016-03-301-3/+10
| | | | | | | | | | | There is no way for the hardware to give us an invalid length in the LRH, since it must have parsed this length field in order to perform header splitting. However, this is difficult to prove conclusively. Add an unnecessary length check to explicitly reject any packets larger than the posted receive I/O buffer. Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [linda] Validate payload lengthMichael Brown2016-03-301-3/+10
| | | | | | | | | | | There is no way for the hardware to give us an invalid length in the LRH, since it must have parsed this length field in order to perform header splitting. However, this is difficult to prove conclusively. Add an unnecessary length check to explicitly reject any packets larger than the posted receive I/O buffer. Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [intel] Add PCI device ID for another I219-VChristian Nilsson2016-03-291-0/+1
| | | | | Signed-off-by: Christian Nilsson <nikize@gmail.com> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [iscsi] Include DHCP server address in iBFTMichael Brown2016-03-291-0/+1
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [golan] Fix build error on some versions of gccChristian Hesse2016-03-231-1/+1
| | | | | | | | | | | Some versions of gcc complain that "'__bswap_variable_32' is static but used in inline function 'golan_check_rc_and_cmd_status' which is not static". Fix by making golan_check_rc_and_cmd_status() a static inline. Modified-by: Michael Brown <mcb30@ipxe.org> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [golan] Add Connect-IB, ConnectX-4 and ConnectX-4 Lx (Infiniband) supportWissam Shoukair2016-03-2255-0/+13087
| | | | | Signed-off-by: Wissam Shoukair <wissams@mellanox.com> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [arbel] Fix received packet lengthMichael Brown2016-03-221-2/+3
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [hermon] Fix received packet lengthMichael Brown2016-03-221-2/+3
| | | | | Debugged-by: Wissam Shoukair <wissams@mellanox.com> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [etherfabric] Avoid use of sleep() in driver codeMichael Brown2016-03-221-1/+1
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [3c5x9] Avoid use of sleep() in driver codeMichael Brown2016-03-221-1/+1
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [infiniband] Allow drivers to override the eIPoIB LEMACMichael Brown2016-03-211-0/+1
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [arbel] Allocate space for GRH on UD queue pairsMichael Brown2016-03-212-16/+55
| | | | | | | As with the previous commit (for Hermon), allocate a separate ring buffer to hold received GRHs. Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [hermon] Allocate space for GRH on UD queue pairsMichael Brown2016-03-212-12/+47
| | | | | | | | | | | | | | | | | | | | | | | | | The Infiniband specification (volume 1, section 11.4.1.2 "Post Receive Request") notes that for UD QPs, the GRH will be placed in the first 40 bytes of the receive buffer if present. (If no GRH is present, which is normal, then the first 40 bytes of the receive buffer will be unused.) Mellanox hardware performs this placement automatically: other headers will be stripped (and their values returned via the CQE), but the first 40 bytes of the data buffer will be consumed by the (probably non-existent) GRH. This does not fit neatly into iPXE's internal abstraction, which expects the data buffer to represent just the data payload with the addresses from the GRH (if present) passed as additional parameters to ib_complete_recv(). The end result of this discrepancy is that attempts to receive full-sized 2048-byte IPoIB packets on Mellanox hardware will fail. Fix by allocating a separate ring buffer to hold the received GRHs. Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [qib7322] Add missing iounmap()Michael Brown2016-03-201-1/+3
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [linda] Add missing iounmap()Michael Brown2016-03-201-1/+3
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [arbel] Add missing iounmap()Michael Brown2016-03-201-10/+14
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [hermon] Add missing iounmap()Michael Brown2016-03-201-22/+20Star
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [ipoib] Allow external code to identify IPoIB network devicesMichael Brown2016-03-201-0/+18
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [pseudobit] Rename bitops.h to pseudobit.hMichael Brown2016-03-162-4/+4
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [tg3] Remove x86-specific inline assemblyMichael Brown2016-03-121-27/+9Star
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [3c595] Fix compilation when "char" is unsigned by defaultMichael Brown2016-03-121-1/+1
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [qib7322] Use standard readq() and writeq() implementationsMichael Brown2016-03-121-26/+8Star
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [linda] Use standard readq() and writeq() implementationsMichael Brown2016-03-121-26/+8Star
| | | | | | | | | This driver is the original source of the current readq() and writeq() implementations for 32-bit iPXE. Switch to using the now-centralised definitions, to avoid including architecture-specific code in an otherwise architecture-independent driver. Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [eoib] Support non-FullMember gateway devicesMichael Brown2016-03-091-2/+98
| | | | | | | | | | | | | Some EoIB implementations utilise an EoIB-to-Ethernet gateway device that does not perform a FullMember join to the multicast group for the EoIB broadcast domain. This has various exciting side-effects, such as requiring every EoIB node to send every broadcast packet twice. As an added bonus, the gateway may also break the EoIB MAC address to GID mapping protocol by sending Ethernet-sourced packets from the wrong QPN. Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [eoib] Allow the multicast group to be forcefully createdMichael Brown2016-03-091-2/+2
| | | | | | | | | | | | | Some EoIB implementations require each individual EoIB node to create the multicast group for the EoIB broadcast domain. It is left as an exercise for the interested reader to determine how such an implementation might ever allow the parameters of such a multicast group to be changed without requiring a simultaneous upgrade of every driver on every operating system on every machine currently attached to the fabric. Signed-off-by: Michael Brown <mcb30@ipxe.org>