Message ID | 20180627083705.ufge2afrszr7ylm5@mwanda (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Signed-off-by: Avi Fishman <AviFishman70@gmail.com> On Wed, Jun 27, 2018 at 4:37 PM Dan Carpenter <dan.carpenter@oracle.com> wrote: > > We accidentally return 1 instead of negative error codes. > > Fixes: df44831ee2dd ("USB host: Add USB ehci support for nuvoton npcm7xx platform") > Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> > --- > v2: fix typo in the commit message > > diff --git a/drivers/usb/host/ehci-npcm7xx.c b/drivers/usb/host/ehci-npcm7xx.c > index c80a8792d3b0..adaf8fb4b459 100644 > --- a/drivers/usb/host/ehci-npcm7xx.c > +++ b/drivers/usb/host/ehci-npcm7xx.c > @@ -74,14 +74,14 @@ static int npcm7xx_ehci_hcd_drv_probe(struct platform_device *pdev) > if (IS_ERR(gcr_regmap)) { > dev_err(&pdev->dev, "%s: failed to find nuvoton,npcm750-gcr\n", > __func__); > - return IS_ERR(gcr_regmap); > + return PTR_ERR(gcr_regmap); > } > > rst_regmap = syscon_regmap_lookup_by_compatible("nuvoton,npcm750-rst"); > if (IS_ERR(rst_regmap)) { > dev_err(&pdev->dev, "%s: failed to find nuvoton,npcm750-rst\n", > __func__); > - return IS_ERR(rst_regmap); > + return PTR_ERR(rst_regmap); > } > > /********* phy init ******/ -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
diff --git a/drivers/usb/host/ehci-npcm7xx.c b/drivers/usb/host/ehci-npcm7xx.c index c80a8792d3b0..adaf8fb4b459 100644 --- a/drivers/usb/host/ehci-npcm7xx.c +++ b/drivers/usb/host/ehci-npcm7xx.c @@ -74,14 +74,14 @@ static int npcm7xx_ehci_hcd_drv_probe(struct platform_device *pdev) if (IS_ERR(gcr_regmap)) { dev_err(&pdev->dev, "%s: failed to find nuvoton,npcm750-gcr\n", __func__); - return IS_ERR(gcr_regmap); + return PTR_ERR(gcr_regmap); } rst_regmap = syscon_regmap_lookup_by_compatible("nuvoton,npcm750-rst"); if (IS_ERR(rst_regmap)) { dev_err(&pdev->dev, "%s: failed to find nuvoton,npcm750-rst\n", __func__); - return IS_ERR(rst_regmap); + return PTR_ERR(rst_regmap); } /********* phy init ******/
We accidentally return 1 instead of negative error codes. Fixes: df44831ee2dd ("USB host: Add USB ehci support for nuvoton npcm7xx platform") Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> --- v2: fix typo in the commit message -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html