aboutsummaryrefslogtreecommitdiffstats
path: root/com32/hdt/hdt-cli.c
diff options
context:
space:
mode:
Diffstat (limited to 'com32/hdt/hdt-cli.c')
-rw-r--r--com32/hdt/hdt-cli.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/com32/hdt/hdt-cli.c b/com32/hdt/hdt-cli.c
index 1e13759e..871fd76c 100644
--- a/com32/hdt/hdt-cli.c
+++ b/com32/hdt/hdt-cli.c
@@ -43,6 +43,7 @@ struct cli_mode_descr *list_modes[] = {
&cpu_mode,
&pci_mode,
&vesa_mode,
+ &vpd_mode,
NULL,
};
@@ -178,6 +179,17 @@ void set_mode(cli_mode_t mode, struct s_hardware* hardware)
snprintf(hdt_cli.prompt, sizeof(hdt_cli.prompt), "%s> ",
CLI_DMI);
break;
+ case VPD_MODE:
+ detect_vpd(hardware);
+ if (!hardware->is_vpd_valid) {
+ printf("No valid VPD table found, exiting.\n");
+ break;
+ }
+ hdt_cli.mode = mode;
+ snprintf(hdt_cli.prompt, sizeof(hdt_cli.prompt), "%s> ",
+ CLI_VPD);
+ break;
+
default:
/* Invalid mode */
printf("Unknown mode, please choose among:\n");