Thread (4 messages) 4 messages, 3 authors, 2022-06-27

Re: drivers/usb/host/ehci-fsl: Fix interrupt setup in host mode.

From: Darren Stevens <hidden>
Date: 2022-06-26 20:03:04
Also in: linux-usb

Hello Sergei

On 26/06/2022, Sergei Shtylyov wrote:
Hello!

On 6/25/22 11:41 PM, Darren Stevens wrote:
quoted
In patch a1a2b7125e10 (Drop static setup of IRQ resource from DT
core) we stopped platform_get_resource() from returning the IRQ, as all
In commit a1a2b7125e10 ("Drop static setup of IRQ resource from DT core")
quoted
drivers were supposed to have switched to platform_get_irq()
Unfortunately the Freescale EHCI driver in host mode got missed. Fix
it. Also fix allocation of resources to work with current kernel.
   The basic rule (especially for the fixes) is "do one thing per patch".
I thought I'd done that, this is the minimum amount of changes that fix what changed in the specified commit. 
[...]
quoted
@@ -92,15 +89,18 @@ static int fsl_ehci_drv_probe(struct platform_device *pdev)
         goto err1;
     }
 
-    res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
-    hcd->regs = devm_ioremap_resource(&pdev->dev, res);
+    tmp = of_address_to_resource(dn, 0, &res);
   Hm, why? What does this fix?
With baseline the mouse and keyboard on our machines don't work - dmesg reports no interrupt. Fixing the interrupt detection throws a 'invalid resoure' error instead (No idea why), which these lines fix. Both problems disappear if we revert the 'fixes' patch.

Hmmm, perhaps title shoud be 'fix resource detection in host mode'?

Regards
Darren
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help