* [PATCH] gpu: host1x: Fix error handling
@ 2017-04-10 20:29 Christophe JAILLET
[not found] ` <20170410202922.17665-1-christophe.jaillet-39ZsbGIQGT5GWvitb5QawA@public.gmane.org>
0 siblings, 1 reply; 3+ messages in thread
From: Christophe JAILLET @ 2017-04-10 20:29 UTC (permalink / raw)
To: thierry.reding-Re5JQEeQqe8AvxtiuMwx3w
Cc: dri-devel-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW,
linux-tegra-u79uwXL29TY76Z2rM5mHXA,
linux-kernel-u79uwXL29TY76Z2rM5mHXA,
kernel-janitors-u79uwXL29TY76Z2rM5mHXA, Christophe JAILLET
If 'devm_reset_control_get' returns an error, then we erroneously return
success because error code is taken from 'host->clk' instead of
'host->rst'.
Fixes: b386c6b73ac6 ("gpu: host1x: Support module reset")
Signed-off-by: Christophe JAILLET <christophe.jaillet-39ZsbGIQGT5GWvitb5QawA@public.gmane.org>
---
drivers/gpu/host1x/dev.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/host1x/dev.c b/drivers/gpu/host1x/dev.c
index f05ebb14fa63..ac65f52850a6 100644
--- a/drivers/gpu/host1x/dev.c
+++ b/drivers/gpu/host1x/dev.c
@@ -172,7 +172,7 @@ static int host1x_probe(struct platform_device *pdev)
host->rst = devm_reset_control_get(&pdev->dev, "host1x");
if (IS_ERR(host->rst)) {
- err = PTR_ERR(host->clk);
+ err = PTR_ERR(host->rst);
dev_err(&pdev->dev, "failed to get reset: %d\n", err);
return err;
}
--
2.11.0
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] gpu: host1x: Fix error handling
[not found] ` <20170410202922.17665-1-christophe.jaillet-39ZsbGIQGT5GWvitb5QawA@public.gmane.org>
@ 2017-04-11 8:38 ` Mikko Perttunen
2017-06-15 12:07 ` Thierry Reding
1 sibling, 0 replies; 3+ messages in thread
From: Mikko Perttunen @ 2017-04-11 8:38 UTC (permalink / raw)
To: Christophe JAILLET, thierry.reding-Re5JQEeQqe8AvxtiuMwx3w
Cc: dri-devel-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW,
linux-tegra-u79uwXL29TY76Z2rM5mHXA,
linux-kernel-u79uwXL29TY76Z2rM5mHXA,
kernel-janitors-u79uwXL29TY76Z2rM5mHXA
On 10.04.2017 23:29, Christophe JAILLET wrote:
> If 'devm_reset_control_get' returns an error, then we erroneously return
> success because error code is taken from 'host->clk' instead of
> 'host->rst'.
>
> Fixes: b386c6b73ac6 ("gpu: host1x: Support module reset")
>
> Signed-off-by: Christophe JAILLET <christophe.jaillet-39ZsbGIQGT5GWvitb5QawA@public.gmane.org>
> ---
> drivers/gpu/host1x/dev.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/host1x/dev.c b/drivers/gpu/host1x/dev.c
> index f05ebb14fa63..ac65f52850a6 100644
> --- a/drivers/gpu/host1x/dev.c
> +++ b/drivers/gpu/host1x/dev.c
> @@ -172,7 +172,7 @@ static int host1x_probe(struct platform_device *pdev)
>
> host->rst = devm_reset_control_get(&pdev->dev, "host1x");
> if (IS_ERR(host->rst)) {
> - err = PTR_ERR(host->clk);
> + err = PTR_ERR(host->rst);
> dev_err(&pdev->dev, "failed to get reset: %d\n", err);
> return err;
> }
>
Reviewed-by: Mikko Perttunen <mperttunen-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] gpu: host1x: Fix error handling
[not found] ` <20170410202922.17665-1-christophe.jaillet-39ZsbGIQGT5GWvitb5QawA@public.gmane.org>
2017-04-11 8:38 ` Mikko Perttunen
@ 2017-06-15 12:07 ` Thierry Reding
1 sibling, 0 replies; 3+ messages in thread
From: Thierry Reding @ 2017-06-15 12:07 UTC (permalink / raw)
To: Christophe JAILLET
Cc: dri-devel-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW,
linux-tegra-u79uwXL29TY76Z2rM5mHXA,
linux-kernel-u79uwXL29TY76Z2rM5mHXA,
kernel-janitors-u79uwXL29TY76Z2rM5mHXA
[-- Attachment #1: Type: text/plain, Size: 538 bytes --]
On Mon, Apr 10, 2017 at 10:29:22PM +0200, Christophe JAILLET wrote:
> If 'devm_reset_control_get' returns an error, then we erroneously return
> success because error code is taken from 'host->clk' instead of
> 'host->rst'.
>
> Fixes: b386c6b73ac6 ("gpu: host1x: Support module reset")
>
> Signed-off-by: Christophe JAILLET <christophe.jaillet-39ZsbGIQGT5GWvitb5QawA@public.gmane.org>
> ---
> drivers/gpu/host1x/dev.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
Applied to drm-misc-fixes, thanks.
Thierry
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2017-06-15 12:07 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-04-10 20:29 [PATCH] gpu: host1x: Fix error handling Christophe JAILLET
[not found] ` <20170410202922.17665-1-christophe.jaillet-39ZsbGIQGT5GWvitb5QawA@public.gmane.org>
2017-04-11 8:38 ` Mikko Perttunen
2017-06-15 12:07 ` Thierry Reding
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).