* [PATCH -next] drm/panfrost: simplify the return expression of cz_ih_hw_init()
@ 2020-09-21 13:10 Qinglang Miao
2020-09-21 14:17 ` Philipp Zabel
2020-10-01 10:57 ` Steven Price
0 siblings, 2 replies; 3+ messages in thread
From: Qinglang Miao @ 2020-09-21 13:10 UTC (permalink / raw)
To: Rob Herring, Tomeu Vizoso, Steven Price, Alyssa Rosenzweig,
David Airlie, Daniel Vetter, Philipp Zabel
Cc: dri-devel, linux-kernel, Qinglang Miao
Simplify the return expression.
Signed-off-by: Qinglang Miao <miaoqinglang@huawei.com>
---
drivers/gpu/drm/panfrost/panfrost_device.c | 8 +-------
1 file changed, 1 insertion(+), 7 deletions(-)
diff --git a/drivers/gpu/drm/panfrost/panfrost_device.c b/drivers/gpu/drm/panfrost/panfrost_device.c
index e68967338..ea8d31863 100644
--- a/drivers/gpu/drm/panfrost/panfrost_device.c
+++ b/drivers/gpu/drm/panfrost/panfrost_device.c
@@ -18,19 +18,13 @@
static int panfrost_reset_init(struct panfrost_device *pfdev)
{
- int err;
-
pfdev->rstc = devm_reset_control_array_get(pfdev->dev, false, true);
if (IS_ERR(pfdev->rstc)) {
dev_err(pfdev->dev, "get reset failed %ld\n", PTR_ERR(pfdev->rstc));
return PTR_ERR(pfdev->rstc);
}
- err = reset_control_deassert(pfdev->rstc);
- if (err)
- return err;
-
- return 0;
+ return reset_control_deassert(pfdev->rstc);
}
static void panfrost_reset_fini(struct panfrost_device *pfdev)
--
2.23.0
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH -next] drm/panfrost: simplify the return expression of cz_ih_hw_init()
2020-09-21 13:10 [PATCH -next] drm/panfrost: simplify the return expression of cz_ih_hw_init() Qinglang Miao
@ 2020-09-21 14:17 ` Philipp Zabel
2020-10-01 10:57 ` Steven Price
1 sibling, 0 replies; 3+ messages in thread
From: Philipp Zabel @ 2020-09-21 14:17 UTC (permalink / raw)
To: Qinglang Miao, Rob Herring, Tomeu Vizoso, Steven Price,
Alyssa Rosenzweig, David Airlie, Daniel Vetter
Cc: dri-devel, linux-kernel
On Mon, 2020-09-21 at 21:10 +0800, Qinglang Miao wrote:
> Simplify the return expression.
>
> Signed-off-by: Qinglang Miao <miaoqinglang@huawei.com>
> ---
> drivers/gpu/drm/panfrost/panfrost_device.c | 8 +-------
> 1 file changed, 1 insertion(+), 7 deletions(-)
>
> diff --git a/drivers/gpu/drm/panfrost/panfrost_device.c b/drivers/gpu/drm/panfrost/panfrost_device.c
> index e68967338..ea8d31863 100644
> --- a/drivers/gpu/drm/panfrost/panfrost_device.c
> +++ b/drivers/gpu/drm/panfrost/panfrost_device.c
> @@ -18,19 +18,13 @@
>
> static int panfrost_reset_init(struct panfrost_device *pfdev)
> {
> - int err;
> -
> pfdev->rstc = devm_reset_control_array_get(pfdev->dev, false, true);
> if (IS_ERR(pfdev->rstc)) {
> dev_err(pfdev->dev, "get reset failed %ld\n", PTR_ERR(pfdev->rstc));
> return PTR_ERR(pfdev->rstc);
> }
>
> - err = reset_control_deassert(pfdev->rstc);
> - if (err)
> - return err;
> -
> - return 0;
> + return reset_control_deassert(pfdev->rstc);
> }
>
> static void panfrost_reset_fini(struct panfrost_device *pfdev)
Reviewed-by: Philipp Zabel <p.zabel@pengutronix.de>
regards
Philipp
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH -next] drm/panfrost: simplify the return expression of cz_ih_hw_init()
2020-09-21 13:10 [PATCH -next] drm/panfrost: simplify the return expression of cz_ih_hw_init() Qinglang Miao
2020-09-21 14:17 ` Philipp Zabel
@ 2020-10-01 10:57 ` Steven Price
1 sibling, 0 replies; 3+ messages in thread
From: Steven Price @ 2020-10-01 10:57 UTC (permalink / raw)
To: Qinglang Miao, Rob Herring, Tomeu Vizoso, Alyssa Rosenzweig,
David Airlie, Daniel Vetter, Philipp Zabel
Cc: dri-devel, linux-kernel
On 21/09/2020 14:10, Qinglang Miao wrote:
> Simplify the return expression.
>
> Signed-off-by: Qinglang Miao <miaoqinglang@huawei.com>
Reviewed-by: Steven Price <steven.price@arm.com>
> ---
> drivers/gpu/drm/panfrost/panfrost_device.c | 8 +-------
> 1 file changed, 1 insertion(+), 7 deletions(-)
>
> diff --git a/drivers/gpu/drm/panfrost/panfrost_device.c b/drivers/gpu/drm/panfrost/panfrost_device.c
> index e68967338..ea8d31863 100644
> --- a/drivers/gpu/drm/panfrost/panfrost_device.c
> +++ b/drivers/gpu/drm/panfrost/panfrost_device.c
> @@ -18,19 +18,13 @@
>
> static int panfrost_reset_init(struct panfrost_device *pfdev)
> {
> - int err;
> -
> pfdev->rstc = devm_reset_control_array_get(pfdev->dev, false, true);
> if (IS_ERR(pfdev->rstc)) {
> dev_err(pfdev->dev, "get reset failed %ld\n", PTR_ERR(pfdev->rstc));
> return PTR_ERR(pfdev->rstc);
> }
>
> - err = reset_control_deassert(pfdev->rstc);
> - if (err)
> - return err;
> -
> - return 0;
> + return reset_control_deassert(pfdev->rstc);
> }
>
> static void panfrost_reset_fini(struct panfrost_device *pfdev)
>
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2020-10-01 10:58 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-09-21 13:10 [PATCH -next] drm/panfrost: simplify the return expression of cz_ih_hw_init() Qinglang Miao
2020-09-21 14:17 ` Philipp Zabel
2020-10-01 10:57 ` Steven Price
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).