All of lore.kernel.org
 help / color / mirror / Atom feed
From: Claudio Fontana <cfontana@suse.de>
To: Paolo Bonzini <pbonzini@redhat.com>
Cc: Alex Bennee <alex.bennee@linaro.org>, qemu-devel <qemu-devel@nongnu.org>
Subject: Re: meson, NEED_CPU_H, CONFIG_TCG and tests/
Date: Fri, 19 Feb 2021 14:13:33 +0100	[thread overview]
Message-ID: <fe900b5b-3987-e9e7-345c-8df77d430292@suse.de> (raw)
In-Reply-To: <eb7d8eca-13ef-07cf-41b4-d7276399fff1@suse.de>

On 2/19/21 2:04 PM, Claudio Fontana wrote:
> Hi Paolo,
> 
> currently we have use of CONFIG_TCG in tests/,
> 
> but is that variable available at all in there?
> 
> I have to adapt some qemu/tests/qtest/* to work also without tcg for ARM,
> 
> but I think I am not seeing CONFIG_TCG filtering through, and I wonder whether all the checks in there are actually "wrong".
> 
> Looking at meson.build it would seem to me that only stuff in target/ would be able to see CONFIG_TCG,
> as a result of
> 
> foreach target : target_dirs
>   config_target = config_target_mak[target]
>   target_name = config_target['TARGET_NAME']
>   arch = config_target['TARGET_BASE_ARCH']
>   arch_srcs = [config_target_h[target]]
>   arch_deps = []
>   c_args = ['-DNEED_CPU_H',
>             '-DCONFIG_TARGET="@0@-config-target.h"'.format(target),
>             '-DCONFIG_DEVICES="@0@-config-devices.h"'.format(target)]
> 
> But how could tests see this?
> 
> Thanks,
> 
> Claudio
> 

By the way, I think Alex is working around this in the TCG tests in the tests/tcg/Makefile.target:

all:
-include ../../../config-host.mak
-include ../config-$(TARGET).mak

..


In my view we need some solution for at least:

tests/qtest/qmp-cmd-test.c
tests/qtest/boot-serial-test.c
tests/qtest/bios-tables-test.c

which need to behave differently according to whether TCG is available or not (--disable-tcg):

For the specific case at hand that I encountered, reopening the issue, 

I need to make tests/qtest/boot-serial-test.c pass different cpu options for TCG and KVM,
ie "cortex-a57" for TCG, and "host" for KVM.

Wdyt?

Ciao,

Claudio



  reply	other threads:[~2021-02-19 13:16 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-02-19 13:04 meson, NEED_CPU_H, CONFIG_TCG and tests/ Claudio Fontana
2021-02-19 13:13 ` Claudio Fontana [this message]
2021-02-19 13:14 ` Philippe Mathieu-Daudé
2021-02-19 13:17   ` Claudio Fontana
2021-02-19 13:48     ` Philippe Mathieu-Daudé
2021-02-19 13:54       ` Claudio Fontana
2021-02-19 13:30 ` Thomas Huth
2021-02-19 16:04   ` Paolo Bonzini
2021-02-19 17:24     ` Claudio Fontana

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=fe900b5b-3987-e9e7-345c-8df77d430292@suse.de \
    --to=cfontana@suse.de \
    --cc=alex.bennee@linaro.org \
    --cc=pbonzini@redhat.com \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.