summaryrefslogtreecommitdiffstats
path: root/src/include
Commit message (Collapse)AuthorAgeFilesLines
* [pci] Add PCI_COMMAND_INTX_DISABLEGlenn Brown2010-01-141-0/+1
| | | | | | | | Taken from Linux /usr/include/linux/pci.h . Signed-off-by: Glenn Brown <glenn@myri.com> Signed-off-by: Stefan Hajnoczi <stefanha@gmail.com> Signed-off-by: Marty Connor <mdc@etherboot.org>
* [wpa] Add CCMP backend (new AES-based cryptosystem)Joshua Oreman2010-01-051-0/+1
| | | | Signed-off-by: Marty Connor <mdc@etherboot.org>
* [wpa] Add TKIP backend (legacy RC4-based cryptosystem)Joshua Oreman2010-01-051-0/+1
| | | | Signed-off-by: Marty Connor <mdc@etherboot.org>
* [wpa] Add pre-shared key frontend (WPA "Personal" with just a passphrase)Joshua Oreman2010-01-051-0/+1
| | | | | Modified-by: Marty Connor <mdc@etherboot.org> Signed-off-by: Marty Connor <mdc@etherboot.org>
* [wpa] Add general support for WPA-protected 802.11 networksJoshua Oreman2010-01-052-0/+504
| | | | | Modified-by: Marty Connor <mdc@etherboot.org> Signed-off-by: Marty Connor <mdc@etherboot.org>
* [eapol] Add basic support for 802.1X EAP over LANsJoshua Oreman2010-01-053-0/+114
| | | | | | | | | EAPOL is a container protocol that can wrap either EAP packets or 802.11 EAPOL-Key frames. For cleanliness' sake, add a stub that strips the framing and sends packets off to the appropriate handler if it is compiled in. Signed-off-by: Marty Connor <mdc@etherboot.org>
* [802.11] Add support for WEP-protected networksJoshua Oreman2010-01-051-0/+1
| | | | | | | | WEP is a highly flawed cryptosystem, barely better than no encryption at all, but many people still use it. It does have the advantage of being very simple and small in code size. Signed-off-by: Marty Connor <mdc@etherboot.org>
* [iwmgmt] Add wireless management commands and text for common errorsJoshua Oreman2010-01-052-0/+18
| | | | | | | | Add commands `iwstat' (to list 802.11-specific status information for 802.11 devices) and `iwlist' (to scan for available networks and print a list along with security information). Signed-off-by: Marty Connor <mdc@etherboot.org>
* [802.11] Add core support for detecting and using encrypted networksJoshua Oreman2010-01-054-144/+376
| | | | Signed-off-by: Marty Connor <mdc@etherboot.org>
* [crypto] Add a placeholder for a proper random number generatorJoshua Oreman2010-01-051-0/+2
| | | | | | Currently it just calls random(). Signed-off-by: Marty Connor <mdc@etherboot.org>
* [crypto] Add AES key-wrap mode (RFC 3394)Joshua Oreman2010-01-051-0/+3
| | | | | | | The unwrapping half is used by WPA2 code; the wrapping half is currently unused. Signed-off-by: Marty Connor <mdc@etherboot.org>
* [crypto] Make AES context size and algorithm structure externally availableJoshua Oreman2010-01-051-0/+17
| | | | | | This is required to support modes of AES beyond cipher-block chaining. Signed-off-by: Marty Connor <mdc@etherboot.org>
* [crypto] Add parentheses around len argument in blocksize assertJoshua Oreman2010-01-051-2/+2
| | | | | | | | This fixes an issue where passing a length as a compound expression (e.g. using `hdrlen + datalen') would trigger compiler warnings and potentially precedence-related errors. Signed-off-by: Marty Connor <mdc@etherboot.org>
* [digest] Add HMAC-SHA1 based pseudorandom function and PBKDF2Joshua Oreman2010-01-051-0/+9
| | | | | | | Both of these routines are used by 802.11 WPA, but they are generic and could be needed by other protocols as well. Signed-off-by: Marty Connor <mdc@etherboot.org>
* [cipher] Add the ARC4 stream cipherJoshua Oreman2010-01-051-0/+22
| | | | Signed-off-by: Marty Connor <mdc@etherboot.org>
* [digest] Add generic CRC32 functionJoshua Oreman2010-01-051-0/+10
| | | | Signed-off-by: Marty Connor <mdc@etherboot.org>
* [settings] Add Bus ID settingShao Miller2009-12-141-0/+1
| | | | | | | | Users can find the bus type and PCI IDs for a network interface with: netX/busid Signed-off-by: Stefan Hajnoczi <stefanha@gmail.com>
* [linker] Add mechanism for subsystem-dependent configuration optionsJoshua Oreman2009-11-211-0/+5
| | | | | | | | | | | | | | | | | | | | It is often the case that some module of gPXE is only relevant if the subsystem it depends on is already being included. For instance, commands to manage wireless interfaces are quite useless if no compiled-in driver has pulled in the wireless networking stack. There may be a user-modifiable configuration options for these dependent modules, but even if enabled, they should not be included when they would be useless. Solve this by allowing the creation of config_subsystem.c, for configuration directives like those in the global config.c that should only be considered when subsystem.c is included in the final gPXE build. For consistency, move core/config.c to the config/ directory, where the other config_subsystem.c files will eventually reside. Signed-off-by: Marty Connor <mdc@etherboot.org>
* [linker] Expand and correct symbol requirement macrosJoshua Oreman2009-11-211-10/+95
| | | | | | | | | | | | | | | REQUIRE_SYMBOL() formerly used a formulation of symbol requirement that would allow a link to succeed despite lacking a required symbol, because it did not introduce any relocations. Fix by renaming it to REQUEST_SYMBOL() (since the soft-requirement behavior can be useful) and add a REQUIRE_SYMBOL() that truly requires. Add EXPORT_SYMBOL() and IMPORT_SYMBOL() for REQUEST_SYMBOL()-like behavior that allows one to make use of the symbol, by combining a weak external on the symbol itself with a REQUEST_SYMBOL() of a second symbol. Signed-off-by: Marty Connor <mdc@etherboot.org>
* [ipoib] Mask out non-QPN bits in the IPoIB destination MAC when sendingMichael Brown2009-11-162-2/+6
| | | | | | | The first byte of the IPoIB MAC address is used for flags indicating support for "connected mode". Strip out the non-QPN bits of the first dword when constructing the address vector for transmitted IPoIB packets, so as not to end up passing an invalid QPN in the BTH.
* [ipoib] Always set the "full membership" bit in the IPv4 broadcast GIDMichael Brown2009-11-161-0/+3
| | | | | The SM always creates the IPoIB multicast groups with full membership partition keys.
* [infiniband] Rename IB_PKEY_NONE to IB_PKEY_DEFAULTMichael Brown2009-11-161-1/+1
| | | | There is no such thing as a non-existent partition.
* [infiniband] Report IB link status as IPoIB netdevice statusMichael Brown2009-11-161-0/+1
|
* [sanboot] Extend the "keep-san" option to non-iSCSI SAN protocolsMichael Brown2009-11-041-0/+2
| | | | This disgustingly ugly hack just keeps getting worse.
* [sis190] Hide the ISA bridge's PCI IDs from parserom.plThomas Miletich2009-10-241-1/+6
| | | | | Signed-off-by: Michael Brown <mcb30@etherboot.org> Modified-by: Michael Brown <mcb30@etherboot.org>
* [netdevice] Add the concept of an "Ethernet-compatible" MAC addressMichael Brown2009-10-232-6/+14
| | | | | | | | | | | | | | The iBFT is Ethernet-centric in providing only six bytes for a MAC address. This is most probably an indirect consequence of a similar design flaw in the Windows NDIS stack. (The WinOF IPoIB stack performs all sorts of contortions in order to pretend to the NDIS layer that it is dealing with six-byte MAC addresses.) There is no sensible way in which to extend the iBFT without breaking compatibility with programs that expect to parse it. Add the notion of an "Ethernet-compatible" MAC address to our link layer abstraction, so that link layers can provide their own workarounds for this limitation.
* [sis190] Add sis190/191 ethernet driverThomas Miletich2009-10-161-0/+1
| | | | | Tested-by: Paul Hackett <paulfxhackett@gmail.com> Signed-off-by: Marty Connor <mdc@etherboot.org>
* [atl1e] Add Attansic L1E gigabit Ethernet driverJoshua Oreman2009-10-161-0/+1
| | | | Signed-off-by: Marty Connor <mdc@etherboot.org>
* [pci] Add generic configuration space backup/restore facilityMichael Brown2009-10-141-0/+33
| | | | | | Some devices can only be reset via a mechanism that also resets the card's PCI core, thus necessitating a backup and restore of all or part of the PCI configuration space across a reset.
* [job] Add missing job_progress() interface methodMichael Brown2009-08-311-0/+2
|
* [802.11] Support multicast hashingMichael Brown2009-08-121-0/+2
| | | | | | | 802.11 multicast hashing is the same as standard Ethernet hashing, so just expose and use eth_mc_hash(). Signed-off-by: Joshua Oreman <oremanj@rwcr.net>
* [dhcp] Fall back to using the hardware address to populate the chaddr fieldMichael Brown2009-08-121-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | For IPoIB, the chaddr field is too small (16 bytes) to contain the 20-byte IPoIB link-layer address. RFC4390 mandates that we should pass an empty chaddr field and rely on the DHCP client identifier instead. This has many problems, not least of which is that a client identifier containing an IPoIB link-layer address is not very useful from the point of view of creating DHCP reservations, since the QPN component is assigned at runtime and may vary between boots. Leave the DHCP client identifier as-is, to avoid breaking existing setups as far as possible, but expose the real hardware address (the port GUID) via the DHCP chaddr field, using the broadcast flag to instruct the DHCP server not to use this chaddr value as a link-layer address. This makes it possible (at least with ISC dhcpd) to create DHCP reservations using host declarations such as: host duckling { fixed-address 10.252.252.99; hardware unknown-32 00:02:c9:02:00:25:a1:b5; }
* [netdevice] Allow the hardware and link-layer addresses to differ in sizeMichael Brown2009-08-122-2/+21
| | | | | | | | | | IPoIB has a 20-byte link-layer address, of which only eight bytes represent anything relating to a "hardware address". The PXE and EFI SNP APIs expect the permanent address to be the same size as the link-layer address, so fill in the "permanent address" field with the initial link layer address (as generated by register_netdev() based upon the real hardware address).
* [netdevice] Separate out the concept of hardware and link-layer addressesMichael Brown2009-08-121-4/+11
| | | | | | | | | | | The hardware address is an intrinsic property of the hardware, while the link-layer address can be changed at runtime. This separation is exposed via APIs such as PXE and EFI, but is currently elided by gPXE. Expose the hardware and link-layer addresses as separate properties within a net device. Drivers should now fill in hw_addr, which will be used to initialise ll_addr at the time of calling register_netdev().
* [infiniband] Disambiguate CM connection rejection reasonsMichael Brown2009-08-101-0/+5
| | | | | | | | | | | | | There is diagnostic value in being able to disambiguate between the various reasons why an IB CM has rejected a connection attempt. In particular, reason 8 "invalid service ID" can be used to identify an incorrect SRP service_id root-path component, and reason 28 "consumer reject" corresponds to a genuine SRP login rejection IU, which can be passed up to the SRP layer. For rejection reasons other than "consumer reject", we should not pass through the private data, since it is most likely generated by the CM without any protocol-specific knowledge.
* [infiniband] Allow SRP reconnection attempts even after reporting failuresMichael Brown2009-08-101-6/+0Star
| | | | | | | | | With iSCSI, connection attempts are expensive; it may take many seconds to determine that a connection will fail. SRP connection attempts are much less expensive, so we may as well avoid the "optimisation" of declaring a state of permanent failure after a certain number of attempts. This allows a gPXE SRP initiator to resume operations after an arbitrary amount of SRP target downtime.
* [infiniband] Add support for SRP over InfinibandMichael Brown2009-08-104-0/+957
| | | | | | | | SRP is the SCSI RDMA Protocol. It allows for a method of SAN booting whereby the target is responsible for reading and writing data using Remote DMA directly to the initiator's memory. The software initiator merely sends and receives SCSI commands; it never has to touch the actual data.
* [infiniband] Add last_opened_ibdev(), analogous to last_opened_netdev()Michael Brown2009-08-101-0/+3
| | | | | | | The minimal-surprise behaviour, when no explicit SRP initiator device is specified, will probably be to use the most recently opened Infiniband device. This matches our behaviour with using the most recently opened net device for PXE, iSCSI, AoE, NBI, etc.
* [infiniband] Add find_ibdev()Michael Brown2009-08-101-0/+1
|
* [infiniband] Add a "communication-managed reliable connection" protocolMichael Brown2009-08-102-0/+21
| | | | | | | SRP over Infiniband uses a protocol whereby data is sent via a combination of the CM private data fields and the RC queue pair itself. This seems sufficiently generic that it's worth having available as a separate protocol.
* [scsi] Make LUN a property of the SCSI backend onlyMichael Brown2009-08-101-2/+0Star
| | | | | Nothing within the SCSI core actually refers to the LUN, so we can simplify matters by treating it as purely a property of the backend.
* [scsi] Generalise iscsi_parse_lun() to scsi_parse_lun()Michael Brown2009-08-102-11/+17
|
* [scsi] Generalise iscsi_detached_command() to scsi_detached_command()Michael Brown2009-08-101-0/+2
|
* [process] Make it safe to call process_add() multiple timesMichael Brown2009-08-101-0/+1
|
* [infiniband] Handle duplicate Communication Management REPsMichael Brown2009-08-091-0/+3
| | | | | | | | | | | We will terminate our transaction as soon as we receive the first CM REP, since that provides all the state that we need. However, the peer may resend the REP if it didn't see our RTU, and if we don't respond with another RTU we risk being disconnected. (This protocol appears not to handle retries gracefully.) Fix by adding a management agent that will listen for these duplicate REPs and send back an RTU.
* [ath5k] Add support for non-802.11n Atheros wireless NICsJoshua Oreman2009-08-091-0/+1
| | | | Signed-off-by: Michael Brown <mcb30@etherboot.org>
* [legal] Add MIT licence declarationJoshua Oreman2009-08-091-0/+10
| | | | Signed-off-by: Michael Brown <mcb30@etherboot.org>
* [802.11] Fix maximum packet lengthJoshua Oreman2009-08-091-5/+13
| | | | | | | | | | | | | Previously the maximum packet length was computed using an erroneous understanding of the role of the MIC field in TKIP-encrypted packets. The field is actually considered to be part of the MSDU (encrypted and fragmented data), not the MPDU (container for each encrypted fragment). As such its size does not contribute to cryptographic overhead outside the data field's size limitations. The net result is that the previous maximum packet length value was 4 bytes too long; fix it to the correct value of 2352. Signed-off-by: Michael Brown <mcb30@etherboot.org>
* [802.11] Enhance support for driver PHY differencesJoshua Oreman2009-08-091-6/+39
| | | | | | | | | | | | | | | | | The prior net80211 model of physical-layer behavior for drivers was overly simplistic and limited the drivers that could be written. To be more flexible, split the driver-provided list of supported rates by band, and add a means for specifying a list of supported channels. Allow drivers to specify a hardware channel value that will be tied to uses of the channel. Expose net80211_duration() to drivers, and make the rate it uses in its computations configurable, so that it can be used in calculating durations that must be set in hardware for ACK and CTS packets. Add net80211_cts_duration() for the common case of calculating the duration for a CTS packet. Signed-off-by: Michael Brown <mcb30@etherboot.org>
* [infiniband] Update all other MAD users to use a management interfaceMichael Brown2009-08-096-76/+157
|