From: "Krzysztof Wilczyński" <kw@linux.com>
To: Klara Modin <klarasmodin@gmail.com>
Cc: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>,
Bartosz Golaszewski <brgl@bgdev.pl>,
Bjorn Helgaas <helgaas@kernel.org>,
Bjorn Helgaas <bhelgaas@google.com>,
Bartosz Golaszewski <bartosz.golaszewski@linaro.org>,
linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org,
Dmitry Baryshkov <dmitry.baryshkov@linaro.org>,
Johan Hovold <johan+linaro@kernel.org>,
Abel Vesa <abel.vesa@linaro.org>,
Stephan Gerhold <stephan.gerhold@linaro.org>,
Srinivas Kandagatla <srinivas.kandagatla@linaro.org>,
Bjorn Andersson <bjorn.andersson@oss.qualcomm.com>,
stable+noautosel@kernel.org,
Krishna chaitanya chundru <quic_krichai@quicinc.com>
Subject: Re: [PATCH v2 2/5] PCI/pwrctl: Create pwrctl devices only if at least one power supply is present
Date: Fri, 22 Nov 2024 01:03:30 +0900 [thread overview]
Message-ID: <20241121160330.GA3239115@rocinante> (raw)
In-Reply-To: <a7b8f84d-efa6-490c-8594-84c1de9a7031@gmail.com>
Hello,
> > > > > > +bool of_pci_is_supply_present(struct device_node *np)
> > > > > > +{
> > > > > > + struct property *prop;
> > > > > > + char *supply;
> > > > > > +
> > > > > > + if (!np)
> > > > > > + return false;
> > > > >
> > > > > Why do we need to test !np here? It should always be non-NULL.
> > > > >
>
> This doesn't appear to be the case, at least on my x86 machine and on x86
> QEMU with CONFIG_OF enabled.
Thank you for testing! Much appreciated.
We've also received other signal about this, too, per:
- https://lore.kernel.org/r/673f39b0.050a0220.363a1b.0126.GAE@google.com
- https://lore.kernel.org/r/CA+G9fYurbY3B6ahZ+k+Syp5bZ3a+YQdeX8DRb6Twi4BDEFbUsw@mail.gmail.com
> > > > Right, I think this can be dropped. We check for the OF node in the
> > > > function above.
> > > >
> > >
> > > I think it was a leftover that I didn't cleanup. But I do plan to move this API
> > > to drivers/of once 6.13-rc1 is out. So even if it didn't get dropped now, I will
> > > do it later.
> >
> > I removed the NULL check directly on the branch. Thank you!
I added the NULL check back.
Krzysztof
next prev parent reply other threads:[~2024-11-21 16:03 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-10-25 7:54 [PATCH v2 0/5] PCI/pwrctl: Ensure that the pwrctl drivers are probed before PCI client drivers Manivannan Sadhasivam
2024-10-25 7:54 ` Manivannan Sadhasivam via B4 Relay
2024-10-25 7:54 ` [PATCH v2 1/5] PCI/pwrctl: Use of_platform_device_create() to create pwrctl devices Manivannan Sadhasivam
2024-10-25 7:54 ` Manivannan Sadhasivam via B4 Relay
2024-10-25 7:57 ` Bartosz Golaszewski
2024-10-25 7:54 ` [PATCH v2 2/5] PCI/pwrctl: Create pwrctl devices only if at least one power supply is present Manivannan Sadhasivam
2024-10-25 7:54 ` Manivannan Sadhasivam via B4 Relay
2024-11-06 21:28 ` Bjorn Helgaas
2024-11-07 9:52 ` Bartosz Golaszewski
2024-11-07 11:15 ` Manivannan Sadhasivam
2024-11-16 18:41 ` Krzysztof Wilczyński
2024-11-21 8:54 ` Klara Modin
2024-11-21 16:03 ` Krzysztof Wilczyński [this message]
2024-10-25 7:54 ` [PATCH v2 3/5] PCI/pwrctl: Ensure that the pwrctl drivers are probed before the PCI client drivers Manivannan Sadhasivam
2024-10-25 7:54 ` Manivannan Sadhasivam via B4 Relay
2024-11-20 16:10 ` Bjorn Helgaas
2024-11-20 17:02 ` Manivannan Sadhasivam
2024-11-20 20:18 ` Bjorn Helgaas
2024-11-21 12:00 ` Manivannan Sadhasivam
2024-11-21 18:28 ` Krzysztof Wilczyński
2024-11-21 20:14 ` Krzysztof Wilczyński
2024-10-25 7:54 ` [PATCH v2 4/5] PCI/pwrctl: Move pwrctl device creation to its own helper function Manivannan Sadhasivam
2024-10-25 7:54 ` Manivannan Sadhasivam via B4 Relay
2024-10-25 8:07 ` Bartosz Golaszewski
2024-10-25 7:54 ` [PATCH v2 5/5] PCI/pwrctl: Remove pwrctl device without iterating over all children of pwrctl parent Manivannan Sadhasivam
2024-10-25 7:54 ` Manivannan Sadhasivam via B4 Relay
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20241121160330.GA3239115@rocinante \
--to=kw@linux.com \
--cc=abel.vesa@linaro.org \
--cc=bartosz.golaszewski@linaro.org \
--cc=bhelgaas@google.com \
--cc=bjorn.andersson@oss.qualcomm.com \
--cc=brgl@bgdev.pl \
--cc=dmitry.baryshkov@linaro.org \
--cc=helgaas@kernel.org \
--cc=johan+linaro@kernel.org \
--cc=klarasmodin@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pci@vger.kernel.org \
--cc=manivannan.sadhasivam@linaro.org \
--cc=quic_krichai@quicinc.com \
--cc=srinivas.kandagatla@linaro.org \
--cc=stable+noautosel@kernel.org \
--cc=stephan.gerhold@linaro.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.