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=-8.2 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS, URIBL_BLOCKED,USER_AGENT_SANE_2 autolearn=ham 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 F3482C2D0DB for ; Mon, 27 Jan 2020 18:08:12 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id C14E62087F for ; Mon, 27 Jan 2020 18:08:12 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726205AbgA0SIL (ORCPT ); Mon, 27 Jan 2020 13:08:11 -0500 Received: from foss.arm.com ([217.140.110.172]:47822 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726173AbgA0SIL (ORCPT ); Mon, 27 Jan 2020 13:08:11 -0500 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 2832A30E; Mon, 27 Jan 2020 10:08:11 -0800 (PST) Received: from donnerap.cambridge.arm.com (usa-sjc-imap-foss1.foss.arm.com [10.121.207.14]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 1F2023F67D; Mon, 27 Jan 2020 10:08:10 -0800 (PST) Date: Mon, 27 Jan 2020 18:08:07 +0000 From: Andre Przywara To: Alexandru Elisei Cc: kvm@vger.kernel.org, will@kernel.org, julien.thierry.kdev@gmail.com, sami.mujawar@arm.com, lorenzo.pieralisi@arm.com, maz@kernel.org Subject: Re: [PATCH v2 kvmtool 06/30] arm/pci: Advertise only PCI bus 0 in the DT Message-ID: <20200127180807.3fd3162b@donnerap.cambridge.arm.com> In-Reply-To: <20200123134805.1993-7-alexandru.elisei@arm.com> References: <20200123134805.1993-1-alexandru.elisei@arm.com> <20200123134805.1993-7-alexandru.elisei@arm.com> Organization: ARM X-Mailer: Claws Mail 3.17.3 (GTK+ 2.24.32; aarch64-unknown-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: kvm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org On Thu, 23 Jan 2020 13:47:41 +0000 Alexandru Elisei wrote: Hi, > The "bus-range" property encodes the PCI bus number of the PCI > controller and the largest bus number of any PCI buses that are > subordinate to this node [1]. kvmtool emulates only PCI bus 0. I am wondering if that ever becomes a limitation, but in the current context it looks like the right thing to do. > Advertise this in the PCI DT node by setting "bus-range" to <0,0>. > > [1] IEEE Std 1275-1994, Section 3 "Bus Nodes Properties and Methods" > > Signed-off-by: Alexandru Elisei Reviewed-by: Andre Przywara Cheers, Andre > --- > arm/pci.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/arm/pci.c b/arm/pci.c > index 557cfa98938d..ed325fa4a811 100644 > --- a/arm/pci.c > +++ b/arm/pci.c > @@ -30,7 +30,7 @@ void pci__generate_fdt_nodes(void *fdt) > struct of_interrupt_map_entry irq_map[OF_PCI_IRQ_MAP_MAX]; > unsigned nentries = 0; > /* Bus range */ > - u32 bus_range[] = { cpu_to_fdt32(0), cpu_to_fdt32(1), }; > + u32 bus_range[] = { cpu_to_fdt32(0), cpu_to_fdt32(0), }; > /* Configuration Space */ > u64 cfg_reg_prop[] = { cpu_to_fdt64(KVM_PCI_CFG_AREA), > cpu_to_fdt64(ARM_PCI_CFG_SIZE), };