Commit 3b7b8ac
committed
pmdomain: core: Add common ->sync_state() support for genpd providers
If the genpd provider's fwnode doesn't have an associated struct device
with it, we can make use of the generic genpd->dev and it corresponding
driver internally in genpd to manage ->sync_state().
More precisely, while adding a genpd OF provider let's check if the fwnode
has a device and if not, make the preparation to handle ->sync_state()
internally through the genpd_provider_driver and the genpd_provider_bus.
Note that, genpd providers may opt out from this behaviour by setting the
GENPD_FLAG_NO_SYNC_STATE config options for the genpds in question.
Suggested-by: Saravana Kannan <saravanak@google.com>
Tested-by: Hiago De Franco <hiago.franco@toradex.com> # Colibri iMX8X
Tested-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com> # TI AM62A,Xilinx ZynqMP ZCU106
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Link: https://lore.kernel.org/r/20250701114733.636510-19-ulf.hansson@linaro.org1 parent 9a4681a commit 3b7b8ac
2 files changed
+57
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
186 | 186 | | |
187 | 187 | | |
188 | 188 | | |
| 189 | + | |
189 | 190 | | |
190 | 191 | | |
191 | 192 | | |
| |||
2351 | 2352 | | |
2352 | 2353 | | |
2353 | 2354 | | |
| 2355 | + | |
2354 | 2356 | | |
2355 | 2357 | | |
2356 | 2358 | | |
| |||
2606 | 2608 | | |
2607 | 2609 | | |
2608 | 2610 | | |
| 2611 | + | |
| 2612 | + | |
2609 | 2613 | | |
2610 | 2614 | | |
2611 | 2615 | | |
| |||
2619 | 2623 | | |
2620 | 2624 | | |
2621 | 2625 | | |
| 2626 | + | |
| 2627 | + | |
| 2628 | + | |
| 2629 | + | |
| 2630 | + | |
| 2631 | + | |
| 2632 | + | |
| 2633 | + | |
| 2634 | + | |
2622 | 2635 | | |
2623 | 2636 | | |
2624 | 2637 | | |
| |||
2643 | 2656 | | |
2644 | 2657 | | |
2645 | 2658 | | |
2646 | | - | |
| 2659 | + | |
2647 | 2660 | | |
2648 | 2661 | | |
2649 | 2662 | | |
| |||
2668 | 2681 | | |
2669 | 2682 | | |
2670 | 2683 | | |
| 2684 | + | |
| 2685 | + | |
2671 | 2686 | | |
2672 | 2687 | | |
| 2688 | + | |
2673 | 2689 | | |
2674 | 2690 | | |
2675 | 2691 | | |
| |||
2680 | 2696 | | |
2681 | 2697 | | |
2682 | 2698 | | |
| 2699 | + | |
| 2700 | + | |
| 2701 | + | |
| 2702 | + | |
| 2703 | + | |
| 2704 | + | |
| 2705 | + | |
2683 | 2706 | | |
2684 | 2707 | | |
2685 | 2708 | | |
| |||
2690 | 2713 | | |
2691 | 2714 | | |
2692 | 2715 | | |
| 2716 | + | |
| 2717 | + | |
| 2718 | + | |
| 2719 | + | |
| 2720 | + | |
| 2721 | + | |
2693 | 2722 | | |
2694 | 2723 | | |
2695 | 2724 | | |
| |||
2712 | 2741 | | |
2713 | 2742 | | |
2714 | 2743 | | |
2715 | | - | |
| 2744 | + | |
2716 | 2745 | | |
2717 | 2746 | | |
2718 | 2747 | | |
| |||
3430 | 3459 | | |
3431 | 3460 | | |
3432 | 3461 | | |
| 3462 | + | |
| 3463 | + | |
| 3464 | + | |
| 3465 | + | |
| 3466 | + | |
| 3467 | + | |
| 3468 | + | |
| 3469 | + | |
| 3470 | + | |
| 3471 | + | |
| 3472 | + | |
| 3473 | + | |
| 3474 | + | |
| 3475 | + | |
| 3476 | + | |
| 3477 | + | |
| 3478 | + | |
| 3479 | + | |
| 3480 | + | |
3433 | 3481 | | |
3434 | 3482 | | |
3435 | 3483 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
133 | 133 | | |
134 | 134 | | |
135 | 135 | | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
136 | 142 | | |
137 | 143 | | |
138 | 144 | | |
| |||
193 | 199 | | |
194 | 200 | | |
195 | 201 | | |
| 202 | + | |
196 | 203 | | |
197 | 204 | | |
198 | 205 | | |
| |||
0 commit comments