summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* [GDBSYM] Remove unused gdbsym.cStefan Hajnoczi2008-06-053-37/+0Star
| | | | | | The GDBSYM config.h option was an attempt at QEMU GDB debugging. I have removed the code since it is unused and may confuse people wanting to use the GDB stub.
* [TCP] Avoid shrinking TCP windowMichael Brown2008-06-051-17/+50
| | | | | | | | | | | | | | | Maintain state for the advertised window length, and only ever increase it (instead of calculating it afresh on each transmit). This avoids triggering "treason uncloaked" messages on Linux peers. Respond to zero-length TCP keepalives (i.e. empty data packets transmitted outside the window). Even if the peer wouldn't otherwise expect an ACK (because its packet consumed no sequence space), force an ACK if it was outside the window. We don't yet generate TCP keepalives. It could be done, but it's unclear what benefit this would have. (Linux, for example, doesn't start sending keepalives until the connection has been idle for two hours.)
* [embed] Add missing register_image() to image/embedded.cMichael Brown2008-06-041-0/+1
| | | | | | | | When the embedded image is a script, the unregister_image() performed by image/script.c corrupts memory, since image/embedded.c omitted the call to register_image(). This is the first bug fixed using Stefan Hajnoczi's gdb stub for gPXE.
* [iSCSI] Produce meaningful errors on login failureMichael Brown2008-06-043-14/+52
| | | | | | | | Return the most appropriate of EACCES, EPERM, ENODEV, ENOTSUP, EIO or EINVAL depending on the exact error returned by the target, rather than just always returning EPERM. Also, ensure that error strings exist for these errors.
* [Makefile] Remove obsolete SRCDIRSMichael Brown2008-05-232-4/+0Star
|
* [prefix] Prompt for entering gPXE shell during POSTMichael Brown2008-05-221-10/+61
| | | | | | | | | The ROM prefix now prompts the user to enter the gPXE shell during POST; this allows for configuring gPXE without needing to attempt to boot from it. (It also slows down system boot by three seconds per gPXE ROM, but hey.) This is apparently a certain OEM's requirement for option ROMs.
* [prefix] Add PCI bus:dev.fn to ROM product stringMichael Brown2008-05-213-95/+131
| | | | | This allows multiple gPXE ROMs in a system to be disambiguated at boot time; the PCI ID will show up in the boot menu for a BBS-compliant BIOS.
* [Contribs] Fix multi-line POSIX errno definitions.Stefan Hajnoczi2008-05-201-8/+7Star
|
* [Contribs] Fix parsing bug in errcode.pyStefan Hajnoczi2008-05-201-1/+4
| | | | Make sure parser doesn't choke on line with space at end.
* [Contribs] Add simple IRC bot for looking up error codes.Stefan Hajnoczi2008-05-203-2/+126
|
* [Contribs] Add README, license text, and invert error code dictionaries.Stefan Hajnoczi2008-05-204-13/+106
|
* [Contribs] Add a web interface for looking up error codes.Stefan Hajnoczi2008-05-201-0/+65
| | | | Add a PHP script to act as a web interface for looking up error codes.
* [Contribs] Add command-line utility for looking up gPXE error codes.Stefan Hajnoczi2008-05-202-0/+129
|
* [SMBIOS] Interpret UUIDs as being in network-endian orderMichael Brown2008-05-202-6/+6
| | | | | | | | | Various specification documents disagree about the byte ordering of UUIDs. However, SMBIOS seems to use the standard in which everything is in network-endian order. This doesn't affect anything sent on the wire; only what gets printed on the screen when the "uuid" variable is displayed.
* [libc] Fix isdigit(), islower() and isupper().Michael Brown2008-05-193-16/+9Star
| | | | From: Stefan Hajnoczi <stefanha@gmail.com>
* [tg3] Add support for tg3-5721Michael Brown2008-05-192-1/+4
| | | | | | | | | | From: Daniel Mealha Cabrita <dancab@utfpr.edu.br> I've added tg3-5721 support for gPXE, the patch (against gpxe-0.9.3) is attached to this message. This chipset is present in HP ML150 G2 servers (possibly other HP machines as well).
* [IPv4] Fix multicast address checkingMichael Brown2008-05-191-1/+1
| | | | | | | | | | | From: Viswanath Krishnamurthy <viswa.krish@gmail.com> The current ipv4 incorrectly checks the IP address for multicast address. This causes valid IPv4 unicast address to be trated as multicast address For e.g if the PXE/tftp server IP address is 192.168.4.XXX where XXX is 224 or greater, it gets treated as multicast address and a ethernet multicast address is sent out on the wire causing timeouts
* [iSCSI] Offer CHAP authentication only if we have a username and passwordMichael Brown2008-04-241-4/+5
| | | | | | | | | | | | | | | | Some EMC targets will fail if we advertise that we can authenticate with CHAP, but the target is configured to allow unauthenticated access to that target. We advertise AuthMethod=CHAP,None; the target should (I think) select AuthMethod=None for unprotected targets. IETD does this, but an EMC Celerra NS83 doesn't. Fix by offering only AuthMethod=None if the user hasn't supplied a username and password; this means that we won't be offering CHAP authentication unless the user is expecting to use it (in which case the target is presumably configured appropriately). Many thanks to Alessandro Iurlano <alessandro.iurlano@gmail.com> for reporting and helping to diagnose this problem.
* [Makefile] Quick hack: always define pci_{vendor,device}_idMichael Brown2008-04-231-2/+2
| | | | | | ROMs will refuse to build unless pci_vendor_id and pci_device_id are defined. We probably ought to fix up the Makefile (and the ROM prefix) so that they're required only for PCI ROMs, but this will do for now.
* [MTNIC] Minor cleanups of vendor-provided driver for Mellanox 10GigE cardsMichael Brown2008-04-223-88/+78Star
| | | | | | | | | Drivers are not allowed to call printf(). Converted eprintf() to DBG(), and removed spurious startup banner. Fixed hardcoded inclusion of little_bswap.h Use EIO rather than 1 as an error number.
* [NETDEV] Add notion of link stateMichael Brown2008-04-2213-2/+110
| | | | | | | | | | | Add ability for network devices to flag link up/down state to the networking core. Autobooting code will now wait for link-up before attempting DHCP. IPoIB reflects the Infiniband link state as the network device link state (which is not strictly correct; we also need a succesful IPoIB IPv4 broadcast group join), but is probably more informative.
* [Infiniband] Fix event queue doorbell ringing on ArbelMichael Brown2008-04-222-2/+14
|
* [Infiniband] Add multiport support for Arbel cardsMichael Brown2008-04-223-18/+304
|
* [Infiniband] Move event-queue process from driver to Infiniband coreMichael Brown2008-04-215-256/+348
|
* [Hermon] Fix event queue doorbells.Michael Brown2008-04-182-24/+60
| | | | | | Event queue doorbells must use UAR pages 0-127 depending on event queue number; other doorbells must use pages 128+ (and we choose to use page 128).
* [Infiniband] Add preliminary multiple port support for Hermon cardsMichael Brown2008-04-186-141/+577
| | | | | | | | | | | | Infiniband devices no longer block waiting for link-up in register_ibdev(). Hermon driver needs to create an event queue and poll for link-up events. Infiniband core needs to reread MAD parameters when link state changes. IPoIB needs to cope with Infiniband link parameters being only partially available at probe and open time.
* [HCI] Display "Not an executable image" when appropriateMichael Brown2008-04-082-0/+9
| | | | | | | | | | | | | PXE is a catch-all image format with no signature checks. If an unsupported image file is loaded, it will be treated as a PXE image. In most cases, the image will be too large to be loaded as a PXE image (which has to fit in base memory), so the error returned to the user will be that the segment could not fit within the memory region. Add an explicit check to pxe_image.c to reject images larger than base memory with ENOEXEC. Add ENOEXEC to the error string table.
* [Drivers-r8169] Add support for newer rtl8169 variants from Hilko BengenMarty Connor2008-03-312-221/+363
| | | | | 03-19-2008, Hilko Bengen, Cleanups and fixes for newer cards (successfully tested with 8110SC-d onboard NIC)
* [http] gPXE is a HTTP/1.0 client, not a HTTP/1.1 clientH. Peter Anvin2008-03-311-1/+1
| | | | | | | | | | | | | | | gPXE is not compliant with the HTTP/1.1 specification (RFC 2616), since it lacks support for "Transfer-Encoding: chunked". gPXE is, however, compliant with the HTTP/1.0 specification (RFC 1945), which does not require "Transfer-Encoding: chunked" to be supported. The only HTTP/1.1 feature that gPXE uses is the "Host:" header, but servers universally accept that one from HTTP/1.0 clients as an optional extension (it is obligatory for HTTP/1.1). gPXE does not, for example, appear to support connection caching. Advertising as a HTTP/1.0 client will typically make the server close the connection immediately upon sending the last data, which is actually beneficial if we aren't going to keep the connection alive anyway.
* [Settings] Expose SMBIOS via settings APIMichael Brown2008-03-289-138/+329
| | | | In particular, expose the system UUID as a setting ("smbios/uuid").
* [DHCP] Add support for ProxyDHCP requestsMichael Brown2008-03-273-351/+557
| | | | | | | | | | | | | | | | The PXE spec is (as usual) unclear on precisely when ProxyDHCPREQUESTs should be issued. We adapt the following, slightly paranoid approach: If an offer contains an IP address, then it is a normal DHCPOFFER. If an offer contains an option #60 "PXEClient", then it is a ProxyDHCPOFFER. Note that the same packet can be both a normal DHCPOFFER and a ProxyDHCPOFFER. After receiving the normal DHCPACK, if we have received a ProxyDHCPOFFER, we unicast a ProxyDHCPREQUEST back to the ProxyDHCP server on port 4011. If we time out waiting for a ProxyDHCPACK, we treat this as a non-fatal error.
* [Settings] find_child_settings() accepts a NULL parentMichael Brown2008-03-271-0/+4
|
* [DHCP] Treat empty fields in DHCP packets as non-existent.Michael Brown2008-03-271-10/+48
| | | | | This avoids confusing other code by insisting that we have e.g. a filename consisting of 128 zero bytes.
* [usr] Offer user a second chance to enter the shell on boot failureMichael Brown2008-03-272-21/+32
|
* [libc] Whitespace cleanup in errno.hMichael Brown2008-03-261-1/+1
|
* [PXEXT] Update documentationH. Peter Anvin2008-03-261-2/+88
| | | | | Add documentation for the FILE_EXEC and FILE_CHECK_API extension calls, and update the documentation for the FILE_READ call.
* [PXEXT] Change the PXE return code for EWOULDBLOCKH. Peter Anvin2008-03-261-2/+2
| | | | | | | | | | | Change the PXE return code for EWOULDBLOCK from PXENV_STATUS_FAILURE to PXENV_STATUS_TFTP_OPEN. This code is only used by the FILE_READ PXEXT call, and is necessary to distinguish "error" from "no data" in that call. (The only other nonblocking call is UDP_READ, where the caller doesn't care about the distinction, however, gPXE doesn't use EWOULDBLOCK internally to represent this condition in that code.)
* [PXEXT] Add FILE_API_CHECK API functionH. Peter Anvin2008-03-264-0/+67
| | | | | Add FILE_API_CHECK to the PXEXT API so the NBP can query the availability and status of the API.
* [DHCP] Save precious packet-aligned memory by copying DHCP responsesMichael Brown2008-03-261-33/+16Star
| | | | | Copy DHCP responses to a standard malloc()ed buffer, rather than retaining the I/O buffer that they arrived in.
* [PXEXT] Avoid queueing zero-length buffers in posix_io.cMichael Brown2008-03-251-6/+12
| | | | | read_user() assumes that zero-length buffers don't exist, and optimises around this.
* [Settings] Remove assumption that all settings have DHCP tag valuesMichael Brown2008-03-2524-709/+854
| | | | | | | | | | | | Allow for settings to be described by something other than a DHCP option tag if desirable. Currently used only for the MAC address setting. Separate out fake DHCP packet creation code from dhcp.c to fakedhcp.c. Remove notion of settings from dhcppkt.c. Rationalise dhcp.c to use settings API only for final registration of the DHCP options, rather than using {store,fetch}_setting throughout.
* [PXEXT] Avoid returning a false EOF when we have an empty buffer queuedMichael Brown2008-03-251-1/+3
|
* [DHCP] Fix DHCP state confusion.Michael Brown2008-03-251-2/+5
| | | | | DHCP code was using an incorrect check for whether to construct a DHCPDISCOVER or DHCPREQUEST packet.
* [Settings] Add named setting for next-serverMichael Brown2008-03-241-0/+6
| | | | | It's probably easier to have a named setting for next-server, rather than to explain to people why they need to pretend it is option 175.3.
* [Makefile] Use -MM instead of -M in dependency generationMichael Brown2008-03-241-1/+1
| | | | | | Using -MM strips out any system header files from the dependency list, which means that we could safely use an external stdarg.h if we wanted to.
* [libc] Use __builtin_va_list et al in stdarg.hMichael Brown2008-03-242-22/+10Star
| | | | | The home-grown versions don't work properly for static variadic functions, when gcc can choose to use a non-standard calling convention.
* [Settings] copy_settings() should not fail if some settings are missing!Michael Brown2008-03-243-59/+71
|
* [IPv4] Use default netmasks when no subnet mask is specified.Michael Brown2008-03-232-8/+27
|
* [IPv4] Tidy up some header files.Michael Brown2008-03-236-63/+25Star
|
* [DHCP] Fix up fake-packet creation as used by PXENV_GET_CACHED_INFOMichael Brown2008-03-235-79/+148
| | | | | | | | | | | Add dedicated functions create_dhcpdiscover(), create_dhcpack() and create_proxydhcpack() for use by external code such as the PXE preboot code. Register ProxyDHCP options under the global scope "proxydhcp". Unregister previously-acquired DHCP and ProxyDHCP settings when DHCP succeeds.