On Wed, Oct 29, 2014 at 09:30:14PM +0530, Varka Bhadram wrote: > From: Varka Bhadram <varkabhadram@xxxxxxxxx> > > Sanity check on resource happening with devm_ioremap_resource(). > > Signed-off-by: Varka Bhadram <varkab@xxxxxxx> next time, use scripts/get_maintainer.pl. It would tell you I maintain dwc3, musb and the gadget framework. I should also be Cced for renesas and dwc2 since those also come through my tree. > --- > drivers/usb/dwc3/core.c | 19 +++++++------------ > 1 file changed, 7 insertions(+), 12 deletions(-) > > diff --git a/drivers/usb/dwc3/core.c b/drivers/usb/dwc3/core.c > index b0f4d52..c9ccac9 100644 > --- a/drivers/usb/dwc3/core.c > +++ b/drivers/usb/dwc3/core.c > @@ -655,10 +655,13 @@ static int dwc3_probe(struct platform_device *pdev) > dwc->xhci_resources[1].name = res->name; > > res = platform_get_resource(pdev, IORESOURCE_MEM, 0); > - if (!res) { > - dev_err(dev, "missing memory resource\n"); > - return -ENODEV; > - } > + /* > + * Request memory region but exclude xHCI regs, > + * since it will be requested by the xhci-plat driver. > + */ > + regs = devm_ioremap_resource(dev, res); > + if (IS_ERR(regs)) > + return PTR_ERR(regs); > > dwc->xhci_resources[0].start = res->start; > dwc->xhci_resources[0].end = dwc->xhci_resources[0].start + > @@ -668,14 +671,6 @@ static int dwc3_probe(struct platform_device *pdev) > > res->start += DWC3_GLOBALS_REGS_START; > > - /* > - * Request memory region but exclude xHCI regs, > - * since it will be requested by the xhci-plat driver. > - */ > - regs = devm_ioremap_resource(dev, res); > - if (IS_ERR(regs)) > - return PTR_ERR(regs); > - this is wrong. Read your patch again and it should be very easy to note the mistake. -- balbi
Attachment:
signature.asc
Description: Digital signature