ipxe.git
6 years ago[int13con] Add basic ability to log to a local disk via INT 13
Michael Brown [Mon, 18 May 2015 15:02:02 +0000 (16:02 +0100)] 
[int13con] Add basic ability to log to a local disk via INT 13

Several popular public cloud providers do not provide any sensible
mechanism for obtaining debug output from an OS which is failing to
boot.  For example, Amazon EC2 provides the "Get System Log" facility,
which occasionally deigns to report a random subset of the characters
emitted via the VM's serial port, but usually returns only a blank
screen.  (Amazingly, this is still superior to the debugging
facilities provided by Azure.)

Work around these shortcomings by adding a console type which sends
output to a magically detected raw disk partition, and including such
a partition within any iPXE .usb-format image.

To use this facility:

 - build an iPXE .usb image with CONSOLE_INT13 enabled

 - boot the cloud VM from this image

 - after the boot fails, attach the VM's boot disk to a second VM

 - from this second VM, use "less -f -R /dev/sdb3" (or similar) to
   view the iPXE output.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[intel] Add intelxvf driver for Intel 10 GigE virtual function NICs
Michael Brown [Sat, 16 May 2015 13:36:56 +0000 (14:36 +0100)] 
[intel] Add intelxvf driver for Intel 10 GigE virtual function NICs

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[intel] Add support for mailbox used by virtual functions
Michael Brown [Sat, 16 May 2015 13:35:13 +0000 (14:35 +0100)] 
[intel] Add support for mailbox used by virtual functions

Virtual functions use a mailbox to communicate with the physical
function driver: this covers functionality such as obtaining the MAC
address.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[intel] Allow for the use of advanced TX descriptors
Michael Brown [Sat, 16 May 2015 13:26:00 +0000 (14:26 +0100)] 
[intel] Allow for the use of advanced TX descriptors

Intel virtual function NICs almost work with the use of "legacy"
transmit and receive descriptors (which are backwards compatible right
back to the original Intel Gigabit NICs).

Unfortunately the "TX switching" feature (which allows for VM<->VM
traffic to be looped back within the NIC itself) does not work when a
legacy TX descriptor is used: the packet is instead sent onto the
wire.

Fix by allowing for the use of an "advanced" TX descriptor (containing
exactly the same information as is found in the "legacy" descriptor).

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[intel] Expose intel_diag() for use by other Intel NIC drivers
Michael Brown [Fri, 15 May 2015 10:52:56 +0000 (11:52 +0100)] 
[intel] Expose intel_diag() for use by other Intel NIC drivers

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[usb] Always clear recorded disconnections after performing hotplug actions
Michael Brown [Wed, 13 May 2015 13:45:21 +0000 (14:45 +0100)] 
[usb] Always clear recorded disconnections after performing hotplug actions

The recorded disconnections (in port->disconnected) will currently be
left uncleared if usb_attached() returns an error (e.g. because there
are no drivers for a particular USB device).  This is incorrect
behaviour: the disconnection has been handled and the record should be
cleared until the next physical disconnection is detected (via the CSC
bit).

The problem is masked for EHCI, UHCI, and USB hubs, since these will
report a changed port (via usb_port_changed()) only when the
underlying hardware reports a change.  xHCI will call
usb_port_changed() in response to any port status event, at which
point the stale value of port->disconnected will be erroneously acted
upon.  This can lead to an endless loop of repeatedly enumerating the
same device when a driverless device is attached to an xHCI root hub
port.

Fix by unconditionally clearing port->disconnected in usb_hotplugged().

Reported-by: Robin Smidsrød <robin@smidsrod.no>
Tested-by: Robin Smidsrød <robin@smidsrod.no>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[usb] Do not call usb_hotplug() when registering a new hub
Michael Brown [Wed, 13 May 2015 13:13:09 +0000 (14:13 +0100)] 
[usb] Do not call usb_hotplug() when registering a new hub

The action of registering a new hub can itself happen in only two
ways: either a new USB hub has been created (in which case we are
already inside a call to usb_hotplug()), or a new root hub has been
created.

In the former case, we do not need to issue a further call to
usb_hotplug(), since the hub's ports will all be marked as changed and
so will be handled after the return from register_usb_hub() anyway.
Calling usb_hotplug() within register_usb_hub() leads to a confusing
order of events, such as:

- root hub port 1 detects a change
- root hub port 2 detects a change
- usb_hotplug() is called
  - root hub port 1 finds a USB hub
    - usb_hotplug() is called
      - this inner call to usb_hotplug() handles root hub port 2

Fix by calling usb_hotplug() only from usb_step() and from
register_usb_bus().  This avoids recursive calls to usb_hotplug() and
ensures that devices are enumerated in the order of detection.

Tested-by: Robin Smidsrød <robin@smidsrod.no>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[usb] Add basic support for USB keyboards
Michael Brown [Mon, 11 May 2015 14:42:54 +0000 (15:42 +0100)] 
[usb] Add basic support for USB keyboards

When USB network card drivers are used, the BIOS' legacy USB
capability is necessarily disabled since there is no way to share the
host controller between the BIOS and iPXE.  This currently results in
USB keyboards becoming non-functional in USB-enabled builds of iPXE.

Fix by adding basic support for USB keyboards, enabled by default in
iPXE builds which include USB support.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[usb] Add generic USB human interface device (HID) framework
Michael Brown [Mon, 11 May 2015 13:57:28 +0000 (14:57 +0100)] 
[usb] Add generic USB human interface device (HID) framework

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[usb] Add USB_INTERRUPT_OUT internal type
Michael Brown [Mon, 11 May 2015 13:56:46 +0000 (14:56 +0100)] 
[usb] Add USB_INTERRUPT_OUT internal type

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[ipv6] Disambiguate received ICMPv6 errors
Michael Brown [Mon, 11 May 2015 11:45:14 +0000 (12:45 +0100)] 
[ipv6] Disambiguate received ICMPv6 errors

Originally-implemented-by: Hannes Reinecke <hare@suse.de>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[uhci] Use meaningful device names in debug messages
Michael Brown [Sat, 9 May 2015 23:18:46 +0000 (00:18 +0100)] 
[uhci] Use meaningful device names in debug messages

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[ehci] Use meaningful device names in debug messages
Michael Brown [Sat, 9 May 2015 22:45:43 +0000 (23:45 +0100)] 
[ehci] Use meaningful device names in debug messages

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[xhci] Use meaningful device names in debug messages
Michael Brown [Sat, 9 May 2015 23:11:07 +0000 (00:11 +0100)] 
[xhci] Use meaningful device names in debug messages

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[usb] Provide usb_endpoint_name() for use by host controller drivers
Michael Brown [Sat, 9 May 2015 22:45:13 +0000 (23:45 +0100)] 
[usb] Provide usb_endpoint_name() for use by host controller drivers

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[uhci] Add support for UHCI host controllers
Michael Brown [Sat, 9 May 2015 22:14:34 +0000 (23:14 +0100)] 
[uhci] Add support for UHCI host controllers

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[ehci] Allow UHCI/OHCI controllers to locate the EHCI companion controller
Michael Brown [Fri, 8 May 2015 15:51:12 +0000 (16:51 +0100)] 
[ehci] Allow UHCI/OHCI controllers to locate the EHCI companion controller

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[usb] Add find_usb_bus_by_location() helper function
Michael Brown [Fri, 8 May 2015 15:50:47 +0000 (16:50 +0100)] 
[usb] Add find_usb_bus_by_location() helper function

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[ehci] Poll child companion controllers after disowning port
Michael Brown [Fri, 8 May 2015 14:33:18 +0000 (15:33 +0100)] 
[ehci] Poll child companion controllers after disowning port

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[usb] Maintain single lists of halted endpoints and changed ports
Michael Brown [Fri, 8 May 2015 17:02:50 +0000 (18:02 +0100)] 
[usb] Maintain single lists of halted endpoints and changed ports

When an EHCI hotplug action results in the controller disowning the
port, it will result in a hotplug action on the corresponding UHCI or
OHCI controller.  Allow such hotplug actions to be carried out as part
of the same call to usb_step() or usb_register_bus(), by maintaining a
single central list of changed ports.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[usb] Maintain a list of all USB buses
Michael Brown [Fri, 8 May 2015 14:07:26 +0000 (15:07 +0100)] 
[usb] Maintain a list of all USB buses

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[usb] Detect missed disconnections
Michael Brown [Wed, 6 May 2015 15:38:28 +0000 (16:38 +0100)] 
[usb] Detect missed disconnections

The USB core will currently fail to detect disconnections if a new
device has attached by the time the port is examined in
usb_hotplug().

Fix by recording the fact that a disconnection has taken place
whenever the "connection status changed" (CSC) bit is observed to be
set.  (Whether the change represents a disconnection or a
reconnection, it indicates that the port has experienced some time of
being disconnected.)

Note that the time at which a disconnection can be detected varies by
hub type.  In particular: root hubs can observe the CSC bit when
polling, and so will record the disconnection before calling
usb_port_changed(), but USB hubs read the port status (and hence the
CSC bit) only during the call to hub_speed(), long after the call to
usb_port_changed().

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[pci] Provide PCI_CLASS() to calculate a scalar PCI class value
Michael Brown [Fri, 8 May 2015 13:54:12 +0000 (14:54 +0100)] 
[pci] Provide PCI_CLASS() to calculate a scalar PCI class value

Rename PCI_CLASS() (which constructs a struct pci_class_id) to
PCI_CLASS_ID(), and provide PCI_CLASS() as a macro which constructs
the 24-bit scalar value of a PCI class code.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[usb] Include setup packet within I/O buffer for message transfers
Michael Brown [Fri, 1 May 2015 15:28:45 +0000 (16:28 +0100)] 
[usb] Include setup packet within I/O buffer for message transfers

The USB API currently assumes that host controllers will have
immediate data buffer space available in which to store the setup
packet.  This is true for xHCI, partially true for EHCI (which happens
to have 12 bytes of padding in each transfer descriptor due to
alignment requirements), and not true at all for UHCI.

Include the setup packet within the I/O buffer passed to the host
controller's message() method, thereby eliminating the requirement for
host controllers to provide immediate data buffers.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[vram] Add "vram" built-in setting to dump video RAM
Michael Brown [Fri, 24 Apr 2015 15:05:59 +0000 (16:05 +0100)] 
[vram] Add "vram" built-in setting to dump video RAM

The "vram" setting returns the (Base64-encoded) contents of video RAM,
and can be used to capture a screenshot.  For example: after running
memtest.0 and encountering an error, the output can be captured and
sent to a remote server for later diagnosis:

  #!ipxe
  chain -a http://server/memtest.0 && goto ok || goto bad
  :bad
  params
  param errno ${errno}
  param vram ${vram}
  chain -a http://server/report.php##params
  :ok

Inspired-by: Christian Nilsson <nikize@gmail.com>
Originally-implemented-by: Christian Nilsson <nikize@gmail.com>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[settings] Add "base64" setting type
Michael Brown [Fri, 24 Apr 2015 12:54:40 +0000 (13:54 +0100)] 
[settings] Add "base64" setting type

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[base64] Add buffer size parameter to base64_encode() and base64_decode()
Michael Brown [Fri, 24 Apr 2015 14:32:04 +0000 (15:32 +0100)] 
[base64] Add buffer size parameter to base64_encode() and base64_decode()

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[base16] Add buffer size parameter to base16_encode() and base16_decode()
Michael Brown [Fri, 24 Apr 2015 13:34:32 +0000 (14:34 +0100)] 
[base16] Add buffer size parameter to base16_encode() and base16_decode()

The current API for Base16 (and Base64) encoding requires the caller
to always provide sufficient buffer space.  This prevents the use of
the generic encoding/decoding functionality in some situations, such
as in formatting the hex setting types.

Implement a generic hex_encode() (based on the existing
format_hex_setting()), implement base16_encode() and base16_decode()
in terms of the more generic hex_encode() and hex_decode(), and update
all callers to provide the additional buffer length parameter.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[test] Include IPv6 support when performing settings self-tests
Michael Brown [Fri, 24 Apr 2015 13:38:14 +0000 (14:38 +0100)] 
[test] Include IPv6 support when performing settings self-tests

The settings self-tests include tests for the "ipv6" setting type.
When IPv6 support is not included, this setting type exists (since it
is referred to by some dual-stack code, such as dns.c) but is
non-functional.

Force IPv6 support to be included within a settings self-test build
using an explicit REQUIRE_OBJECT() macro.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[ath9k] Remove confusing logic inversion in an ANI variable
Christian Hesse [Thu, 23 Apr 2015 11:33:26 +0000 (13:33 +0200)] 
[ath9k] Remove confusing logic inversion in an ANI variable

This changed in Linux kernel the same way in commit 7067e701
("ath9k_hw: remove confusing logic inversion in an ANI variable") by
Felix Fietkau.

Additionally this fixes "error: logical not is only applied to the
left hand side of comparison" with GCC 5.1.0.

Signed-off-by: Christian Hesse <mail@eworm.de>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[build] Add missing "const" qualifiers
Christian Hesse [Thu, 23 Apr 2015 11:33:25 +0000 (13:33 +0200)] 
[build] Add missing "const" qualifiers

This fixes "initialization discards 'const' qualifier from pointer
target type" warnings with GCC 5.1.0.

Signed-off-by: Christian Hesse <mail@eworm.de>
Modified-by: Michael Brown <mcb30@ipxe.org>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[intel] Add PCI device IDs for Intel I218-LM and I218-V
Christian Hesse [Wed, 22 Apr 2015 12:48:01 +0000 (14:48 +0200)] 
[intel] Add PCI device IDs for Intel I218-LM and I218-V

I218-LM (rev 3) is found in Lenovo Thinkpad X250.  The remaining
device IDs are from linux/drivers/net/ethernet/intel/e1000e/hw.h

Signed-off-by: Christian Hesse <mail@eworm.de>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[build] Construct all-drivers list based on driver class
Michael Brown [Wed, 22 Apr 2015 11:14:16 +0000 (12:14 +0100)] 
[build] Construct all-drivers list based on driver class

The USB bus drivers (ehci.c and xhci.c) have PCI device ID tables and
hence PCI_ROM() lines, but should probably not be included in the
all-drivers build on this basis, since they do nothing useful unless a
USB network driver is also present.

Fix by constructing the all-drivers list based on the driver class
(i.e. the portion of the source path immediately after "drivers/").

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[rtl818x] Obviate RTL_ROM() hack
Michael Brown [Wed, 22 Apr 2015 10:05:19 +0000 (11:05 +0100)] 
[rtl818x] Obviate RTL_ROM() hack

Reported-by: Robin Smidsrød <robin@smidsrod.no>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[realtek] Do not attempt to access EEPROM on RTL8169 chips
Michael Brown [Tue, 21 Apr 2015 16:42:36 +0000 (17:42 +0100)] 
[realtek] Do not attempt to access EEPROM on RTL8169 chips

On some RTL8169 onboard NICs (observed with a Lenovo ThinkPad 11e),
the EEPROM is not merely not present: any attempt to read from the
non-existent EEPROM will crash and reboot the system.

The equivalent code to read from the EEPROM was removed from the Linux
r8169 driver in 2009 with a comment suggesting that it was similarly
found to be unreliable on some systems.

Fix by accessing the EEPROM only on RTL8139 NICs, and assuming that
the MAC address will always be correctly preset on RTL8169 NICs.

Reported-by: Evan Prohaska <eprohaska@edkey.org>
Tested-by: Evan Prohaska <eprohaska@edkey.org>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[intel] Force RX polling on VMware emulated 82545em
Michael Brown [Tue, 21 Apr 2015 15:43:30 +0000 (16:43 +0100)] 
[intel] Force RX polling on VMware emulated 82545em

The emulated Intel 82545em in some versions of VMware (observed with
ESXi v5.1) seems to sometimes fail to set the RXT0 bit in the
interrupt cause register (ICR), causing iPXE to stop receiving
packets.  Work around this problem (for the 82545em only) by always
polling the receive queue regardless of the state of the ICR.

Reported-by: Slava Bendersky <volga629@networklab.ca>
Tested-by: Slava Bendersky <volga629@networklab.ca>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[intel] Report any unexpected interrupt causes
Michael Brown [Tue, 21 Apr 2015 14:20:13 +0000 (15:20 +0100)] 
[intel] Report any unexpected interrupt causes

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[intel] Update PCI device IDs for Intel 82599 and X540 10G NICs
Ed Swierk [Thu, 19 Feb 2015 21:12:44 +0000 (13:12 -0800)] 
[intel] Update PCI device IDs for Intel 82599 and X540 10G NICs

Identifiers are based on defines in Linux ixgbe_type.h.

Descriptive names are based on
https://www-ssl.intel.com/content/www/us/en/ethernet-controllers/82599-10-gbe-controller-spec-update.html
and
https://www-ssl.intel.com/content/www/us/en/network-adapters/10-gigabit-network-adapters/ethernet-x540-spec-update.html

Signed-off-by: Ed Swierk <eswierk@skyportsystems.com>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[build] Use a single call to parserom.pl to speed up building
Michael Brown [Sat, 18 Apr 2015 10:21:45 +0000 (11:21 +0100)] 
[build] Use a single call to parserom.pl to speed up building

Inspired-by: Robin Smidsrød <robin@smidsrod.no>
Tested-by: Robin Smidsrød <robin@smidsrod.no>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[build] Work around binutils quirk on OpenBSD 5.7
Michael Brown [Fri, 17 Apr 2015 23:53:27 +0000 (00:53 +0100)] 
[build] Work around binutils quirk on OpenBSD 5.7

The assembler on OpenBSD 5.7 seems not to correctly handle the
combinations of .struct and .previous used in unlzma.S, and ends up
complaining about an "attempt to allocate data in absolute section".

Work around this problem by explicitly resetting the section after the
data structure definitions.

Reported-by: Jiri B <jirib@devio.us>
Tested-by: Jiri B <jirib@devio.us>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[build] Fix compiler warning on OpenBSD 5.7
Michael Brown [Fri, 17 Apr 2015 22:56:03 +0000 (23:56 +0100)] 
[build] Fix compiler warning on OpenBSD 5.7

Reported-by: Jiri B <jirib@devio.us>
Tested-by: Jiri B <jirib@devio.us>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[build] Allow building PCI ROMs with device ID lists
Michael Brown [Tue, 14 Apr 2015 08:59:59 +0000 (09:59 +0100)] 
[build] Allow building PCI ROMs with device ID lists

PCI v3.0 supports a "device list" which allows the ROM to claim
support for multiple PCI device IDs (but only a single vendor ID).
Add support for building such ROMs by scanning the build target
element list and incorporating any device IDs into the ROM's device
list header.  For example:

  make bin/8086153a--8086153b.mrom

would build a ROM claiming support for both 8086:153a and 8086:153b.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[prism2] Remove duplicate PCI_ROM() lines
Michael Brown [Wed, 15 Apr 2015 10:37:20 +0000 (11:37 +0100)] 
[prism2] Remove duplicate PCI_ROM() lines

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[eepro100] Remove duplicate PCI_ROM() line
Michael Brown [Wed, 15 Apr 2015 10:37:09 +0000 (11:37 +0100)] 
[eepro100] Remove duplicate PCI_ROM() line

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[efi] Use the EFI_RNG_PROTOCOL as an entropy source if available
Michael Brown [Tue, 14 Apr 2015 16:53:13 +0000 (17:53 +0100)] 
[efi] Use the EFI_RNG_PROTOCOL as an entropy source if available

Entropy gathering via timer ticks is slow under UEFI (of the order of
20-30 seconds on some machines).  Use the EFI_RNG_PROTOCOL if
available, to speed up the process of entropy gathering.

Note that some implementations (including EDK2) will fail if we
request fewer than 32 random bytes at a time, and that the RNG
protocol provides no guarantees about the amount of entropy provided
by a call to GetRNG().  We take the (hopefully pessimistic) view that
a 32-byte block returned by GetRNG() will contain at least the 1.3
bits of entropy claimed by min_entropy_per_sample().

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[efi] Poll for TX completions only when there is an outstanding TX buffer
Michael Brown [Tue, 14 Apr 2015 16:02:00 +0000 (17:02 +0100)] 
[efi] Poll for TX completions only when there is an outstanding TX buffer

At least one NII implementation (in a Microsoft Surface tablet) seems
to fail to report the absence (sic) of TX completions properly.  Work
around this by checking for TX completions only when we expect to see
one.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[efi] Poll media status only if advertised as supported
Michael Brown [Tue, 14 Apr 2015 15:44:37 +0000 (16:44 +0100)] 
[efi] Poll media status only if advertised as supported

Some NII implementations will fail the GET_STATUS operation if we
request the media status.  Fix by doing so only if GET_INIT_INFO
reported that media status is supported.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[efi] Provide a dummy data block in nii_initialise()
Michael Brown [Tue, 14 Apr 2015 15:20:32 +0000 (16:20 +0100)] 
[efi] Provide a dummy data block in nii_initialise()

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[efi] Add EFI time source
Michael Brown [Tue, 14 Apr 2015 10:55:08 +0000 (11:55 +0100)] 
[efi] Add EFI time source

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[efi] Add EFI entropy source
Michael Brown [Tue, 14 Apr 2015 09:56:20 +0000 (10:56 +0100)] 
[efi] Add EFI entropy source

Originally-implemented-by: Jarrod Johnson <jbjohnso@us.ibm.com>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[util] Add ability to dump PCI device ID list
Michael Brown [Mon, 13 Apr 2015 15:22:35 +0000 (16:22 +0100)] 
[util] Add ability to dump PCI device ID list

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[romprefix] Allow autoboot device filter to be disabled
Michael Brown [Mon, 13 Apr 2015 13:49:02 +0000 (14:49 +0100)] 
[romprefix] Allow autoboot device filter to be disabled

Our current behaviour when booting as a ROM is to autoboot only from
devices which are attached via the PCI bus:dev.fn address passed to
the ROM's initialisation vector.

Add a build configuration option AUTOBOOT_ROM_FILTER (enabled by
default) to control this behaviour.  This allows for ROMs to be built
which will attempt to boot from any detected device, even if not
attached via the original PCI bus:dev.fn address.  (This is
particularly useful when building combined EHCI/xHCI ROMs for USB
network boot, since the BIOS may request a boot via the EHCI
controller but the xHCI driver will reroute the root hub ports to the
xHCI controller.)

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[xhci] Always reset root hub ports
Michael Brown [Mon, 13 Apr 2015 13:08:09 +0000 (14:08 +0100)] 
[xhci] Always reset root hub ports

In theory USB3 ports do not require a reset to enable the port.
Experimentation shows that this is sometimes required, particularly
when rerouting ports from EHCI to xHCI and switching speeds.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[build] Rewrite parserom.pl to support multiple source files
Robin Smidsrød [Mon, 6 Apr 2015 15:09:54 +0000 (17:09 +0200)] 
[build] Rewrite parserom.pl to support multiple source files

Running util/parserom.pl on all source files (637) one by one takes
approximately 35 seconds because of the startup cost of each invocation.
With the utility rewritten to support multiple source files it now takes
approximately 1 second to scan all source files for ROM declarations.

The --exclude-driver and --exclude-driver-class options have been added,
making it possible to skip certain source files from being scanned at all.

In addition --debug option has been added to more easily trace progress.

Finally --help option was added to show usage information.

Signed-off-by: Robin Smidsrød <robin@smidsrod.no>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[peerdist] Add support for decoding PeerDist Content Information
Michael Brown [Mon, 13 Apr 2015 11:26:05 +0000 (12:26 +0100)] 
[peerdist] Add support for decoding PeerDist Content Information

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[efi] Ensure drivers are disconnected when ExitBootServices() is called
Michael Brown [Mon, 13 Apr 2015 11:06:59 +0000 (12:06 +0100)] 
[efi] Ensure drivers are disconnected when ExitBootServices() is called

We hook the UEFI ExitBootServices() event and use it to trigger a call
to shutdown_boot().  This does not automatically cause drivers to be
disconnected from their devices, since device enumeration is now
handled by the UEFI core rather than by iPXE.  (Under the old and
dubiously compatible device model, iPXE used to perform its own device
enumeration and so the call to shutdown_boot() would indeed have
caused drivers to be disconnected.)

Fix by replicating parts of the dummy "EFI root device" from
efiprefix.c to efidrvprefix.c, so that the call to shutdown_boot()
will call efi_driver_disconnect_all().

Originally-fixed-by: Laszlo Ersek <lersek@redhat.com>
Tested-by: Laszlo Ersek <lersek@redhat.com>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[crypto] Add SHA-512/224 algorithm
Michael Brown [Sun, 12 Apr 2015 15:57:25 +0000 (16:57 +0100)] 
[crypto] Add SHA-512/224 algorithm

SHA-512/224 is almost identical to SHA-512, with differing initial
hash values and a truncated output length.

This implementation has been verified using the NIST SHA-512/224 test
vectors.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[crypto] Add SHA-512/256 algorithm
Michael Brown [Sun, 12 Apr 2015 15:34:33 +0000 (16:34 +0100)] 
[crypto] Add SHA-512/256 algorithm

SHA-512/256 is almost identical to SHA-512, with differing initial
hash values and a truncated output length.

This implementation has been verified using the NIST SHA-512/256 test
vectors.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[crypto] Add SHA-384 algorithm
Michael Brown [Sun, 12 Apr 2015 14:53:39 +0000 (15:53 +0100)] 
[crypto] Add SHA-384 algorithm

SHA-384 is almost identical to SHA-512, with differing initial hash
values and a truncated output length.

This implementation has been verified using the NIST SHA-384 test
vectors.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[crypto] Add SHA-512 algorithm
Michael Brown [Sun, 12 Apr 2015 14:42:45 +0000 (15:42 +0100)] 
[crypto] Add SHA-512 algorithm

This implementation has been verified using the NIST SHA-512 test
vectors.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[crypto] Add SHA-224 algorithm
Michael Brown [Sun, 12 Apr 2015 13:50:18 +0000 (14:50 +0100)] 
[crypto] Add SHA-224 algorithm

SHA-224 is almost identical to SHA-256, with differing initial hash
values and a truncated output length.

This implementation has been verified using the NIST SHA-224 test
vectors.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[test] Simplify digest algorithm self-tests
Michael Brown [Sun, 12 Apr 2015 11:41:08 +0000 (12:41 +0100)] 
[test] Simplify digest algorithm self-tests

Update the digest self-tests to use okx(), and centralise concepts and
data shared between tests for multiple algorithms to reduce duplicated
code.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[virtio] Downgrade per-iobuf debug messages to DBGC2
Laszlo Ersek [Fri, 10 Apr 2015 19:53:21 +0000 (21:53 +0200)] 
[virtio] Downgrade per-iobuf debug messages to DBGC2

Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[test] Add setjmp()/longjmp() self-tests
Michael Brown [Tue, 7 Apr 2015 05:40:46 +0000 (06:40 +0100)] 
[test] Add setjmp()/longjmp() self-tests

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[libc] Add x86_64 versions of setjmp() and longjmp()
Michael Brown [Tue, 7 Apr 2015 05:40:42 +0000 (06:40 +0100)] 
[libc] Add x86_64 versions of setjmp() and longjmp()

None of the x86_64 builds currently have any way of invoking these
functions.  They are included only to avoid introducing unnecessary
architecture-specific dependencies into the self-test suite.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[libc] Fix typo in longjmp()
Michael Brown [Tue, 7 Apr 2015 05:40:34 +0000 (06:40 +0100)] 
[libc] Fix typo in longjmp()

Commit 8ab4b00 ("[libc] Rewrite setjmp() and longjmp()") introduced a
regression in which the saved values of %ebx, %esi, and %edi were all
accidentally restored into %esp.  The result is that the second and
subsequent returns from setjmp() would effectively corrupt %ebx, %esi,
%edi, and the stack pointer %esp.

Use of setjmp() and longjmp() is generally discouraged: our only use
occurs as part of the implementation of PXENV_RESTART_TFTP, since the
PXE API effectively mandates its use here.  The call to setjmp()
occurs at the start of pxe_start_nbp(), where there are almost
certainly no values held in %ebx, %esi, or %edi.  The corruption of
these registers therefore had no visible effect on program execution.
The corruption of %esp would have been visible on return from
pxe_start_nbp(), but there are no known PXE NBPs which first call
PXENV_RESTART_TFTP and subsequently attempt to return to the PXE base
code.  The effect on program execution was therefore similar to that
of moving the stack to a pseudo-random location in the 32-bit address
space; this will often allow execution to complete successfully since
there is a high chance that the pseudo-random location will be unused.
The regression therefore went undetected for around one month.

Fix by restoring the correct registers from the saved jmp_buf
structure.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[xhci] Support USB1 devices attached via transaction translators
Michael Brown [Mon, 23 Mar 2015 20:24:20 +0000 (20:24 +0000)] 
[xhci] Support USB1 devices attached via transaction translators

xHCI provides a somewhat convoluted mechanism for specifying details
of a transaction translator.  Hubs must be marked as such in the
device slot context.  The only opportunity to do so is as part of a
Configure Endpoint command, which can be executed only when opening
the hub's interrupt endpoint.

We add a mechanism for host controllers to intercept the opening of
hub devices, providing xHCI with an opportunity to update the internal
device slot structure for the corresponding USB device to indicate
that the device is a hub.  We then include the hub-specific details in
the input context whenever any Configure Endpoint command is issued.

When a device is opened, we record the device slot and port for its
transaction translator (if any), and supply these as part of the
Address Device command.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[usb] Improve debug messages for failed control transactions
Michael Brown [Mon, 23 Mar 2015 20:18:02 +0000 (20:18 +0000)] 
[usb] Improve debug messages for failed control transactions

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[ehci] Support USB1 devices attached via transaction translators
Michael Brown [Mon, 23 Mar 2015 13:34:16 +0000 (13:34 +0000)] 
[ehci] Support USB1 devices attached via transaction translators

Support low-speed and full-speed devices attached to a USB2 hub.  Such
devices use a transaction translator (TT) within the USB2 hub, which
asynchronously initiates transactions on the lower-speed bus and
returns the result via a split completion on the high-speed bus.

We make the simplifying assumption that there will never be more than
sixteen active interrupt endpoints behind a single transaction
translator; this assumption allows us to schedule all periodic start
splits in microframe 0 and all periodic split completions in
microframes 2 and 3.  (We do not handle isochronous endpoints.)

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[usb] Clear transaction translator buffers when applicable
Michael Brown [Mon, 23 Mar 2015 16:20:36 +0000 (16:20 +0000)] 
[usb] Clear transaction translator buffers when applicable

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[usb] Add clear_tt() hub method to clear transaction translator buffer
Michael Brown [Mon, 23 Mar 2015 15:59:51 +0000 (15:59 +0000)] 
[usb] Add clear_tt() hub method to clear transaction translator buffer

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[usb] Reset endpoints without waiting for a new transfer to be enqueued
Michael Brown [Mon, 23 Mar 2015 15:05:28 +0000 (15:05 +0000)] 
[usb] Reset endpoints without waiting for a new transfer to be enqueued

The current endpoint reset logic defers the reset until the caller
attempts to enqueue a new transfer to that endpoint.  This is
insufficient when dealing with endpoints behind a transaction
translator, since the transaction translator is a resource shared
between multiple endpoints.

We cannot reset the endpoint as part of the completion handling, since
that would introduce recursive calls to usb_poll().  Instead, we
add the endpoint to a list of halted endpoints, and perform the reset
on the next call to usb_step().

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[xhci] Ring doorbell as part of endpoint reset
Michael Brown [Mon, 23 Mar 2015 14:22:23 +0000 (14:22 +0000)] 
[xhci] Ring doorbell as part of endpoint reset

The endpoint may already have enqueued TRBs at the time that
xhci_endpoint_reset() is called.  Ring the doorbell to resume
processing these TRBs immediately, rather than waiting until the next
call to xhci_endpoint_message() or xhci_endpoint_stream().

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[libprefix] Fix building on 64-bit FreeBSD 8.4
Michael Brown [Mon, 23 Mar 2015 13:28:59 +0000 (13:28 +0000)] 
[libprefix] Fix building on 64-bit FreeBSD 8.4

Reported-by: Pavel Antonov <holly@istu.edu>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[usb] Fix USB timeouts to match specification
Michael Brown [Wed, 18 Mar 2015 16:43:18 +0000 (16:43 +0000)] 
[usb] Fix USB timeouts to match specification

Several of the USB timeouts were chosen on the principle of "pick an
arbitrary but ridiculously large value, just to be safe".  It turns
out that some of the timeouts permitted by the USB specification are
even larger: for example, control transactions are allowed to take up
to five seconds to complete.

Fix up these USB timeout values to match those found in the USB2
specification.

Debugged-by: Robin Smidsrød <robin@smidsrod.no>
Tested-by: Robin Smidsrød <robin@smidsrod.no>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[netdevice] Add missing bus types to netdev_fetch_bustype()
Michael Brown [Wed, 18 Mar 2015 16:42:39 +0000 (16:42 +0000)] 
[netdevice] Add missing bus types to netdev_fetch_bustype()

Reported-by: Robin Smidsrød <robin@smidsrod.no>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[ehci] Add support for EHCI host controllers
Michael Brown [Sun, 15 Mar 2015 01:01:08 +0000 (01:01 +0000)] 
[ehci] Add support for EHCI host controllers

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[xhci] Do not release ownership back to BIOS when booting an OS
Michael Brown [Wed, 18 Mar 2015 11:57:41 +0000 (11:57 +0000)] 
[xhci] Do not release ownership back to BIOS when booting an OS

xHCI (and EHCI) nominally provide a mechanism for releasing ownership
of the host controller back to the BIOS, which can then potentially
restore legacy USB keyboard functionality.

This is a rarely used code path, since most operating systems claim
ownership and never attempt to later return to the BIOS.  On some
systems (observed with a Lenovo X1 Carbon), this code path leads to
obscure and interesting bugs: if the xHCI and EHCI controllers are
both claimed and later released back to the BIOS, then a subsequent
call to INT 16,0305 to set the keyboard repeat rate to a non-default
value will lock the system.

Obscure though this sequence of operations may sound, it is exactly
what happens when using iPXE to boot a Linux kernel via a USB network
card.  There is old and probably unwanted code in Linux's
arch/x86/boot/main.c which sets the keyboard repeat rate (with the
accompanying comment "Set keyboard repeat rate (why?)").  When booting
Linux via a USB network card on a Lenovo X1 Carbon, the system
therefore locks up immediately after jumping to the kernel's entry
point.

Work around this problem by preventing the release of ownership back
to the BIOS if it is known that we are shutting down to boot an OS.
This should allow legacy USB keyboard functionality to be restored if
the user chooses to exit iPXE, while avoiding the rarely used code
paths (and corresponding BIOS bugs) if the user chooses instead to
boot an OS.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[usb] Add config/usb.h for USB configuration options
Michael Brown [Wed, 18 Mar 2015 11:37:51 +0000 (11:37 +0000)] 
[usb] Add config/usb.h for USB configuration options

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[autoboot] Match against parent devices when matching by bus type and location
Michael Brown [Tue, 17 Mar 2015 02:30:06 +0000 (02:30 +0000)] 
[autoboot] Match against parent devices when matching by bus type and location

When using iPXE as an option ROM for a PCI USB controller (e.g. via
qemu's "-device nec-usb-xhci,romfile=..." syntax), the ROM prefix will
set the PCI bus:dev.fn address of the USB controller as the PCI
autoboot device.  This will cause iPXE to fail to boot from any
detected USB network devices, since they will not match the autoboot
bus type (or location).

Fix by allowing the autoboot bus type and location to match against
the network device or any of its parent devices.  This allows the
match to succeed for USB network devices attached to the selected PCI
USB controller.

Reported-by: Dan Ellis <Dan.Ellis@displaylink.com>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[xhci] Forcibly disable SMIs if BIOS fails to release ownership
Michael Brown [Mon, 16 Mar 2015 20:32:33 +0000 (20:32 +0000)] 
[xhci] Forcibly disable SMIs if BIOS fails to release ownership

If the BIOS fails to gracefully release ownership of the xHCI
controller, we can forcibly claim it by disabling all SMIs via the
USB legacy support control/status register.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[usb] Add functions for manual device address assignment
Michael Brown [Mon, 16 Mar 2015 15:37:39 +0000 (15:37 +0000)] 
[usb] Add functions for manual device address assignment

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[ncm] Respect maximum transfer size of the bus
Michael Brown [Mon, 16 Mar 2015 05:39:41 +0000 (05:39 +0000)] 
[ncm] Respect maximum transfer size of the bus

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[usb] Add the concept of a USB bus maximum transfer size
Michael Brown [Mon, 16 Mar 2015 05:39:14 +0000 (05:39 +0000)] 
[usb] Add the concept of a USB bus maximum transfer size

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[libc] Add ffs(), ffsl(), and ffsll()
Michael Brown [Sun, 15 Mar 2015 19:28:05 +0000 (19:28 +0000)] 
[libc] Add ffs(), ffsl(), and ffsll()

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[tcpip] Fix dubious calculation of min_port
Michael Brown [Fri, 13 Mar 2015 10:19:44 +0000 (10:19 +0000)] 
[tcpip] Fix dubious calculation of min_port

Detected using sparse.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[smsc75xx] Move RX FIFO overflow message to DBGLVL_EXTRA
Michael Brown [Wed, 11 Mar 2015 22:33:51 +0000 (22:33 +0000)] 
[smsc75xx] Move RX FIFO overflow message to DBGLVL_EXTRA

RX FIFO overflow is almost inevitable since the (usable) USB2 bus
bandwidth is approximately one quarter of the Ethernet bandwidth.
Avoid flooding the console with RX FIFO overflow messages in a
standard debug build.

With TCP SACK implemented, the RX FIFO overflow no longer causes a
catastrophic drop in throughput.  Experimentation shows that HTTP
downloads now progress at a fairly smooth 250Mbps, which is around the
maximum speed attainable for a USB2 NIC.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[tcp] Implement support for TCP Selective Acknowledgements (SACK)
Michael Brown [Wed, 11 Mar 2015 17:53:29 +0000 (17:53 +0000)] 
[tcp] Implement support for TCP Selective Acknowledgements (SACK)

The TCP Selective Acknowledgement option (specified in RFC2018)
provides a mechanism for the receiver to indicate packets that have
been received out of order (e.g. due to earlier dropped packets).

iPXE often operates in environments in which there is a high
probability of packet loss.  For example, the legacy USB keyboard
emulation in some BIOSes involves polling the USB bus from within a
system management interrupt: this introduces an invisible delay of
around 500us which is long enough for around 40 full-length packets to
be dropped.  Similarly, almost all 1Gbps USB2 devices will eventually
end up dropping packets because the USB2 bus does not provide enough
bandwidth to sustain a 1Gbps stream, and most devices will not provide
enough internal buffering to hold a full TCP window's worth of
received packets.

Add support for sending TCP Selective Acknowledgements.  This provides
the sender with more detailed information about which packets have
been lost, and so allows for a more efficient retransmission strategy.

We include a SACK-permitted option in our SYN packet, since
experimentation shows that at least Linux peers will not include a
SACK-permitted option in the SYN-ACK packet if one was not present in
the initial SYN.  (RFC2018 does not seem to mandate this behaviour,
but it is consistent with the approach taken in RFC1323.)  We ignore
any received SACK options; this is safe to do since SACK is only ever
advisory and we never have to send non-trivial amounts of data.

Since our TCP receive queue is a candidate for cache discarding under
low memory conditions, we may end up discarding data that has been
reported as received via a SACK option.  This is permitted by RFC2018.
We follow the stricture that SACK blocks must not report data which is
no longer held by the receiver: previously-reported blocks are
validated against the current receive queue before being included
within the current SACK block list.

Experiments in a qemu VM using forced packet drops (by setting
NETDEV_DISCARD_RATE to 32) show that implementing SACK improves
throughput by around 400%.

Experiments with a USB2 NIC (an SMSC7500) show that implementing SACK
improves throughput by around 700%, increasing the download rate from
35Mbps up to 250Mbps (which is approximately the usable bandwidth
limit for USB2).

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[legal] Relicense files under GPL2_OR_LATER_OR_UBDL
Michael Brown [Wed, 11 Mar 2015 14:23:14 +0000 (14:23 +0000)] 
[legal] Relicense files under GPL2_OR_LATER_OR_UBDL

Several of the assembly files in arch/i386/prefix were missed by the
automated relicensing tool due to missing licence declarations, code
dating back to the initial git revision, etc.  Manual review shows
that these files may be relicensed.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[smsc75xx] Add driver for SMSC/Microchip LAN75xx USB Ethernet NICs
Michael Brown [Tue, 10 Mar 2015 14:37:18 +0000 (14:37 +0000)] 
[smsc75xx] Add driver for SMSC/Microchip LAN75xx USB Ethernet NICs

This driver is functional but any downloads via a TCP-based protocol
tend to perform poorly.  The 1Gbps Ethernet line rate is substantially
higher than the 480Mbps (in practice around 280Mbps) provided by USB2,
and the device has only 32kB of internal buffer memory.  Our 256kB TCP
receive window therefore rapidly overflows the RX FIFO, leading to
multiple dropped packets (usually within the same TCP window) and
hence a low overall throughput.

Reducing the TCP window size so that the RX FIFO does not overflow
greatly increases throughput, but is not a general-purpose solution.

Further investigation is required to determine how other OSes
(e.g. Linux) cope with this scenario.  It is possible that
implementing TCP SACK would provide some benefit.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[mii] Add generic mii_check_link() function
Michael Brown [Tue, 10 Mar 2015 21:23:51 +0000 (21:23 +0000)] 
[mii] Add generic mii_check_link() function

Most devices expose at least the link up/down status via a bit in a
MAC register, since the MAC generally already needs to know whether or
not the link is up.  Some devices (e.g. the SMSC75xx USB NIC) expose
this information to software only via the MII registers.

Provide a generic mii_check_link() implementation to check the BMSR
and report the link status via netdev_link_{up,down}().

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[legal] Relicense Davicom DM96xx drivers
Michael Brown [Tue, 10 Mar 2015 00:12:39 +0000 (00:12 +0000)] 
[legal] Relicense Davicom DM96xx drivers

Reported-by: Robin Smidsrød <robin@smidsrod.no>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[dm96xx] Add driver for Davicom DM96xx USB Ethernet NICs
Michael Brown [Mon, 16 Feb 2015 15:22:44 +0000 (15:22 +0000)] 
[dm96xx] Add driver for Davicom DM96xx USB Ethernet NICs

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[intel] Add PCI ID for I218-LM
Thomas Miletich [Fri, 6 Mar 2015 20:39:42 +0000 (21:39 +0100)] 
[intel] Add PCI ID for I218-LM

Signed-off-by: Thomas Miletich <thomas.miletich@gmail.com>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[http] Support MD5-sess Digest authentication
Michael Brown [Mon, 9 Mar 2015 13:22:49 +0000 (13:22 +0000)] 
[http] Support MD5-sess Digest authentication

Microsoft IIS supports only MD5-sess for Digest authentication.

Requested-by: Andreas Hammarskjöld <junior@2PintSoftware.com>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[http] Abstract out HTTP Digest hash algorithm operations
Michael Brown [Mon, 9 Mar 2015 12:35:17 +0000 (12:35 +0000)] 
[http] Abstract out HTTP Digest hash algorithm operations

Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[xen] Set the "feature-rx-notify" flag for netfront devices
Michael Brown [Fri, 6 Mar 2015 17:19:09 +0000 (17:19 +0000)] 
[xen] Set the "feature-rx-notify" flag for netfront devices

iPXE already sends RX notifications to the backend when needed, but
does not set the "feature-rx-notify" flag.  As of XenServer 6.5, this
flag is mandatory and omitting it will cause the backend to fail.

Fix by setting the "feature-rx-notify" flag, to inform the backend
that we will send notifications.

Reported-by: Shalom Bhooshi <shalom.bhooshi@citrix.com>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[xhci] Undo PCH-specific quirk fixes when removing device
Michael Brown [Fri, 6 Mar 2015 17:15:29 +0000 (17:15 +0000)] 
[xhci] Undo PCH-specific quirk fixes when removing device

Restore the original values of XUSB2PR and USB3PSSEN, in case we are
booting an OS with no support for xHCI.

Suggested-by: Dan Ellis <Dan.Ellis@displaylink.com>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[xhci] Enable USB3 ports on Intel PCH8/PCH9 controllers
Michael Brown [Fri, 6 Mar 2015 11:41:37 +0000 (11:41 +0000)] 
[xhci] Enable USB3 ports on Intel PCH8/PCH9 controllers

Intel PCH controllers default to routing USB2 ports to EHCI rather
than xHCI, and default to disabling SuperSpeed connections.
Manipulate the PCI configuration space registers as necessary to
reroute ports and enable SuperSpeed.

Originally-fixed-by: Dan Ellis <Dan.Ellis@displaylink.com>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
6 years ago[legal] Relicense files under GPL2_OR_LATER_OR_UBDL
Michael Brown [Thu, 5 Mar 2015 11:36:30 +0000 (11:36 +0000)] 
[legal] Relicense files under GPL2_OR_LATER_OR_UBDL

Relicense files with kind permission from

    Stefan Hajnoczi <stefanha@redhat.com>

alongside the contributors who have already granted such relicensing
permission.

Signed-off-by: Michael Brown <mcb30@ipxe.org>