From 71b3b06b563089adef288eb8c33266ad6654cc83 Mon Sep 17 00:00:00 2001 From: Nathaniel Wesley Filardo Date: Wed, 8 Jan 2025 19:00:43 +0000 Subject: [PATCH] tests: conditionalize candperms ~gl Sonata ISA versions do support this so disable the test and show a message instead. --- sdk/boards/sonata-0.2.json | 3 ++- sdk/boards/sonata-prerelease.json | 3 ++- tests/misc-test.cc | 5 +++++ 3 files changed, 9 insertions(+), 2 deletions(-) diff --git a/sdk/boards/sonata-0.2.json b/sdk/boards/sonata-0.2.json index 63b6657a..3b78434f 100644 --- a/sdk/boards/sonata-0.2.json +++ b/sdk/boards/sonata-0.2.json @@ -73,7 +73,8 @@ "SUNBURST_SHADOW_SIZE=0x4000", "DEFAULT_UART_BAUD_RATE=115200", "ipconfigDRIVER_INCLUDED_RX_IP_CHECKSUM=1", - "ipconfigDRIVER_INCLUDED_TX_IP_CHECKSUM=1" + "ipconfigDRIVER_INCLUDED_TX_IP_CHECKSUM=1", + "CHERIOT_NO_SAIL_83" ], "driver_includes" : [ "../include/platform/sunburst/v0.2", diff --git a/sdk/boards/sonata-prerelease.json b/sdk/boards/sonata-prerelease.json index 115f1119..83f22114 100644 --- a/sdk/boards/sonata-prerelease.json +++ b/sdk/boards/sonata-prerelease.json @@ -91,7 +91,8 @@ "SUNBURST_SHADOW_BASE=0x30000000", "SUNBURST_SHADOW_SIZE=0x800", "ipconfigDRIVER_INCLUDED_RX_IP_CHECKSUM=1", - "ipconfigDRIVER_INCLUDED_TX_IP_CHECKSUM=1" + "ipconfigDRIVER_INCLUDED_TX_IP_CHECKSUM=1", + "CHERIOT_NO_SAIL_83" ], "cxflags": "-mllvm -enable-machine-outliner=never", "driver_includes" : [ diff --git a/tests/misc-test.cc b/tests/misc-test.cc index e39b1e5c..3df46897 100644 --- a/tests/misc-test.cc +++ b/tests/misc-test.cc @@ -268,6 +268,7 @@ void check_sealed_scoping() o.permissions().without(Permission::Global), "Loading global sealed cap through non-LoadGlobal bad perms"); +#ifndef CHERIOT_NO_SAIL_83 /* * Use CAndPerm to shed Global from our o cap. * Spell this a little oddly to make sure we get CAndPerm with a mask of @@ -278,6 +279,10 @@ void check_sealed_scoping() oLocal2.without_permissions(Permission::Global); TEST_EQUAL(oLocal2, OLocal1, "CAndPerm ~GL gone wrong"); +#else + debug_log( + "Skipping test for cheriot-sail#83 because the ISA version is too old."); +#endif } int test_misc()