Received: by 2002:a25:d783:0:0:0:0:0 with SMTP id o125csp228671ybg; Wed, 18 Mar 2020 21:31:32 -0700 (PDT) X-Google-Smtp-Source: ADFU+vskIbTReZUGxvROJqOOMg+DUqD+iNICtcjZGlyzCxzUZ0W0LnnNCS9QDo4wscyd7MxIIXf+ X-Received: by 2002:a05:6808:a0a:: with SMTP id n10mr1052542oij.10.1584592292022; Wed, 18 Mar 2020 21:31:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1584592292; cv=none; d=google.com; s=arc-20160816; b=lChdJet16VTtMXqL0leqOrbMzZ1uY7C8YHK8RrbeAPjqmWMp0GXPxzeIUkyHY/2EQq D9BIEOvGlXu70SMCiB7IEbNgDrgk/hUnUcDbry/q1ohIUgeOYln3K4V8Tr86FDc6K9Wo uQPZCCLNHCk+BtsJLoCbrZf8i3N+BaKYDwF6pfqfFfG84gea7WcZpWtAc1ABRAS1It2g 750lii7o8wdrxyJM8qRmYn7IFKuwxzLN9myMINRVt3pFYa8puxDhZx8nQKViLKTWZuoj ThNavX09RzM5OrfVnMM67pBy0FH/xxeIR/dUWsFPgJ6dnI4ffXR0jIddCXwv6wCR2XZu z81A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=BNG/4gsDlzID/iu3w+7gBGtdDaCICA3ZSeGXD3zpCk4=; b=CQ2eUjU2HrT7p17mHSr6DIl2caXYJw1m1xTYwSVqdSo1z5MQdSKT3lykfMZc3js4il S2uYhg+I4vmUoShwn6nRQJc9LOYdy03SOmovbaJvZ5rfMQC+Q42/cKyAeTmKzuFnTTNU WRdIoGSKcjeOw1O48dcPEJe9NuweqGMjHGlBQdnfTuUQLSZH6RhPnG1noGn1qBq7Bx4F lQKH4InQHarBPsQUBaEpF6Dw8LhcsNcEOM3eqo5EDwZYI8MP92Z5UhceL4dYVhxtSGwj 7MyoUnHQRgu+lL/0+agPhtLKZfFxp2jUPCkRZs1OLpjzu++wbm/Gr/FPlhobq1dE3HMB oetg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@brainfault-org.20150623.gappssmtp.com header.s=20150623 header.b=YXAM1GQ1; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id q6si579988otg.84.2020.03.18.21.31.18; Wed, 18 Mar 2020 21:31:32 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@brainfault-org.20150623.gappssmtp.com header.s=20150623 header.b=YXAM1GQ1; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726838AbgCSEaL (ORCPT + 99 others); Thu, 19 Mar 2020 00:30:11 -0400 Received: from mail-wm1-f68.google.com ([209.85.128.68]:33514 "EHLO mail-wm1-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725817AbgCSEaK (ORCPT ); Thu, 19 Mar 2020 00:30:10 -0400 Received: by mail-wm1-f68.google.com with SMTP id r7so3825073wmg.0 for ; Wed, 18 Mar 2020 21:30:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=brainfault-org.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=BNG/4gsDlzID/iu3w+7gBGtdDaCICA3ZSeGXD3zpCk4=; b=YXAM1GQ1QpTkAV165dYe5R2hLUQ7NtlOJaPdIEHv4eQutWDukXGoQWco8p0IFSXu7x WTXdbLZFfC+6+MxJE1nkJEldIgRV/i/jYYEq8mD6ch/keXX8TyluN7g4fTrddvuX31wi pXWcbqNc4kEFZ6vMaF86+ybbobPrWmBn7aPm5WK4oRZZ7j88SZ3zQNcs1SQQqiy8Q7XU 09lDLm56TmcwsJIUdrAGY8GDjmQssR16AdbliMTA4vi2OiFJmqaeu3NDwIFDxth/Cbtr USrVqSkQng8XOo48I+QO604ysAX3eUtd/76DaBLY15WpsZKSF+87pDhBsnRvAmSmB6Ec gRXQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=BNG/4gsDlzID/iu3w+7gBGtdDaCICA3ZSeGXD3zpCk4=; b=PQ1UHyw1vfkxUjvLROrgCiB7Hs9s8rA6m0+AodiVtxdduE5hPkr99hyxq73FqxAp1n 5cHtgrVMuPUItn8MdQgPvdvzVFhfepNQcbNauh5uLkkOdbTUXF4pqTn+a7loLkdN9BXk tK1B7OE7UY4sypkcYs+HyWBny9NjLAPx7TEyRmL79ByZomwLrAS+towlG9SJsIl2WsZR lVDTzlrDgum6wMMur18Wx2mUIaatzKfPkt/xwJqN686joaaLNuCqEbvwD73MsFRnZoDZ 9idk3caUkFkSOEcPRcpQm2Hqt5Zxb6LbAQZzQPknX4VlsGW4CcisUyKMlP9v7EWZlCeh GQFQ== X-Gm-Message-State: ANhLgQ28zXcJ6Q9ZNLConyciyPDe2ug1NMHX7N7mSLSr10GgfS0IfRQa C5DJuOvq4SXdwGP2aeVTWt97uyixcDGdbo3niYt9y39U X-Received: by 2002:a7b:c458:: with SMTP id l24mr1229147wmi.120.1584592208974; Wed, 18 Mar 2020 21:30:08 -0700 (PDT) MIME-Version: 1.0 References: <20200310115925.126174-1-anup.patel@wdc.com> <20200310081558-mutt-send-email-mst@kernel.org> In-Reply-To: <20200310081558-mutt-send-email-mst@kernel.org> From: Anup Patel Date: Thu, 19 Mar 2020 09:59:56 +0530 Message-ID: Subject: Re: [PATCH] RISC-V: Only select essential drivers for SOC_VIRT config To: Palmer Dabbelt , Palmer Dabbelt Cc: Anup Patel , Paul Walmsley , Albert Ou , "linux-kernel@vger.kernel.org List" , Atish Patra , Alistair Francis , "Michael S. Tsirkin" , linux-riscv Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Palmer, On Tue, Mar 10, 2020 at 5:46 PM Michael S. Tsirkin wrote: > > On Tue, Mar 10, 2020 at 05:29:25PM +0530, Anup Patel wrote: > > The kconfig select causes build failues for SOC_VIRT config becaus > > we are selecting lot of VIRTIO drivers without selecting all required > > dependencies. > > > > Better approach is to only select essential drivers from SOC_VIRT > > config option and enable required VIRTIO drivers using defconfigs. > > > > Fixes: 759bdc168181 ("RISC-V: Add kconfig option for QEMU virt machine") > > Signed-off-by: Anup Patel > > Yea makes sense. > > Acked-by: Michael S. Tsirkin Can you take this fix for Linux-5.6-rc7 ? Regards, Anup > > > --- > > arch/riscv/Kconfig.socs | 14 -------------- > > arch/riscv/configs/defconfig | 16 +++++++++++++++- > > arch/riscv/configs/rv32_defconfig | 16 +++++++++++++++- > > 3 files changed, 30 insertions(+), 16 deletions(-) > > > > diff --git a/arch/riscv/Kconfig.socs b/arch/riscv/Kconfig.socs > > index 3078b2de0b2d..a131174a0a77 100644 > > --- a/arch/riscv/Kconfig.socs > > +++ b/arch/riscv/Kconfig.socs > > @@ -12,20 +12,6 @@ config SOC_SIFIVE > > > > config SOC_VIRT > > bool "QEMU Virt Machine" > > - select VIRTIO_PCI > > - select VIRTIO_BALLOON > > - select VIRTIO_MMIO > > - select VIRTIO_CONSOLE > > - select VIRTIO_NET > > - select NET_9P_VIRTIO > > - select VIRTIO_BLK > > - select SCSI_VIRTIO > > - select DRM_VIRTIO_GPU > > - select HW_RANDOM_VIRTIO > > - select RPMSG_CHAR > > - select RPMSG_VIRTIO > > - select CRYPTO_DEV_VIRTIO > > - select VIRTIO_INPUT > > select POWER_RESET_SYSCON > > select POWER_RESET_SYSCON_POWEROFF > > select GOLDFISH > > diff --git a/arch/riscv/configs/defconfig b/arch/riscv/configs/defconfig > > index c8f084203067..2557c5372a25 100644 > > --- a/arch/riscv/configs/defconfig > > +++ b/arch/riscv/configs/defconfig > > @@ -31,6 +31,7 @@ CONFIG_IP_PNP_BOOTP=y > > CONFIG_IP_PNP_RARP=y > > CONFIG_NETLINK_DIAG=y > > CONFIG_NET_9P=y > > +CONFIG_NET_9P_VIRTIO=y > > CONFIG_PCI=y > > CONFIG_PCIEPORTBUS=y > > CONFIG_PCI_HOST_GENERIC=y > > @@ -38,12 +39,15 @@ CONFIG_PCIE_XILINX=y > > CONFIG_DEVTMPFS=y > > CONFIG_DEVTMPFS_MOUNT=y > > CONFIG_BLK_DEV_LOOP=y > > +CONFIG_VIRTIO_BLK=y > > CONFIG_BLK_DEV_SD=y > > CONFIG_BLK_DEV_SR=y > > +CONFIG_SCSI_VIRTIO=y > > CONFIG_ATA=y > > CONFIG_SATA_AHCI=y > > CONFIG_SATA_AHCI_PLATFORM=y > > CONFIG_NETDEVICES=y > > +CONFIG_VIRTIO_NET=y > > CONFIG_MACB=y > > CONFIG_E1000E=y > > CONFIG_R8169=y > > @@ -54,13 +58,16 @@ CONFIG_SERIAL_8250_CONSOLE=y > > CONFIG_SERIAL_OF_PLATFORM=y > > CONFIG_SERIAL_EARLYCON_RISCV_SBI=y > > CONFIG_HVC_RISCV_SBI=y > > +CONFIG_VIRTIO_CONSOLE=y > > CONFIG_HW_RANDOM=y > > +CONFIG_HW_RANDOM_VIRTIO=y > > CONFIG_SPI=y > > CONFIG_SPI_SIFIVE=y > > # CONFIG_PTP_1588_CLOCK is not set > > CONFIG_POWER_RESET=y > > CONFIG_DRM=y > > CONFIG_DRM_RADEON=y > > +CONFIG_DRM_VIRTIO_GPU=y > > CONFIG_FRAMEBUFFER_CONSOLE=y > > CONFIG_USB=y > > CONFIG_USB_XHCI_HCD=y > > @@ -74,6 +81,12 @@ CONFIG_USB_UAS=y > > CONFIG_MMC=y > > CONFIG_MMC_SPI=y > > CONFIG_RTC_CLASS=y > > +CONFIG_VIRTIO_PCI=y > > +CONFIG_VIRTIO_BALLOON=y > > +CONFIG_VIRTIO_INPUT=y > > +CONFIG_VIRTIO_MMIO=y > > +CONFIG_RPMSG_CHAR=y > > +CONFIG_RPMSG_VIRTIO=y > > CONFIG_EXT4_FS=y > > CONFIG_EXT4_FS_POSIX_ACL=y > > CONFIG_AUTOFS4_FS=y > > @@ -88,16 +101,17 @@ CONFIG_NFS_V4_2=y > > CONFIG_ROOT_NFS=y > > CONFIG_9P_FS=y > > CONFIG_CRYPTO_USER_API_HASH=y > > +CONFIG_CRYPTO_DEV_VIRTIO=y > > CONFIG_PRINTK_TIME=y > > CONFIG_DEBUG_FS=y > > CONFIG_DEBUG_PAGEALLOC=y > > +CONFIG_SCHED_STACK_END_CHECK=y > > CONFIG_DEBUG_VM=y > > CONFIG_DEBUG_VM_PGFLAGS=y > > CONFIG_DEBUG_MEMORY_INIT=y > > CONFIG_DEBUG_PER_CPU_MAPS=y > > CONFIG_SOFTLOCKUP_DETECTOR=y > > CONFIG_WQ_WATCHDOG=y > > -CONFIG_SCHED_STACK_END_CHECK=y > > CONFIG_DEBUG_TIMEKEEPING=y > > CONFIG_DEBUG_RT_MUTEXES=y > > CONFIG_DEBUG_SPINLOCK=y > > diff --git a/arch/riscv/configs/rv32_defconfig b/arch/riscv/configs/rv32_defconfig > > index a844920a261f..0292879a9690 100644 > > --- a/arch/riscv/configs/rv32_defconfig > > +++ b/arch/riscv/configs/rv32_defconfig > > @@ -31,6 +31,7 @@ CONFIG_IP_PNP_BOOTP=y > > CONFIG_IP_PNP_RARP=y > > CONFIG_NETLINK_DIAG=y > > CONFIG_NET_9P=y > > +CONFIG_NET_9P_VIRTIO=y > > CONFIG_PCI=y > > CONFIG_PCIEPORTBUS=y > > CONFIG_PCI_HOST_GENERIC=y > > @@ -38,12 +39,15 @@ CONFIG_PCIE_XILINX=y > > CONFIG_DEVTMPFS=y > > CONFIG_DEVTMPFS_MOUNT=y > > CONFIG_BLK_DEV_LOOP=y > > +CONFIG_VIRTIO_BLK=y > > CONFIG_BLK_DEV_SD=y > > CONFIG_BLK_DEV_SR=y > > +CONFIG_SCSI_VIRTIO=y > > CONFIG_ATA=y > > CONFIG_SATA_AHCI=y > > CONFIG_SATA_AHCI_PLATFORM=y > > CONFIG_NETDEVICES=y > > +CONFIG_VIRTIO_NET=y > > CONFIG_MACB=y > > CONFIG_E1000E=y > > CONFIG_R8169=y > > @@ -54,11 +58,14 @@ CONFIG_SERIAL_8250_CONSOLE=y > > CONFIG_SERIAL_OF_PLATFORM=y > > CONFIG_SERIAL_EARLYCON_RISCV_SBI=y > > CONFIG_HVC_RISCV_SBI=y > > +CONFIG_VIRTIO_CONSOLE=y > > CONFIG_HW_RANDOM=y > > +CONFIG_HW_RANDOM_VIRTIO=y > > # CONFIG_PTP_1588_CLOCK is not set > > CONFIG_POWER_RESET=y > > CONFIG_DRM=y > > CONFIG_DRM_RADEON=y > > +CONFIG_DRM_VIRTIO_GPU=y > > CONFIG_FRAMEBUFFER_CONSOLE=y > > CONFIG_USB=y > > CONFIG_USB_XHCI_HCD=y > > @@ -70,6 +77,12 @@ CONFIG_USB_OHCI_HCD_PLATFORM=y > > CONFIG_USB_STORAGE=y > > CONFIG_USB_UAS=y > > CONFIG_RTC_CLASS=y > > +CONFIG_VIRTIO_PCI=y > > +CONFIG_VIRTIO_BALLOON=y > > +CONFIG_VIRTIO_INPUT=y > > +CONFIG_VIRTIO_MMIO=y > > +CONFIG_RPMSG_CHAR=y > > +CONFIG_RPMSG_VIRTIO=y > > CONFIG_EXT4_FS=y > > CONFIG_EXT4_FS_POSIX_ACL=y > > CONFIG_AUTOFS4_FS=y > > @@ -84,16 +97,17 @@ CONFIG_NFS_V4_2=y > > CONFIG_ROOT_NFS=y > > CONFIG_9P_FS=y > > CONFIG_CRYPTO_USER_API_HASH=y > > +CONFIG_CRYPTO_DEV_VIRTIO=y > > CONFIG_PRINTK_TIME=y > > CONFIG_DEBUG_FS=y > > CONFIG_DEBUG_PAGEALLOC=y > > +CONFIG_SCHED_STACK_END_CHECK=y > > CONFIG_DEBUG_VM=y > > CONFIG_DEBUG_VM_PGFLAGS=y > > CONFIG_DEBUG_MEMORY_INIT=y > > CONFIG_DEBUG_PER_CPU_MAPS=y > > CONFIG_SOFTLOCKUP_DETECTOR=y > > CONFIG_WQ_WATCHDOG=y > > -CONFIG_SCHED_STACK_END_CHECK=y > > CONFIG_DEBUG_TIMEKEEPING=y > > CONFIG_DEBUG_RT_MUTEXES=y > > CONFIG_DEBUG_SPINLOCK=y > > -- > > 2.17.1 > > > > >