[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH] tests: switch tests to accel=kvm:tcg
From: |
Thomas Huth |
Subject: |
Re: [Qemu-devel] [PATCH] tests: switch tests to accel=kvm:tcg |
Date: |
Mon, 14 Aug 2017 17:47:12 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.2.0 |
On 14.08.2017 17:33, Cornelia Huck wrote:
> On Mon, 14 Aug 2017 17:34:15 +0300
> "Michael S. Tsirkin" <address@hidden> wrote:
>
>> Speed up tests on host systems with kvm support.
>> In particular, this fixes tests with --disable-tcg.
[...]
>> diff --git a/tests/pnv-xscom-test.c b/tests/pnv-xscom-test.c
>> index 5adc3fd..7be396f 100644
>> --- a/tests/pnv-xscom-test.c
>> +++ b/tests/pnv-xscom-test.c
>> @@ -84,7 +84,7 @@ static void test_cfam_id(const void *data)
>> char *args;
>> const PnvChip *chip = data;
>>
>> - args = g_strdup_printf("-M powernv,accel=tcg -cpu %s", chip->cpu_model);
>> + args = g_strdup_printf("-M powernv,accel=kvm:tcg -cpu %s",
>> chip->cpu_model);
>>
>> qtest_start(args);
>> test_xscom_cfam_id(chip);
>> @@ -112,7 +112,7 @@ static void test_core(const void *data)
>> char *args;
>> const PnvChip *chip = data;
>>
>> - args = g_strdup_printf("-M powernv,accel=tcg -cpu %s", chip->cpu_model);
>> + args = g_strdup_printf("-M powernv,accel=kvm:tcg -cpu %s",
>> chip->cpu_model);
>>
>> qtest_start(args);
>> test_xscom_core(chip);
>
> These seem to test a specified cpu model explicitly, so I'm not sure
> how well this will work with kvm.
AFAIK the powernv machine does not work with KVM yet (Cédric, can you
confirm?), so you better drop the changes to this file.
>> diff --git a/tests/prom-env-test.c b/tests/prom-env-test.c
>> index eac207b..0a10f06 100644
>> --- a/tests/prom-env-test.c
>> +++ b/tests/prom-env-test.c
>> @@ -50,7 +50,7 @@ static void test_machine(const void *machine)
>> /* The pseries firmware boots much faster without the default devices */
>> extra_args = strcmp(machine, "pseries") == 0 ? "-nodefaults" : "";
>>
>> - args = g_strdup_printf("-M %s,accel=tcg %s -prom-env
>> 'use-nvramrc?=true' "
>> + args = g_strdup_printf("-M %s,accel=kvm:tcg %s -prom-env
>> 'use-nvramrc?=true' "
>> "-prom-env 'nvramrc=%x %x l!' ",
>> (const char *)machine, extra_args, MAGIC,
>> ADDRESS);
>
> The header explicitly states that this is supposed to test tcg mode.
This change should be OK here. But it is currently not necessary yet:
The test only runs on SPARC and PPC machines, and both do not support
the --disable-tcg switch yet.
Thomas