All of lore.kernel.org
 help / color / mirror / Atom feed
From: b.brezillon@overkiz.com (boris brezillon)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] usb: at91-udc: fix irq and iomem resource retrieval
Date: Tue, 28 Jan 2014 11:05:53 +0100	[thread overview]
Message-ID: <52E78101.3060102@overkiz.com> (raw)
In-Reply-To: <52E130FE.1070506@atmel.com>

On 23/01/2014 16:10, Nicolas Ferre wrote:
> On 23/01/2014 15:41, Jean-Jacques Hiblot :
>> When using dt resources retrieval (interrupts and reg properties) there is
>> no predefined order for these resources in the platform dev resource
>> table. Also don't expect the number of resource to be always 2.
>>
>> Signed-off-by: Jean-Jacques Hiblot <jjhiblot@traphandler.com>
Acked-by: Boris BREZILLON <b.brezillon@overkiz.com>
> Yes, indeed.
>
> Acked-by: Nicolas Ferre <nicolas.ferre@atmel.com>
>
> Maybe we can also add a "stable" tag to it. Looking at the history of
> this file, I think that we can add a pretty old stable limit... But as
> it only makes sense with DT, I would advice something like this, for the
> 3.4-ish timeframe:
>
> Cc: stable <stable@vger.kernel.org> # 3.4
>
> Bye,
>
>> ---
>>   drivers/usb/gadget/at91_udc.c | 10 ----------
>>   1 file changed, 10 deletions(-)
>>
>> diff --git a/drivers/usb/gadget/at91_udc.c b/drivers/usb/gadget/at91_udc.c
>> index 4cc4fd6..dfd2943 100644
>> --- a/drivers/usb/gadget/at91_udc.c
>> +++ b/drivers/usb/gadget/at91_udc.c
>> @@ -1710,16 +1710,6 @@ static int at91udc_probe(struct platform_device *pdev)
>>   		return -ENODEV;
>>   	}
>>   
>> -	if (pdev->num_resources != 2) {
>> -		DBG("invalid num_resources\n");
>> -		return -ENODEV;
>> -	}
>> -	if ((pdev->resource[0].flags != IORESOURCE_MEM)
>> -			|| (pdev->resource[1].flags != IORESOURCE_IRQ)) {
>> -		DBG("invalid resource type\n");
>> -		return -ENODEV;
>> -	}
>> -
>>   	res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
>>   	if (!res)
>>   		return -ENXIO;
>>
>

  reply	other threads:[~2014-01-28 10:05 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-01-23 14:41 [PATCH] usb: at91-udc: fix irq and iomem resource retrieval Jean-Jacques Hiblot
2014-01-23 15:10 ` Nicolas Ferre
2014-01-28 10:05   ` boris brezillon [this message]
2014-02-12 13:03 ` [PATCH RESEND] " Nicolas Ferre
2014-02-12 13:03   ` Nicolas Ferre
2014-03-12 14:57   ` Nicolas Ferre
2014-03-12 14:57     ` Nicolas Ferre
2014-03-12 15:31     ` Greg Kroah-Hartman
2014-03-12 15:31       ` Greg Kroah-Hartman
2014-03-12 16:28       ` Nicolas Ferre
2014-03-12 16:28         ` Nicolas Ferre
2014-03-12 16:30 ` Nicolas Ferre
2014-03-12 16:30   ` Nicolas Ferre
  -- strict thread matches above, loose matches on Subject: below --
2014-01-23 14:40 [PATCH] " Jean-Jacques Hiblot

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=52E78101.3060102@overkiz.com \
    --to=b.brezillon@overkiz.com \
    --cc=linux-arm-kernel@lists.infradead.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.