Received: by 2002:a05:6a10:17d3:0:0:0:0 with SMTP id hz19csp2991281pxb; Tue, 13 Apr 2021 15:46:25 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzBcY+k+LUWoMbzovya8rAqq2CZzbba9trQ5SC8QcT6fovrhPbL6eHsxp590PLBVyUv2ACe X-Received: by 2002:a17:906:3385:: with SMTP id v5mr34547922eja.539.1618353985588; Tue, 13 Apr 2021 15:46:25 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1618353985; cv=none; d=google.com; s=arc-20160816; b=KAXvL8CnTq6b5HqfzW92UfcCk3RQi77l7784rYSPSI2/scrnTnhS6A/kS36fvejSWB aKyfT0W/taC8aXkY1Nx2LaP/nliYF5daO82ROjcFfWrbgnWHrMiJEQ/9cow/NI3PoE9F +bYL94NTBfiiOkIUpxCjAakeD9njUIGzA6dblZ5Y1rU0en6gzMyeSE9lNibUMWsJxZuz R8Ux3AVhicGYQ0QlLfQSIysgge7EhbME5GIIdbrsFdjNPKQrB+bLlzjtxQv5s+Nsif5q G2dyttoIEp0oCS6LzGqK2JUZlJWMBgB1IJhAq+n2lnE8tXlrafCd8rWipeLo9msPYQW/ K8uA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=P2qR6BxuvyCT4kf+Cw1mtsrHskyBbpWrMzwKUFohQWI=; b=NOphM/brsZOOKzJc/B0wzX3swvTRqWkLci+zcP8xHaMCUeS7dvO7fHdVZvWCJXtTu2 RwxnnmzOazzIejCVko5vV5ttJP1qOG5juMOz/7JNRr37LWqSKupkhC1/KbBsljP8I4UY 72GJ+7krypmjoyzfFpIzW2OHk49ORxEM5yl3ov9he8aNRoUUvMU8+D7MHsu40xyR8Ltd rJUyrWmydxa6eoZbhQ32yePqmYG5lHxRdHmRN9X7U33kdMWPrdgvlXaVqFMsPU70S/cK H/X4XhzvzT66qanwoM4I9gPhuRT6f3nb26ftdtVSM3O1jE2hQe1FSB4Cro418gvaWFhk /tOw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=bEvtTnHQ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id v2si11084164edy.362.2021.04.13.15.46.02; Tue, 13 Apr 2021 15:46:25 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=bEvtTnHQ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1347590AbhDMSSD (ORCPT + 99 others); Tue, 13 Apr 2021 14:18:03 -0400 Received: from mail.kernel.org ([198.145.29.99]:49956 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238322AbhDMSSC (ORCPT ); Tue, 13 Apr 2021 14:18:02 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 35251613BA; Tue, 13 Apr 2021 18:17:42 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1618337862; bh=WnJiO8xMI84T93ixx6pdUvMpBrWgeGZXvzjBysS19Yw=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=bEvtTnHQ5UqIFlRDkZndzLIFghxt7ReVRVwQig8raE4wmg7tAFhXBmlHCYyBy/xmv bUYZ48nBTrCfmIf/56UkPJatNuYmUU9MWoEJB62HfVz9ArjYxLYVD6WNZSbkWmVprN W2ZkoChA9RIsRslNSRZBbsMbX3Bt/WfzZ+q1BYAJCtwQVKy1BTusESDxmGdlfDgz09 RmziPKFozn7sKgyatoRu7spRhAMbo9YWtPmRQpSl2PdOfzq2g2wzQQOoMNcVJ833uJ uJaE4bQSAK3xxcqSbZ9Dqvwj+KeWamta/f7u8QrxfTJLRi4ETInwQ1oLcBmrUWH9IW PQ7IOmKgzLRSw== Received: by mail-qv1-f41.google.com with SMTP id h3so7784446qve.13; Tue, 13 Apr 2021 11:17:42 -0700 (PDT) X-Gm-Message-State: AOAM530YhAt6Tf0WR3qLi/jo/b46n87AHD7nfDbTMiP621D4RUhOLnoP oDPuUp7kWiYwRK5rNDdkbPqpA+D9G/5WnI11jQ== X-Received: by 2002:a05:6214:8c4:: with SMTP id da4mr34891158qvb.57.1618337861448; Tue, 13 Apr 2021 11:17:41 -0700 (PDT) MIME-Version: 1.0 References: <20210412123936.25555-1-pali@kernel.org> In-Reply-To: <20210412123936.25555-1-pali@kernel.org> From: Rob Herring Date: Tue, 13 Apr 2021 13:17:29 -0500 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH] arm64: dts: marvell: armada-37xx: Set linux,pci-domain to zero To: =?UTF-8?Q?Pali_Roh=C3=A1r?= Cc: Andrew Lunn , Gregory Clement , Sebastian Hesselbarth , =?UTF-8?B?TWFyZWsgQmVow7pu?= , linux-arm-kernel , devicetree@vger.kernel.org, "linux-kernel@vger.kernel.org" , PCI Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Apr 12, 2021 at 7:41 AM Pali Roh=C3=A1r wrote: > > Since commit 526a76991b7b ("PCI: aardvark: Implement driver 'remove' > function and allow to build it as module") PCIe controller driver for > Armada 37xx can be dynamically loaded and unloaded at runtime. Also drive= r > allows dynamic binding and unbinding of PCIe controller device. > > Kernel PCI subsystem assigns by default dynamically allocated PCI domain > number (starting from zero) for this PCIe controller every time when devi= ce > is bound. So PCI domain changes after every unbind / bind operation. PCI host bridges as a module are relatively new, so seems likely a bug to m= e. > Alternative way for assigning PCI domain number is to use static allocate= d > numbers defined in Device Tree. This option has requirement that every PC= I > controller in system must have defined PCI bus number in Device Tree. That seems entirely pointless from a DT point of view with a single PCI bri= dge. > Armada 37xx has only one PCIe controller, so assign for it PCI domain 0 i= n > Device Tree. > > After this change PCI domain on Armada 37xx is always zero, even after > repeated unbind and bind operations. > > Signed-off-by: Pali Roh=C3=A1r > Fixes: 526a76991b7b ("PCI: aardvark: Implement driver 'remove' function a= nd allow to build it as module") > --- > arch/arm64/boot/dts/marvell/armada-37xx.dtsi | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/arch/arm64/boot/dts/marvell/armada-37xx.dtsi b/arch/arm64/bo= ot/dts/marvell/armada-37xx.dtsi > index 7a2df148c6a3..f02058ef5364 100644 > --- a/arch/arm64/boot/dts/marvell/armada-37xx.dtsi > +++ b/arch/arm64/boot/dts/marvell/armada-37xx.dtsi > @@ -495,6 +495,7 @@ > <0 0 0 2 &pcie_intc 1>, > <0 0 0 3 &pcie_intc 2>, > <0 0 0 4 &pcie_intc 3>; > + linux,pci-domain =3D <0>; > max-link-speed =3D <2>; > phys =3D <&comphy1 0>; > pcie_intc: interrupt-controller { > -- > 2.20.1 >