From: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
To: Manivannan Sadhasivam <mani@kernel.org>
Cc: "Manivannan Sadhasivam" <manivannan.sadhasivam@oss.qualcomm.com>,
"Lorenzo Pieralisi" <lpieralisi@kernel.org>,
"Krzysztof Wilczyński" <kwilczynski@kernel.org>,
"Rob Herring" <robh@kernel.org>,
"Bjorn Helgaas" <bhelgaas@google.com>,
linux-arm-msm@vger.kernel.org, linux-pci@vger.kernel.org,
linux-kernel@vger.kernel.org, "Johan Hovold" <johan@kernel.org>,
"Krishna Chaitanya Chundru" <krishna.chundru@oss.qualcomm.com>
Subject: Re: [PATCH 2/2] PCI: qcom: Move qcom_pcie_icc_opp_update() to notifier callback
Date: Tue, 15 Jul 2025 12:45:36 +0200 [thread overview]
Message-ID: <55f2e014-044c-4021-8b01-99bdf2a0fd7f@oss.qualcomm.com> (raw)
In-Reply-To: <jdnjyvw2kkos44unooy5ooix3yn2644r4yvtmekoyk2uozjvo5@atigu3wjikss>
On 7/15/25 12:36 PM, Manivannan Sadhasivam wrote:
> On Tue, Jul 15, 2025 at 11:54:48AM GMT, Konrad Dybcio wrote:
>> On 7/14/25 8:01 PM, Manivannan Sadhasivam wrote:
>>> It allows us to group all the settings that need to be done when a PCI
>>> device is attached to the bus in a single place.
>>>
>>> Signed-off-by: Manivannan Sadhasivam <manivannan.sadhasivam@oss.qualcomm.com>
>>> ---
>>> drivers/pci/controller/dwc/pcie-qcom.c | 3 +--
>>> 1 file changed, 1 insertion(+), 2 deletions(-)
>>>
>>> diff --git a/drivers/pci/controller/dwc/pcie-qcom.c b/drivers/pci/controller/dwc/pcie-qcom.c
>>> index b4993642ed90915299e825e47d282b8175a78346..b364977d78a2c659f65f0f12ce4274601d20eaa6 100644
>>> --- a/drivers/pci/controller/dwc/pcie-qcom.c
>>> +++ b/drivers/pci/controller/dwc/pcie-qcom.c
>>> @@ -1616,8 +1616,6 @@ static irqreturn_t qcom_pcie_global_irq_thread(int irq, void *data)
>>> pci_lock_rescan_remove();
>>> pci_rescan_bus(pp->bridge->bus);
>>> pci_unlock_rescan_remove();
>>> -
>>> - qcom_pcie_icc_opp_update(pcie);
>>> } else {
>>> dev_WARN_ONCE(dev, 1, "Received unknown event. INT_STATUS: 0x%08x\n",
>>> status);
>>> @@ -1765,6 +1763,7 @@ static int pcie_qcom_notify(struct notifier_block *nb, unsigned long action,
>>> switch (action) {
>>> case BUS_NOTIFY_BIND_DRIVER:
>>> qcom_pcie_enable_aspm(pdev);
>>> + qcom_pcie_icc_opp_update(pcie);
>>
>> So I assume that we're not exactly going to do much with the device if
>> there isn't a driver for it, but I have concerns that since the link
>> would already be established(?), the icc vote may be too low, especially
>> if the user uses something funky like UIO
>>
>
> Hmm, that's a good point. Not enabling ASPM wouldn't have much consequence, but
> not updating OPP would be.
>
> Let me think of other ways to call these two APIs during the device addition. If
> there are no sane ways, I'll drop *this* patch.
Would it be too naive to assume BUS_NOTIFY_ADD_DEVICE is a good fit? Do
ASPM setting need to be reapplied after the PCIe device is reset? (well
I would assume there are probably multiple levels of "reset" :/)
Konrad
next prev parent reply other threads:[~2025-07-15 10:45 UTC|newest]
Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-07-14 18:01 [PATCH 0/2] PCI: qcom: Switch to bus notifier for enabling ASPM of PCI devices Manivannan Sadhasivam
2025-07-14 18:01 ` [PATCH 1/2] " Manivannan Sadhasivam
2025-07-15 7:48 ` Johan Hovold
2025-07-15 9:11 ` Manivannan Sadhasivam
2025-07-15 9:33 ` Johan Hovold
2025-07-15 9:46 ` Konrad Dybcio
2025-07-15 10:27 ` Manivannan Sadhasivam
2025-07-15 12:31 ` Johan Hovold
2025-07-21 9:32 ` Johan Hovold
2025-07-21 10:56 ` Manivannan Sadhasivam
2025-07-21 12:49 ` Johan Hovold
2025-07-21 15:45 ` Manivannan Sadhasivam
2025-07-14 18:01 ` [PATCH 2/2] PCI: qcom: Move qcom_pcie_icc_opp_update() to notifier callback Manivannan Sadhasivam
2025-07-15 7:51 ` Johan Hovold
2025-07-15 9:13 ` Manivannan Sadhasivam
2025-07-15 9:54 ` Konrad Dybcio
2025-07-15 10:36 ` Manivannan Sadhasivam
2025-07-15 10:45 ` Konrad Dybcio [this message]
2025-07-16 5:28 ` Manivannan Sadhasivam
2025-07-16 10:33 ` Konrad Dybcio
2025-07-21 9:15 ` Johan Hovold
2025-07-16 4:54 ` Krishna Chaitanya Chundru
2025-07-16 6:46 ` Manivannan Sadhasivam
2025-07-16 6:53 ` Krishna Chaitanya Chundru
2025-07-16 7:18 ` Manivannan Sadhasivam
2025-07-21 9:02 ` Johan Hovold
2025-07-21 10:59 ` Manivannan Sadhasivam
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=55f2e014-044c-4021-8b01-99bdf2a0fd7f@oss.qualcomm.com \
--to=konrad.dybcio@oss.qualcomm.com \
--cc=bhelgaas@google.com \
--cc=johan@kernel.org \
--cc=krishna.chundru@oss.qualcomm.com \
--cc=kwilczynski@kernel.org \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pci@vger.kernel.org \
--cc=lpieralisi@kernel.org \
--cc=mani@kernel.org \
--cc=manivannan.sadhasivam@oss.qualcomm.com \
--cc=robh@kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®