[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [RFC PATCH v3 21/28] tests/qtest: Skip tests that depend on TCG when
From: |
Fabiano Rosas |
Subject: |
Re: [RFC PATCH v3 21/28] tests/qtest: Skip tests that depend on TCG when CONFIG_TCG=n |
Date: |
Fri, 13 Jan 2023 12:16:26 -0300 |
Thomas Huth <thuth@redhat.com> writes:
> On 13/01/2023 15.04, Fabiano Rosas wrote:
>> Signed-off-by: Fabiano Rosas <farosas@suse.de>
>> ---
>> tests/qtest/arm-cpu-features.c | 24 ++++++++++++++++++++++++
>> 1 file changed, 24 insertions(+)
>>
>> diff --git a/tests/qtest/arm-cpu-features.c b/tests/qtest/arm-cpu-features.c
>> index 4be1415823..9a052e41fc 100644
>> --- a/tests/qtest/arm-cpu-features.c
>> +++ b/tests/qtest/arm-cpu-features.c
>> @@ -217,6 +217,15 @@ static void assert_bad_props(QTestState *qts, const
>> char *cpu_type)
>> qobject_unref(resp);
>> }
>>
>> +static bool tcg_disabled(void)
>> +{
>> +#ifndef CONFIG_TCG
>> + return true;
>> +#else
>> + return false;
>> +#endif
>> +}
>> +
>> static uint64_t resp_get_sve_vls(QDict *resp)
>> {
>> QDict *props;
>> @@ -338,6 +347,11 @@ static void sve_tests_sve_max_vq_8(const void *data)
>> {
>> QTestState *qts;
>>
>> + if (tcg_disabled()) {
>> + g_test_skip("TCG support disabled in this build");
>> + return;
>> + }
>
> Could you please use qtest_has_accel("tcg") instead? ... that's what we use
> in other spots in the qtests for checking for valid accelerators already.
Ah, that's much better, thanks!
- Re: [RFC PATCH v3 18/28] target/arm: Move common cpu code into cpu.c, (continued)
[RFC PATCH v3 19/28] target/arm: move cpu_tcg to tcg/cpu32.c, Fabiano Rosas, 2023/01/13
[RFC PATCH v3 17/28] target/arm: Move cortex sysregs into cpregs.c, Fabiano Rosas, 2023/01/13
[RFC PATCH v3 21/28] tests/qtest: Skip tests that depend on TCG when CONFIG_TCG=n, Fabiano Rosas, 2023/01/13
[RFC PATCH v3 20/28] target/arm: Set cortex-a57 as default cpu for KVM-only build, Fabiano Rosas, 2023/01/13
Re: [RFC PATCH v3 20/28] target/arm: Set cortex-a57 as default cpu for KVM-only build, Richard Henderson, 2023/01/13