PM / devfreq: rockchip-dfi: Handle LPDDR2 correctly
authorSascha Hauer <s.hauer@pengutronix.de>
Wed, 18 Oct 2023 06:16:59 +0000 (08:16 +0200)
committerChanwoo Choi <cw00.choi@samsung.com>
Thu, 19 Oct 2023 11:46:17 +0000 (20:46 +0900)
commit038ff6f53da07971a9df636bcc9bf1344c468dd5
tree84f7d29ca167691e3cfd0f61ead87194afae8da7
parent076b0597f5b6fbec47cddedf9b39d864938a365c
PM / devfreq: rockchip-dfi: Handle LPDDR2 correctly

According to the downstream driver the DDRMON_CTRL_LPDDR23 bit must be
set for both LPDDR2 and LPDDR3. Add the missing LPDDR2 case and while
at it turn the if/else if/else into switch/case which makes it easier
to read.

Link: https://lore.kernel.org/all/20231018061714.3553817-12-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