[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <559D3724.9040806@ti.com>
Date: Wed, 8 Jul 2015 17:43:48 +0300
From: Roger Quadros <rogerq@...com>
To: Sergei Shtylyov <sergei.shtylyov@...entembedded.com>,
<balbi@...com>
CC: <tony@...mide.com>, <Joao.Pinto@...opsys.com>,
<linux-usb@...r.kernel.org>, <linux-kernel@...r.kernel.org>,
<linux-omap@...r.kernel.org>
Subject: Re: [PATCH v3 4/9] usb: dwc3: core: Adapt to named interrupts
Hi,
On 08/07/15 16:06, Sergei Shtylyov wrote:
> Hello.
>
> On 7/8/2015 1:36 PM, Roger Quadros wrote:
>
>> From: Felipe Balbi <balbi@...com>
>
>> Add support to use interrupt names,
>
>> Following are the interrupt names
>
>> Peripheral Interrupt - peripheral
>> HOST Interrupt - host
>> OTG Interrupt - otg
>
>> [Roger Q]
>> - If any of these are missing we use the
>> first available IRQ resource so that we don't
>> break with older DTBs.
>
>> - Use gadget_irq in gadget driver.
>
>> Signed-off-by: Felipe Balbi <balbi@...com>
>> Signed-off-by: Roger Quadros <rogerq@...com>
>> ---
>> drivers/usb/dwc3/core.c | 12 ++++++++++++
>> drivers/usb/dwc3/core.h | 7 +++++++
>> drivers/usb/dwc3/gadget.c | 2 +-
>> 3 files changed, 20 insertions(+), 1 deletion(-)
>
>> diff --git a/drivers/usb/dwc3/core.c b/drivers/usb/dwc3/core.c
>> index a7498e0..7b33d7b 100644
>> --- a/drivers/usb/dwc3/core.c
>> +++ b/drivers/usb/dwc3/core.c
>> @@ -941,6 +941,18 @@ static int dwc3_probe(struct platform_device *pdev)
>> dwc->xhci_resources[1].flags = res->flags;
>> dwc->xhci_resources[1].name = res->name;
>>
>> + dwc->otg_irq = platform_get_irq_byname(pdev, "otg");
>> + if (!dwc->otg_irq)
>
> The usual mistake repeated again: that function reutrns error # on failure, not 0.
>
>> + dwc->otg_irq = res->start;
>> +
>> + dwc->gadget_irq = platform_get_irq_byname(pdev, "peripheral");
>> + if (!dwc->gadget_irq)
>> + dwc->gadget_irq = res->start;
>
> Likewise.
>
>> +
>> + dwc->xhci_irq = platform_get_irq_byname(pdev, "host");
>> + if (!dwc->xhci_irq)
>
> Likewise.
Right. I'll fix it up. Thanks.
cheers,
-roger
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists