summaryrefslogtreecommitdiffstats
path: root/src/drivers
Commit message (Collapse)AuthorAgeFilesLines
* [netdevice] Allow link layer to report broadcast/multicast packets via pull()Michael Brown2011-07-151-1/+4
| | | | | | | | Allow the link layer to directly report whether or not a packet is multicast or broadcast at the time of calling pull(), rather than relying on heuristics to determine this at a later stage. Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [igb] Remove __BIG_ENDIAN conditionalThomas Miletich2011-07-151-5/+0Star
| | | | | | Reported-by: Stefan Hajnoczi <stefanha@gmail.com> Signed-off-by: Thomas Miletich <thomas.miletich@gmail.com> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [scsi] Eliminate polling while waiting for window to openMichael Brown2011-06-281-6/+13
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [process] Pass containing object pointer to process step() methodsMichael Brown2011-06-281-5/+8
| | | | | | | | | Give the step() method a pointer to the containing object, rather than a pointer to the process. This is consistent with the operation of interface methods, and allows a single function to serve as both an interface method and a process step() method. Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [forcedeth] Ensure that IRQ line is deasserted when disabling interruptsMichael Brown2011-05-041-3/+2Star
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [hermon] Remove temporary workaround for missing BOFM mport supportMichael Brown2011-05-041-39/+15Star
| | | | | | | This reverts commit 15c1200 ("[hermon] Work around missing mport support in current BOFM implementations"). Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [hermon] Work around missing mport support in current BOFM implementationsMichael Brown2011-04-081-15/+39
| | | | | | | | | | | | | | | | | | | | | | | Current BOFM versions are unable to create entries with mport>1, which means that only the port 1 MAC address can be explicitly specified. Work around this by using the provided MAC address as a base address for all subsequent ports. For example, if BOFM assigns the address 00:1A:64:76:00:09 for port 1 then we will assign the addresses 00:1A:64:76:00:09 for port 1 00:1A:64:76:00:0a for port 2 Future BOFM versions that may correctly support mport will work with this scheme without modification provided that the BOFM entries are created in increasing order of mport. Since BOFM tools tend to generate entries in increasing order (of slot, port, etc), this is not an unreasonable compromise. Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [arbel] Stop firmware only once on shutdownMichael Brown2011-04-081-1/+0Star
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [hermon] Stop firmware only once on shutdownMichael Brown2011-04-081-1/+0Star
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [device] Make driver name a generic device propertyMichael Brown2011-04-085-6/+8
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [forcedeth] Never change the NVREG_TRANSMITPOLL_MAC_ADDR_REV flagMichael Brown2011-03-301-5/+0Star
| | | | | | | | | | | iPXE operates the forcedeth NIC in promiscuous mode, and never changes the unicast MAC address filter registers. We should not therefore set the flag indicating (to other drivers loaded later) that the MAC address order has already been corrected. Reported-by: Tal Aloni <tal.aloni.il@gmail.com> Tested-by: Tal Aloni <tal.aloni.il@gmail.com> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [forcedeth] Remove software unicast MAC address filterMichael Brown2011-03-291-9/+2Star
| | | | | | | | | | | | | | | | | | | The forcedeth driver currently implements unicast MAC address filtering in software. This is almost invariably the wrong thing to do (since the network stack must already be able to cope with unwanted packets) and it breaks FCoE (which requires the card to operate in promiscuous mode). Also, the implementation is buggy: is_local_ether_addr() is used to check for a locally-assigned Ethernet address (not to check for a unicast address), and the current link-layer address is in netdev->ll_addr, not netdev->hw_addr. Fix by removing this code. Reported-by: Tal Aloni <tal.aloni.il@gmail.com> Tested-by: Tal Aloni <tal.aloni.il@gmail.com> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [forcedeth] Avoid unused-but-set variable warning in gcc 4.6Thomas Miletich2011-03-281-3/+2Star
| | | | | | | | | Avoid unused-but-set variable warning in gcc 4.6 which was introduced by commit 9215b7f ("[forcedeth] Clear the MII link status register on link status changes"). Signed-off-by: Thomas Miletich <thomas.miletich@gmail.com> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [settings] Formalise notion of setting applicabilityMichael Brown2011-03-221-4/+21
| | | | | | | | | | | | | | | Expose a function setting_applies() to allow a caller to determine whether or not a particular setting is applicable to a particular settings block. Restrict DHCP-backed settings blocks to accepting only DHCP-based settings. Restrict network device settings blocks to accepting only DHCP-based settings and network device-specific settings such as "mac". Inspired-by: Glenn Brown <glenn@myri.com> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [forcedeth] Clear the MII link status register on link status changesYann Cézard2011-03-201-0/+6
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [qib7322] Avoid unused variable warning in gcc 4.6Michael Brown2011-03-161-4/+0Star
| | | | | | Reported-by: Ralph Giles <giles@thaumas.net> Tested-by: Ralph Giles <giles@thaumas.net> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [hermon] Avoid unused variable warning in gcc 4.6Michael Brown2011-03-161-2/+0Star
| | | | | | Reported-by: Ralph Giles <giles@thaumas.net> Tested-by: Ralph Giles <giles@thaumas.net> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [arbel] Avoid unused variable warning in gcc 4.6Michael Brown2011-03-161-1/+1
| | | | | | Reported-by: Ralph Giles <giles@thaumas.net> Tested-by: Ralph Giles <giles@thaumas.net> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [vxge] Avoid unused variable warning in gcc 4.6Michael Brown2011-03-162-11/+1Star
| | | | | | Reported-by: Ralph Giles <giles@thaumas.net> Tested-by: Ralph Giles <giles@thaumas.net> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [ath5k] Avoid unused variable warning in gcc 4.6Michael Brown2011-03-163-12/+1Star
| | | | | | Reported-by: Ralph Giles <giles@thaumas.net> Tested-by: Ralph Giles <giles@thaumas.net> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [eepro] Avoid unused variable warning in gcc 4.6Michael Brown2011-03-161-0/+1
| | | | | | | | | | From a cursory examination, it appears as though the calculation of tx_available is redundant, since eepro_transmit() waits for transmit completion before returning anyway. Reported-by: Ralph Giles <giles@thaumas.net> Tested-by: Ralph Giles <giles@thaumas.net> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [w89c840] Avoid unused variable warning in gcc 4.6Michael Brown2011-03-161-2/+2
| | | | | | Reported-by: Ralph Giles <giles@thaumas.net> Tested-by: Ralph Giles <giles@thaumas.net> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [smc9000] Avoid unused variable warning in gcc 4.6Michael Brown2011-03-161-3/+0Star
| | | | | | Reported-by: Ralph Giles <giles@thaumas.net> Tested-by: Ralph Giles <giles@thaumas.net> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [etherfabric] Avoid unused variable warning in gcc 4.6Michael Brown2011-03-161-6/+1Star
| | | | | | Reported-by: Ralph Giles <giles@thaumas.net> Tested-by: Ralph Giles <giles@thaumas.net> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [sis190] Avoid unused variable warning in gcc 4.6Michael Brown2011-03-161-2/+0Star
| | | | | | Reported-by: Ralph Giles <giles@thaumas.net> Tested-by: Ralph Giles <giles@thaumas.net> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [epic100] Avoid unused variable warning in gcc 4.6Michael Brown2011-03-161-2/+0Star
| | | | | | Reported-by: Ralph Giles <giles@thaumas.net> Tested-by: Ralph Giles <giles@thaumas.net> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [sky2] Avoid unused variable warning in gcc 4.6Michael Brown2011-03-161-5/+0Star
| | | | | | Reported-by: Ralph Giles <giles@thaumas.net> Tested-by: Ralph Giles <giles@thaumas.net> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [forcedeth] Avoid unused variable warning in gcc 4.6Michael Brown2011-03-161-2/+2
| | | | | | Reported-by: Ralph Giles <giles@thaumas.net> Tested-by: Ralph Giles <giles@thaumas.net> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [ns83820] Update to standard debugging infrastructureMichael Brown2011-03-161-26/+19Star
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [atl1e] Avoid unused variable warning in gcc 4.6Michael Brown2011-03-161-5/+1Star
| | | | | | Reported-by: Ralph Giles <giles@thaumas.net> Tested-by: Ralph Giles <giles@thaumas.net> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [via-velocity] Avoid unused variable warning in gcc 4.6Michael Brown2011-03-161-16/+1Star
| | | | | | Reported-by: Ralph Giles <giles@thaumas.net> Tested-by: Ralph Giles <giles@thaumas.net> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [sis900] Avoid unused variable warning in gcc 4.6Michael Brown2011-03-161-2/+1Star
| | | | | | Reported-by: Ralph Giles <giles@thaumas.net> Tested-by: Ralph Giles <giles@thaumas.net> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [e1000] Remove unused variable when ICR register is simply clearedMichael Brown2011-03-1612-30/+24Star
| | | | | | | | | | | | | On reset and close, the ICR register is read to clear any pending interrupts, but the value is simply ignored. Avoid assigning the value to a variable, to inhibit a warning from gcc 4.6. Also fix a potential race condition in reset routines which clear interrupts before disabling them. Reported-by: Ralph Giles <giles@thaumas.net> Tested-by: Ralph Giles <giles@thaumas.net> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [igbvf] Remove some unused Linux-specific portions of igbvf.hMichael Brown2011-03-161-2/+4
| | | | | | | | | These unused portions trigger a compiler warning under gcc 4.6, due to the ambiguity over the "page" field in struct igbvf_buffer. Reported-by: Ralph Giles <giles@thaumas.net> Tested-by: Ralph Giles <giles@thaumas.net> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [phantom] Remove unused variable in phantom_dmesg()Michael Brown2011-03-161-2/+0Star
| | | | | | Reported-by: Ralph Giles <giles@thaumas.net> Tested-by: Ralph Giles <giles@thaumas.net> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [eepro100] Do not discard short packetsMichael Brown2011-03-121-1/+1
| | | | | | | | | | | In a virtual environment such as qemu, we can legitimately receive packets less than 64 bytes in length, such as ARP replies. These are currently discarded, causing most IPv4 communication to fail. Fix by ignoring the RFDShort bit when receiving packets. Reported-by: Alex Williamson <alex.williamson@redhat.com> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [console] Move include/console.h to include/ipxe/console.hMichael Brown2011-03-095-5/+5
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [spi] Reset device on each accessMichael Brown2011-03-041-0/+3
| | | | | | | | | | | | | | When chainloading rtl8139.pxe from an old Etherboot rtl8139.zrom, iPXE can end up misreading the first word of the MAC address from the EEPROM as being all zeroes. This is presumably because Etherboot has left the serial EEPROM in an unexpected state. Fix by using the chip select line to reset the SPI device before we start accessing it. Reported-by: Mandar U Jog <mandarjog@gmail.com> Tested-by: Mandar U Jog <mandarjog@gmail.com> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [arbel] Make driver 64-bit safeMichael Brown2011-03-041-2/+37
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [hermon] Make driver 64-bit safeMichael Brown2011-03-042-0/+37
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [iscsi] Change default initiator IQNMichael Brown2011-03-031-5/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The default initiator IQN is "iqn.2000-09.org.etherboot:UNKNOWN". This is problematic for two reasons: a) the etherboot.org domain (and hence the associated IQN namespace) is not under the control of the iPXE project, and b) some targets (correctly) refuse to allow concurrent connections from different initiators using the same initiator IQN. Solve both problems by changing the default initiator IQN to be iqn.2010-04.org.ipxe:<hostname> if a hostname is set, or iqn.2010-04.org.ipxe:<uuid> if no hostname is set. Explicit initiator IQNs set via DHCP option 203 are not affected by this change. Unfortunately, this change is likely to break some existing configurations, where ACL rules have been put in place referring to the old default initiator IQN. Users may need to update ACLs, or force the use of the old IQN using an iPXE script line such as set initiator-iqn iqn.2000-09.org.etherboot:UNKNOWN or a dhcpd.conf option such as option iscsi-initiator-iqn "iqn.2000-09.org.etherboot:UNKNOWN" Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [hermon] Add BOFM supportMichael Brown2011-03-033-58/+415
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [iscsi] Fix minor typo in ibft_set_ipaddr()Michael Brown2011-02-251-1/+1
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [pci] Modularise PCI device supportMichael Brown2011-02-171-47/+79
| | | | | | | | Some operating environments require (or at least prefer) that we do not perform our own PCI bus scan, but deal only with specified devices. Modularise the PCI core to allow for this. Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [pci] Make driver PCI ID a property of the PCI deviceMichael Brown2011-02-1742-96/+71Star
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [pci] Replace pci_max_bus() with pci_num_bus()Michael Brown2011-02-171-1/+1
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [pci] Use single "busdevfn" field in struct pci_deviceMichael Brown2011-02-174-71/+69Star
| | | | | | | Merge the "bus" and "devfn" fields into a single "busdevfn" field, to match the format used by the majority of external code. Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [hermon] Add missing __attribute__ (( packed ))Michael Brown2011-02-171-2/+2
| | | | | | | | | | On 64-bit builds, MLX_DECLARE_STRUCT() produces a structure that is always a multiple of 64 bits long, causing the HCR structure to be over-length by one dword. This in turn causes hermon_cmd() to write beyond the end of the HCR, which causes commands to fail. Reported-by: Itay Gazit <itayg@mellanox.co.il> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [hermon] Force link speed to SDRItay Gazit2011-02-173-5/+62
| | | | | | | SDR link comes up much faster than other speeds. Signed-off-by: Itay Gazit <itaygazit@gmail.com> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [hermon] Use circular event queueItay Gazit2011-02-172-4/+10
| | | | | | | | | Avoid memory leak of untreated events by having circular event queue operation. Signed-off-by: Itay Gazit <itaygazit@gmail.com> Modified-by: Michael Brown <mcb30@ipxe.org> Signed-off-by: Michael Brown <mcb30@ipxe.org>