summaryrefslogtreecommitdiffstats
path: root/src/net/netdev_settings.c
Commit message (Collapse)AuthorAgeFilesLines
* [netdevice] Add missing bus types to netdev_fetch_bustype()Michael Brown2015-03-181-0/+4
| | | | | Reported-by: Robin Smidsrød <robin@smidsrod.no> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [legal] Relicense files under GPL2_OR_LATER_OR_UBDLMichael Brown2015-03-021-1/+5
| | | | | | | | | | | | | | | Relicence files with kind permission from the following contributors: Alex Williamson <alex.williamson@redhat.com> Eduardo Habkost <ehabkost@redhat.com> Greg Jednaszewski <jednaszewski@gmail.com> H. Peter Anvin <hpa@zytor.com> Marin Hannache <git@mareo.fr> Robin Smidsrød <robin@smidsrod.no> Shao Miller <sha0.miller@gmail.com> Thomas Horsten <thomas@horsten.com> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [settings] Force settings into alphabetical order within sectionsMichael Brown2013-12-051-5/+5
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [settings] Explicitly separate the concept of a completed fetched settingMichael Brown2013-12-051-7/+8
| | | | | | | | | | 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>
* [linux] Give tap devices a name and bus typeMichael Brown2013-08-271-1/+2
| | | | | | | | Give tap devices a meaningful name, and avoid segmentation faults when attempting to retrieve ${net0/bustype} by assigning a new bus type for tap devices. Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [settings] Clarify usage of the term "named setting"Michael Brown2013-07-181-1/+1
| | | | | | | | | | | | There are currently two conflicting usages of the term "named setting" within iPXE: one refers to predefined settings (such as show up in the "config" UI), the other refers to settings identified by a name (such as "net0.dhcp/ip"). Split these usages into the term "predefined setting" and "named setting" to avoid ambiguity. Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [settings] Make "netX" settings block function as a symbolic linkMichael Brown2013-07-131-0/+49
| | | | | | | | | | | | | | Add a facility for settings blocks to act as symbolic links to other settings blocks, and reimplement the "netX" virtual settings block using this facility. The primary advantage of this approach is that unscoped settings such as ${mac} and ${filename} will now reflect the settings obtained from the most recently opened network device: in most cases, this will mean the settings obtained from the most recent DHCP attempt. This should improve conformance to the principle of least astonishment. Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [netdevice] Add "bustype" and "busloc" settingsMichael Brown2013-07-121-0/+60
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [netdevice] Reset MAC address when asked to clear the "mac" settingMichael Brown2013-05-161-3/+11
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [netdevice] Add "chip" settingMichael Brown2013-05-161-26/+131
| | | | | Suggested-by: Robin Smidsrød <robin@smidsrod.no> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [settings] Eliminate settings "tag magic"Michael Brown2013-05-011-17/+0Star
| | | | | | | 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>
* [legal] Update FSF mailing address in GPL licence textsMichael Brown2012-07-201-1/+2
| | | | | Suggested-by: Daniel P. Berrange <berrange@redhat.com> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [settings] Impose a fixed order on settingsMichael Brown2011-03-231-2/+2
| | | | | | | Improve the appearance of the "config" user interface by ensuring that settings appear in some kind of logical order. Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [settings] Reject attempts to change a network device's bus IDMichael Brown2011-03-231-0/+2
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [settings] Formalise notion of setting applicabilityMichael Brown2011-03-221-0/+18
| | | | | | | | | | | | | | | 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>
* [build] Rename gPXE to iPXEMichael Brown2010-04-201-4/+4
| | | | | | | | | | | 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>
* [settings] Add Bus ID settingShao Miller2009-12-141-0/+18
| | | | | | | | Users can find the bus type and PCI IDs for a network interface with: netX/busid Signed-off-by: Stefan Hajnoczi <stefanha@gmail.com>
* [settings] Allow for arbitrarily-named settingsMichael Brown2009-05-261-4/+14
| | | | | This provides a mechanism for using arbitrarily-named variables within gPXE, using the existing syntax for settings.
* [legal] Add a selection of FILE_LICENCE declarationsMichael Brown2009-05-181-0/+2
| | | | | Add FILE_LICENCE declarations to almost all files that make up the various standard builds of gPXE.
* [Settings] Remove assumption that all settings have DHCP tag valuesMichael Brown2008-03-251-22/+17Star
| | | | | | | | | | | | 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.
* [Settings] Implement simple_settings backed with extensible DHCP optionsMichael Brown2008-03-221-4/+4
|
* [Settings] Add per-netdevice settings blockMichael Brown2008-03-201-0/+95
Add a configuration settings block for each net device. This will provide the parent scope for settings applicable only to that network device (e.g. non-volatile options stored on the NIC, options obtained via DHCP, etc.). Expose the MAC address as a setting.