david/ipxe
david
/
ipxe
Archived
1
0
Fork 0
Commit Graph

37 Commits

Author SHA1 Message Date
Michael Brown f76210961c [pci] Support systems with multiple PCI root bridges
Extend the 16-bit PCI bus:dev.fn address to a 32-bit seg🚌dev.fn
address, assuming a segment value of zero in contexts where multiple
segments are unsupported by the underlying data structures (e.g. in
the iBFT or BOFM tables).

Signed-off-by: Michael Brown <mcb30@ipxe.org>
2016-06-09 09:36:28 +01:00
Michael Brown b6ee89ffb5 [legal] Relicense files under GPL2_OR_LATER_OR_UBDL
Relicense files for which I am the sole author (as identified by
util/relicense.pl).

Signed-off-by: Michael Brown <mcb30@ipxe.org>
2015-03-02 14:17:31 +00:00
Michael Brown 22001cb206 [settings] Explicitly separate the concept of a completed fetched setting
The fetch_setting() family of functions may currently modify the
definition of the specified setting (e.g. to add missing type
information).  Clean up this interface by requiring callers to provide
an explicit buffer to contain the completed definition of the fetched
setting, if required.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
2013-12-05 00:37:02 +00:00
Michael Brown 15d2f947f5 [settings] Eliminate settings "tag magic"
Create an explicit concept of "settings scope" and eliminate the magic
values used for numerical setting tags.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
2013-05-01 19:52:12 +01:00
Michael Brown c3b4860ce3 [legal] Update FSF mailing address in GPL licence texts
Suggested-by: Daniel P. Berrange <berrange@redhat.com>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
2012-07-20 19:55:45 +01:00
Michael Brown f5fd4dec3b [settings] Formalise notion of setting applicability
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>
2011-03-22 19:54:58 +00:00
Michael Brown 070100b21d [phantom] Remove unused variable in phantom_dmesg()
Reported-by: Ralph Giles <giles@thaumas.net>
Tested-by: Ralph Giles <giles@thaumas.net>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
2011-03-16 19:32:23 +00:00
Michael Brown 5bde349e55 [pci] Make driver PCI ID a property of the PCI device
Signed-off-by: Michael Brown <mcb30@ipxe.org>
2011-02-17 01:25:12 +00:00
Michael Brown f9b3fae8d4 [pci] Use single "busdevfn" field in struct pci_device
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>
2011-02-17 01:25:11 +00:00
Michael Brown 67b45186a5 [settings] Apply settings block name in register_settings()
Pass the settings block name as a parameter to register_settings(),
rather than defining it with settings_init() (and then possibly
changing it by directly manipulating settings->name).

Signed-off-by: Michael Brown <mcb30@ipxe.org>
2010-12-01 16:35:00 +00:00
Michael Brown 8406115834 [build] Rename gPXE to iPXE
Access to the gpxe.org and etherboot.org domains and associated
resources has been revoked by the registrant of the domain.  Work
around this problem by renaming project from gPXE to iPXE, and
updating URLs to match.

Also update README, LOG and COPYRIGHTS to remove obsolete information.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
2010-04-19 23:43:39 +01:00
Michael Brown b3533dd2bb [phantom] Update interrupt support to match current firmware
The interrupt control mechanism on Phantom cards has changed
substantially since the driver was initially written.  This updates
the code to match the mechanism used in production firmware.

This is sufficient to allow DOS wget to function successfully using
the 3Com UNDI/NDIS, Intel UNDI/NDIS, and UNDIPD.COM UNDI/PD stacks.

Signed-off-by: Michael Brown <mcb30@etherboot.org>
2010-03-22 21:59:27 +00:00
Michael Brown 37a0aab4ff [netdevice] Separate out the concept of hardware and link-layer addresses
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().
2009-08-12 00:19:14 +01:00
Michael Brown d09290161e [netdevice] Make ll_broadcast per-netdevice rather than per-ll_protocol
IPoIB has a link-layer broadcast address that varies according to the
partition key.  We currently go through several contortions to pretend
that the link-layer address is a fixed constant; by making the
broadcast address a property of the network device rather than the
link-layer protocol it will be possible to simplify IPoIB's broadcast
handling.
2009-07-17 23:02:48 +01:00
Michael Brown c44a193d0d [legal] Add a selection of FILE_LICENCE declarations
Add FILE_LICENCE declarations to almost all files that make up the
various standard builds of gPXE.
2009-05-18 08:33:25 +01:00
Thomas Miletich 3da6f1c7bd [pci] Add driver_data field to struct pci_device_id
Modified-by: Michael Brown <mcb30@etherboot.org>
Signed-off-by: Michael Brown <mcb30@etherboot.org>
2009-03-26 10:22:15 +00:00
Michael Brown b59e0cc56e [i386] Change [u]int32_t to [unsigned] int, rather than [unsigned] long
This brings us in to line with Linux definitions, and also simplifies
adding x86_64 support since both platforms have 2-byte shorts, 4-byte
ints and 8-byte long longs.
2008-11-19 19:15:44 +00:00
Michael Brown 46f43d8ea7 [phantom] Do not halt PEGs on driver shutdown
Halting the PEGs breaks platforms where there is sideband access to
the NIC (e.g. HP machines using iLO).  (We have to retain the
unhalting code because on some other platforms (e.g. IBM blades with
BOFM) the pre-PXE firmware must halt the PEGs to avoid issues with the
BIOS rereading via the expansion ROM BAR.)
2008-11-08 05:10:23 +00:00
Michael Brown aa95744915 [phantom] Allow for PXE boot to be enabled/disabled on a per-port basis
This is something of an ugly hack to accommodate an OEM requirement.
The NIC has only one expansion ROM BAR, rather than one per port.  To
allow individual ports to be selectively enabled/disabled for PXE boot
(as required), we must therefore leave the expansion ROM always
enabled, and place the per-port enable/disable logic within the gPXE
driver.
2008-11-01 01:55:13 +00:00
Michael Brown 32bc76f902 [phantom] Assume one net device per PCI function
The Phantom firmware selectively disables PCI functions based on the
board type, with the end result that we see one PCI function for each
network port.  This allows us to eliminate the code for reading from
flash and, more importantly, removes knowledge of the board type magic
number from the gPXE driver.
2008-10-31 01:55:58 +00:00
Michael Brown 0a6c66a830 [settings] Add the notion of a "tag magic" to numbered settings
Settings can be constructed using a dotted-decimal notation, to allow
for access to unnamed settings.  The default interpretation is as a
DHCP option number (with encapsulated options represented as
"<encapsulating option>.<encapsulated option>".

In several contexts (e.g. SMBIOS, Phantom CLP), it is useful to
interpret the dotted-decimal notation as referring to non-DHCP
options.  In this case, it becomes necessary for these contexts to
ignore standard DHCP options, otherwise we end up trying to, for
example, retrieve the boot filename from SMBIOS.

Allow settings blocks to specify a "tag magic".  When dotted-decimal
notation is used to construct a setting, the tag magic value of the
originating settings block will be ORed in to the tag number.
Store/fetch methods can then check for the magic number before
interpreting arbitrarily-numbered settings.
2008-10-30 21:47:14 +00:00
Michael Brown 1bc2adea9a [phantom] Add CLP settings interface
This interface provides access to firmware settings (e.g. MAC address)
that will apply to all drivers loaded for the duration of the current
system boot.
2008-10-28 18:49:58 +00:00
Michael Brown 664f4cf365 [phantom] Unhalt/halt all PEGs during driver startup/shutdown
A hardware bug means that reads through the expansion ROM BAR can
return corrupted data if the PEGs are running.  This breaks platforms
that re-read the expansion ROM after invoking gPXE code, such as IBM
blade servers.

Halt PEGs during driver shutdown, and unhalt PEGs during driver
startup if we detect that this is not the first startup since
power-on.
2008-10-28 18:47:44 +00:00
Michael Brown df033de24f [phantom] Add line count limit to phantom_dmesg()
The Phantom firmware debug logs can be extremely long, so add the
ability to restrict the output to the last N lines.
2008-10-28 18:47:00 +00:00
Michael Brown d4c8273569 [phantom] Change register space abstraction to match other drivers
Most other Phantom drivers define a register space in terms of a 64M
virtual address space.  While this doesn't map in any meaningful way
to the actual addresses used on the latest cards, it makes maintenance
easier if we do the same.
2008-10-24 03:52:17 +01:00
Michael Brown e226a8d8d9 [phantom] Add missing #include <gpxe/io.h> 2008-10-12 12:52:47 +01:00
Michael Brown 4011f9d956 [phantom] Skip command PEG initialisation if PEG is already running
It is possible for the BIOS to use the UNDI API to bring up the NIC
prior to system boot.  If this happens, UNM_NIC_REG_CMDPEG_STATE will
contain the value 0xf00f (UNM_NIC_REG_CMDPEG_STATE_INITIALIZE_ACK),
and we should skip initialising the command PEG.
2008-09-23 23:36:55 +01:00
Michael Brown e13d793160 [phantom] Omit an initialisation step now performed by the firmware
The firmware will now determine the right port mode on all cards, so
the PXE driver doesn't have to set it.  (Setting the port mode
apparently breaks some newer cards.)
2008-09-23 23:11:05 +01:00
Michael Brown cb6fea0690 [phantom] Fix P3 B1 silicon bug workaround
Commit f58cc3f introduced a temporary workaround for a bug in current
prototype silicon, but failed to apply it to all eight PCI functions
within the device.
2008-08-27 21:25:06 +01:00
Michael Brown 07581d3faa [phantom] Remove comment that no longer matches reality 2008-08-26 04:45:31 +01:00
Michael Brown f58cc3fca8 [phantom] Temporary workaround for bug in prototype (P3 B1) silicon 2008-08-25 23:25:33 +01:00
Michael Brown f493283c74 [phantom] Add new board type 2008-07-24 19:40:10 +01:00
Michael Brown 4e033c774b [phantom] Guard against partially-written status descriptors
Conjecture: The hardware issues 64-bit DMA writes of status descriptors,
which some PCI bridges seem to split into two 32-bit writes in reverse
order (i.e. dword 1 first).  This means that we sometimes observe a
partial status descriptor.  Add an explicit check to ensure that the
descriptor is complete before processing it.

Also ensure that the RDS consumer counter is incremented only when we
know that we have actually consumed an RX descriptor.
2008-07-17 15:45:40 +01:00
Michael Brown d474386336 [phantom] Remove warning relating to now-fixed firmware bug 2008-07-08 22:37:36 +01:00
Michael Brown 22d00797f1 [phantom] Add NetXen dual copyright 2008-07-08 22:36:07 +01:00
Michael Brown 4f05d2fca7 [phantom] Initialise RCVPEG before reading MAC addresses 2008-07-08 20:59:33 +01:00
Michael Brown 3ad348e55a [phantom] Add support for NetXen Phantom NICs 2008-07-04 19:38:14 -07:00