memory: mtk-smi: Invoke pm runtime_callback to enable clocks
authorYong Wu <yong.wu@mediatek.com>
Sat, 24 Aug 2019 03:02:04 +0000 (11:02 +0800)
committerJoerg Roedel <jroedel@suse.de>
Fri, 30 Aug 2019 13:57:27 +0000 (15:57 +0200)
commit4f0a1a1ae35197e9b7a6d11b4e881bcfe973ad8f
treee4d26e289f990947334e319e32d59fb3b9658e3b
parent15a01f4c60607ad888faf0386070181f9c97577f
memory: mtk-smi: Invoke pm runtime_callback to enable clocks

This patch only move the clk_prepare_enable and config_port into the
runtime suspend/resume callback. It doesn't change the code content
and sequence.

This is a preparing patch for adjusting SMI_BUS_SEL for mt8183.
(SMI_BUS_SEL need to be restored after smi-common resume every time.)
Also it gives a chance to get rid of mtk_smi_larb_get/put which could
be a next topic.

CC: Matthias Brugger <matthias.bgg@gmail.com>
Signed-off-by: Yong Wu <yong.wu@mediatek.com>
Reviewed-by: Evan Green <evgreen@chromium.org>
Reviewed-by: Matthias Brugger <matthias.bgg@gmail.com>
Signed-off-by: Joerg Roedel <jroedel@suse.de>
drivers/memory/mtk-smi.c