* [PATCH] usb: dwc2: pci: Fix an error code in probe
@ 2018-10-18 7:36 ` Dan Carpenter
0 siblings, 0 replies; 4+ messages in thread
From: Dan Carpenter @ 2018-10-18 7:36 UTC (permalink / raw)
To: Minas Harutyunyan, Vardan Mikayelyan
Cc: Greg Kroah-Hartman, linux-usb, kernel-janitors
We added some error handling to this function but forgot to set the
error code on this path.
Fixes: ecd29dabb2ba ("usb: dwc2: pci: Handle error cleanup in probe")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
---
drivers/usb/dwc2/pci.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/usb/dwc2/pci.c b/drivers/usb/dwc2/pci.c
index d257c541e51b..7afc10872f1f 100644
--- a/drivers/usb/dwc2/pci.c
+++ b/drivers/usb/dwc2/pci.c
@@ -120,6 +120,7 @@ static int dwc2_pci_probe(struct pci_dev *pci,
dwc2 = platform_device_alloc("dwc2", PLATFORM_DEVID_AUTO);
if (!dwc2) {
dev_err(dev, "couldn't allocate dwc2 device\n");
+ ret = -ENOMEM;
goto err;
}
--
2.11.0
^ permalink raw reply related [flat|nested] 4+ messages in thread
* usb: dwc2: pci: Fix an error code in probe
@ 2018-10-18 7:36 ` Dan Carpenter
0 siblings, 0 replies; 4+ messages in thread
From: Dan Carpenter @ 2018-10-18 7:36 UTC (permalink / raw)
To: Minas Harutyunyan, Vardan Mikayelyan
Cc: Greg Kroah-Hartman, linux-usb, kernel-janitors
We added some error handling to this function but forgot to set the
error code on this path.
Fixes: ecd29dabb2ba ("usb: dwc2: pci: Handle error cleanup in probe")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
---
drivers/usb/dwc2/pci.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/usb/dwc2/pci.c b/drivers/usb/dwc2/pci.c
index d257c541e51b..7afc10872f1f 100644
--- a/drivers/usb/dwc2/pci.c
+++ b/drivers/usb/dwc2/pci.c
@@ -120,6 +120,7 @@ static int dwc2_pci_probe(struct pci_dev *pci,
dwc2 = platform_device_alloc("dwc2", PLATFORM_DEVID_AUTO);
if (!dwc2) {
dev_err(dev, "couldn't allocate dwc2 device\n");
+ ret = -ENOMEM;
goto err;
}
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] usb: dwc2: pci: Fix an error code in probe
@ 2018-10-18 7:50 ` Minas Harutyunyan
0 siblings, 0 replies; 4+ messages in thread
From: Minas Harutyunyan @ 2018-10-18 7:50 UTC (permalink / raw)
To: Dan Carpenter, Minas Harutyunyan, Vardan Mikayelyan
Cc: Greg Kroah-Hartman, linux-usb, kernel-janitors
On 10/18/2018 11:37 AM, Dan Carpenter wrote:
> We added some error handling to this function but forgot to set the
> error code on this path.
>
> Fixes: ecd29dabb2ba ("usb: dwc2: pci: Handle error cleanup in probe")
> Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Acked-by: Minas Harutyunyan <hminas@synopsys.com>
> ---
> drivers/usb/dwc2/pci.c | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/drivers/usb/dwc2/pci.c b/drivers/usb/dwc2/pci.c
> index d257c541e51b..7afc10872f1f 100644
> --- a/drivers/usb/dwc2/pci.c
> +++ b/drivers/usb/dwc2/pci.c
> @@ -120,6 +120,7 @@ static int dwc2_pci_probe(struct pci_dev *pci,
> dwc2 = platform_device_alloc("dwc2", PLATFORM_DEVID_AUTO);
> if (!dwc2) {
> dev_err(dev, "couldn't allocate dwc2 device\n");
> + ret = -ENOMEM;
> goto err;
> }
>
>
^ permalink raw reply [flat|nested] 4+ messages in thread
* usb: dwc2: pci: Fix an error code in probe
@ 2018-10-18 7:50 ` Minas Harutyunyan
0 siblings, 0 replies; 4+ messages in thread
From: Minas Harutyunyan @ 2018-10-18 7:50 UTC (permalink / raw)
To: Dan Carpenter, Minas Harutyunyan, Vardan Mikayelyan
Cc: Greg Kroah-Hartman, linux-usb, kernel-janitors
On 10/18/2018 11:37 AM, Dan Carpenter wrote:
> We added some error handling to this function but forgot to set the
> error code on this path.
>
> Fixes: ecd29dabb2ba ("usb: dwc2: pci: Handle error cleanup in probe")
> Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Acked-by: Minas Harutyunyan <hminas@synopsys.com>
> ---
> drivers/usb/dwc2/pci.c | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/drivers/usb/dwc2/pci.c b/drivers/usb/dwc2/pci.c
> index d257c541e51b..7afc10872f1f 100644
> --- a/drivers/usb/dwc2/pci.c
> +++ b/drivers/usb/dwc2/pci.c
> @@ -120,6 +120,7 @@ static int dwc2_pci_probe(struct pci_dev *pci,
> dwc2 = platform_device_alloc("dwc2", PLATFORM_DEVID_AUTO);
> if (!dwc2) {
> dev_err(dev, "couldn't allocate dwc2 device\n");
> + ret = -ENOMEM;
> goto err;
> }
>
>
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2018-10-18 7:50 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-10-18 7:36 [PATCH] usb: dwc2: pci: Fix an error code in probe Dan Carpenter
2018-10-18 7:36 ` Dan Carpenter
2018-10-18 7:50 ` [PATCH] " Minas Harutyunyan
2018-10-18 7:50 ` Minas Harutyunyan
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.