Received: by 2002:a05:7412:ba23:b0:fa:4c10:6cad with SMTP id jp35csp19578rdb; Wed, 17 Jan 2024 15:39:12 -0800 (PST) X-Google-Smtp-Source: AGHT+IHI+GkADClaGdHcs15nJhhcEBWA+rZrX8B8sIoCgWtHZx6aY++IeolzXkOwvQ8cR3K4eO89 X-Received: by 2002:a05:620a:386:b0:783:4976:7fa with SMTP id q6-20020a05620a038600b00783497607famr10350588qkm.108.1705534751999; Wed, 17 Jan 2024 15:39:11 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1705534751; cv=pass; d=google.com; s=arc-20160816; b=zmTYDRa1EymPEBR1H37H1loM5Bi1y4AXshL8C2SdFUWzAHBae1L/yxdQgBHeKlVPM6 tRlJYpG/4Pg51MFqLArSvFgiY0gZMCIzELw0hhbTAA8Vc84aqIEg9ZAtzh6PmWJgEvPz 2504xd7X1CT17OU5LOPBOEqwPbjQAtfd0cvtJRJK20TW7yYyEVa4RdCP11R2Hlr7YHuB YL/0Wd2NOZxDo3Hu+SSHVUVYzQ3aeR+4Jq+JjtWj9Uc5VewM+q8cuYtZHC+OdSh/AxNi egHFpglVagg4L5LrohTFBnO1GV84Qm8M1jL70vYWt7/jTR+4jCW+pDBkDCPOoYVc0rS/ 4wMw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:list-unsubscribe:list-subscribe :list-id:precedence:dkim-signature; bh=krii6L/fb3HusCYQ5TUDMqg3//8x3yTLZXc7/etrzfI=; fh=8MWuCN9kKCKU736DO1zhtDRzbYM35G0QA0WVmNttXc8=; b=kATp+K9cyzaj11AeDMYiRrrokzYKJRrmPRMCylM2i1r5BiDr1szZOorwaC74zGh8Q+ gRoCmmWkRuvuF0NK3ycgCrPNMbR/WFoy3s2mfYj+7B8QlvDhitJRFDGeWNICaASE6taG 4PSi48wSaZpUOcjC2n+0SnNp0ax5/vF39BuTbxQWxbIb5lqHfuHRMN5u96u8m3QH7KBd fwA0ifW34pIDSjvU0J3zWJnZfEbCnb1XUwndW6GV3oMCmFLbppCmj0Q8RJRwIFfBVPKc Hy/3Ua5Yrf1qZa7snSkB9fQV4GzXpajA4WboQ75STkTWkss9BTqBUZKXmJ0D5aFRijeW bQTw== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="P/monbzG"; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-wireless+bounces-2129-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-wireless+bounces-2129-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id pj23-20020a05620a1d9700b007832fc253b7si11981767qkn.249.2024.01.17.15.39.11 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 17 Jan 2024 15:39:11 -0800 (PST) Received-SPF: pass (google.com: domain of linux-wireless+bounces-2129-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="P/monbzG"; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-wireless+bounces-2129-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-wireless+bounces-2129-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id C04B61C21A4A for ; Wed, 17 Jan 2024 23:39:11 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 288B225620; Wed, 17 Jan 2024 23:39:02 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="P/monbzG" X-Original-To: linux-wireless@vger.kernel.org Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id CE94B28DA5; Wed, 17 Jan 2024 23:39:01 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1705534742; cv=none; b=ce/9dmsTbk1sOaVJHOchcZtmd3V29Jx9+dt2RjxkDuwu4Qnkhp3dylQeNp+Va3paJ1HnwnnwwgVua06zVQmy+bEq1fvNHTNb6KFEmYiM6hxUUWGpXlfhF3t2Rya6hv1hoxFmnkUgIzQZN9jRRWydtOJqQkdw25dSI2gnSkGfIFA= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1705534742; c=relaxed/simple; bh=GcKMmCstmmaFfeggXxTBt9vMpMX9qJbtMbVXoCROP+E=; h=Received:DKIM-Signature:Received:X-Gm-Message-State: X-Google-Smtp-Source:X-Received:MIME-Version:References: In-Reply-To:From:Date:X-Gmail-Original-Message-ID:Message-ID: Subject:To:Cc:Content-Type:Content-Transfer-Encoding; b=nsMxsDskOK0FCeiivNr9cU6L6EbfiCeoHAv1toeirCJr3dae/f+cA24THAOH2qMUiaQa4UEYSbWNqOf/6vaoawOWBSFx8SisRcTBS/7DonujZu8xbPQkTMlR29BCOit/gRMLDTnZFffo5cQEKcK1ICogLbhbChHkg4/ASaIopSg= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=P/monbzG; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 5CDDAC43394; Wed, 17 Jan 2024 23:39:01 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1705534741; bh=GcKMmCstmmaFfeggXxTBt9vMpMX9qJbtMbVXoCROP+E=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=P/monbzGlW0++yqPjaDQoZLzVooAp6kReBYDiIz8rAJmq88GF9ce70Vl4VjdzDe2k xkHbL7jN3aYVhUV29HmQCX/xqczOCzb4+sUDWjf6LhGQmLh9ju5jIRmfUVTPU5aGYv rxTicLT86DwaZcO3g1It5KdDccPNbI23bzVM/tLnLGBTEhDxS7xgJJah2/vEZWopPo qyAG9tN4JbGq39q1b6DO+Dd16PUcs616Iken9djORnqWMCl1gn0RcHNl9RaBPLwS5y 4PUKFxx29eSO4D4YW7ImRRarUAWTon3QNhmg1wsXFbfX9SgcvlsbPlCUwV8w6ciNqm cvgheWDst5x5Q== Received: by mail-ed1-f46.google.com with SMTP id 4fb4d7f45d1cf-557ad92cabbso11741034a12.0; Wed, 17 Jan 2024 15:39:01 -0800 (PST) X-Gm-Message-State: AOJu0YyushLXE8lsCDZH+3td8k1q4zoMrKHd7zWHG4FyVVs7S9ZFCU9/ IsHtFHWyhwSmzFjcEUaNrIfqe4M4tqo97bySPGKCW67XRntqTvplOfh2XzZpcSJTHVBzG9ZrJK3 E9Jt+UALcyyoFTwzWJa8TWKM4Qg== X-Received: by 2002:a05:6512:234a:b0:50e:9d91:cfb8 with SMTP id p10-20020a056512234a00b0050e9d91cfb8mr2312813lfu.187.1705534719254; Wed, 17 Jan 2024 15:38:39 -0800 (PST) Precedence: bulk X-Mailing-List: linux-wireless@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 References: <20240109144327.GA10780@wunner.de> <20240110132853.GA6860@wunner.de> <20240110164105.GA13451@wunner.de> <20240111104211.GA32504@wunner.de> <20240111150201.GA28409@wunner.de> <20240112094312.GA8704@wunner.de> In-Reply-To: <20240112094312.GA8704@wunner.de> From: Rob Herring Date: Wed, 17 Jan 2024 17:38:27 -0600 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [RFC 3/9] PCI/portdrv: create platform devices for child OF nodes To: Lukas Wunner Cc: Bartosz Golaszewski , Kalle Valo , "David S . Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Krzysztof Kozlowski , Conor Dooley , Bjorn Andersson , Konrad Dybcio , Catalin Marinas , Will Deacon , Bjorn Helgaas , Heiko Stuebner , Jernej Skrabec , Chris Morgan , Linus Walleij , Geert Uytterhoeven , Arnd Bergmann , Neil Armstrong , =?UTF-8?B?TsOtY29sYXMgRiAuIFIgLiBBIC4gUHJhZG8=?= , Marek Szyprowski , Peng Fan , Robert Richter , Dan Williams , Jonathan Cameron , Terry Bowman , Kuppuswamy Sathyanarayanan , =?UTF-8?Q?Ilpo_J=C3=A4rvinen?= , Huacai Chen , Alex Elder , Srini Kandagatla , Greg Kroah-Hartman , linux-wireless@vger.kernel.org, netdev@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-pci@vger.kernel.org, Bartosz Golaszewski Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Fri, Jan 12, 2024 at 3:43=E2=80=AFAM Lukas Wunner wrot= e: > > On Thu, Jan 11, 2024 at 05:16:45PM +0100, Bartosz Golaszewski wrote: > > On Thu, Jan 11, 2024 at 4:02???PM Lukas Wunner wrote: > > > On Wed, Jan 10, 2024 at 05:26:52PM +0100, Bartosz Golaszewski wrote: > > > > if (pci_is_bridge(dev)) > > > > of_pci_make_dev_node(dev); > > > > > > But perhaps of_pci_make_dev_node() returns immediately because: > > > > No, it was actually a no-op due to CONFIG_PCI_DYNAMIC_OF_NODES not > > being set. But this is only available if CONFIG_OF_DYNAMIC is enabled > > which requires OF_UNITTEST (!). > > > > We definitely don't need to enable dynamic OF nodes. We don't want to > > modify the DT, we want to create devices for existing nodes. > > Consider refactoring of_pci_make_dev_node() to suit your needs or > add a separate function call inside the "if (pci_is_bridge(dev))" > clause which populates the child OF nodes. The latter because of_pci_make_dev_node() has absolutely nothing to do with the issue this series solves. The uses are pretty much mutually exclusive. If we have a DT node with power related properties, there is no need to create that node because it already exists. Rob