PM / devfreq: rockchip-dfi: Prepare for multiple users
authorSascha Hauer <s.hauer@pengutronix.de>
Wed, 18 Oct 2023 06:17:02 +0000 (08:17 +0200)
committerChanwoo Choi <cw00.choi@samsung.com>
Thu, 19 Oct 2023 11:50:10 +0000 (20:50 +0900)
commitd724f4a4581b2910ce79b45bd353ee66e7cf9d7f
tree7c2d36abf97329b59c8fbf566b5cc95fccb5d417
parentb82932fbd870b64fd71a999f9b61fbdcf2924ee6
PM / devfreq: rockchip-dfi: Prepare for multiple users

When adding perf support later the DFI must be enabled when
either of devfreq-event or perf is active. Prepare for that
by adding a usage counter for the DFI. Also move enabling
and disabling of the clock away from the devfreq-event specific
functions to which the perf specific part won't have access.

Link: https://lore.kernel.org/all/20231018061714.3553817-15-s.hauer@pengutronix.de/
Reviewed-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Reviewed-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Acked-by: Chanwoo Choi <cw00.choi@samsung.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>
drivers/devfreq/event/rockchip-dfi.c