mirror of
https://github.com/ipxe/ipxe
synced 2026-04-16 03:00:10 +03:00
[block] Allow SAN boot device to be identified by UUID
Add a "--uuid" option which may be used to specify a boot device UUID, to be matched against the GPT partition GUID. Signed-off-by: Michael Brown <mcb30@ipxe.org>
This commit is contained in:
@@ -126,10 +126,18 @@ struct named_setting {
|
||||
struct setting setting;
|
||||
};
|
||||
|
||||
/** A UUID command-line option */
|
||||
struct uuid_option {
|
||||
/** UUID */
|
||||
union uuid *value;
|
||||
/** Storage buffer */
|
||||
union uuid buf;
|
||||
};
|
||||
|
||||
extern int parse_string ( char *text, char **value );
|
||||
extern int parse_integer ( char *text, unsigned int *value );
|
||||
extern int parse_timeout ( char *text, unsigned long *value );
|
||||
extern int parse_uuid ( char *text, union uuid *value );
|
||||
extern int parse_uuid ( char *text, struct uuid_option *uuid );
|
||||
extern int parse_netdev ( char *text, struct net_device **netdev );
|
||||
extern int
|
||||
parse_netdev_configurator ( char *text,
|
||||
|
||||
@@ -19,6 +19,7 @@ FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL );
|
||||
#include <ipxe/process.h>
|
||||
#include <ipxe/blockdev.h>
|
||||
#include <ipxe/acpi.h>
|
||||
#include <ipxe/uuid.h>
|
||||
#include <config/sanboot.h>
|
||||
|
||||
/**
|
||||
@@ -109,6 +110,8 @@ enum san_device_flags {
|
||||
struct san_boot_config {
|
||||
/** Boot filename (or NULL to use default) */
|
||||
const char *filename;
|
||||
/** UUID (or NULL to ignore UUID) */
|
||||
union uuid *uuid;
|
||||
};
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user