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=-12.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS 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 270F3C43462 for ; Mon, 10 May 2021 07:06:11 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 02BB861433 for ; Mon, 10 May 2021 07:06:10 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230138AbhEJHHN (ORCPT ); Mon, 10 May 2021 03:07:13 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49032 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229863AbhEJHHM (ORCPT ); Mon, 10 May 2021 03:07:12 -0400 Received: from mail-qk1-x72d.google.com (mail-qk1-x72d.google.com [IPv6:2607:f8b0:4864:20::72d]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2906AC061573; Mon, 10 May 2021 00:06:08 -0700 (PDT) Received: by mail-qk1-x72d.google.com with SMTP id x8so14450158qkl.2; Mon, 10 May 2021 00:06:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=fzTT8AwhXbeiIYIpohTCJBhuBfkrqXpqL4kJl6Kq54k=; b=DT1uy1DD9S7nDKl3io2POX2p5LuML0vt3UgrOTE5L7JX6FteKVmgGE19npte0LBxcQ q6M6Bul+wVvNGgGK3J+xiPGp96Q8OORbvTnKC3jWvZU5OWwQPloapOqMZTg96RnjbBkM 9jHTO+gvJHNEPiDSAyrwiUnRSkho5uS+MhGf5bK9SGpQTQSrOgwXlTw4Exa7gfnSM1TP QpGnbeH51qT0Wwaiib7j4f01uLAc09HkXMMx+e9BNm5Odsw/bQy1BnQZTRkn61Qovb/V +3kLufDufVZcAN3PYQtYCbRVOW8kvEjXP2WHv10Q2VavDIBwkCXP2DKh4d7v+cmga9tc fXuQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=fzTT8AwhXbeiIYIpohTCJBhuBfkrqXpqL4kJl6Kq54k=; b=GUsZdBeEWXZYj3/ZCLwhCzyaGsX+Lsl47VdIe/hvn58LmVaERtCtREByJG5YjknKtP svS2R0lFHiud34ykRT9jOHhpgIbd5zD5RhiqsSIYJ6j15oeD02X2TTAZTg38vVp8lP3g JZJ+VpSylJFepJk4K9D83jXDDUU70f7GrH0UTMbd2do8E268HGOJaE45FFX1LeOpzgSf OzMqoObk8n+q36cV9pYsSVDtgwR+yjjlXevZSQVsoUjDI1Dfpiayk0b5pjv55SJqws5B 810DM58QmRkvT9eDGT0mwsSumRRpGRcT2XuiB3rtEo1DgmyJw2HxkwgxdBxeDGKti6V1 eUTw== X-Gm-Message-State: AOAM531Lk1VsMrnTZejx3lohDYR5yPlkRDZb9IymDhuAH1WgQPSK+WG8 b9VjdB7wV5iPSxCtTo39QY0= X-Google-Smtp-Source: ABdhPJxhQXzrpH8zO78pv7hLAsgTKinweWYxNRxTYL8Ec6U/DGsZ0Z+qzfVKb84OjWeQTXV7ce05kw== X-Received: by 2002:a37:ea12:: with SMTP id t18mr20335056qkj.41.1620630367365; Mon, 10 May 2021 00:06:07 -0700 (PDT) Received: from auth1-smtp.messagingengine.com (auth1-smtp.messagingengine.com. [66.111.4.227]) by smtp.gmail.com with ESMTPSA id o10sm9380679qki.72.2021.05.10.00.06.06 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 10 May 2021 00:06:06 -0700 (PDT) Received: from compute3.internal (compute3.nyi.internal [10.202.2.43]) by mailauth.nyi.internal (Postfix) with ESMTP id 2FD3327C0054; Mon, 10 May 2021 03:06:06 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute3.internal (MEProxy); Mon, 10 May 2021 03:06:06 -0400 X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduledrvdegjedgudduvdcutefuodetggdotefrod ftvfcurfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfgh necuuegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmd enucfjughrpeffhffvuffkfhggtggujgesthdtredttddtvdenucfhrhhomhepuehoqhhu nhcuhfgvnhhguceosghoqhhunhdrfhgvnhhgsehgmhgrihhlrdgtohhmqeenucggtffrrg htthgvrhhnpedvleeigedugfegveejhfejveeuveeiteejieekvdfgjeefudehfefhgfeg vdegjeenucfkphepudefuddruddtjedruddrvdehgeenucevlhhushhtvghrufhiiigvpe dtnecurfgrrhgrmhepmhgrihhlfhhrohhmpegsohhquhhnodhmvghsmhhtphgruhhthhhp vghrshhonhgrlhhithihqdeiledvgeehtdeigedqudejjeekheehhedvqdgsohhquhhnrd hfvghngheppehgmhgrihhlrdgtohhmsehfihigmhgvrdhnrghmvg X-ME-Proxy: Received: from localhost (unknown [131.107.1.254]) by mail.messagingengine.com (Postfix) with ESMTPA; Mon, 10 May 2021 03:06:01 -0400 (EDT) Date: Mon, 10 May 2021 15:04:49 +0800 From: Boqun Feng To: Bjorn Helgaas Cc: Bjorn Helgaas , Arnd Bergmann , Marc Zyngier , Russell King , Andrew Lunn , Sebastian Hesselbarth , Gregory Clement , Catalin Marinas , Will Deacon , Thomas Bogendoerfer , Lorenzo Pieralisi , Rob Herring , "K. Y. Srinivasan" , Haiyang Zhang , Stephen Hemminger , Wei Liu , Thomas Petazzoni , Mike Rapoport , Robin Murphy , Thomas Gleixner , Jon Derrick , Sunil Muthuswamy , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-mips@vger.kernel.org, linux-pci@vger.kernel.org, linux-hyperv@vger.kernel.org Subject: Re: [RFC v2 6/7] PCI: arm64: Allow pci_config_window::parent to be NULL Message-ID: References: <20210503144635.2297386-7-boqun.feng@gmail.com> <20210506222530.GA1441653@bjorn-Precision-5520> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210506222530.GA1441653@bjorn-Precision-5520> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, May 06, 2021 at 05:25:30PM -0500, Bjorn Helgaas wrote: > Make your subject something like this so it matches previous practice: > > arm64: PCI: ... > Got it. > The "::" notation probably comes from C++, but doesn't really apply in > C. In C, we would say "cfg.parent" or "cfg->parent". > > But pci_config_window and cfg->parent are probably too low-level for > the subject anyway. Seems like it should mention Hyper-V, for > instance. > I'm going to make the title something like: arm64: PCI: Support root bridge preparation for Hyper-V PCI works for you? Also I will add comment inside the function as explanation. > On Mon, May 03, 2021 at 10:46:34PM +0800, Boqun Feng wrote: > > This is purely a hack, for ARM64 Hyper-V guest, there is no > > corresponding ACPI device for the root bridge, so the best we can > > provide is an all-zeroed pci_config_window, and in this case make > > pcibios_root_bridge_prepare() act as the ACPI device is NULL. > > Why is there no ACPI device? Is this a needless arch dependency? Or > is this related to using DT instead of ACPI? > For Hyper-V virtual PCI host bridges, neither DT or ACPI is used to describe them, a hypervisor-specific mechanism (VMBus) is used to enumerate PCI host bridges. So actually on x86, Hyper-V PCI host bridge's ACPI companion is set as NULL. > The cover letter hints that this might be related to > PCI_DOMAINS_GENERIC=y, but that doesn't sound like a very convincing > reason (and the cover letter can provide an overview, but the commit > logs of individual patches shouldn't assume knowledge of the cover > letter). > Ok, I will add a better explanation in the commit log in the next version. Thanks! Regards, Boqun > > Signed-off-by: Boqun Feng > > --- > > arch/arm64/kernel/pci.c | 2 +- > > 1 file changed, 1 insertion(+), 1 deletion(-) > > > > diff --git a/arch/arm64/kernel/pci.c b/arch/arm64/kernel/pci.c > > index e9a6eeb6a694..f159df903ccb 100644 > > --- a/arch/arm64/kernel/pci.c > > +++ b/arch/arm64/kernel/pci.c > > @@ -83,7 +83,7 @@ int pcibios_root_bridge_prepare(struct pci_host_bridge *bridge) > > { > > if (!acpi_disabled) { > > struct pci_config_window *cfg = bridge->bus->sysdata; > > - struct acpi_device *adev = to_acpi_device(cfg->parent); > > + struct acpi_device *adev = cfg->parent ? to_acpi_device(cfg->parent) : NULL; > > struct device *bus_dev = &bridge->bus->dev; > > > > ACPI_COMPANION_SET(&bridge->dev, adev); > > -- > > 2.30.2 > > 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=-10.8 required=3.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED,DKIM_SIGNED,DKIM_VALID,FREEMAIL_FORGED_FROMDOMAIN, FREEMAIL_FROM,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS 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 89618C433B4 for ; Mon, 10 May 2021 07:07:52 +0000 (UTC) Received: from desiato.infradead.org (desiato.infradead.org [90.155.92.199]) (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 DEAC26101B for ; Mon, 10 May 2021 07:07:51 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org DEAC26101B Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=desiato.20200630; h=Sender:Content-Transfer-Encoding :Content-Type:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References:Message-ID: Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=OA6zGRpnlu7snbIHtKWhryM1nWJT9nI6cuvrsnAsCFQ=; b=Hn7+2k7A7J1FuF2BtJrY7gJ06 AR1LzXoGi2tEcEkttqhWZLPiLtKmBvnpnsHN3DMILZ2zUbGb3oSQJtC5jIYsZJzn6uhpY4OTymQVm 1uVVuUB+GTo29wETu1OeX7/TirYuxpPRzRni476qjz/GL51NYqgVKlMGn8SevOoXyC+yUrh4g4Zb5 97YgAi18ijlqoVwt2NM2mE4/E8dUdxsfBlS6M+bkBQ52s+3nM6qOO3aXSzOG6yQXYSL/CbnTA3TQP O2APDkwkWOrfONxxWWnBLPS3S0suhOCmkxZSP2xmCz4BXIyPIW4G3SN/xxAkxblgrEmkwN0+w5MDp 4A7HHD6MQ==; Received: from localhost ([::1] helo=desiato.infradead.org) by desiato.infradead.org with esmtp (Exim 4.94 #2 (Red Hat Linux)) id 1lfzzb-00DS0w-6d; Mon, 10 May 2021 07:06:15 +0000 Received: from bombadil.infradead.org ([2607:7c80:54:e::133]) by desiato.infradead.org with esmtps (Exim 4.94 #2 (Red Hat Linux)) id 1lfzzY-00DS0I-0x for linux-arm-kernel@desiato.infradead.org; Mon, 10 May 2021 07:06:12 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=In-Reply-To:Content-Type:MIME-Version :References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=fzTT8AwhXbeiIYIpohTCJBhuBfkrqXpqL4kJl6Kq54k=; b=L90yg/D1/2Jedo9iqOSDhTpveV vePMQ30MgCPUT2sJoHissPghd4xe2pwJsW37ZqNkMgUDxOwVHg7RrTp9kTGrR6EaELFz9xwBy5LQY PXw4do0b/le4CGWKukY9LVhxToA/hQ3TWCDpvQqx5MZheBJUe48LrxjwFQezRcdaZjk+qWMf4kfTp 61aACuSFzVe/NZVyCEMirfrs/C0G4AW5VjgzLIwH/j3gQbKFEB0p7tiNpjSU4IDBpGmZpTZMVcM6B PNLJ6tCG5+CqVrDMwQDTkpzWBepoAocOa6Zm697n46C4blzN2FabDd0HUOBWSe9MnRA32I9BGipKg TV3JVdkg==; Received: from mail-qk1-x72d.google.com ([2607:f8b0:4864:20::72d]) by bombadil.infradead.org with esmtps (Exim 4.94 #2 (Red Hat Linux)) id 1lfzzV-008MRp-3a for linux-arm-kernel@lists.infradead.org; Mon, 10 May 2021 07:06:10 +0000 Received: by mail-qk1-x72d.google.com with SMTP id a2so14407510qkh.11 for ; Mon, 10 May 2021 00:06:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=fzTT8AwhXbeiIYIpohTCJBhuBfkrqXpqL4kJl6Kq54k=; b=DT1uy1DD9S7nDKl3io2POX2p5LuML0vt3UgrOTE5L7JX6FteKVmgGE19npte0LBxcQ q6M6Bul+wVvNGgGK3J+xiPGp96Q8OORbvTnKC3jWvZU5OWwQPloapOqMZTg96RnjbBkM 9jHTO+gvJHNEPiDSAyrwiUnRSkho5uS+MhGf5bK9SGpQTQSrOgwXlTw4Exa7gfnSM1TP QpGnbeH51qT0Wwaiib7j4f01uLAc09HkXMMx+e9BNm5Odsw/bQy1BnQZTRkn61Qovb/V +3kLufDufVZcAN3PYQtYCbRVOW8kvEjXP2WHv10Q2VavDIBwkCXP2DKh4d7v+cmga9tc fXuQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=fzTT8AwhXbeiIYIpohTCJBhuBfkrqXpqL4kJl6Kq54k=; b=SZoPkXHcqOJ1VMiCn1Xb0k3Tl+x7GupYCr5WQpBKtdzQh3FJEIdJW90BDwmAKJ3hv4 uDfZGIY7gaiCKl8voeZzyDKAJDiMt6+VkaooPFS7pPKXPgwFTCo6crXpXUoyGZxg7lZD v2PzWPWTEPGNUK4Rkdxsl1+ttBIYcWmDKIH4OoCZNJ4XtyaKKQeIgYlcFz0dlppB31vi A7gs3Dq9ycRYtFx8PQFdzWi2uk7SZgM9yJXWnpdmUrbH8SubjB0yKewvv9KkrkxgVtgM ij7Qf1ip9swWI44DIOrddmotSjVHnmWbaXeGFDjrdKaqBdDHrYUz/cR/+aQrsdYS1gUp YEvw== X-Gm-Message-State: AOAM531TnzAWGmlcltr7lwCJ2LUxPucgpKCHUsCKuPt0VuN6YXggin0w wGSTuRKDZu7rxpyZGBkos3E= X-Google-Smtp-Source: ABdhPJxhQXzrpH8zO78pv7hLAsgTKinweWYxNRxTYL8Ec6U/DGsZ0Z+qzfVKb84OjWeQTXV7ce05kw== X-Received: by 2002:a37:ea12:: with SMTP id t18mr20335056qkj.41.1620630367365; Mon, 10 May 2021 00:06:07 -0700 (PDT) Received: from auth1-smtp.messagingengine.com (auth1-smtp.messagingengine.com. [66.111.4.227]) by smtp.gmail.com with ESMTPSA id o10sm9380679qki.72.2021.05.10.00.06.06 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 10 May 2021 00:06:06 -0700 (PDT) Received: from compute3.internal (compute3.nyi.internal [10.202.2.43]) by mailauth.nyi.internal (Postfix) with ESMTP id 2FD3327C0054; Mon, 10 May 2021 03:06:06 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute3.internal (MEProxy); Mon, 10 May 2021 03:06:06 -0400 X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduledrvdegjedgudduvdcutefuodetggdotefrod ftvfcurfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfgh necuuegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmd enucfjughrpeffhffvuffkfhggtggujgesthdtredttddtvdenucfhrhhomhepuehoqhhu nhcuhfgvnhhguceosghoqhhunhdrfhgvnhhgsehgmhgrihhlrdgtohhmqeenucggtffrrg htthgvrhhnpedvleeigedugfegveejhfejveeuveeiteejieekvdfgjeefudehfefhgfeg vdegjeenucfkphepudefuddruddtjedruddrvdehgeenucevlhhushhtvghrufhiiigvpe dtnecurfgrrhgrmhepmhgrihhlfhhrohhmpegsohhquhhnodhmvghsmhhtphgruhhthhhp vghrshhonhgrlhhithihqdeiledvgeehtdeigedqudejjeekheehhedvqdgsohhquhhnrd hfvghngheppehgmhgrihhlrdgtohhmsehfihigmhgvrdhnrghmvg X-ME-Proxy: Received: from localhost (unknown [131.107.1.254]) by mail.messagingengine.com (Postfix) with ESMTPA; Mon, 10 May 2021 03:06:01 -0400 (EDT) Date: Mon, 10 May 2021 15:04:49 +0800 From: Boqun Feng To: Bjorn Helgaas Cc: Bjorn Helgaas , Arnd Bergmann , Marc Zyngier , Russell King , Andrew Lunn , Sebastian Hesselbarth , Gregory Clement , Catalin Marinas , Will Deacon , Thomas Bogendoerfer , Lorenzo Pieralisi , Rob Herring , "K. Y. Srinivasan" , Haiyang Zhang , Stephen Hemminger , Wei Liu , Thomas Petazzoni , Mike Rapoport , Robin Murphy , Thomas Gleixner , Jon Derrick , Sunil Muthuswamy , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-mips@vger.kernel.org, linux-pci@vger.kernel.org, linux-hyperv@vger.kernel.org Subject: Re: [RFC v2 6/7] PCI: arm64: Allow pci_config_window::parent to be NULL Message-ID: References: <20210503144635.2297386-7-boqun.feng@gmail.com> <20210506222530.GA1441653@bjorn-Precision-5520> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20210506222530.GA1441653@bjorn-Precision-5520> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210510_000609_198930_04C5DB75 X-CRM114-Status: GOOD ( 32.32 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Thu, May 06, 2021 at 05:25:30PM -0500, Bjorn Helgaas wrote: > Make your subject something like this so it matches previous practice: > > arm64: PCI: ... > Got it. > The "::" notation probably comes from C++, but doesn't really apply in > C. In C, we would say "cfg.parent" or "cfg->parent". > > But pci_config_window and cfg->parent are probably too low-level for > the subject anyway. Seems like it should mention Hyper-V, for > instance. > I'm going to make the title something like: arm64: PCI: Support root bridge preparation for Hyper-V PCI works for you? Also I will add comment inside the function as explanation. > On Mon, May 03, 2021 at 10:46:34PM +0800, Boqun Feng wrote: > > This is purely a hack, for ARM64 Hyper-V guest, there is no > > corresponding ACPI device for the root bridge, so the best we can > > provide is an all-zeroed pci_config_window, and in this case make > > pcibios_root_bridge_prepare() act as the ACPI device is NULL. > > Why is there no ACPI device? Is this a needless arch dependency? Or > is this related to using DT instead of ACPI? > For Hyper-V virtual PCI host bridges, neither DT or ACPI is used to describe them, a hypervisor-specific mechanism (VMBus) is used to enumerate PCI host bridges. So actually on x86, Hyper-V PCI host bridge's ACPI companion is set as NULL. > The cover letter hints that this might be related to > PCI_DOMAINS_GENERIC=y, but that doesn't sound like a very convincing > reason (and the cover letter can provide an overview, but the commit > logs of individual patches shouldn't assume knowledge of the cover > letter). > Ok, I will add a better explanation in the commit log in the next version. Thanks! Regards, Boqun > > Signed-off-by: Boqun Feng > > --- > > arch/arm64/kernel/pci.c | 2 +- > > 1 file changed, 1 insertion(+), 1 deletion(-) > > > > diff --git a/arch/arm64/kernel/pci.c b/arch/arm64/kernel/pci.c > > index e9a6eeb6a694..f159df903ccb 100644 > > --- a/arch/arm64/kernel/pci.c > > +++ b/arch/arm64/kernel/pci.c > > @@ -83,7 +83,7 @@ int pcibios_root_bridge_prepare(struct pci_host_bridge *bridge) > > { > > if (!acpi_disabled) { > > struct pci_config_window *cfg = bridge->bus->sysdata; > > - struct acpi_device *adev = to_acpi_device(cfg->parent); > > + struct acpi_device *adev = cfg->parent ? to_acpi_device(cfg->parent) : NULL; > > struct device *bus_dev = &bridge->bus->dev; > > > > ACPI_COMPANION_SET(&bridge->dev, adev); > > -- > > 2.30.2 > > _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel