* [PATCH] misc: apds990x: Fix missing pm_runtime_disable()
@ 2024-09-23 3:55 Jinjie Ruan
2024-10-08 2:37 ` Jinjie Ruan
0 siblings, 1 reply; 4+ messages in thread
From: Jinjie Ruan @ 2024-09-23 3:55 UTC (permalink / raw)
To: arnd, gregkh, samu.p.onkalo, jic23, akpm, linux-kernel; +Cc: ruanjinjie
The pm_runtime_disable() is missing in probe error path,
so add it to fix it.
Fixes: 92b1f84d46b2 ("drivers/misc: driver for APDS990X ALS and proximity sensors")
Signed-off-by: Jinjie Ruan <ruanjinjie@huawei.com>
---
drivers/misc/apds990x.c | 12 +++++++-----
1 file changed, 7 insertions(+), 5 deletions(-)
diff --git a/drivers/misc/apds990x.c b/drivers/misc/apds990x.c
index 6d4edd69db12..e7d73c972f65 100644
--- a/drivers/misc/apds990x.c
+++ b/drivers/misc/apds990x.c
@@ -1147,7 +1147,7 @@ static int apds990x_probe(struct i2c_client *client)
err = chip->pdata->setup_resources();
if (err) {
err = -EINVAL;
- goto fail3;
+ goto fail4;
}
}
@@ -1155,7 +1155,7 @@ static int apds990x_probe(struct i2c_client *client)
apds990x_attribute_group);
if (err < 0) {
dev_err(&chip->client->dev, "Sysfs registration failed\n");
- goto fail4;
+ goto fail5;
}
err = request_threaded_irq(client->irq, NULL,
@@ -1166,15 +1166,17 @@ static int apds990x_probe(struct i2c_client *client)
if (err) {
dev_err(&client->dev, "could not get IRQ %d\n",
client->irq);
- goto fail5;
+ goto fail6;
}
return err;
-fail5:
+fail6:
sysfs_remove_group(&chip->client->dev.kobj,
&apds990x_attribute_group[0]);
-fail4:
+fail5:
if (chip->pdata && chip->pdata->release_resources)
chip->pdata->release_resources();
+fail4:
+ pm_runtime_disable(&client->dev);
fail3:
regulator_bulk_disable(ARRAY_SIZE(chip->regs), chip->regs);
fail2:
--
2.34.1
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] misc: apds990x: Fix missing pm_runtime_disable()
2024-09-23 3:55 [PATCH] misc: apds990x: Fix missing pm_runtime_disable() Jinjie Ruan
@ 2024-10-08 2:37 ` Jinjie Ruan
2024-10-13 15:10 ` Greg KH
0 siblings, 1 reply; 4+ messages in thread
From: Jinjie Ruan @ 2024-10-08 2:37 UTC (permalink / raw)
To: arnd, gregkh, samu.p.onkalo, jic23, akpm, linux-kernel
Ping.
On 2024/9/23 11:55, Jinjie Ruan wrote:
> The pm_runtime_disable() is missing in probe error path,
> so add it to fix it.
>
> Fixes: 92b1f84d46b2 ("drivers/misc: driver for APDS990X ALS and proximity sensors")
> Signed-off-by: Jinjie Ruan <ruanjinjie@huawei.com>
> ---
> drivers/misc/apds990x.c | 12 +++++++-----
> 1 file changed, 7 insertions(+), 5 deletions(-)
>
> diff --git a/drivers/misc/apds990x.c b/drivers/misc/apds990x.c
> index 6d4edd69db12..e7d73c972f65 100644
> --- a/drivers/misc/apds990x.c
> +++ b/drivers/misc/apds990x.c
> @@ -1147,7 +1147,7 @@ static int apds990x_probe(struct i2c_client *client)
> err = chip->pdata->setup_resources();
> if (err) {
> err = -EINVAL;
> - goto fail3;
> + goto fail4;
> }
> }
>
> @@ -1155,7 +1155,7 @@ static int apds990x_probe(struct i2c_client *client)
> apds990x_attribute_group);
> if (err < 0) {
> dev_err(&chip->client->dev, "Sysfs registration failed\n");
> - goto fail4;
> + goto fail5;
> }
>
> err = request_threaded_irq(client->irq, NULL,
> @@ -1166,15 +1166,17 @@ static int apds990x_probe(struct i2c_client *client)
> if (err) {
> dev_err(&client->dev, "could not get IRQ %d\n",
> client->irq);
> - goto fail5;
> + goto fail6;
> }
> return err;
> -fail5:
> +fail6:
> sysfs_remove_group(&chip->client->dev.kobj,
> &apds990x_attribute_group[0]);
> -fail4:
> +fail5:
> if (chip->pdata && chip->pdata->release_resources)
> chip->pdata->release_resources();
> +fail4:
> + pm_runtime_disable(&client->dev);
> fail3:
> regulator_bulk_disable(ARRAY_SIZE(chip->regs), chip->regs);
> fail2:
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] misc: apds990x: Fix missing pm_runtime_disable()
2024-10-08 2:37 ` Jinjie Ruan
@ 2024-10-13 15:10 ` Greg KH
2024-10-14 1:14 ` Jinjie Ruan
0 siblings, 1 reply; 4+ messages in thread
From: Greg KH @ 2024-10-13 15:10 UTC (permalink / raw)
To: Jinjie Ruan; +Cc: arnd, samu.p.onkalo, jic23, akpm, linux-kernel
On Tue, Oct 08, 2024 at 10:37:23AM +0800, Jinjie Ruan wrote:
> Ping.
For what?
If you are worried your patches are not being reviewed, please take the
time to review other outstanding patches on the mailing list to make the
workload be decreased for everyone.
thanks,
greg k-h
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] misc: apds990x: Fix missing pm_runtime_disable()
2024-10-13 15:10 ` Greg KH
@ 2024-10-14 1:14 ` Jinjie Ruan
0 siblings, 0 replies; 4+ messages in thread
From: Jinjie Ruan @ 2024-10-14 1:14 UTC (permalink / raw)
To: Greg KH; +Cc: arnd, samu.p.onkalo, jic23, akpm, linux-kernel
On 2024/10/13 23:10, Greg KH wrote:
> On Tue, Oct 08, 2024 at 10:37:23AM +0800, Jinjie Ruan wrote:
>> Ping.
>
> For what?
>
> If you are worried your patches are not being reviewed, please take the
> time to review other outstanding patches on the mailing list to make the
> workload be decreased for everyone.
Hi, greg
Thank you for your suggestion, I'll try to review other people's patches
as much as I can.
>
> thanks,
>
> greg k-h
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2024-10-14 1:14 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-09-23 3:55 [PATCH] misc: apds990x: Fix missing pm_runtime_disable() Jinjie Ruan
2024-10-08 2:37 ` Jinjie Ruan
2024-10-13 15:10 ` Greg KH
2024-10-14 1:14 ` Jinjie Ruan
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.