Commit a3c6eab
iio: adc: rzg2l: Cleanup suspend/resume path
There is no need to manually track the runtime PM status in the driver.
The pm_runtime_force_suspend() and pm_runtime_force_resume() functions
already call pm_runtime_status_suspended() to check the runtime PM state.
Additionally, avoid calling pm_runtime_put_autosuspend() during the
suspend/resume path, as this would decrease the usage counter of a
potential user that had the ADC open before the suspend/resume cycle.
Fixes: 563cf94 ("iio: adc: rzg2l_adc: Add suspend/resume support")
Reviewed-by: Ulf Hansson <ulf.hansson@linaro.org>
Reviewed-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>
Signed-off-by: Claudiu Beznea <claudiu.beznea.uj@bp.renesas.com>
Link: https://patch.msgid.link/20250810123328.800104-2-claudiu.beznea.uj@bp.renesas.com
Cc: <Stable@vger.kernel.org>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>1 parent b04e455 commit a3c6eab
1 file changed
Lines changed: 8 additions & 21 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
89 | 89 | | |
90 | 90 | | |
91 | 91 | | |
92 | | - | |
93 | 92 | | |
94 | 93 | | |
95 | 94 | | |
| |||
541 | 540 | | |
542 | 541 | | |
543 | 542 | | |
544 | | - | |
545 | | - | |
546 | | - | |
547 | | - | |
548 | | - | |
549 | | - | |
550 | | - | |
551 | | - | |
| 543 | + | |
| 544 | + | |
| 545 | + | |
552 | 546 | | |
553 | 547 | | |
554 | 548 | | |
| |||
557 | 551 | | |
558 | 552 | | |
559 | 553 | | |
560 | | - | |
561 | | - | |
562 | | - | |
| 554 | + | |
563 | 555 | | |
564 | 556 | | |
565 | 557 | | |
| |||
577 | 569 | | |
578 | 570 | | |
579 | 571 | | |
580 | | - | |
581 | | - | |
582 | | - | |
583 | | - | |
584 | | - | |
| 572 | + | |
| 573 | + | |
| 574 | + | |
585 | 575 | | |
586 | 576 | | |
587 | 577 | | |
| |||
590 | 580 | | |
591 | 581 | | |
592 | 582 | | |
593 | | - | |
594 | | - | |
595 | | - | |
596 | | - | |
| 583 | + | |
597 | 584 | | |
598 | 585 | | |
599 | 586 | | |
| |||
0 commit comments