aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--sample/hdt.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/sample/hdt.c b/sample/hdt.c
index 7d7e3efc..6329fd04 100644
--- a/sample/hdt.c
+++ b/sample/hdt.c
@@ -1088,10 +1088,14 @@ void detect_hardware(s_dmi *dmi, s_cpu *cpu, struct pci_domain **pci_domain, str
detect_disks(disk_info);
printf("DMI: Detecting Table\n");
- if (detect_dmi(dmi) ==0 )
- is_dmi_valid=true;
-
- printf("DMI: Table found ! (version %d.%d)\n",dmi->dmitable.major_version,dmi->dmitable.minor_version);
+ if (detect_dmi(dmi) == -ENODMITABLE ) {
+ is_dmi_valid=false;
+ printf("DMI: ERROR ! Table not found ! \n");
+ printf("DMI: Many hardware components will not be detected ! \n");
+ } else {
+ is_dmi_valid=true;
+ printf("DMI: Table found ! (version %d.%d)\n",dmi->dmitable.major_version,dmi->dmitable.minor_version);
+ }
#ifdef WITH_PCI
printf("PCI: Detecting Devices\n");