Skip to contentSkip to conversation

kvm-s390: small fixes

PATCH In review Christian Borntraeger 2 participants 7 messages Jul 15, 2008

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

cover kvm-s390: small fixes

Hello Avi,

here are two small patches for kvm on s390:
1. kvm-s390: Fix guest kconfig for virtio
2. kvm-s390: change help text of guest Kconfig

Christian

#1 lore raw

PATCH 1/2 kvm-s390: Fix guest kconfig for virtio

Cornelia Huck noticed that a modular virtio without kvm guest support leads to a build error in the s390 virtio transport:

CONFIG_VIRTIO=m leads to
ERROR: "vmem_add_mapping" [drivers/s390/kvm/kvm_virtio.ko] undefined!
ERROR: "max_pfn" [drivers/s390/kvm/kvm_virtio.ko] undefined!
ERROR: "vmem_remove_mapping" [drivers/s390/kvm/kvm_virtio.ko] undefined!

The virtio transport only works with kvm guest support and only as a builtin. Lets change the build process of drivers/s390/kvm/kvm_virtio.c to depend on kvm guest support, which is also a bool.

---
 drivers/s390/kvm/Makefile |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/s390/kvm/Makefile +1 -1
Index: kvm/drivers/s390/kvm/Makefile
===================================================================
@@ -6,4 +6,4 @@
 # it under the terms of the GNU General Public License (version 2 only)
 # as published by the Free Software Foundation.
 
-obj-$(CONFIG_VIRTIO) += kvm_virtio.o
+obj-$(CONFIG_S390_GUEST) += kvm_virtio.o
#2 lore raw

Re: [PATCH 1/2] kvm-s390: Fix guest kconfig for virtio

Quoted 11 lines · Christian Borntraeger

Cornelia Huck noticed that a modular virtio without kvm guest support leads to a build error in the s390 virtio transport:

CONFIG_VIRTIO=m leads to ERROR: "vmem_add_mapping" [drivers/s390/kvm/kvm_virtio.ko] undefined!
ERROR: "max_pfn" [drivers/s390/kvm/kvm_virtio.ko] undefined!
ERROR: "vmem_remove_mapping" [drivers/s390/kvm/kvm_virtio.ko] undefined!

The virtio transport only works with kvm guest support and only as a builtin. Lets change the build process of drivers/s390/kvm/kvm_virtio.c to depend on kvm guest support, which is also a bool.

This leads to confusion if CONFIG_VIRTIO is unset but CONFIG_S390_GUEST is set.

What about having CONFIG_S390_GUEST select CONFIG_VIRTIO instead?

Signature · 1 line
Do not meddle in the internals of kernels, for they are subtle and quick to panic.
#3 lore raw

Re: [PATCH 1/2] kvm-s390: Fix guest kconfig for virtio

Am Dienstag, 15. Juli 2008 schrieb Avi Kivity:

Quoted 4 lines

This leads to confusion if CONFIG_VIRTIO is unset but CONFIG_S390_GUEST is set.

What about having CONFIG_S390_GUEST select CONFIG_VIRTIO instead?

That is already the case. S390_GUEST has

bool "s390 guest support (EXPERIMENTAL)"

        depends on 64BIT && EXPERIMENTAL
        select VIRTIO
        select VIRTIO_RING

[...]

#4 lore raw

PATCH 2/2 kvm-s390: change help text of guest Kconfig

In reply to Christian Borntraeger

The current help text for CONFIG_S390_GUEST is not very helpful. Add more text.

---
 arch/s390/Kconfig |    7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)
arch/s390/Kconfig +5 -2
Index: kvm/arch/s390/Kconfig
===================================================================
@@ -540,13 +540,16 @@ config ZFCPDUMP
 	  Refer to <file:Documentation/s390/zfcpdump.txt> for more details on this.
 
 config S390_GUEST
-bool "s390 guest support (EXPERIMENTAL)"
+bool "s390 guest support for KVM (EXPERIMENTAL)"
 	depends on 64BIT && EXPERIMENTAL
 	select VIRTIO
 	select VIRTIO_RING
 	select VIRTIO_CONSOLE
 	help
-	  Select this option if you want to run the kernel under s390 linux
+	  Select this option if you want to run the kernel as a guest under
+	  the KVM hypervisor. This will add detection for KVM as well  as a
+	  virtio transport. If KVM is detected, the virtio console will be
+	  the default console.
 endmenu
 
 source "net/Kconfig"
#5 lore raw

Re: [PATCH 2/2] kvm-s390: change help text of guest Kconfig

Quoted 4 lines · Christian Borntraeger

The current help text for CONFIG_S390_GUEST is not very helpful. Add more text.

Doesn't apply (even with -C0)? What tree are based on?

Signature · 1 line
Do not meddle in the internals of kernels, for they are subtle and quick to panic.
#6 lore raw

Re: [PATCH 2/2] kvm-s390: change help text of guest Kconfig

Am Dienstag, 15. Juli 2008 schrieb Avi Kivity:

Quoted 7 lines
Quoted 4 lines · Christian Borntraeger

The current help text for CONFIG_S390_GUEST is not very helpful. Add more text.

Doesn't apply (even with -C0)? What tree are based on?

Hmm, I think the problem stems from the virtio_console patches which are in Rustys tree. They add an select statement to CONFIG_S390_GUEST. Lets drop this patch until Rustys tree is merged.

Christian