The testsuites contain several tests which require the "mac99" and "g3beige" machine types, which will fail when CONFIG_MAC is not specified.
Signed-off-by: David Gibson <da...@gibson.dropbear.id.au> --- tests/boot-order-test.c | 6 ++++++ tests/endianness-test.c | 4 ++++ 2 files changed, 10 insertions(+) diff --git a/tests/boot-order-test.c b/tests/boot-order-test.c index bff16b5..1a7aa8b 100644 --- a/tests/boot-order-test.c +++ b/tests/boot-order-test.c @@ -138,12 +138,14 @@ static void test_prep_boot_order(void) } #endif /* CONFIG_PREP */ +#ifdef CONFIG_MAC static uint64_t read_boot_order_pmac(void) { QFWCFG *fw_cfg = mm_fw_cfg_init(0xf0000510); return qfw_cfg_get_u16(fw_cfg, FW_CFG_BOOT_DEVICE); } +#endif /* CONFIG_MAC */ static const boot_order_test test_cases_fw_cfg[] = { { "", 'c', 'c' }, @@ -153,6 +155,7 @@ static const boot_order_test test_cases_fw_cfg[] = { {} }; +#ifdef CONFIG_MAC static void test_pmac_oldworld_boot_order(void) { test_boot_orders("g3beige", read_boot_order_pmac, test_cases_fw_cfg); @@ -162,6 +165,7 @@ static void test_pmac_newworld_boot_order(void) { test_boot_orders("mac99", read_boot_order_pmac, test_cases_fw_cfg); } +#endif /* CONFIG_MAC */ static uint64_t read_boot_order_sun4m(void) { @@ -199,10 +203,12 @@ int main(int argc, char *argv[]) #ifdef CONFIG_PREP qtest_add_func("boot-order/prep", test_prep_boot_order); #endif /* CONFIG_PREP */ +#ifdef CONFIG_MAC qtest_add_func("boot-order/pmac_oldworld", test_pmac_oldworld_boot_order); qtest_add_func("boot-order/pmac_newworld", test_pmac_newworld_boot_order); +#endif /* CONFIG_MAC */ } else if (strcmp(arch, "sparc") == 0) { qtest_add_func("boot-order/sun4m", test_sun4m_boot_order); } else if (strcmp(arch, "sparc64") == 0) { diff --git a/tests/endianness-test.c b/tests/endianness-test.c index 0857784..73b512b 100644 --- a/tests/endianness-test.c +++ b/tests/endianness-test.c @@ -40,12 +40,16 @@ static const TestCase test_cases[] = { { "mips64", "mips", 0x14000000, .bswap = true }, { "mips64", "malta", 0x10000000, .bswap = true }, { "mips64el", "fulong2e", 0x1fd00000 }, +#ifdef CONFIG_MAC { "ppc", "g3beige", 0xfe000000, .bswap = true, .superio = "i82378" }, +#endif /* CONFIG_MAC */ #ifdef CONFIG_PREP { "ppc", "prep", 0x80000000, .bswap = true }, #endif /* CONFIG_PREP */ { "ppc", "bamboo", 0xe8000000, .bswap = true, .superio = "i82378" }, +#ifdef CONFIG_MAC { "ppc64", "mac99", 0xf2000000, .bswap = true, .superio = "i82378" }, +#endif /* CONFIG_MAC */ { "ppc64", "pseries", 0x10080000000ULL, .bswap = true, .superio = "i82378" }, { "sh4", "r2d", 0xfe240000, .superio = "i82378" }, -- 1.9.3