* [PATCH] PCI: brcmstb: fix broken brcm_pcie_mdio_write() polling
@ 2024-02-17 13:37 Stefan Wahren
2024-02-17 17:27 ` Florian Fainelli
2024-03-09 17:08 ` Krzysztof Wilczyński
0 siblings, 2 replies; 6+ messages in thread
From: Stefan Wahren @ 2024-02-17 13:37 UTC (permalink / raw)
To: Jim Quinlan, Nicolas Saenz Julienne, Florian Fainelli,
Lorenzo Pieralisi, Krzysztof Wilczyński, Rob Herring,
Bjorn Helgaas, Cyril Brulebois
Cc: bcm-kernel-feedback-list, linux-pci, linux-arm-kernel,
Jonathan Bell, Stefan Wahren
From: Jonathan Bell <jonathan@raspberrypi.com>
MDIO_WR_DONE() tests bit 31, which is always 0 (==done) as
readw_poll_timeout_atomic does a 16-bit read. Replace with the readl
variant.
Fixes: ca5dcc76314d ("PCI: brcmstb: Replace status loops with read_poll_timeout_atomic()")
Signed-off-by: Jonathan Bell <jonathan@raspberrypi.com>
Signed-off-by: Stefan Wahren <wahrenst@gmx.net>
---
drivers/pci/controller/pcie-brcmstb.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/pci/controller/pcie-brcmstb.c b/drivers/pci/controller/pcie-brcmstb.c
index 618e84402eb50..a7f05e0c4ac51 100644
--- a/drivers/pci/controller/pcie-brcmstb.c
+++ b/drivers/pci/controller/pcie-brcmstb.c
@@ -420,7 +420,7 @@ static int brcm_pcie_mdio_write(void __iomem *base, u8 port,
readl(base + PCIE_RC_DL_MDIO_ADDR);
writel(MDIO_DATA_DONE_MASK | wrdata, base + PCIE_RC_DL_MDIO_WR_DATA);
- err = readw_poll_timeout_atomic(base + PCIE_RC_DL_MDIO_WR_DATA, data,
+ err = readl_poll_timeout_atomic(base + PCIE_RC_DL_MDIO_WR_DATA, data,
MDIO_WT_DONE(data), 10, 100);
return err;
}
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH] PCI: brcmstb: fix broken brcm_pcie_mdio_write() polling
2024-02-17 13:37 [PATCH] PCI: brcmstb: fix broken brcm_pcie_mdio_write() polling Stefan Wahren
@ 2024-02-17 17:27 ` Florian Fainelli
2024-03-02 9:45 ` Stefan Wahren
2024-03-09 17:08 ` Krzysztof Wilczyński
1 sibling, 1 reply; 6+ messages in thread
From: Florian Fainelli @ 2024-02-17 17:27 UTC (permalink / raw)
To: Stefan Wahren, Jim Quinlan, Nicolas Saenz Julienne,
Lorenzo Pieralisi, Krzysztof Wilczyński, Rob Herring,
Bjorn Helgaas, Cyril Brulebois
Cc: bcm-kernel-feedback-list, linux-pci, linux-arm-kernel,
Jonathan Bell
[-- Attachment #1.1: Type: text/plain, Size: 575 bytes --]
On 2/17/2024 5:37 AM, Stefan Wahren wrote:
> From: Jonathan Bell <jonathan@raspberrypi.com>
>
> MDIO_WR_DONE() tests bit 31, which is always 0 (==done) as
> readw_poll_timeout_atomic does a 16-bit read. Replace with the readl
> variant.
>
> Fixes: ca5dcc76314d ("PCI: brcmstb: Replace status loops with read_poll_timeout_atomic()")
> Signed-off-by: Jonathan Bell <jonathan@raspberrypi.com>
> Signed-off-by: Stefan Wahren <wahrenst@gmx.net>
Excellent catch! Not sure what the real world impact was.
Acked-by: Florian Fainelli <florian.fainelli@broadcom.com>
--
Florian
[-- Attachment #1.2: S/MIME Cryptographic Signature --]
[-- Type: application/pkcs7-signature, Size: 4221 bytes --]
[-- Attachment #2: Type: text/plain, Size: 176 bytes --]
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] PCI: brcmstb: fix broken brcm_pcie_mdio_write() polling
2024-02-17 17:27 ` Florian Fainelli
@ 2024-03-02 9:45 ` Stefan Wahren
2024-03-07 18:59 ` Stefan Wahren
0 siblings, 1 reply; 6+ messages in thread
From: Stefan Wahren @ 2024-03-02 9:45 UTC (permalink / raw)
To: Florian Fainelli, Jim Quinlan, Nicolas Saenz Julienne,
Lorenzo Pieralisi, Krzysztof Wilczyński, Rob Herring,
Bjorn Helgaas, Cyril Brulebois
Cc: bcm-kernel-feedback-list, linux-pci, linux-arm-kernel,
Jonathan Bell
Hi,
Am 17.02.24 um 18:27 schrieb Florian Fainelli:
>
>
> On 2/17/2024 5:37 AM, Stefan Wahren wrote:
>> From: Jonathan Bell <jonathan@raspberrypi.com>
>>
>> MDIO_WR_DONE() tests bit 31, which is always 0 (==done) as
>> readw_poll_timeout_atomic does a 16-bit read. Replace with the readl
>> variant.
>>
>> Fixes: ca5dcc76314d ("PCI: brcmstb: Replace status loops with
>> read_poll_timeout_atomic()")
>> Signed-off-by: Jonathan Bell <jonathan@raspberrypi.com>
>> Signed-off-by: Stefan Wahren <wahrenst@gmx.net>
>
> Excellent catch! Not sure what the real world impact was.
>
> Acked-by: Florian Fainelli <florian.fainelli@broadcom.com>
is there anything what prevents this patch from being applied?
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] PCI: brcmstb: fix broken brcm_pcie_mdio_write() polling
2024-03-02 9:45 ` Stefan Wahren
@ 2024-03-07 18:59 ` Stefan Wahren
2024-03-09 17:13 ` Krzysztof Wilczyński
0 siblings, 1 reply; 6+ messages in thread
From: Stefan Wahren @ 2024-03-07 18:59 UTC (permalink / raw)
To: Jim Quinlan, Nicolas Saenz Julienne, Lorenzo Pieralisi,
Krzysztof Wilczyński, Rob Herring, Bjorn Helgaas,
Cyril Brulebois
Cc: bcm-kernel-feedback-list, linux-pci, linux-arm-kernel,
Jonathan Bell, Florian Fainelli
Am 02.03.24 um 10:45 schrieb Stefan Wahren:
> Hi,
>
> Am 17.02.24 um 18:27 schrieb Florian Fainelli:
>>
>>
>> On 2/17/2024 5:37 AM, Stefan Wahren wrote:
>>> From: Jonathan Bell <jonathan@raspberrypi.com>
>>>
>>> MDIO_WR_DONE() tests bit 31, which is always 0 (==done) as
>>> readw_poll_timeout_atomic does a 16-bit read. Replace with the readl
>>> variant.
>>>
>>> Fixes: ca5dcc76314d ("PCI: brcmstb: Replace status loops with
>>> read_poll_timeout_atomic()")
>>> Signed-off-by: Jonathan Bell <jonathan@raspberrypi.com>
>>> Signed-off-by: Stefan Wahren <wahrenst@gmx.net>
>>
>> Excellent catch! Not sure what the real world impact was.
>>
>> Acked-by: Florian Fainelli <florian.fainelli@broadcom.com>
> is there anything what prevents this patch from being applied?
ping
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] PCI: brcmstb: fix broken brcm_pcie_mdio_write() polling
2024-02-17 13:37 [PATCH] PCI: brcmstb: fix broken brcm_pcie_mdio_write() polling Stefan Wahren
2024-02-17 17:27 ` Florian Fainelli
@ 2024-03-09 17:08 ` Krzysztof Wilczyński
1 sibling, 0 replies; 6+ messages in thread
From: Krzysztof Wilczyński @ 2024-03-09 17:08 UTC (permalink / raw)
To: Stefan Wahren
Cc: Jim Quinlan, Nicolas Saenz Julienne, Florian Fainelli,
Lorenzo Pieralisi, Rob Herring, Bjorn Helgaas, Cyril Brulebois,
bcm-kernel-feedback-list, linux-pci, linux-arm-kernel,
Jonathan Bell
Hello,
> MDIO_WR_DONE() tests bit 31, which is always 0 (==done) as
> readw_poll_timeout_atomic does a 16-bit read. Replace with the readl
> variant.
Applied to controller/broadcom, thank you!
[1/1] PCI: brcmstb: Fix broken brcm_pcie_mdio_write() polling
https://git.kernel.org/pci/pci/c/48389d984332
Krzysztof
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] PCI: brcmstb: fix broken brcm_pcie_mdio_write() polling
2024-03-07 18:59 ` Stefan Wahren
@ 2024-03-09 17:13 ` Krzysztof Wilczyński
0 siblings, 0 replies; 6+ messages in thread
From: Krzysztof Wilczyński @ 2024-03-09 17:13 UTC (permalink / raw)
To: Stefan Wahren
Cc: Jim Quinlan, Nicolas Saenz Julienne, Lorenzo Pieralisi,
Rob Herring, Bjorn Helgaas, Cyril Brulebois,
bcm-kernel-feedback-list, linux-pci, linux-arm-kernel,
Jonathan Bell, Florian Fainelli
Hello,
[...]
> > is there anything what prevents this patch from being applied?
> ping
Everything looks good! Apologies for the delay.
Krzysztof
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2024-03-09 17:13 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-02-17 13:37 [PATCH] PCI: brcmstb: fix broken brcm_pcie_mdio_write() polling Stefan Wahren
2024-02-17 17:27 ` Florian Fainelli
2024-03-02 9:45 ` Stefan Wahren
2024-03-07 18:59 ` Stefan Wahren
2024-03-09 17:13 ` Krzysztof Wilczyński
2024-03-09 17:08 ` Krzysztof Wilczyński
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).