qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 00/10] accel: Allow targets to use Kconfig, disable semihosting by default
@ 2020-05-15 17:07 Philippe Mathieu-Daudé
  2020-05-15 17:07 ` [PATCH v2 01/10] MAINTAINERS: Fix KVM path expansion glob Philippe Mathieu-Daudé
                   ` (11 more replies)
  0 siblings, 12 replies; 23+ messages in thread
From: Philippe Mathieu-Daudé @ 2020-05-15 17:07 UTC (permalink / raw)
  To: qemu-devel
  Cc: Marek Vasut, Peter Maydell, Thomas Huth, qemu-riscv,
	Sagar Karandikar, Bastian Koppelmann, Chris Wulff,
	Laurent Vivier, Philippe Mathieu-Daudé,
	Max Filippov, Aleksandar Markovic, qemu-arm, Palmer Dabbelt,
	Michael Walle, Paolo Bonzini, Alistair Francis,
	Aleksandar Rikalo, Alex Bennée, Aurelien Jarno,
	Richard Henderson

This series include generic patches I took of the KVM/ARM
specific series which will follow.

- List orphan accelerators in MAINTAINERS
- Add accel/Kconfig
- Allow targets to use their how Kconfig
- Enforce semihosting on architecture where required,
  disable it elsewhere

Since v1:
https://www.mail-archive.com/qemu-devel@nongnu.org/msg689024.html
- Drop HVF MAINTAINERS patch (merged elsewhere)
- Kconfig-select SEMIHOSTING (bonzini)
- Drop user-mode selection patches
- consider m68k/nios2/xtensa/riscv (pm215)
- reword Kconfig SEMIHOSTING description (pm215)
- reset some of rth R-b tags

Previous RFC for semihosting posted earlier:
https://www.mail-archive.com/qemu-devel@nongnu.org/msg631218.html

$ git backport-diff -u v1 -r v2
Key:
[----] : patches are identical
[####] : number of functional differences between upstream/downstream patch
[down] : patch is downstream-only
The flags [FC] indicate (F)unctional and (C)ontextual differences, respectively

001/10:[----] [--] 'MAINTAINERS: Fix KVM path expansion glob'
002/10:[----] [-C] 'MAINTAINERS: Add an 'overall' entry for accelerators'
003/10:[----] [-C] 'MAINTAINERS: Add an entry for the HAX accelerator'
004/10:[down] 'accel/tcg: Add stub for probe_access()'
005/10:[down] 'Makefile: Remove dangerous EOL trailing backslash'
006/10:[0003] [FC] 'Makefile: Write MINIKCONF variables as one entry per line'
007/10:[----] [--] 'accel/Kconfig: Extract accel selectors into their own config'
008/10:[----] [--] 'accel/Kconfig: Add the TCG selector'
009/10:[down] 'Makefile: Allow target-specific optional Kconfig'
010/10:[0028] [FC] 'hw/semihosting: Make the feature depend of TCG, and allow to disable it'

Philippe Mathieu-Daudé (10):
  MAINTAINERS: Fix KVM path expansion glob
  MAINTAINERS: Add an 'overall' entry for accelerators
  MAINTAINERS: Add an entry for the HAX accelerator
  accel/tcg: Add stub for probe_access()
  Makefile: Remove dangerous EOL trailing backslash
  Makefile: Write MINIKCONF variables as one entry per line
  accel/Kconfig: Extract accel selectors into their own config
  accel/Kconfig: Add the TCG selector
  Makefile: Allow target-specific optional Kconfig
  hw/semihosting: Make the feature depend of TCG, and allow to disable
    it

 Makefile                                | 15 +++++++++++----
 default-configs/arm-softmmu.mak         |  1 -
 default-configs/lm32-softmmu.mak        |  2 --
 default-configs/m68k-softmmu.mak        |  2 --
 default-configs/mips-softmmu-common.mak |  3 ---
 default-configs/nios2-softmmu.mak       |  2 --
 default-configs/xtensa-softmmu.mak      |  2 --
 accel/stubs/tcg-stub.c                  |  7 +++++++
 Kconfig.host                            |  7 -------
 MAINTAINERS                             | 17 ++++++++++++++++-
 accel/Kconfig                           |  9 +++++++++
 hw/semihosting/Kconfig                  |  4 +++-
 target/arm/Kconfig                      |  2 ++
 target/lm32/Kconfig                     |  2 ++
 target/m68k/Kconfig                     |  2 ++
 target/mips/Kconfig                     |  2 ++
 target/nios2/Kconfig                    |  2 ++
 target/riscv/Kconfig                    |  2 ++
 target/xtensa/Kconfig                   |  2 ++
 19 files changed, 60 insertions(+), 25 deletions(-)
 create mode 100644 accel/Kconfig
 create mode 100644 target/arm/Kconfig
 create mode 100644 target/lm32/Kconfig
 create mode 100644 target/m68k/Kconfig
 create mode 100644 target/mips/Kconfig
 create mode 100644 target/nios2/Kconfig
 create mode 100644 target/riscv/Kconfig
 create mode 100644 target/xtensa/Kconfig

-- 
2.21.3



^ permalink raw reply	[flat|nested] 23+ messages in thread

* [PATCH v2 01/10] MAINTAINERS: Fix KVM path expansion glob
  2020-05-15 17:07 [PATCH v2 00/10] accel: Allow targets to use Kconfig, disable semihosting by default Philippe Mathieu-Daudé
@ 2020-05-15 17:07 ` Philippe Mathieu-Daudé
  2020-05-17 17:23   ` Thomas Huth
  2020-05-15 17:07 ` [PATCH v2 02/10] MAINTAINERS: Add an 'overall' entry for accelerators Philippe Mathieu-Daudé
                   ` (10 subsequent siblings)
  11 siblings, 1 reply; 23+ messages in thread
From: Philippe Mathieu-Daudé @ 2020-05-15 17:07 UTC (permalink / raw)
  To: qemu-devel
  Cc: Marek Vasut, Peter Maydell, Thomas Huth, qemu-riscv,
	Sagar Karandikar, Bastian Koppelmann, Chris Wulff,
	Richard Henderson, Laurent Vivier, Philippe Mathieu-Daudé,
	Max Filippov, Aleksandar Markovic, qemu-arm, Palmer Dabbelt,
	Michael Walle, Paolo Bonzini, Alistair Francis,
	Aleksandar Rikalo, Alex Bennée, Aurelien Jarno,
	Richard Henderson

The KVM files has been moved from target-ARCH to the target/ARCH/
folder in commit fcf5ef2a. Fix the pathname expansion.

Fixes: fcf5ef2a ("Move target-* CPU file into a target/ folder")
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
---
 MAINTAINERS | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/MAINTAINERS b/MAINTAINERS
index 47ef3139e6..fd88a3de49 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -361,7 +361,7 @@ Overall KVM CPUs
 M: Paolo Bonzini <pbonzini@redhat.com>
 L: kvm@vger.kernel.org
 S: Supported
-F: */kvm.*
+F: */*/kvm*
 F: accel/kvm/
 F: accel/stubs/kvm-stub.c
 F: include/hw/kvm/
-- 
2.21.3



^ permalink raw reply related	[flat|nested] 23+ messages in thread

* [PATCH v2 02/10] MAINTAINERS: Add an 'overall' entry for accelerators
  2020-05-15 17:07 [PATCH v2 00/10] accel: Allow targets to use Kconfig, disable semihosting by default Philippe Mathieu-Daudé
  2020-05-15 17:07 ` [PATCH v2 01/10] MAINTAINERS: Fix KVM path expansion glob Philippe Mathieu-Daudé
@ 2020-05-15 17:07 ` Philippe Mathieu-Daudé
  2020-05-17 17:26   ` Thomas Huth
  2020-05-15 17:07 ` [PATCH v2 03/10] MAINTAINERS: Add an entry for the HAX accelerator Philippe Mathieu-Daudé
                   ` (9 subsequent siblings)
  11 siblings, 1 reply; 23+ messages in thread
From: Philippe Mathieu-Daudé @ 2020-05-15 17:07 UTC (permalink / raw)
  To: qemu-devel
  Cc: Marek Vasut, Peter Maydell, Thomas Huth, qemu-riscv,
	Sagar Karandikar, Bastian Koppelmann, Chris Wulff,
	Richard Henderson, Laurent Vivier, Philippe Mathieu-Daudé,
	Max Filippov, Aleksandar Markovic, qemu-arm, Palmer Dabbelt,
	Michael Walle, Paolo Bonzini, Alistair Francis,
	Aleksandar Rikalo, Alex Bennée, Aurelien Jarno,
	Richard Henderson

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
---
Cc: Paolo Bonzini <pbonzini@redhat.com>
---
 MAINTAINERS | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/MAINTAINERS b/MAINTAINERS
index fd88a3de49..659092eb43 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -415,6 +415,15 @@ S: Supported
 F: target/i386/kvm.c
 F: scripts/kvm/vmxcap
 
+Guest CPU Cores (other accelerators)
+------------------------------------
+Overall
+M: Richard Henderson <rth@twiddle.net>
+R: Paolo Bonzini <pbonzini@redhat.com>
+S: Maintained
+F: include/sysemu/accel.h
+F: accel/stubs/Makefile.objs
+
 X86 HVF CPUs
 M: Roman Bolshakov <r.bolshakov@yadro.com>
 S: Maintained
-- 
2.21.3



^ permalink raw reply related	[flat|nested] 23+ messages in thread

* [PATCH v2 03/10] MAINTAINERS: Add an entry for the HAX accelerator
  2020-05-15 17:07 [PATCH v2 00/10] accel: Allow targets to use Kconfig, disable semihosting by default Philippe Mathieu-Daudé
  2020-05-15 17:07 ` [PATCH v2 01/10] MAINTAINERS: Fix KVM path expansion glob Philippe Mathieu-Daudé
  2020-05-15 17:07 ` [PATCH v2 02/10] MAINTAINERS: Add an 'overall' entry for accelerators Philippe Mathieu-Daudé
@ 2020-05-15 17:07 ` Philippe Mathieu-Daudé
  2020-05-15 17:07 ` [PATCH v2 04/10] accel/tcg: Add stub for probe_access() Philippe Mathieu-Daudé
                   ` (8 subsequent siblings)
  11 siblings, 0 replies; 23+ messages in thread
From: Philippe Mathieu-Daudé @ 2020-05-15 17:07 UTC (permalink / raw)
  To: qemu-devel
  Cc: Peter Maydell, Sagar Karandikar, Max Filippov, Alistair Francis,
	Colin Xu, Yu Ning, Tao Wu, Marek Vasut, Vincent Palatin,
	David Chou, Aleksandar Markovic, Aleksandar Rikalo,
	Philippe Mathieu-Daudé,
	Thomas Huth, haxm-team, Hang Yuan, qemu-arm, Alex Bennée,
	Richard Henderson, qemu-riscv, Bastian Koppelmann, Chris Wulff,
	Laurent Vivier, Sergio Andres Gomez Del Real, Michael Walle,
	Palmer Dabbelt, Wenchao Wang, Paolo Bonzini, Aurelien Jarno

Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
---
Cc: Sergio Andres Gomez Del Real <sergio.g.delreal@gmail.com>
Cc: Vincent Palatin <vpalatin@chromium.org>
Cc: Yu Ning <yu.ning@intel.com>
Cc: Tao Wu <lepton@google.com>
Cc: haxm-team@intel.com
Cc: Colin Xu <colin.xu@intel.com>
Cc: Hang Yuan <hang.yuan@intel.com>
Cc: David Chou <david.j.chou@intel.com>
Cc: Wenchao Wang <wenchao.wang@intel.com>
---
 MAINTAINERS | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/MAINTAINERS b/MAINTAINERS
index 659092eb43..5172e9a734 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -424,6 +424,12 @@ S: Maintained
 F: include/sysemu/accel.h
 F: accel/stubs/Makefile.objs
 
+HAX Accelerator
+S: Orphan
+F: accel/stubs/hax-stub.c
+F: target/i386/hax-all.c
+F: include/sysemu/hax.h
+
 X86 HVF CPUs
 M: Roman Bolshakov <r.bolshakov@yadro.com>
 S: Maintained
-- 
2.21.3



^ permalink raw reply related	[flat|nested] 23+ messages in thread

* [PATCH v2 04/10] accel/tcg: Add stub for probe_access()
  2020-05-15 17:07 [PATCH v2 00/10] accel: Allow targets to use Kconfig, disable semihosting by default Philippe Mathieu-Daudé
                   ` (2 preceding siblings ...)
  2020-05-15 17:07 ` [PATCH v2 03/10] MAINTAINERS: Add an entry for the HAX accelerator Philippe Mathieu-Daudé
@ 2020-05-15 17:07 ` Philippe Mathieu-Daudé
  2020-05-19 21:41   ` Richard Henderson
  2020-05-15 17:07 ` [PATCH v2 05/10] Makefile: Remove dangerous EOL trailing backslash Philippe Mathieu-Daudé
                   ` (7 subsequent siblings)
  11 siblings, 1 reply; 23+ messages in thread
From: Philippe Mathieu-Daudé @ 2020-05-15 17:07 UTC (permalink / raw)
  To: qemu-devel
  Cc: Peter Maydell, Sagar Karandikar, David Hildenbrand,
	Philippe Mathieu-Daudé,
	Max Filippov, Alistair Francis, Marek Vasut, Aleksandar Markovic,
	Emilio G . Cota, Aleksandar Rikalo, Thomas Huth, qemu-arm,
	Alex Bennée, Richard Henderson, qemu-riscv,
	Bastian Koppelmann, Chris Wulff, Laurent Vivier, Michael Walle,
	Palmer Dabbelt, Paolo Bonzini, Aurelien Jarno

From: Philippe Mathieu-Daudé <f4bug@amsat.org>

The TCG helpers where added in b92e5a22ec3 in softmmu_template.h.
probe_write() was added in there in 3b4afc9e75a to be moved out
to accel/tcg/cputlb.c in 3b08f0a9254, and was later refactored
as probe_access() in c25c283df0f.
Since it is a TCG specific helper, add a stub to avoid failures
when building without TCG, such:

  target/arm/helper.o: In function `probe_read':
  include/exec/exec-all.h:362: undefined reference to `probe_access'

Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
---
Cc: Richard Henderson <rth@twiddle.net>
Cc: Emilio G. Cota <cota@braap.org>
Cc: Alex Bennée <alex.bennee@linaro.org>
Cc: David Hildenbrand <david@redhat.com>
---
 accel/stubs/tcg-stub.c | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/accel/stubs/tcg-stub.c b/accel/stubs/tcg-stub.c
index 677191a69c..e4bbf997aa 100644
--- a/accel/stubs/tcg-stub.c
+++ b/accel/stubs/tcg-stub.c
@@ -22,3 +22,10 @@ void tb_flush(CPUState *cpu)
 void tlb_set_dirty(CPUState *cpu, target_ulong vaddr)
 {
 }
+
+void *probe_access(CPUArchState *env, target_ulong addr, int size,
+                   MMUAccessType access_type, int mmu_idx, uintptr_t retaddr)
+{
+     /* Handled by hardware accelerator. */
+     g_assert_not_reached();
+}
-- 
2.21.3



^ permalink raw reply related	[flat|nested] 23+ messages in thread

* [PATCH v2 05/10] Makefile: Remove dangerous EOL trailing backslash
  2020-05-15 17:07 [PATCH v2 00/10] accel: Allow targets to use Kconfig, disable semihosting by default Philippe Mathieu-Daudé
                   ` (3 preceding siblings ...)
  2020-05-15 17:07 ` [PATCH v2 04/10] accel/tcg: Add stub for probe_access() Philippe Mathieu-Daudé
@ 2020-05-15 17:07 ` Philippe Mathieu-Daudé
  2020-05-17 18:00   ` Thomas Huth
  2020-05-18 16:46   ` Alistair Francis
  2020-05-15 17:08 ` [PATCH v2 06/10] Makefile: Write MINIKCONF variables as one entry per line Philippe Mathieu-Daudé
                   ` (6 subsequent siblings)
  11 siblings, 2 replies; 23+ messages in thread
From: Philippe Mathieu-Daudé @ 2020-05-15 17:07 UTC (permalink / raw)
  To: qemu-devel
  Cc: Marek Vasut, Peter Maydell, Thomas Huth, qemu-riscv,
	Sagar Karandikar, Bastian Koppelmann, Chris Wulff,
	Laurent Vivier, Philippe Mathieu-Daudé,
	Max Filippov, Aleksandar Markovic, qemu-arm, Palmer Dabbelt,
	Michael Walle, Paolo Bonzini, Alistair Francis,
	Aleksandar Rikalo, Alex Bennée, Aurelien Jarno,
	Richard Henderson

One might get caught trying to understand unexpected Makefile
behavior. Trailing backslash can help to split very long lines,
but are rather dangerous when nothing follow. Preserve other
developers debugging time by removing this one.

Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
---
 Makefile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Makefile b/Makefile
index 34275f57c9..84453789f9 100644
--- a/Makefile
+++ b/Makefile
@@ -420,7 +420,7 @@ MINIKCONF_ARGS = \
 
 MINIKCONF_INPUTS = $(SRC_PATH)/Kconfig.host $(SRC_PATH)/hw/Kconfig
 MINIKCONF_DEPS = $(MINIKCONF_INPUTS) $(wildcard $(SRC_PATH)/hw/*/Kconfig)
-MINIKCONF = $(PYTHON) $(SRC_PATH)/scripts/minikconf.py \
+MINIKCONF = $(PYTHON) $(SRC_PATH)/scripts/minikconf.py
 
 $(SUBDIR_DEVICES_MAK): %/config-devices.mak: default-configs/%.mak $(MINIKCONF_DEPS) $(BUILD_DIR)/config-host.mak
 	$(call quiet-command, $(MINIKCONF) $(MINIKCONF_ARGS) > $@.tmp, "GEN", "$@.tmp")
-- 
2.21.3



^ permalink raw reply related	[flat|nested] 23+ messages in thread

* [PATCH v2 06/10] Makefile: Write MINIKCONF variables as one entry per line
  2020-05-15 17:07 [PATCH v2 00/10] accel: Allow targets to use Kconfig, disable semihosting by default Philippe Mathieu-Daudé
                   ` (4 preceding siblings ...)
  2020-05-15 17:07 ` [PATCH v2 05/10] Makefile: Remove dangerous EOL trailing backslash Philippe Mathieu-Daudé
@ 2020-05-15 17:08 ` Philippe Mathieu-Daudé
  2020-05-15 17:08 ` [PATCH v2 07/10] accel/Kconfig: Extract accel selectors into their own config Philippe Mathieu-Daudé
                   ` (5 subsequent siblings)
  11 siblings, 0 replies; 23+ messages in thread
From: Philippe Mathieu-Daudé @ 2020-05-15 17:08 UTC (permalink / raw)
  To: qemu-devel
  Cc: Marek Vasut, Peter Maydell, Thomas Huth, qemu-riscv,
	Sagar Karandikar, Bastian Koppelmann, Chris Wulff,
	Richard Henderson, Laurent Vivier, Philippe Mathieu-Daudé,
	Max Filippov, Aleksandar Markovic, qemu-arm, Palmer Dabbelt,
	Michael Walle, Paolo Bonzini, Alistair Francis,
	Aleksandar Rikalo, Alex Bennée, Aurelien Jarno,
	Richard Henderson

Having one entry per line helps reviews/refactors. As we are
going to modify the MINIKCONF variables, split them now to
ease further review.

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
---
 Makefile | 9 ++++++---
 1 file changed, 6 insertions(+), 3 deletions(-)

diff --git a/Makefile b/Makefile
index 84453789f9..665900d5c8 100644
--- a/Makefile
+++ b/Makefile
@@ -418,12 +418,15 @@ MINIKCONF_ARGS = \
     CONFIG_LINUX=$(CONFIG_LINUX) \
     CONFIG_PVRDMA=$(CONFIG_PVRDMA)
 
-MINIKCONF_INPUTS = $(SRC_PATH)/Kconfig.host $(SRC_PATH)/hw/Kconfig
-MINIKCONF_DEPS = $(MINIKCONF_INPUTS) $(wildcard $(SRC_PATH)/hw/*/Kconfig)
+MINIKCONF_INPUTS = $(SRC_PATH)/Kconfig.host \
+                   $(SRC_PATH)/hw/Kconfig
+MINIKCONF_DEPS = $(MINIKCONF_INPUTS) \
+                 $(wildcard $(SRC_PATH)/hw/*/Kconfig)
 MINIKCONF = $(PYTHON) $(SRC_PATH)/scripts/minikconf.py
 
 $(SUBDIR_DEVICES_MAK): %/config-devices.mak: default-configs/%.mak $(MINIKCONF_DEPS) $(BUILD_DIR)/config-host.mak
-	$(call quiet-command, $(MINIKCONF) $(MINIKCONF_ARGS) > $@.tmp, "GEN", "$@.tmp")
+	$(call quiet-command, $(MINIKCONF) $(MINIKCONF_ARGS) \
+		> $@.tmp, "GEN", "$@.tmp")
 	$(call quiet-command, if test -f $@; then \
 	  if cmp -s $@.old $@; then \
 	    mv $@.tmp $@; \
-- 
2.21.3



^ permalink raw reply related	[flat|nested] 23+ messages in thread

* [PATCH v2 07/10] accel/Kconfig: Extract accel selectors into their own config
  2020-05-15 17:07 [PATCH v2 00/10] accel: Allow targets to use Kconfig, disable semihosting by default Philippe Mathieu-Daudé
                   ` (5 preceding siblings ...)
  2020-05-15 17:08 ` [PATCH v2 06/10] Makefile: Write MINIKCONF variables as one entry per line Philippe Mathieu-Daudé
@ 2020-05-15 17:08 ` Philippe Mathieu-Daudé
  2020-05-15 17:08 ` [PATCH v2 08/10] accel/Kconfig: Add the TCG selector Philippe Mathieu-Daudé
                   ` (4 subsequent siblings)
  11 siblings, 0 replies; 23+ messages in thread
From: Philippe Mathieu-Daudé @ 2020-05-15 17:08 UTC (permalink / raw)
  To: qemu-devel
  Cc: Marek Vasut, Peter Maydell, Thomas Huth, qemu-riscv,
	Sagar Karandikar, Bastian Koppelmann, Chris Wulff,
	Richard Henderson, Laurent Vivier, Philippe Mathieu-Daudé,
	Max Filippov, Aleksandar Markovic, qemu-arm, Palmer Dabbelt,
	Michael Walle, Paolo Bonzini, Alistair Francis,
	Aleksandar Rikalo, Alex Bennée, Aurelien Jarno,
	Richard Henderson

Move the accel selectors from the global Kconfig.host to their
own Kconfig file.

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
---
 Makefile      | 1 +
 Kconfig.host  | 7 -------
 accel/Kconfig | 6 ++++++
 3 files changed, 7 insertions(+), 7 deletions(-)
 create mode 100644 accel/Kconfig

diff --git a/Makefile b/Makefile
index 665900d5c8..06826273c1 100644
--- a/Makefile
+++ b/Makefile
@@ -419,6 +419,7 @@ MINIKCONF_ARGS = \
     CONFIG_PVRDMA=$(CONFIG_PVRDMA)
 
 MINIKCONF_INPUTS = $(SRC_PATH)/Kconfig.host \
+                   $(SRC_PATH)/accel/Kconfig \
                    $(SRC_PATH)/hw/Kconfig
 MINIKCONF_DEPS = $(MINIKCONF_INPUTS) \
                  $(wildcard $(SRC_PATH)/hw/*/Kconfig)
diff --git a/Kconfig.host b/Kconfig.host
index 55136e037d..a6d871c399 100644
--- a/Kconfig.host
+++ b/Kconfig.host
@@ -2,9 +2,6 @@
 # down to Kconfig.  See also MINIKCONF_ARGS in the Makefile:
 # these two need to be kept in sync.
 
-config KVM
-    bool
-
 config LINUX
     bool
 
@@ -31,10 +28,6 @@ config VHOST_KERNEL
     bool
     select VHOST
 
-config XEN
-    bool
-    select FSDEV_9P if VIRTFS
-
 config VIRTFS
     bool
 
diff --git a/accel/Kconfig b/accel/Kconfig
new file mode 100644
index 0000000000..c21802bb49
--- /dev/null
+++ b/accel/Kconfig
@@ -0,0 +1,6 @@
+config KVM
+    bool
+
+config XEN
+    bool
+    select FSDEV_9P if VIRTFS
-- 
2.21.3



^ permalink raw reply related	[flat|nested] 23+ messages in thread

* [PATCH v2 08/10] accel/Kconfig: Add the TCG selector
  2020-05-15 17:07 [PATCH v2 00/10] accel: Allow targets to use Kconfig, disable semihosting by default Philippe Mathieu-Daudé
                   ` (6 preceding siblings ...)
  2020-05-15 17:08 ` [PATCH v2 07/10] accel/Kconfig: Extract accel selectors into their own config Philippe Mathieu-Daudé
@ 2020-05-15 17:08 ` Philippe Mathieu-Daudé
  2020-05-15 17:08 ` [PATCH v2 09/10] Makefile: Allow target-specific optional Kconfig Philippe Mathieu-Daudé
                   ` (3 subsequent siblings)
  11 siblings, 0 replies; 23+ messages in thread
From: Philippe Mathieu-Daudé @ 2020-05-15 17:08 UTC (permalink / raw)
  To: qemu-devel
  Cc: Marek Vasut, Peter Maydell, Thomas Huth, qemu-riscv,
	Sagar Karandikar, Bastian Koppelmann, Chris Wulff,
	Richard Henderson, Laurent Vivier, Philippe Mathieu-Daudé,
	Max Filippov, Aleksandar Markovic, qemu-arm, Palmer Dabbelt,
	Michael Walle, Paolo Bonzini, Alistair Francis,
	Aleksandar Rikalo, Alex Bennée, Aurelien Jarno,
	Richard Henderson

Expose the CONFIG_TCG selector to let minikconf.py uses it.

When building with --disable-tcg build, this helps to deselect
devices that are TCG-dependent.

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
---
 Makefile      | 1 +
 accel/Kconfig | 3 +++
 2 files changed, 4 insertions(+)

diff --git a/Makefile b/Makefile
index 06826273c1..b4c0830b26 100644
--- a/Makefile
+++ b/Makefile
@@ -405,6 +405,7 @@ endif
 MINIKCONF_ARGS = \
     $(CONFIG_MINIKCONF_MODE) \
     $@ $*/config-devices.mak.d $< $(MINIKCONF_INPUTS) \
+    CONFIG_TCG=$(CONFIG_TCG) \
     CONFIG_KVM=$(CONFIG_KVM) \
     CONFIG_SPICE=$(CONFIG_SPICE) \
     CONFIG_IVSHMEM=$(CONFIG_IVSHMEM) \
diff --git a/accel/Kconfig b/accel/Kconfig
index c21802bb49..2ad94a3839 100644
--- a/accel/Kconfig
+++ b/accel/Kconfig
@@ -1,3 +1,6 @@
+config TCG
+    bool
+
 config KVM
     bool
 
-- 
2.21.3



^ permalink raw reply related	[flat|nested] 23+ messages in thread

* [PATCH v2 09/10] Makefile: Allow target-specific optional Kconfig
  2020-05-15 17:07 [PATCH v2 00/10] accel: Allow targets to use Kconfig, disable semihosting by default Philippe Mathieu-Daudé
                   ` (7 preceding siblings ...)
  2020-05-15 17:08 ` [PATCH v2 08/10] accel/Kconfig: Add the TCG selector Philippe Mathieu-Daudé
@ 2020-05-15 17:08 ` Philippe Mathieu-Daudé
  2020-05-19 21:42   ` Richard Henderson
  2020-05-21 17:33   ` Philippe Mathieu-Daudé
  2020-05-15 17:08 ` [PATCH v2 10/10] hw/semihosting: Make the feature depend of TCG, and allow to disable it Philippe Mathieu-Daudé
                   ` (2 subsequent siblings)
  11 siblings, 2 replies; 23+ messages in thread
From: Philippe Mathieu-Daudé @ 2020-05-15 17:08 UTC (permalink / raw)
  To: qemu-devel
  Cc: Marek Vasut, Peter Maydell, Thomas Huth, qemu-riscv,
	Sagar Karandikar, Bastian Koppelmann, Chris Wulff,
	Laurent Vivier, Philippe Mathieu-Daudé,
	Max Filippov, Aleksandar Markovic, qemu-arm, Palmer Dabbelt,
	Michael Walle, Paolo Bonzini, Alistair Francis,
	Aleksandar Rikalo, Alex Bennée, Aurelien Jarno,
	Richard Henderson

Allow use of target-specific Kconfig file.

Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
---
 Makefile | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/Makefile b/Makefile
index b4c0830b26..5fce168fcb 100644
--- a/Makefile
+++ b/Makefile
@@ -423,11 +423,13 @@ MINIKCONF_INPUTS = $(SRC_PATH)/Kconfig.host \
                    $(SRC_PATH)/accel/Kconfig \
                    $(SRC_PATH)/hw/Kconfig
 MINIKCONF_DEPS = $(MINIKCONF_INPUTS) \
-                 $(wildcard $(SRC_PATH)/hw/*/Kconfig)
+                 $(wildcard $(SRC_PATH)/hw/*/Kconfig) \
+                 $(wildcard $(SRC_PATH)/target/*/Kconfig)
 MINIKCONF = $(PYTHON) $(SRC_PATH)/scripts/minikconf.py
 
 $(SUBDIR_DEVICES_MAK): %/config-devices.mak: default-configs/%.mak $(MINIKCONF_DEPS) $(BUILD_DIR)/config-host.mak
 	$(call quiet-command, $(MINIKCONF) $(MINIKCONF_ARGS) \
+		$(wildcard $(SRC_PATH)/target/$(firstword $(subst -, ,$@))/Kconfig) \
 		> $@.tmp, "GEN", "$@.tmp")
 	$(call quiet-command, if test -f $@; then \
 	  if cmp -s $@.old $@; then \
-- 
2.21.3



^ permalink raw reply related	[flat|nested] 23+ messages in thread

* [PATCH v2 10/10] hw/semihosting: Make the feature depend of TCG, and allow to disable it
  2020-05-15 17:07 [PATCH v2 00/10] accel: Allow targets to use Kconfig, disable semihosting by default Philippe Mathieu-Daudé
                   ` (8 preceding siblings ...)
  2020-05-15 17:08 ` [PATCH v2 09/10] Makefile: Allow target-specific optional Kconfig Philippe Mathieu-Daudé
@ 2020-05-15 17:08 ` Philippe Mathieu-Daudé
  2020-05-19 21:44   ` Richard Henderson
  2020-05-16  3:44 ` [PATCH v2 00/10] accel: Allow targets to use Kconfig, disable semihosting by default no-reply
  2020-05-16  3:57 ` no-reply
  11 siblings, 1 reply; 23+ messages in thread
From: Philippe Mathieu-Daudé @ 2020-05-15 17:08 UTC (permalink / raw)
  To: qemu-devel
  Cc: Marek Vasut, Peter Maydell, Thomas Huth, qemu-riscv,
	Sagar Karandikar, Bastian Koppelmann, Chris Wulff,
	Laurent Vivier, Philippe Mathieu-Daudé,
	Max Filippov, Aleksandar Markovic, qemu-arm, Palmer Dabbelt,
	Michael Walle, Paolo Bonzini, Alistair Francis,
	Aleksandar Rikalo, Alex Bennée, Aurelien Jarno,
	Richard Henderson

The semihosting feature is only meaningful when using TCG.

Do not enable it by default, and let the few targets requiring
it to manually select it.
The targets restricted to TCG that previously selected it
(see commit 16932bb761e52c2 'introduce CONFIG_SEMIHOSTING')
are left unmodified; however the selection is moved to the
target Kconfig.

Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
---
 default-configs/arm-softmmu.mak         | 1 -
 default-configs/lm32-softmmu.mak        | 2 --
 default-configs/m68k-softmmu.mak        | 2 --
 default-configs/mips-softmmu-common.mak | 3 ---
 default-configs/nios2-softmmu.mak       | 2 --
 default-configs/xtensa-softmmu.mak      | 2 --
 hw/semihosting/Kconfig                  | 4 +++-
 target/arm/Kconfig                      | 2 ++
 target/lm32/Kconfig                     | 2 ++
 target/m68k/Kconfig                     | 2 ++
 target/mips/Kconfig                     | 2 ++
 target/nios2/Kconfig                    | 2 ++
 target/riscv/Kconfig                    | 2 ++
 target/xtensa/Kconfig                   | 2 ++
 14 files changed, 17 insertions(+), 13 deletions(-)
 create mode 100644 target/arm/Kconfig
 create mode 100644 target/lm32/Kconfig
 create mode 100644 target/m68k/Kconfig
 create mode 100644 target/mips/Kconfig
 create mode 100644 target/nios2/Kconfig
 create mode 100644 target/riscv/Kconfig
 create mode 100644 target/xtensa/Kconfig

diff --git a/default-configs/arm-softmmu.mak b/default-configs/arm-softmmu.mak
index 8fc09a4a51..f6044f1121 100644
--- a/default-configs/arm-softmmu.mak
+++ b/default-configs/arm-softmmu.mak
@@ -40,6 +40,5 @@ CONFIG_MICROBIT=y
 CONFIG_FSL_IMX25=y
 CONFIG_FSL_IMX7=y
 CONFIG_FSL_IMX6UL=y
-CONFIG_SEMIHOSTING=y
 CONFIG_ALLWINNER_H3=y
 CONFIG_ACPI_APEI=y
diff --git a/default-configs/lm32-softmmu.mak b/default-configs/lm32-softmmu.mak
index 115b3e34c9..6d259665d6 100644
--- a/default-configs/lm32-softmmu.mak
+++ b/default-configs/lm32-softmmu.mak
@@ -4,8 +4,6 @@
 #
 #CONFIG_MILKYMIST_TMU2=n        # disabling it actually causes compile-time failures
 
-CONFIG_SEMIHOSTING=y
-
 # Boards:
 #
 CONFIG_LM32=y
diff --git a/default-configs/m68k-softmmu.mak b/default-configs/m68k-softmmu.mak
index 6629fd2aa3..4fef4bd731 100644
--- a/default-configs/m68k-softmmu.mak
+++ b/default-configs/m68k-softmmu.mak
@@ -1,7 +1,5 @@
 # Default configuration for m68k-softmmu
 
-CONFIG_SEMIHOSTING=y
-
 # Boards:
 #
 CONFIG_AN5206=y
diff --git a/default-configs/mips-softmmu-common.mak b/default-configs/mips-softmmu-common.mak
index da29c6c0b2..6c0904b200 100644
--- a/default-configs/mips-softmmu-common.mak
+++ b/default-configs/mips-softmmu-common.mak
@@ -1,8 +1,5 @@
 # Common mips*-softmmu CONFIG defines
 
-# CONFIG_SEMIHOSTING is always required on this architecture
-CONFIG_SEMIHOSTING=y
-
 CONFIG_ISA_BUS=y
 CONFIG_PCI=y
 CONFIG_PCI_DEVICES=y
diff --git a/default-configs/nios2-softmmu.mak b/default-configs/nios2-softmmu.mak
index 1bc4082ea9..e130d024e6 100644
--- a/default-configs/nios2-softmmu.mak
+++ b/default-configs/nios2-softmmu.mak
@@ -1,7 +1,5 @@
 # Default configuration for nios2-softmmu
 
-CONFIG_SEMIHOSTING=y
-
 # Boards:
 #
 CONFIG_NIOS2_10M50=y
diff --git a/default-configs/xtensa-softmmu.mak b/default-configs/xtensa-softmmu.mak
index 4fe1bf00c9..49e4c9da88 100644
--- a/default-configs/xtensa-softmmu.mak
+++ b/default-configs/xtensa-softmmu.mak
@@ -1,7 +1,5 @@
 # Default configuration for Xtensa
 
-CONFIG_SEMIHOSTING=y
-
 # Boards:
 #
 CONFIG_XTENSA_SIM=y
diff --git a/hw/semihosting/Kconfig b/hw/semihosting/Kconfig
index efe0a30734..30befcdd21 100644
--- a/hw/semihosting/Kconfig
+++ b/hw/semihosting/Kconfig
@@ -1,3 +1,5 @@
 
+# default is 'n'
 config SEMIHOSTING
-       bool
+    bool
+    depends on TCG
diff --git a/target/arm/Kconfig b/target/arm/Kconfig
new file mode 100644
index 0000000000..3224cac4ad
--- /dev/null
+++ b/target/arm/Kconfig
@@ -0,0 +1,2 @@
+config SEMIHOSTING
+    default y if TCG
diff --git a/target/lm32/Kconfig b/target/lm32/Kconfig
new file mode 100644
index 0000000000..c0a9a9e799
--- /dev/null
+++ b/target/lm32/Kconfig
@@ -0,0 +1,2 @@
+config SEMIHOSTING
+    default y
diff --git a/target/m68k/Kconfig b/target/m68k/Kconfig
new file mode 100644
index 0000000000..c0a9a9e799
--- /dev/null
+++ b/target/m68k/Kconfig
@@ -0,0 +1,2 @@
+config SEMIHOSTING
+    default y
diff --git a/target/mips/Kconfig b/target/mips/Kconfig
new file mode 100644
index 0000000000..3224cac4ad
--- /dev/null
+++ b/target/mips/Kconfig
@@ -0,0 +1,2 @@
+config SEMIHOSTING
+    default y if TCG
diff --git a/target/nios2/Kconfig b/target/nios2/Kconfig
new file mode 100644
index 0000000000..c0a9a9e799
--- /dev/null
+++ b/target/nios2/Kconfig
@@ -0,0 +1,2 @@
+config SEMIHOSTING
+    default y
diff --git a/target/riscv/Kconfig b/target/riscv/Kconfig
new file mode 100644
index 0000000000..3224cac4ad
--- /dev/null
+++ b/target/riscv/Kconfig
@@ -0,0 +1,2 @@
+config SEMIHOSTING
+    default y if TCG
diff --git a/target/xtensa/Kconfig b/target/xtensa/Kconfig
new file mode 100644
index 0000000000..c0a9a9e799
--- /dev/null
+++ b/target/xtensa/Kconfig
@@ -0,0 +1,2 @@
+config SEMIHOSTING
+    default y
-- 
2.21.3



^ permalink raw reply related	[flat|nested] 23+ messages in thread

* Re: [PATCH v2 00/10] accel: Allow targets to use Kconfig, disable semihosting by default
  2020-05-15 17:07 [PATCH v2 00/10] accel: Allow targets to use Kconfig, disable semihosting by default Philippe Mathieu-Daudé
                   ` (9 preceding siblings ...)
  2020-05-15 17:08 ` [PATCH v2 10/10] hw/semihosting: Make the feature depend of TCG, and allow to disable it Philippe Mathieu-Daudé
@ 2020-05-16  3:44 ` no-reply
  2020-05-16  3:57 ` no-reply
  11 siblings, 0 replies; 23+ messages in thread
From: no-reply @ 2020-05-16  3:44 UTC (permalink / raw)
  To: philmd
  Cc: marex, peter.maydell, thuth, qemu-riscv, sagark, kbastian,
	crwulff, qemu-devel, laurent, alex.bennee, jcmvbkbc,
	aleksandar.qemu.devel, qemu-arm, palmer, michael, pbonzini,
	Alistair.Francis, philmd, aleksandar.rikalo, aurelien, rth

Patchew URL: https://patchew.org/QEMU/20200515170804.5707-1-philmd@redhat.com/



Hi,

This series failed the docker-quick@centos7 build test. Please find the testing commands and
their output below. If you have Docker installed, you can probably reproduce it
locally.

=== TEST SCRIPT BEGIN ===
#!/bin/bash
make docker-image-centos7 V=1 NETWORK=1
time make docker-test-quick@centos7 SHOW_ENV=1 J=14 NETWORK=1
=== TEST SCRIPT END ===

/tmp/qemu-test/src/target/arm/arm-semi.c:787: undefined reference to `qemu_semihosting_console_outs'
/tmp/qemu-test/src/target/arm/arm-semi.c:815: undefined reference to `qemu_semihosting_console_inc'
/tmp/qemu-test/src/target/arm/arm-semi.c:784: undefined reference to `qemu_semihosting_console_outc'
collect2: error: ld returned 1 exit status
make[1]: *** [qemu-system-aarch64] Error 1
make: *** [aarch64-softmmu/all] Error 2
Traceback (most recent call last):
  File "./tests/docker/docker.py", line 664, in <module>
    sys.exit(main())
---
    raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['sudo', '-n', 'docker', 'run', '--label', 'com.qemu.instance.uuid=490bf18b41e04df58182bdb1996b896b', '-u', '1003', '--security-opt', 'seccomp=unconfined', '--rm', '-e', 'TARGET_LIST=', '-e', 'EXTRA_CONFIGURE_OPTS=', '-e', 'V=', '-e', 'J=14', '-e', 'DEBUG=', '-e', 'SHOW_ENV=1', '-e', 'CCACHE_DIR=/var/tmp/ccache', '-v', '/home/patchew2/.cache/qemu-docker-ccache:/var/tmp/ccache:z', '-v', '/var/tmp/patchew-tester-tmp-k03oe5yh/src/docker-src.2020-05-15-23.41.43.21629:/var/tmp/qemu:z,ro', 'qemu:centos7', '/var/tmp/qemu/run', 'test-quick']' returned non-zero exit status 2.
filter=--filter=label=com.qemu.instance.uuid=490bf18b41e04df58182bdb1996b896b
make[1]: *** [docker-run] Error 1
make[1]: Leaving directory `/var/tmp/patchew-tester-tmp-k03oe5yh/src'
make: *** [docker-run-test-quick@centos7] Error 2

real    2m45.420s
user    0m8.257s


The full log is available at
http://patchew.org/logs/20200515170804.5707-1-philmd@redhat.com/testing.docker-quick@centos7/?type=message.
---
Email generated automatically by Patchew [https://patchew.org/].
Please send your feedback to patchew-devel@redhat.com

^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: [PATCH v2 00/10] accel: Allow targets to use Kconfig, disable semihosting by default
  2020-05-15 17:07 [PATCH v2 00/10] accel: Allow targets to use Kconfig, disable semihosting by default Philippe Mathieu-Daudé
                   ` (10 preceding siblings ...)
  2020-05-16  3:44 ` [PATCH v2 00/10] accel: Allow targets to use Kconfig, disable semihosting by default no-reply
@ 2020-05-16  3:57 ` no-reply
  11 siblings, 0 replies; 23+ messages in thread
From: no-reply @ 2020-05-16  3:57 UTC (permalink / raw)
  To: philmd
  Cc: marex, peter.maydell, thuth, qemu-riscv, sagark, kbastian,
	crwulff, qemu-devel, laurent, alex.bennee, jcmvbkbc,
	aleksandar.qemu.devel, qemu-arm, palmer, michael, pbonzini,
	Alistair.Francis, philmd, aleksandar.rikalo, aurelien, rth

Patchew URL: https://patchew.org/QEMU/20200515170804.5707-1-philmd@redhat.com/



Hi,

This series failed the docker-mingw@fedora build test. Please find the testing commands and
their output below. If you have Docker installed, you can probably reproduce it
locally.

=== TEST SCRIPT BEGIN ===
#! /bin/bash
export ARCH=x86_64
make docker-image-fedora V=1 NETWORK=1
time make docker-test-mingw@fedora J=14 NETWORK=1
=== TEST SCRIPT END ===

/tmp/qemu-test/src/target/arm/arm-semi.c:815: undefined reference to `qemu_semihosting_console_inc'
/tmp/qemu-test/src/target/arm/arm-semi.c:787: undefined reference to `qemu_semihosting_console_outs'
/tmp/qemu-test/src/target/arm/arm-semi.c:784: undefined reference to `qemu_semihosting_console_outc'
collect2: error: ld returned 1 exit status
make[1]: *** [Makefile:208: qemu-system-aarch64w.exe] Error 1
make: *** [Makefile:534: aarch64-softmmu/all] Error 2
make: *** Waiting for unfinished jobs....
Traceback (most recent call last):
  File "./tests/docker/docker.py", line 664, in <module>
---
    raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['sudo', '-n', 'docker', 'run', '--label', 'com.qemu.instance.uuid=e4300b50b74f4cf6a4342bebb0db3e5b', '-u', '1001', '--security-opt', 'seccomp=unconfined', '--rm', '-e', 'TARGET_LIST=', '-e', 'EXTRA_CONFIGURE_OPTS=', '-e', 'V=', '-e', 'J=14', '-e', 'DEBUG=', '-e', 'SHOW_ENV=', '-e', 'CCACHE_DIR=/var/tmp/ccache', '-v', '/home/patchew/.cache/qemu-docker-ccache:/var/tmp/ccache:z', '-v', '/var/tmp/patchew-tester-tmp-d_su7kf_/src/docker-src.2020-05-15-23.55.36.10662:/var/tmp/qemu:z,ro', 'qemu:fedora', '/var/tmp/qemu/run', 'test-mingw']' returned non-zero exit status 2.
filter=--filter=label=com.qemu.instance.uuid=e4300b50b74f4cf6a4342bebb0db3e5b
make[1]: *** [docker-run] Error 1
make[1]: Leaving directory `/var/tmp/patchew-tester-tmp-d_su7kf_/src'
make: *** [docker-run-test-mingw@fedora] Error 2

real    2m20.941s
user    0m8.489s


The full log is available at
http://patchew.org/logs/20200515170804.5707-1-philmd@redhat.com/testing.docker-mingw@fedora/?type=message.
---
Email generated automatically by Patchew [https://patchew.org/].
Please send your feedback to patchew-devel@redhat.com

^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: [PATCH v2 01/10] MAINTAINERS: Fix KVM path expansion glob
  2020-05-15 17:07 ` [PATCH v2 01/10] MAINTAINERS: Fix KVM path expansion glob Philippe Mathieu-Daudé
@ 2020-05-17 17:23   ` Thomas Huth
  0 siblings, 0 replies; 23+ messages in thread
From: Thomas Huth @ 2020-05-17 17:23 UTC (permalink / raw)
  To: Philippe Mathieu-Daudé, qemu-devel
  Cc: Marek Vasut, Peter Maydell, qemu-riscv, Sagar Karandikar,
	Bastian Koppelmann, Chris Wulff, Richard Henderson,
	Laurent Vivier, Max Filippov, Aleksandar Markovic, qemu-arm,
	Palmer Dabbelt, Michael Walle, Paolo Bonzini, Alistair Francis,
	Aleksandar Rikalo, Alex Bennée, Aurelien Jarno,
	Richard Henderson

On 15/05/2020 19.07, Philippe Mathieu-Daudé wrote:
> The KVM files has been moved from target-ARCH to the target/ARCH/
> folder in commit fcf5ef2a. Fix the pathname expansion.
> 
> Fixes: fcf5ef2a ("Move target-* CPU file into a target/ folder")

Oops, my bad. Sorry for that oversight!

> diff --git a/MAINTAINERS b/MAINTAINERS
> index 47ef3139e6..fd88a3de49 100644
> --- a/MAINTAINERS
> +++ b/MAINTAINERS
> @@ -361,7 +361,7 @@ Overall KVM CPUs
>  M: Paolo Bonzini <pbonzini@redhat.com>
>  L: kvm@vger.kernel.org
>  S: Supported
> -F: */kvm.*
> +F: */*/kvm*
>  F: accel/kvm/
>  F: accel/stubs/kvm-stub.c
>  F: include/hw/kvm/
> 

Reviewed-by: Thomas Huth <thuth@redhat.com>



^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: [PATCH v2 02/10] MAINTAINERS: Add an 'overall' entry for accelerators
  2020-05-15 17:07 ` [PATCH v2 02/10] MAINTAINERS: Add an 'overall' entry for accelerators Philippe Mathieu-Daudé
@ 2020-05-17 17:26   ` Thomas Huth
  2020-05-21 15:09     ` Philippe Mathieu-Daudé
  0 siblings, 1 reply; 23+ messages in thread
From: Thomas Huth @ 2020-05-17 17:26 UTC (permalink / raw)
  To: Philippe Mathieu-Daudé, qemu-devel
  Cc: Marek Vasut, Peter Maydell, qemu-riscv, Sagar Karandikar,
	Bastian Koppelmann, Chris Wulff, Richard Henderson,
	Laurent Vivier, Max Filippov, Aleksandar Markovic, qemu-arm,
	Palmer Dabbelt, Michael Walle, Paolo Bonzini, Alistair Francis,
	Aleksandar Rikalo, Alex Bennée, Aurelien Jarno,
	Richard Henderson

On 15/05/2020 19.07, Philippe Mathieu-Daudé wrote:
> Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
> Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
> ---
> Cc: Paolo Bonzini <pbonzini@redhat.com>
> ---
>  MAINTAINERS | 9 +++++++++
>  1 file changed, 9 insertions(+)
> 
> diff --git a/MAINTAINERS b/MAINTAINERS
> index fd88a3de49..659092eb43 100644
> --- a/MAINTAINERS
> +++ b/MAINTAINERS
> @@ -415,6 +415,15 @@ S: Supported
>  F: target/i386/kvm.c
>  F: scripts/kvm/vmxcap
>  
> +Guest CPU Cores (other accelerators)

Maybe s/other accelerators/accelerators generic code/ ?

> +------------------------------------
> +Overall
> +M: Richard Henderson <rth@twiddle.net>
> +R: Paolo Bonzini <pbonzini@redhat.com>
> +S: Maintained
> +F: include/sysemu/accel.h
> +F: accel/stubs/Makefile.objs

What about accel/accel.c and accel/Makefile.objs ? Should they also be
in the list here?

 Thomas



^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: [PATCH v2 05/10] Makefile: Remove dangerous EOL trailing backslash
  2020-05-15 17:07 ` [PATCH v2 05/10] Makefile: Remove dangerous EOL trailing backslash Philippe Mathieu-Daudé
@ 2020-05-17 18:00   ` Thomas Huth
  2020-05-18 16:46   ` Alistair Francis
  1 sibling, 0 replies; 23+ messages in thread
From: Thomas Huth @ 2020-05-17 18:00 UTC (permalink / raw)
  To: Philippe Mathieu-Daudé, qemu-devel
  Cc: Marek Vasut, Peter Maydell, Alistair Francis, qemu-riscv,
	Sagar Karandikar, QEMU Trivial, Bastian Koppelmann, Chris Wulff,
	Laurent Vivier, Max Filippov, Aleksandar Markovic, qemu-arm,
	Palmer Dabbelt, Michael Walle, Paolo Bonzini, Aleksandar Rikalo,
	Alex Bennée, Aurelien Jarno, Richard Henderson

On 15/05/2020 19.07, Philippe Mathieu-Daudé wrote:
> One might get caught trying to understand unexpected Makefile
> behavior. Trailing backslash can help to split very long lines,
> but are rather dangerous when nothing follow. Preserve other
> developers debugging time by removing this one.
> 
> Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
> ---
>  Makefile | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/Makefile b/Makefile
> index 34275f57c9..84453789f9 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -420,7 +420,7 @@ MINIKCONF_ARGS = \
>  
>  MINIKCONF_INPUTS = $(SRC_PATH)/Kconfig.host $(SRC_PATH)/hw/Kconfig
>  MINIKCONF_DEPS = $(MINIKCONF_INPUTS) $(wildcard $(SRC_PATH)/hw/*/Kconfig)
> -MINIKCONF = $(PYTHON) $(SRC_PATH)/scripts/minikconf.py \
> +MINIKCONF = $(PYTHON) $(SRC_PATH)/scripts/minikconf.py
>  
>  $(SUBDIR_DEVICES_MAK): %/config-devices.mak: default-configs/%.mak $(MINIKCONF_DEPS) $(BUILD_DIR)/config-host.mak
>  	$(call quiet-command, $(MINIKCONF) $(MINIKCONF_ARGS) > $@.tmp, "GEN", "$@.tmp")
> 

Reviewed-by: Thomas Huth <thuth@redhat.com>



^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: [PATCH v2 05/10] Makefile: Remove dangerous EOL trailing backslash
  2020-05-15 17:07 ` [PATCH v2 05/10] Makefile: Remove dangerous EOL trailing backslash Philippe Mathieu-Daudé
  2020-05-17 18:00   ` Thomas Huth
@ 2020-05-18 16:46   ` Alistair Francis
  1 sibling, 0 replies; 23+ messages in thread
From: Alistair Francis @ 2020-05-18 16:46 UTC (permalink / raw)
  To: Philippe Mathieu-Daudé
  Cc: Marek Vasut, Peter Maydell, Thomas Huth, open list:RISC-V,
	Sagar Karandikar, Bastian Koppelmann, Chris Wulff,
	qemu-devel@nongnu.org Developers, Laurent Vivier, Max Filippov,
	Aleksandar Markovic, qemu-arm, Palmer Dabbelt, Michael Walle,
	Paolo Bonzini, Alistair Francis, Alex Bennée,
	Aleksandar Rikalo, Aurelien Jarno, Richard Henderson

On Fri, May 15, 2020 at 10:11 AM Philippe Mathieu-Daudé
<philmd@redhat.com> wrote:
>
> One might get caught trying to understand unexpected Makefile
> behavior. Trailing backslash can help to split very long lines,
> but are rather dangerous when nothing follow. Preserve other
> developers debugging time by removing this one.
>
> Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>

Reviewed-by: Alistair Francis <alistair.francis@wdc.com>

Alistair

> ---
>  Makefile | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/Makefile b/Makefile
> index 34275f57c9..84453789f9 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -420,7 +420,7 @@ MINIKCONF_ARGS = \
>
>  MINIKCONF_INPUTS = $(SRC_PATH)/Kconfig.host $(SRC_PATH)/hw/Kconfig
>  MINIKCONF_DEPS = $(MINIKCONF_INPUTS) $(wildcard $(SRC_PATH)/hw/*/Kconfig)
> -MINIKCONF = $(PYTHON) $(SRC_PATH)/scripts/minikconf.py \
> +MINIKCONF = $(PYTHON) $(SRC_PATH)/scripts/minikconf.py
>
>  $(SUBDIR_DEVICES_MAK): %/config-devices.mak: default-configs/%.mak $(MINIKCONF_DEPS) $(BUILD_DIR)/config-host.mak
>         $(call quiet-command, $(MINIKCONF) $(MINIKCONF_ARGS) > $@.tmp, "GEN", "$@.tmp")
> --
> 2.21.3
>
>


^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: [PATCH v2 04/10] accel/tcg: Add stub for probe_access()
  2020-05-15 17:07 ` [PATCH v2 04/10] accel/tcg: Add stub for probe_access() Philippe Mathieu-Daudé
@ 2020-05-19 21:41   ` Richard Henderson
  0 siblings, 0 replies; 23+ messages in thread
From: Richard Henderson @ 2020-05-19 21:41 UTC (permalink / raw)
  To: Philippe Mathieu-Daudé, qemu-devel
  Cc: Peter Maydell, Sagar Karandikar, David Hildenbrand,
	Laurent Vivier, Max Filippov, Alistair Francis, Marek Vasut,
	Aleksandar Markovic, Emilio G . Cota, Aleksandar Rikalo,
	Thomas Huth, qemu-arm, Alex Bennée, Richard Henderson,
	qemu-riscv, Bastian Koppelmann, Chris Wulff,
	Philippe Mathieu-Daudé,
	Michael Walle, Palmer Dabbelt, Paolo Bonzini, Aurelien Jarno

On 5/15/20 10:07 AM, Philippe Mathieu-Daudé wrote:
> From: Philippe Mathieu-Daudé <f4bug@amsat.org>
> 
> The TCG helpers where added in b92e5a22ec3 in softmmu_template.h.
> probe_write() was added in there in 3b4afc9e75a to be moved out
> to accel/tcg/cputlb.c in 3b08f0a9254, and was later refactored
> as probe_access() in c25c283df0f.
> Since it is a TCG specific helper, add a stub to avoid failures
> when building without TCG, such:
> 
>   target/arm/helper.o: In function `probe_read':
>   include/exec/exec-all.h:362: undefined reference to `probe_access'
> 
> Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
> ---
> Cc: Richard Henderson <rth@twiddle.net>
> Cc: Emilio G. Cota <cota@braap.org>
> Cc: Alex Bennée <alex.bennee@linaro.org>
> Cc: David Hildenbrand <david@redhat.com>
> ---
>  accel/stubs/tcg-stub.c | 7 +++++++
>  1 file changed, 7 insertions(+)

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>

r~


^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: [PATCH v2 09/10] Makefile: Allow target-specific optional Kconfig
  2020-05-15 17:08 ` [PATCH v2 09/10] Makefile: Allow target-specific optional Kconfig Philippe Mathieu-Daudé
@ 2020-05-19 21:42   ` Richard Henderson
  2020-05-21 17:33   ` Philippe Mathieu-Daudé
  1 sibling, 0 replies; 23+ messages in thread
From: Richard Henderson @ 2020-05-19 21:42 UTC (permalink / raw)
  To: Philippe Mathieu-Daudé, qemu-devel
  Cc: Marek Vasut, Peter Maydell, Thomas Huth, qemu-riscv,
	Sagar Karandikar, Bastian Koppelmann, Chris Wulff,
	Laurent Vivier, Max Filippov, Aleksandar Markovic, qemu-arm,
	Palmer Dabbelt, Michael Walle, Paolo Bonzini, Alistair Francis,
	Alex Bennée, Aleksandar Rikalo, Aurelien Jarno,
	Richard Henderson

On 5/15/20 10:08 AM, Philippe Mathieu-Daudé wrote:
> Allow use of target-specific Kconfig file.
> 
> Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
> ---
>  Makefile | 4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>

r~



^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: [PATCH v2 10/10] hw/semihosting: Make the feature depend of TCG,  and allow to disable it
  2020-05-15 17:08 ` [PATCH v2 10/10] hw/semihosting: Make the feature depend of TCG, and allow to disable it Philippe Mathieu-Daudé
@ 2020-05-19 21:44   ` Richard Henderson
  2020-05-21 19:55     ` Philippe Mathieu-Daudé
  0 siblings, 1 reply; 23+ messages in thread
From: Richard Henderson @ 2020-05-19 21:44 UTC (permalink / raw)
  To: Philippe Mathieu-Daudé, qemu-devel
  Cc: Marek Vasut, Peter Maydell, Thomas Huth, qemu-riscv,
	Sagar Karandikar, Bastian Koppelmann, Chris Wulff,
	Laurent Vivier, Max Filippov, Aleksandar Markovic, qemu-arm,
	Palmer Dabbelt, Michael Walle, Paolo Bonzini, Alistair Francis,
	Alex Bennée, Aleksandar Rikalo, Aurelien Jarno,
	Richard Henderson

On 5/15/20 10:08 AM, Philippe Mathieu-Daudé wrote:
> +++ b/hw/semihosting/Kconfig
> @@ -1,3 +1,5 @@
>  
> +# default is 'n'
>  config SEMIHOSTING
> -       bool
> +    bool
> +    depends on TCG
> diff --git a/target/arm/Kconfig b/target/arm/Kconfig
> new file mode 100644
> index 0000000000..3224cac4ad
> --- /dev/null
> +++ b/target/arm/Kconfig
> @@ -0,0 +1,2 @@
> +config SEMIHOSTING
> +    default y if TCG

Do you really have to duplicate the TCG condition?


r~


^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: [PATCH v2 02/10] MAINTAINERS: Add an 'overall' entry for accelerators
  2020-05-17 17:26   ` Thomas Huth
@ 2020-05-21 15:09     ` Philippe Mathieu-Daudé
  0 siblings, 0 replies; 23+ messages in thread
From: Philippe Mathieu-Daudé @ 2020-05-21 15:09 UTC (permalink / raw)
  To: Thomas Huth, qemu-devel
  Cc: Marek Vasut, Peter Maydell, qemu-riscv, Sagar Karandikar,
	Bastian Koppelmann, Chris Wulff, Richard Henderson,
	Laurent Vivier, Max Filippov, Aleksandar Markovic, qemu-arm,
	Palmer Dabbelt, Michael Walle, Paolo Bonzini, Alistair Francis,
	Aleksandar Rikalo, Alex Bennée, Aurelien Jarno,
	Richard Henderson

On 5/17/20 7:26 PM, Thomas Huth wrote:
> On 15/05/2020 19.07, Philippe Mathieu-Daudé wrote:
>> Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
>> Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
>> ---
>> Cc: Paolo Bonzini <pbonzini@redhat.com>
>> ---
>>   MAINTAINERS | 9 +++++++++
>>   1 file changed, 9 insertions(+)
>>
>> diff --git a/MAINTAINERS b/MAINTAINERS
>> index fd88a3de49..659092eb43 100644
>> --- a/MAINTAINERS
>> +++ b/MAINTAINERS
>> @@ -415,6 +415,15 @@ S: Supported
>>   F: target/i386/kvm.c
>>   F: scripts/kvm/vmxcap
>>   
>> +Guest CPU Cores (other accelerators)
> 
> Maybe s/other accelerators/accelerators generic code/ ?

But then we have HVF and WHPX listed there...

> 
>> +------------------------------------
>> +Overall
>> +M: Richard Henderson <rth@twiddle.net>
>> +R: Paolo Bonzini <pbonzini@redhat.com>
>> +S: Maintained
>> +F: include/sysemu/accel.h
>> +F: accel/stubs/Makefile.objs
> 
> What about accel/accel.c and accel/Makefile.objs ? Should they also be
> in the list here?

OK.

> 
>   Thomas
> 



^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: [PATCH v2 09/10] Makefile: Allow target-specific optional Kconfig
  2020-05-15 17:08 ` [PATCH v2 09/10] Makefile: Allow target-specific optional Kconfig Philippe Mathieu-Daudé
  2020-05-19 21:42   ` Richard Henderson
@ 2020-05-21 17:33   ` Philippe Mathieu-Daudé
  1 sibling, 0 replies; 23+ messages in thread
From: Philippe Mathieu-Daudé @ 2020-05-21 17:33 UTC (permalink / raw)
  To: QEMU Developers
  Cc: Marek Vasut, Peter Maydell, Thomas Huth, open list:RISC-V,
	Sagar Karandikar, Bastian Koppelmann, Chris Wulff,
	Laurent Vivier, Max Filippov, Aleksandar Markovic, qemu-arm,
	Palmer Dabbelt, Michael Walle, Paolo Bonzini, Alistair Francis,
	Aleksandar Rikalo, Alex Bennée, Aurelien Jarno,
	Richard Henderson

On Fri, May 15, 2020 at 7:08 PM Philippe Mathieu-Daudé
<philmd@redhat.com> wrote:
>
> Allow use of target-specific Kconfig file.
>
> Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
> ---
>  Makefile | 4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)
>
> diff --git a/Makefile b/Makefile
> index b4c0830b26..5fce168fcb 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -423,11 +423,13 @@ MINIKCONF_INPUTS = $(SRC_PATH)/Kconfig.host \
>                     $(SRC_PATH)/accel/Kconfig \
>                     $(SRC_PATH)/hw/Kconfig
>  MINIKCONF_DEPS = $(MINIKCONF_INPUTS) \
> -                 $(wildcard $(SRC_PATH)/hw/*/Kconfig)
> +                 $(wildcard $(SRC_PATH)/hw/*/Kconfig) \
> +                 $(wildcard $(SRC_PATH)/target/*/Kconfig)
>  MINIKCONF = $(PYTHON) $(SRC_PATH)/scripts/minikconf.py
>
>  $(SUBDIR_DEVICES_MAK): %/config-devices.mak: default-configs/%.mak $(MINIKCONF_DEPS) $(BUILD_DIR)/config-host.mak
>         $(call quiet-command, $(MINIKCONF) $(MINIKCONF_ARGS) \
> +               $(wildcard $(SRC_PATH)/target/$(firstword $(subst -, ,$@))/Kconfig) \

This is incorrect, $@ is a $TARGET_ARCH (example aarch64) and we want
to include $TARGET_BASE_ARCH (example arm).

>                 > $@.tmp, "GEN", "$@.tmp")
>         $(call quiet-command, if test -f $@; then \
>           if cmp -s $@.old $@; then \
> --
> 2.21.3
>



^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: [PATCH v2 10/10] hw/semihosting: Make the feature depend of TCG,  and allow to disable it
  2020-05-19 21:44   ` Richard Henderson
@ 2020-05-21 19:55     ` Philippe Mathieu-Daudé
  0 siblings, 0 replies; 23+ messages in thread
From: Philippe Mathieu-Daudé @ 2020-05-21 19:55 UTC (permalink / raw)
  To: Richard Henderson, qemu-devel, Paolo Bonzini
  Cc: Marek Vasut, Peter Maydell, Thomas Huth, qemu-riscv,
	Sagar Karandikar, Bastian Koppelmann, Chris Wulff,
	Laurent Vivier, Max Filippov, Aleksandar Markovic, qemu-arm,
	Palmer Dabbelt, Michael Walle, Alistair Francis,
	Aleksandar Rikalo, Alex Bennée, Aurelien Jarno,
	Richard Henderson

On 5/19/20 11:44 PM, Richard Henderson wrote:
> On 5/15/20 10:08 AM, Philippe Mathieu-Daudé wrote:
>> +++ b/hw/semihosting/Kconfig
>> @@ -1,3 +1,5 @@
>>   
>> +# default is 'n'
>>   config SEMIHOSTING
>> -       bool
>> +    bool
>> +    depends on TCG
>> diff --git a/target/arm/Kconfig b/target/arm/Kconfig
>> new file mode 100644
>> index 0000000000..3224cac4ad
>> --- /dev/null
>> +++ b/target/arm/Kconfig
>> @@ -0,0 +1,2 @@
>> +config SEMIHOSTING
>> +    default y if TCG
> 
> Do you really have to duplicate the TCG condition?

How so? The semihosting default table is:

       TCG KVM XEN
       y n y n y n
TCG y - - y y y y
     n   - n n n n
KVM y     - - n n
     n         n n
XEN y         - -
     n           -

So checking for TCG is the simpler way.

Maybe I'm not understanding well your question.

The logic is if TCG is selected, SEMIHOSTING is too.



^ permalink raw reply	[flat|nested] 23+ messages in thread

end of thread, other threads:[~2020-05-21 19:57 UTC | newest]

Thread overview: 23+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-05-15 17:07 [PATCH v2 00/10] accel: Allow targets to use Kconfig, disable semihosting by default Philippe Mathieu-Daudé
2020-05-15 17:07 ` [PATCH v2 01/10] MAINTAINERS: Fix KVM path expansion glob Philippe Mathieu-Daudé
2020-05-17 17:23   ` Thomas Huth
2020-05-15 17:07 ` [PATCH v2 02/10] MAINTAINERS: Add an 'overall' entry for accelerators Philippe Mathieu-Daudé
2020-05-17 17:26   ` Thomas Huth
2020-05-21 15:09     ` Philippe Mathieu-Daudé
2020-05-15 17:07 ` [PATCH v2 03/10] MAINTAINERS: Add an entry for the HAX accelerator Philippe Mathieu-Daudé
2020-05-15 17:07 ` [PATCH v2 04/10] accel/tcg: Add stub for probe_access() Philippe Mathieu-Daudé
2020-05-19 21:41   ` Richard Henderson
2020-05-15 17:07 ` [PATCH v2 05/10] Makefile: Remove dangerous EOL trailing backslash Philippe Mathieu-Daudé
2020-05-17 18:00   ` Thomas Huth
2020-05-18 16:46   ` Alistair Francis
2020-05-15 17:08 ` [PATCH v2 06/10] Makefile: Write MINIKCONF variables as one entry per line Philippe Mathieu-Daudé
2020-05-15 17:08 ` [PATCH v2 07/10] accel/Kconfig: Extract accel selectors into their own config Philippe Mathieu-Daudé
2020-05-15 17:08 ` [PATCH v2 08/10] accel/Kconfig: Add the TCG selector Philippe Mathieu-Daudé
2020-05-15 17:08 ` [PATCH v2 09/10] Makefile: Allow target-specific optional Kconfig Philippe Mathieu-Daudé
2020-05-19 21:42   ` Richard Henderson
2020-05-21 17:33   ` Philippe Mathieu-Daudé
2020-05-15 17:08 ` [PATCH v2 10/10] hw/semihosting: Make the feature depend of TCG, and allow to disable it Philippe Mathieu-Daudé
2020-05-19 21:44   ` Richard Henderson
2020-05-21 19:55     ` Philippe Mathieu-Daudé
2020-05-16  3:44 ` [PATCH v2 00/10] accel: Allow targets to use Kconfig, disable semihosting by default no-reply
2020-05-16  3:57 ` no-reply

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).