From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=3.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI, SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id A7B88C2BBFD for ; Tue, 14 Apr 2020 05:54:09 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 80B3720678 for ; Tue, 14 Apr 2020 05:54:09 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=ellerman.id.au header.i=@ellerman.id.au header.b="rGDOlIHN" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2405660AbgDNFyG (ORCPT ); Tue, 14 Apr 2020 01:54:06 -0400 Received: from bilbo.ozlabs.org ([203.11.71.1]:36697 "EHLO ozlabs.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729230AbgDNFyC (ORCPT ); Tue, 14 Apr 2020 01:54:02 -0400 Received: from authenticated.ozlabs.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mail.ozlabs.org (Postfix) with ESMTPSA id 491ZRm0Nd7z9sSt; Tue, 14 Apr 2020 15:53:55 +1000 (AEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ellerman.id.au; s=201909; t=1586843638; bh=5CTXgwD6QRZ19R0dMPZNZMlbhZJTKR1ERFLzk/tOayw=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From; b=rGDOlIHN9VhZPHk0xqQQTGt0JIeqe7ZuCMPimjxIqjtZ0UA6hVuTVpMDgMDbKLF3t Byzd1hqCI0OgLrCMXpU4cdONHOELBWF8A3sEG8Jaj9ggLQvb/trXrJEk3tAcOtLmBV nYbiOhJSSCgm4n6u+mAo7gMrEfF0Cf5y9d3HHUacZZzfn2OuszK9t8QRMpWr7emaXL mTiNgU4ldQAShaI7GU8oArrlpkmY/tjdxRai1o/bHIKYxP/M9N2nZIEzqItnl5wczs XEjj0FSxQ7L+v553P84EnjCs+cIm/VjAbjOlpBmlyvJnzHCM02OjI7D75vStEBNhD5 Jk1fzaFhKL7pw== From: Michael Ellerman To: Jason Wang , mst@redhat.com, jasowang@redhat.com Cc: linux-mips@vger.kernel.org, linux-kernel@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, linux-s390@vger.kernel.org, kvm@vger.kernel.org, virtualization@lists.linux-foundation.org, netdev@vger.kernel.org, geert@linux-m68k.org, Thomas Bogendoerfer , Benjamin Herrenschmidt , Paul Mackerras , Heiko Carstens , Vasily Gorbik , Christian Borntraeger Subject: Re: [PATCH] vhost: do not enable VHOST_MENU by default In-Reply-To: <20200414024438.19103-1-jasowang@redhat.com> References: <20200414024438.19103-1-jasowang@redhat.com> Date: Tue, 14 Apr 2020 15:54:05 +1000 Message-ID: <87h7xmk3ya.fsf@mpe.ellerman.id.au> MIME-Version: 1.0 Content-Type: text/plain Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Jason Wang writes: > We try to keep the defconfig untouched after decoupling CONFIG_VHOST > out of CONFIG_VIRTUALIZATION in commit 20c384f1ea1a > ("vhost: refine vhost and vringh kconfig") by enabling VHOST_MENU by > default. Then the defconfigs can keep enabling CONFIG_VHOST_NET > without the caring of CONFIG_VHOST. > > But this will leave a "CONFIG_VHOST_MENU=y" in all defconfigs and even > for the ones that doesn't want vhost. So it actually shifts the > burdens to the maintainers of all other to add "CONFIG_VHOST_MENU is > not set". So this patch tries to enable CONFIG_VHOST explicitly in > defconfigs that enables CONFIG_VHOST_NET and CONFIG_VHOST_VSOCK. > > Cc: Thomas Bogendoerfer > Cc: Benjamin Herrenschmidt > Cc: Paul Mackerras > Cc: Michael Ellerman > Cc: Heiko Carstens > Cc: Vasily Gorbik > Cc: Christian Borntraeger > Reported-by: Geert Uytterhoeven > Signed-off-by: Jason Wang > --- > arch/mips/configs/malta_kvm_defconfig | 1 + > arch/powerpc/configs/powernv_defconfig | 1 + > arch/powerpc/configs/ppc64_defconfig | 1 + > arch/powerpc/configs/pseries_defconfig | 1 + Fine by me. Acked-by: Michael Ellerman (powerpc) cheers > arch/s390/configs/debug_defconfig | 1 + > arch/s390/configs/defconfig | 1 + > drivers/vhost/Kconfig | 18 +++++------------- > 7 files changed, 11 insertions(+), 13 deletions(-) > > diff --git a/arch/mips/configs/malta_kvm_defconfig b/arch/mips/configs/malta_kvm_defconfig > index 8ef612552a19..06f0c7a0ca87 100644 > --- a/arch/mips/configs/malta_kvm_defconfig > +++ b/arch/mips/configs/malta_kvm_defconfig > @@ -18,6 +18,7 @@ CONFIG_PCI=y > CONFIG_VIRTUALIZATION=y > CONFIG_KVM=m > CONFIG_KVM_MIPS_DEBUG_COP0_COUNTERS=y > +CONFIG_VHOST=m > CONFIG_VHOST_NET=m > CONFIG_MODULES=y > CONFIG_MODULE_UNLOAD=y > diff --git a/arch/powerpc/configs/powernv_defconfig b/arch/powerpc/configs/powernv_defconfig > index 71749377d164..404245b4594d 100644 > --- a/arch/powerpc/configs/powernv_defconfig > +++ b/arch/powerpc/configs/powernv_defconfig > @@ -346,5 +346,6 @@ CONFIG_CRYPTO_DEV_VMX=y > CONFIG_VIRTUALIZATION=y > CONFIG_KVM_BOOK3S_64=m > CONFIG_KVM_BOOK3S_64_HV=m > +CONFIG_VHOST=m > CONFIG_VHOST_NET=m > CONFIG_PRINTK_TIME=y > diff --git a/arch/powerpc/configs/ppc64_defconfig b/arch/powerpc/configs/ppc64_defconfig > index 7e68cb222c7b..4599fc7be285 100644 > --- a/arch/powerpc/configs/ppc64_defconfig > +++ b/arch/powerpc/configs/ppc64_defconfig > @@ -61,6 +61,7 @@ CONFIG_ELECTRA_CF=y > CONFIG_VIRTUALIZATION=y > CONFIG_KVM_BOOK3S_64=m > CONFIG_KVM_BOOK3S_64_HV=m > +CONFIG_VHOST=m > CONFIG_VHOST_NET=m > CONFIG_OPROFILE=m > CONFIG_KPROBES=y > diff --git a/arch/powerpc/configs/pseries_defconfig b/arch/powerpc/configs/pseries_defconfig > index 6b68109e248f..4cad3901b5de 100644 > --- a/arch/powerpc/configs/pseries_defconfig > +++ b/arch/powerpc/configs/pseries_defconfig > @@ -321,5 +321,6 @@ CONFIG_CRYPTO_DEV_VMX=y > CONFIG_VIRTUALIZATION=y > CONFIG_KVM_BOOK3S_64=m > CONFIG_KVM_BOOK3S_64_HV=m > +CONFIG_VHOST=m > CONFIG_VHOST_NET=m > CONFIG_PRINTK_TIME=y > diff --git a/arch/s390/configs/debug_defconfig b/arch/s390/configs/debug_defconfig > index 0c86ba19fa2b..6ec6e69630d1 100644 > --- a/arch/s390/configs/debug_defconfig > +++ b/arch/s390/configs/debug_defconfig > @@ -57,6 +57,7 @@ CONFIG_PROTECTED_VIRTUALIZATION_GUEST=y > CONFIG_CMM=m > CONFIG_APPLDATA_BASE=y > CONFIG_KVM=m > +CONFIG_VHOST=m > CONFIG_VHOST_NET=m > CONFIG_VHOST_VSOCK=m > CONFIG_OPROFILE=m > diff --git a/arch/s390/configs/defconfig b/arch/s390/configs/defconfig > index 6b27d861a9a3..d1b3bf83d687 100644 > --- a/arch/s390/configs/defconfig > +++ b/arch/s390/configs/defconfig > @@ -57,6 +57,7 @@ CONFIG_PROTECTED_VIRTUALIZATION_GUEST=y > CONFIG_CMM=m > CONFIG_APPLDATA_BASE=y > CONFIG_KVM=m > +CONFIG_VHOST=m > CONFIG_VHOST_NET=m > CONFIG_VHOST_VSOCK=m > CONFIG_OPROFILE=m > diff --git a/drivers/vhost/Kconfig b/drivers/vhost/Kconfig > index e79cbbdfea45..14d296dc18cd 100644 > --- a/drivers/vhost/Kconfig > +++ b/drivers/vhost/Kconfig > @@ -12,23 +12,18 @@ config VHOST_RING > This option is selected by any driver which needs to access > the host side of a virtio ring. > > -config VHOST > - tristate > +menuconfig VHOST > + tristate "Vhost Devices" > select VHOST_IOTLB > help > - This option is selected by any driver which needs to access > - the core of vhost. > - > -menuconfig VHOST_MENU > - bool "VHOST drivers" > - default y > + Enable option to support host kernel or hardware accelerator > + for virtio device. > > -if VHOST_MENU > +if VHOST > > config VHOST_NET > tristate "Host kernel accelerator for virtio net" > depends on NET && EVENTFD && (TUN || !TUN) && (TAP || !TAP) > - select VHOST > ---help--- > This kernel module can be loaded in host kernel to accelerate > guest networking with virtio_net. Not to be confused with virtio_net > @@ -40,7 +35,6 @@ config VHOST_NET > config VHOST_SCSI > tristate "VHOST_SCSI TCM fabric driver" > depends on TARGET_CORE && EVENTFD > - select VHOST > default n > ---help--- > Say M here to enable the vhost_scsi TCM fabric module > @@ -49,7 +43,6 @@ config VHOST_SCSI > config VHOST_VSOCK > tristate "vhost virtio-vsock driver" > depends on VSOCKETS && EVENTFD > - select VHOST > select VIRTIO_VSOCKETS_COMMON > default n > ---help--- > @@ -63,7 +56,6 @@ config VHOST_VSOCK > config VHOST_VDPA > tristate "Vhost driver for vDPA-based backend" > depends on EVENTFD > - select VHOST > depends on VDPA > help > This kernel module can be loaded in host kernel to accelerate > -- > 2.20.1 From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from bilbo.ozlabs.org ([203.11.71.1]:36697 "EHLO ozlabs.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729230AbgDNFyC (ORCPT ); Tue, 14 Apr 2020 01:54:02 -0400 From: Michael Ellerman Subject: Re: [PATCH] vhost: do not enable VHOST_MENU by default In-Reply-To: <20200414024438.19103-1-jasowang@redhat.com> References: <20200414024438.19103-1-jasowang@redhat.com> Date: Tue, 14 Apr 2020 15:54:05 +1000 Message-ID: <87h7xmk3ya.fsf@mpe.ellerman.id.au> MIME-Version: 1.0 Content-Type: text/plain Sender: linux-s390-owner@vger.kernel.org List-ID: To: Jason Wang , mst@redhat.comjasowang@redhat.com Cc: linux-mips@vger.kernel.org, linux-kernel@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, linux-s390@vger.kernel.org, kvm@vger.kernel.org, virtualization@lists.linux-foundation.org, netdev@vger.kernel.org, geert@linux-m68k.org, Thomas Bogendoerfer , Benjamin Herrenschmidt , Paul Mackerras , Heiko Carstens , Vasily Gorbik , Christian Borntraeger Jason Wang writes: > We try to keep the defconfig untouched after decoupling CONFIG_VHOST > out of CONFIG_VIRTUALIZATION in commit 20c384f1ea1a > ("vhost: refine vhost and vringh kconfig") by enabling VHOST_MENU by > default. Then the defconfigs can keep enabling CONFIG_VHOST_NET > without the caring of CONFIG_VHOST. > > But this will leave a "CONFIG_VHOST_MENU=y" in all defconfigs and even > for the ones that doesn't want vhost. So it actually shifts the > burdens to the maintainers of all other to add "CONFIG_VHOST_MENU is > not set". So this patch tries to enable CONFIG_VHOST explicitly in > defconfigs that enables CONFIG_VHOST_NET and CONFIG_VHOST_VSOCK. > > Cc: Thomas Bogendoerfer > Cc: Benjamin Herrenschmidt > Cc: Paul Mackerras > Cc: Michael Ellerman > Cc: Heiko Carstens > Cc: Vasily Gorbik > Cc: Christian Borntraeger > Reported-by: Geert Uytterhoeven > Signed-off-by: Jason Wang > --- > arch/mips/configs/malta_kvm_defconfig | 1 + > arch/powerpc/configs/powernv_defconfig | 1 + > arch/powerpc/configs/ppc64_defconfig | 1 + > arch/powerpc/configs/pseries_defconfig | 1 + Fine by me. Acked-by: Michael Ellerman (powerpc) cheers > arch/s390/configs/debug_defconfig | 1 + > arch/s390/configs/defconfig | 1 + > drivers/vhost/Kconfig | 18 +++++------------- > 7 files changed, 11 insertions(+), 13 deletions(-) > > diff --git a/arch/mips/configs/malta_kvm_defconfig b/arch/mips/configs/malta_kvm_defconfig > index 8ef612552a19..06f0c7a0ca87 100644 > --- a/arch/mips/configs/malta_kvm_defconfig > +++ b/arch/mips/configs/malta_kvm_defconfig > @@ -18,6 +18,7 @@ CONFIG_PCI=y > CONFIG_VIRTUALIZATION=y > CONFIG_KVM=m > CONFIG_KVM_MIPS_DEBUG_COP0_COUNTERS=y > +CONFIG_VHOST=m > CONFIG_VHOST_NET=m > CONFIG_MODULES=y > CONFIG_MODULE_UNLOAD=y > diff --git a/arch/powerpc/configs/powernv_defconfig b/arch/powerpc/configs/powernv_defconfig > index 71749377d164..404245b4594d 100644 > --- a/arch/powerpc/configs/powernv_defconfig > +++ b/arch/powerpc/configs/powernv_defconfig > @@ -346,5 +346,6 @@ CONFIG_CRYPTO_DEV_VMX=y > CONFIG_VIRTUALIZATION=y > CONFIG_KVM_BOOK3S_64=m > CONFIG_KVM_BOOK3S_64_HV=m > +CONFIG_VHOST=m > CONFIG_VHOST_NET=m > CONFIG_PRINTK_TIME=y > diff --git a/arch/powerpc/configs/ppc64_defconfig b/arch/powerpc/configs/ppc64_defconfig > index 7e68cb222c7b..4599fc7be285 100644 > --- a/arch/powerpc/configs/ppc64_defconfig > +++ b/arch/powerpc/configs/ppc64_defconfig > @@ -61,6 +61,7 @@ CONFIG_ELECTRA_CF=y > CONFIG_VIRTUALIZATION=y > CONFIG_KVM_BOOK3S_64=m > CONFIG_KVM_BOOK3S_64_HV=m > +CONFIG_VHOST=m > CONFIG_VHOST_NET=m > CONFIG_OPROFILE=m > CONFIG_KPROBES=y > diff --git a/arch/powerpc/configs/pseries_defconfig b/arch/powerpc/configs/pseries_defconfig > index 6b68109e248f..4cad3901b5de 100644 > --- a/arch/powerpc/configs/pseries_defconfig > +++ b/arch/powerpc/configs/pseries_defconfig > @@ -321,5 +321,6 @@ CONFIG_CRYPTO_DEV_VMX=y > CONFIG_VIRTUALIZATION=y > CONFIG_KVM_BOOK3S_64=m > CONFIG_KVM_BOOK3S_64_HV=m > +CONFIG_VHOST=m > CONFIG_VHOST_NET=m > CONFIG_PRINTK_TIME=y > diff --git a/arch/s390/configs/debug_defconfig b/arch/s390/configs/debug_defconfig > index 0c86ba19fa2b..6ec6e69630d1 100644 > --- a/arch/s390/configs/debug_defconfig > +++ b/arch/s390/configs/debug_defconfig > @@ -57,6 +57,7 @@ CONFIG_PROTECTED_VIRTUALIZATION_GUEST=y > CONFIG_CMM=m > CONFIG_APPLDATA_BASE=y > CONFIG_KVM=m > +CONFIG_VHOST=m > CONFIG_VHOST_NET=m > CONFIG_VHOST_VSOCK=m > CONFIG_OPROFILE=m > diff --git a/arch/s390/configs/defconfig b/arch/s390/configs/defconfig > index 6b27d861a9a3..d1b3bf83d687 100644 > --- a/arch/s390/configs/defconfig > +++ b/arch/s390/configs/defconfig > @@ -57,6 +57,7 @@ CONFIG_PROTECTED_VIRTUALIZATION_GUEST=y > CONFIG_CMM=m > CONFIG_APPLDATA_BASE=y > CONFIG_KVM=m > +CONFIG_VHOST=m > CONFIG_VHOST_NET=m > CONFIG_VHOST_VSOCK=m > CONFIG_OPROFILE=m > diff --git a/drivers/vhost/Kconfig b/drivers/vhost/Kconfig > index e79cbbdfea45..14d296dc18cd 100644 > --- a/drivers/vhost/Kconfig > +++ b/drivers/vhost/Kconfig > @@ -12,23 +12,18 @@ config VHOST_RING > This option is selected by any driver which needs to access > the host side of a virtio ring. > > -config VHOST > - tristate > +menuconfig VHOST > + tristate "Vhost Devices" > select VHOST_IOTLB > help > - This option is selected by any driver which needs to access > - the core of vhost. > - > -menuconfig VHOST_MENU > - bool "VHOST drivers" > - default y > + Enable option to support host kernel or hardware accelerator > + for virtio device. > > -if VHOST_MENU > +if VHOST > > config VHOST_NET > tristate "Host kernel accelerator for virtio net" > depends on NET && EVENTFD && (TUN || !TUN) && (TAP || !TAP) > - select VHOST > ---help--- > This kernel module can be loaded in host kernel to accelerate > guest networking with virtio_net. Not to be confused with virtio_net > @@ -40,7 +35,6 @@ config VHOST_NET > config VHOST_SCSI > tristate "VHOST_SCSI TCM fabric driver" > depends on TARGET_CORE && EVENTFD > - select VHOST > default n > ---help--- > Say M here to enable the vhost_scsi TCM fabric module > @@ -49,7 +43,6 @@ config VHOST_SCSI > config VHOST_VSOCK > tristate "vhost virtio-vsock driver" > depends on VSOCKETS && EVENTFD > - select VHOST > select VIRTIO_VSOCKETS_COMMON > default n > ---help--- > @@ -63,7 +56,6 @@ config VHOST_VSOCK > config VHOST_VDPA > tristate "Vhost driver for vDPA-based backend" > depends on EVENTFD > - select VHOST > depends on VDPA > help > This kernel module can be loaded in host kernel to accelerate > -- > 2.20.1 From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.5 required=3.0 tests=DKIM_INVALID,DKIM_SIGNED, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id E243FC2BB1D for ; Tue, 14 Apr 2020 05:58:02 +0000 (UTC) Received: from lists.ozlabs.org (lists.ozlabs.org [203.11.71.2]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 8FA4020678 for ; Tue, 14 Apr 2020 05:58:02 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=ellerman.id.au header.i=@ellerman.id.au header.b="rGDOlIHN" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 8FA4020678 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=ellerman.id.au Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=linuxppc-dev-bounces+linuxppc-dev=archiver.kernel.org@lists.ozlabs.org Received: from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) by lists.ozlabs.org (Postfix) with ESMTP id 491ZXS4NmGzDqJW for ; Tue, 14 Apr 2020 15:58:00 +1000 (AEST) Received: from ozlabs.org (bilbo.ozlabs.org [IPv6:2401:3900:2:1::2]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 491ZRp5BN3zDqVT for ; Tue, 14 Apr 2020 15:53:58 +1000 (AEST) Authentication-Results: lists.ozlabs.org; dmarc=none (p=none dis=none) header.from=ellerman.id.au Authentication-Results: lists.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=ellerman.id.au header.i=@ellerman.id.au header.a=rsa-sha256 header.s=201909 header.b=rGDOlIHN; dkim-atps=neutral Received: from authenticated.ozlabs.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mail.ozlabs.org (Postfix) with ESMTPSA id 491ZRm0Nd7z9sSt; Tue, 14 Apr 2020 15:53:55 +1000 (AEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ellerman.id.au; s=201909; t=1586843638; bh=5CTXgwD6QRZ19R0dMPZNZMlbhZJTKR1ERFLzk/tOayw=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From; b=rGDOlIHN9VhZPHk0xqQQTGt0JIeqe7ZuCMPimjxIqjtZ0UA6hVuTVpMDgMDbKLF3t Byzd1hqCI0OgLrCMXpU4cdONHOELBWF8A3sEG8Jaj9ggLQvb/trXrJEk3tAcOtLmBV nYbiOhJSSCgm4n6u+mAo7gMrEfF0Cf5y9d3HHUacZZzfn2OuszK9t8QRMpWr7emaXL mTiNgU4ldQAShaI7GU8oArrlpkmY/tjdxRai1o/bHIKYxP/M9N2nZIEzqItnl5wczs XEjj0FSxQ7L+v553P84EnjCs+cIm/VjAbjOlpBmlyvJnzHCM02OjI7D75vStEBNhD5 Jk1fzaFhKL7pw== From: Michael Ellerman To: Jason Wang , mst@redhat.com, jasowang@redhat.com Subject: Re: [PATCH] vhost: do not enable VHOST_MENU by default In-Reply-To: <20200414024438.19103-1-jasowang@redhat.com> References: <20200414024438.19103-1-jasowang@redhat.com> Date: Tue, 14 Apr 2020 15:54:05 +1000 Message-ID: <87h7xmk3ya.fsf@mpe.ellerman.id.au> MIME-Version: 1.0 Content-Type: text/plain X-BeenThere: linuxppc-dev@lists.ozlabs.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-s390@vger.kernel.org, Thomas Bogendoerfer , Vasily Gorbik , kvm@vger.kernel.org, linux-kernel@vger.kernel.org, Heiko Carstens , linux-mips@vger.kernel.org, virtualization@lists.linux-foundation.org, Christian Borntraeger , geert@linux-m68k.org, netdev@vger.kernel.org, Paul Mackerras , linuxppc-dev@lists.ozlabs.org Errors-To: linuxppc-dev-bounces+linuxppc-dev=archiver.kernel.org@lists.ozlabs.org Sender: "Linuxppc-dev" Jason Wang writes: > We try to keep the defconfig untouched after decoupling CONFIG_VHOST > out of CONFIG_VIRTUALIZATION in commit 20c384f1ea1a > ("vhost: refine vhost and vringh kconfig") by enabling VHOST_MENU by > default. Then the defconfigs can keep enabling CONFIG_VHOST_NET > without the caring of CONFIG_VHOST. > > But this will leave a "CONFIG_VHOST_MENU=y" in all defconfigs and even > for the ones that doesn't want vhost. So it actually shifts the > burdens to the maintainers of all other to add "CONFIG_VHOST_MENU is > not set". So this patch tries to enable CONFIG_VHOST explicitly in > defconfigs that enables CONFIG_VHOST_NET and CONFIG_VHOST_VSOCK. > > Cc: Thomas Bogendoerfer > Cc: Benjamin Herrenschmidt > Cc: Paul Mackerras > Cc: Michael Ellerman > Cc: Heiko Carstens > Cc: Vasily Gorbik > Cc: Christian Borntraeger > Reported-by: Geert Uytterhoeven > Signed-off-by: Jason Wang > --- > arch/mips/configs/malta_kvm_defconfig | 1 + > arch/powerpc/configs/powernv_defconfig | 1 + > arch/powerpc/configs/ppc64_defconfig | 1 + > arch/powerpc/configs/pseries_defconfig | 1 + Fine by me. Acked-by: Michael Ellerman (powerpc) cheers > arch/s390/configs/debug_defconfig | 1 + > arch/s390/configs/defconfig | 1 + > drivers/vhost/Kconfig | 18 +++++------------- > 7 files changed, 11 insertions(+), 13 deletions(-) > > diff --git a/arch/mips/configs/malta_kvm_defconfig b/arch/mips/configs/malta_kvm_defconfig > index 8ef612552a19..06f0c7a0ca87 100644 > --- a/arch/mips/configs/malta_kvm_defconfig > +++ b/arch/mips/configs/malta_kvm_defconfig > @@ -18,6 +18,7 @@ CONFIG_PCI=y > CONFIG_VIRTUALIZATION=y > CONFIG_KVM=m > CONFIG_KVM_MIPS_DEBUG_COP0_COUNTERS=y > +CONFIG_VHOST=m > CONFIG_VHOST_NET=m > CONFIG_MODULES=y > CONFIG_MODULE_UNLOAD=y > diff --git a/arch/powerpc/configs/powernv_defconfig b/arch/powerpc/configs/powernv_defconfig > index 71749377d164..404245b4594d 100644 > --- a/arch/powerpc/configs/powernv_defconfig > +++ b/arch/powerpc/configs/powernv_defconfig > @@ -346,5 +346,6 @@ CONFIG_CRYPTO_DEV_VMX=y > CONFIG_VIRTUALIZATION=y > CONFIG_KVM_BOOK3S_64=m > CONFIG_KVM_BOOK3S_64_HV=m > +CONFIG_VHOST=m > CONFIG_VHOST_NET=m > CONFIG_PRINTK_TIME=y > diff --git a/arch/powerpc/configs/ppc64_defconfig b/arch/powerpc/configs/ppc64_defconfig > index 7e68cb222c7b..4599fc7be285 100644 > --- a/arch/powerpc/configs/ppc64_defconfig > +++ b/arch/powerpc/configs/ppc64_defconfig > @@ -61,6 +61,7 @@ CONFIG_ELECTRA_CF=y > CONFIG_VIRTUALIZATION=y > CONFIG_KVM_BOOK3S_64=m > CONFIG_KVM_BOOK3S_64_HV=m > +CONFIG_VHOST=m > CONFIG_VHOST_NET=m > CONFIG_OPROFILE=m > CONFIG_KPROBES=y > diff --git a/arch/powerpc/configs/pseries_defconfig b/arch/powerpc/configs/pseries_defconfig > index 6b68109e248f..4cad3901b5de 100644 > --- a/arch/powerpc/configs/pseries_defconfig > +++ b/arch/powerpc/configs/pseries_defconfig > @@ -321,5 +321,6 @@ CONFIG_CRYPTO_DEV_VMX=y > CONFIG_VIRTUALIZATION=y > CONFIG_KVM_BOOK3S_64=m > CONFIG_KVM_BOOK3S_64_HV=m > +CONFIG_VHOST=m > CONFIG_VHOST_NET=m > CONFIG_PRINTK_TIME=y > diff --git a/arch/s390/configs/debug_defconfig b/arch/s390/configs/debug_defconfig > index 0c86ba19fa2b..6ec6e69630d1 100644 > --- a/arch/s390/configs/debug_defconfig > +++ b/arch/s390/configs/debug_defconfig > @@ -57,6 +57,7 @@ CONFIG_PROTECTED_VIRTUALIZATION_GUEST=y > CONFIG_CMM=m > CONFIG_APPLDATA_BASE=y > CONFIG_KVM=m > +CONFIG_VHOST=m > CONFIG_VHOST_NET=m > CONFIG_VHOST_VSOCK=m > CONFIG_OPROFILE=m > diff --git a/arch/s390/configs/defconfig b/arch/s390/configs/defconfig > index 6b27d861a9a3..d1b3bf83d687 100644 > --- a/arch/s390/configs/defconfig > +++ b/arch/s390/configs/defconfig > @@ -57,6 +57,7 @@ CONFIG_PROTECTED_VIRTUALIZATION_GUEST=y > CONFIG_CMM=m > CONFIG_APPLDATA_BASE=y > CONFIG_KVM=m > +CONFIG_VHOST=m > CONFIG_VHOST_NET=m > CONFIG_VHOST_VSOCK=m > CONFIG_OPROFILE=m > diff --git a/drivers/vhost/Kconfig b/drivers/vhost/Kconfig > index e79cbbdfea45..14d296dc18cd 100644 > --- a/drivers/vhost/Kconfig > +++ b/drivers/vhost/Kconfig > @@ -12,23 +12,18 @@ config VHOST_RING > This option is selected by any driver which needs to access > the host side of a virtio ring. > > -config VHOST > - tristate > +menuconfig VHOST > + tristate "Vhost Devices" > select VHOST_IOTLB > help > - This option is selected by any driver which needs to access > - the core of vhost. > - > -menuconfig VHOST_MENU > - bool "VHOST drivers" > - default y > + Enable option to support host kernel or hardware accelerator > + for virtio device. > > -if VHOST_MENU > +if VHOST > > config VHOST_NET > tristate "Host kernel accelerator for virtio net" > depends on NET && EVENTFD && (TUN || !TUN) && (TAP || !TAP) > - select VHOST > ---help--- > This kernel module can be loaded in host kernel to accelerate > guest networking with virtio_net. Not to be confused with virtio_net > @@ -40,7 +35,6 @@ config VHOST_NET > config VHOST_SCSI > tristate "VHOST_SCSI TCM fabric driver" > depends on TARGET_CORE && EVENTFD > - select VHOST > default n > ---help--- > Say M here to enable the vhost_scsi TCM fabric module > @@ -49,7 +43,6 @@ config VHOST_SCSI > config VHOST_VSOCK > tristate "vhost virtio-vsock driver" > depends on VSOCKETS && EVENTFD > - select VHOST > select VIRTIO_VSOCKETS_COMMON > default n > ---help--- > @@ -63,7 +56,6 @@ config VHOST_VSOCK > config VHOST_VDPA > tristate "Vhost driver for vDPA-based backend" > depends on EVENTFD > - select VHOST > depends on VDPA > help > This kernel module can be loaded in host kernel to accelerate > -- > 2.20.1