[PATCH] fwtstest: boot-0001: sync with boot table check on efi firmware

Ivan Hu ivan.hu at canonical.com
Thu Sep 26 07:52:52 UTC 2019


Signed-off-by: Ivan Hu <ivan.hu at canonical.com>
---
 fwts-test/boot-0001/boot-0001-efi.log | 8 ++++++++
 fwts-test/boot-0001/boot-0002-efi.log | 8 ++++++++
 fwts-test/boot-0001/test-0001.sh      | 9 ++++++++-
 fwts-test/boot-0001/test-0002.sh      | 8 +++++++-
 4 files changed, 31 insertions(+), 2 deletions(-)
 create mode 100644 fwts-test/boot-0001/boot-0001-efi.log
 create mode 100644 fwts-test/boot-0001/boot-0002-efi.log

diff --git a/fwts-test/boot-0001/boot-0001-efi.log b/fwts-test/boot-0001/boot-0001-efi.log
new file mode 100644
index 0000000..6335af2
--- /dev/null
+++ b/fwts-test/boot-0001/boot-0001-efi.log
@@ -0,0 +1,8 @@
+boot            boot: BOOT Table test.
+boot            ----------------------------------------------------------
+boot            ACPI BOOT table is depreciated on UEFI firmware, skipping
+boot            test
+boot            ==========================================================
+boot            0 passed, 0 failed, 0 warning, 0 aborted, 1 skipped, 0
+boot            info only.
+boot            ==========================================================
diff --git a/fwts-test/boot-0001/boot-0002-efi.log b/fwts-test/boot-0001/boot-0002-efi.log
new file mode 100644
index 0000000..6335af2
--- /dev/null
+++ b/fwts-test/boot-0001/boot-0002-efi.log
@@ -0,0 +1,8 @@
+boot            boot: BOOT Table test.
+boot            ----------------------------------------------------------
+boot            ACPI BOOT table is depreciated on UEFI firmware, skipping
+boot            test
+boot            ==========================================================
+boot            0 passed, 0 failed, 0 warning, 0 aborted, 1 skipped, 0
+boot            info only.
+boot            ==========================================================
diff --git a/fwts-test/boot-0001/test-0001.sh b/fwts-test/boot-0001/test-0001.sh
index 6c0dc92..4395448 100755
--- a/fwts-test/boot-0001/test-0001.sh
+++ b/fwts-test/boot-0001/test-0001.sh
@@ -10,8 +10,15 @@ if [ $? -eq 1 ]; then
 	exit 77
 fi
 
+if [ -d /sys/firmware/efi ]; then
+        FILE=boot-0001-efi.log
+else
+	FILE=boot-0001.log
+fi
+
+
 $FWTS --log-format="%line %owner " -w 80 --dumpfile=$FWTSTESTDIR/boot-0001/acpidump-0001.log boot - | cut -c7- | grep "^boot" > $TMPLOG
-diff $TMPLOG $FWTSTESTDIR/boot-0001/boot-0001.log >> $FAILURE_LOG
+diff $TMPLOG $FWTSTESTDIR/boot-0001/$FILE >> $FAILURE_LOG
 ret=$?
 if [ $ret -eq 0 ]; then
 	echo PASSED: $TEST, $NAME
diff --git a/fwts-test/boot-0001/test-0002.sh b/fwts-test/boot-0001/test-0002.sh
index bd3e917..b5f91f2 100755
--- a/fwts-test/boot-0001/test-0002.sh
+++ b/fwts-test/boot-0001/test-0002.sh
@@ -10,8 +10,14 @@ if [ $? -eq 1 ]; then
 	exit 77
 fi
 
+if [ -d /sys/firmware/efi ]; then
+        FILE=boot-0002-efi.log
+else
+        FILE=boot-0002.log
+fi
+
 $FWTS --log-format="%line %owner " -w 80 --dumpfile=$FWTSTESTDIR/boot-0001/acpidump-0002.log boot - | cut -c7- | grep "^boot" > $TMPLOG
-diff $TMPLOG $FWTSTESTDIR/boot-0001/boot-0002.log >> $FAILURE_LOG
+diff $TMPLOG $FWTSTESTDIR/boot-0001/$FILE >> $FAILURE_LOG
 ret=$?
 if [ $ret -eq 0 ]; then
 	echo PASSED: $TEST, $NAME
-- 
2.7.4




More information about the fwts-devel mailing list