summaryrefslogtreecommitdiffstats
path: root/src/drivers/net
diff options
context:
space:
mode:
authorMichael Brown2010-12-01 17:34:23 +0100
committerMichael Brown2010-12-01 17:35:00 +0100
commit67b45186a572fb051e73fd88d4fc580a0d4d2f6b (patch)
tree9c1b23f9ceab3f9e9bf3ca0563103bc6230c0ee5 /src/drivers/net
parent[iscsi] Disambiguate the common EINVAL cases (diff)
downloadipxe-67b45186a572fb051e73fd88d4fc580a0d4d2f6b.tar.gz
ipxe-67b45186a572fb051e73fd88d4fc580a0d4d2f6b.tar.xz
ipxe-67b45186a572fb051e73fd88d4fc580a0d4d2f6b.zip
[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>
Diffstat (limited to 'src/drivers/net')
-rw-r--r--src/drivers/net/phantom/phantom.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/drivers/net/phantom/phantom.c b/src/drivers/net/phantom/phantom.c
index 665bbb022..f6b2f0064 100644
--- a/src/drivers/net/phantom/phantom.c
+++ b/src/drivers/net/phantom/phantom.c
@@ -2061,7 +2061,7 @@ static int phantom_probe ( struct pci_device *pci,
assert ( phantom->port < PHN_MAX_NUM_PORTS );
settings_init ( &phantom->settings,
&phantom_settings_operations,
- &netdev->refcnt, "clp", PHN_CLP_TAG_MAGIC );
+ &netdev->refcnt, PHN_CLP_TAG_MAGIC );
/* Fix up PCI device */
adjust_pci_device ( pci );
@@ -2111,7 +2111,7 @@ static int phantom_probe ( struct pci_device *pci,
/* Register settings blocks */
parent_settings = netdev_settings ( netdev );
if ( ( rc = register_settings ( &phantom->settings,
- parent_settings ) ) != 0 ) {
+ parent_settings, "clp" ) ) != 0 ) {
DBGC ( phantom, "Phantom %p could not register settings: "
"%s\n", phantom, strerror ( rc ) );
goto err_register_settings;