iPXE
|
VMware GuestInfo settings. More...
#include <stdint.h>
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include <errno.h>
#include <ipxe/init.h>
#include <ipxe/settings.h>
#include <ipxe/netdevice.h>
#include <ipxe/guestrpc.h>
Go to the source code of this file.
Functions | |
FILE_LICENCE (GPL2_OR_LATER) | |
static int | guestinfo_fetch_type (struct settings *settings, struct setting *setting, const struct setting_type *type, void *data, size_t len, int *found) |
Fetch value of typed GuestInfo setting. More... | |
static int | guestinfo_fetch (struct settings *settings, struct setting *setting, void *data, size_t len) |
Fetch value of GuestInfo setting. More... | |
static void | guestinfo_init (void) |
Initialise GuestInfo settings. More... | |
struct init_fn guestinfo_init_fn | __init_fn (INIT_NORMAL) |
GuestInfo settings initialiser. More... | |
static int | guestinfo_net_probe (struct net_device *netdev, void *priv) |
Create per-netdevice GuestInfo settings. More... | |
Variables | |
static int | guestinfo_channel |
GuestInfo GuestRPC channel. More... | |
static struct settings_operations | guestinfo_settings_operations |
GuestInfo settings operations. More... | |
static struct settings | guestinfo_settings |
GuestInfo settings. More... | |
struct net_driver guestinfo_net_driver | __net_driver |
GuestInfo per-netdevice driver. More... | |
VMware GuestInfo settings.
Definition in file guestinfo.c.
FILE_LICENCE | ( | GPL2_OR_LATER | ) |
|
static |
Fetch value of typed GuestInfo setting.
settings | Settings block |
setting | Setting to fetch |
type | Setting type to attempt (or NULL for default) |
data | Buffer to fill with setting data |
len | Length of buffer |
found | Setting found in GuestInfo |
len | Length of setting data, or negative error |
Definition at line 52 of file guestinfo.c.
References assert(), data, DBGC, DBGC2, EIO, ENOMEM, find_setting(), free, guestinfo_channel, guestrpc_command(), info, info_len, len, setting::name, settings::name, NULL, settings::parent, setting_parse(), snprintf(), strerror(), strlen(), type, setting::type, and zalloc().
Referenced by guestinfo_fetch().
|
static |
Fetch value of GuestInfo setting.
settings | Settings block |
setting | Setting to fetch |
data | Buffer to fill with setting data |
len | Length of buffer |
len | Length of setting data, or negative error |
Definition at line 141 of file guestinfo.c.
References data, ENOENT, for_each_table_entry, guestinfo_fetch_type(), len, NULL, SETTING_TYPES, and type.
|
static |
Initialise GuestInfo settings.
Definition at line 180 of file guestinfo.c.
References DBG, guestinfo_channel, guestinfo_settings, guestrpc_open(), NULL, rc, register_settings(), and strerror().
struct init_fn guestinfo_init_fn __init_fn | ( | INIT_NORMAL | ) |
GuestInfo settings initialiser.
|
static |
Create per-netdevice GuestInfo settings.
netdev | Network device |
priv | Private data |
rc | Return status code |
Definition at line 213 of file guestinfo.c.
References DBGC, guestinfo_channel, guestinfo_settings_operations, net_device::name, netdev, netdev_settings(), NULL, priv, rc, net_device::refcnt, register_settings(), settings_init(), and strerror().
|
static |
GuestInfo GuestRPC channel.
Definition at line 39 of file guestinfo.c.
Referenced by guestinfo_fetch_type(), guestinfo_init(), and guestinfo_net_probe().
|
static |
GuestInfo settings operations.
Definition at line 167 of file guestinfo.c.
Referenced by guestinfo_net_probe().
|
static |
GuestInfo settings.
Definition at line 172 of file guestinfo.c.
Referenced by guestinfo_init().
struct net_driver guestinfo_net_driver __net_driver |
GuestInfo per-netdevice driver.
Definition at line 237 of file guestinfo.c.