[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v1 18/24] tests/tcg/arm: fix hello-arm
From: |
Philippe Mathieu-Daudé |
Subject: |
Re: [Qemu-devel] [PATCH v1 18/24] tests/tcg/arm: fix hello-arm |
Date: |
Sun, 15 Apr 2018 22:28:55 -0300 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.7.0 |
Hi Alex,
On 04/10/2018 04:39 PM, Alex Bennée wrote:
> As hello-arm is a bare bones syscall test it needs specific compiler
> flags so it doesn't try and link against glibc.
>
> Signed-off-by: Alex Bennée <address@hidden>
> ---
> tests/tcg/arm/Makefile.target | 6 ++++++
> 1 file changed, 6 insertions(+)
> create mode 100644 tests/tcg/arm/Makefile.target
>
> diff --git a/tests/tcg/arm/Makefile.target b/tests/tcg/arm/Makefile.target
> new file mode 100644
> index 0000000000..b7c146c88e
> --- /dev/null
> +++ b/tests/tcg/arm/Makefile.target
> @@ -0,0 +1,6 @@
> +# -*- Mode: makefile -*-
> +#
> +# ARM specific tweaks
... (Thumb mode explicitly disabled)
> +
> +hello-arm: CFLAGS+=-marm -ffreestanding
> +hello-arm: LDFLAGS+=-nostdlib
What about enforcing ARM mode for the swi call by the _syscallX()
functions with:
-- >8 --
#define _syscall0(type,name) \
+__attribute__((target("arm"))) \
type name(void) { \
long __res; \
__asm__ __volatile__ (\
--
(and so for _syscall[1..5])
So main() Thumb mode can also be tested.
tested with the following tests/tcg/arm/Makefile.include:
-- >8 --
DOCKER_IMAGE=debian-armel-cross
DOCKER_CROSS_COMPILER=arm-linux-gnueabi-gcc
--
Reviewed-by: Philippe Mathieu-Daudé <address@hidden>
Tested-by: Philippe Mathieu-Daudé <address@hidden>
- Re: [Qemu-devel] [PATCH v1 10/24] tests/tcg/multiarch: Build fix for linux-test, (continued)
[Qemu-devel] [PATCH v1 14/24] tests/tcg/i386: fix test-i386, Alex Bennée, 2018/04/10
[Qemu-devel] [PATCH v1 15/24] tests/tcg/i368: fix hello-i386, Alex Bennée, 2018/04/10
[Qemu-devel] [PATCH v1 18/24] tests/tcg/arm: fix hello-arm, Alex Bennée, 2018/04/10
[Qemu-devel] [PATCH v1 24/24] tests/Makefile.include: add (clean-)check-tcg targets, Alex Bennée, 2018/04/10
[Qemu-devel] [PATCH v1 23/24] Makefile.target: add (clean-)guest-tests targets, Alex Bennée, 2018/04/10
- Re: [Qemu-devel] [PATCH v1 23/24] Makefile.target: add (clean-)guest-tests targets, Philippe Mathieu-Daudé, 2018/04/15
- Re: [Qemu-devel] [PATCH v1 23/24] Makefile.target: add (clean-)guest-tests targets, Philippe Mathieu-Daudé, 2018/04/15
- Re: [Qemu-devel] [PATCH v1 23/24] Makefile.target: add (clean-)guest-tests targets, Alex Bennée, 2018/04/16
- Re: [Qemu-devel] [PATCH v1 23/24] Makefile.target: add (clean-)guest-tests targets, Philippe Mathieu-Daudé, 2018/04/16
- Re: [Qemu-devel] [PATCH v1 23/24] Makefile.target: add (clean-)guest-tests targets, Philippe Mathieu-Daudé, 2018/04/16
- Re: [Qemu-devel] [PATCH v1 23/24] Makefile.target: add (clean-)guest-tests targets, Alex Bennée, 2018/04/16
- Re: [Qemu-devel] [PATCH v1 23/24] Makefile.target: add (clean-)guest-tests targets, Philippe Mathieu-Daudé, 2018/04/17