Patch "mmc: dw_mmc: Avoid accessing registers in runtime suspended state" has been added to the 4.15-stable tree
This is a note to let you know that I've just added the patch titled
mmc: dw_mmc: Avoid accessing registers in runtime suspended state
to the 4.15-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary
The filename of the patch is:
mmc-dw_mmc-avoid-accessing-registers-in-runtime-suspended-state.patch
and it can be found in the queue-4.15 subdirectory.
If you, or anyone else, feels it should not be added to the stable tree, please let <[email protected]> know about it.
Quoted 1 line
From
5b43df8b4c1a7f0c3fbf793c9566068e6b1e570cMon Sep 17 00:00:00 2001
From: Shawn Lin <[email protected]>
Date: Fri, 23 Feb 2018 16:47:25 +0800
Subject: mmc: dw_mmc: Avoid accessing registers in runtime suspended state
From: Shawn Lin <[email protected]>
commit 5b43df8b4c1a7f0c3fbf793c9566068e6b1e570c upstream.
cat /sys/kernel/debug/mmc0/regs will hang up the system since it's in runtime suspended state, so the genpd and biu_clk is off. This patch fixes this problem by calling pm_runtime_get_sync to wake it up before reading the registers.
--- drivers/mmc/host/dw_mmc.c | 4 ++++ 1 file changed, 4 insertions(+)
drivers/mmc/host/dw_mmc.c +4 -0
@@ -165,6 +165,8 @@ static int dw_mci_regs_show(struct seq_f {struct dw_mci *host = s->private; +pm_runtime_get_sync (host->dev); +seq_printf (s,"STATUS:\t0x%08x\n" ,mci_readl (host,STATUS ));seq_printf (s,"RINTSTS:\t0x%08x\n" ,mci_readl (host,RINTSTS ));seq_printf (s,"CMD:\t0x%08x\n" ,mci_readl (host,CMD ));
@@ -172,6 +174,8 @@ static int dw_mci_regs_show(struct seq_fseq_printf (s,"INTMASK:\t0x%08x\n" ,mci_readl (host,INTMASK ));seq_printf (s,"CLKENA:\t0x%08x\n" ,mci_readl (host,CLKENA )); +pm_runtime_put_autosuspend (host->dev); +return 0 ; }
Patches currently in stable-queue which might be from [email protected] are
queue-4.15/mmc-dw_mmc-factor-out-dw_mci_init_slot_caps.patch queue-4.15/mmc-dw_mmc-fix-out-of-bounds-access-for-slot-s-caps.patch queue-4.15/mmc-dw_mmc-avoid-accessing-registers-in-runtime-suspended-state.patch queue-4.15/mmc-dw_mmc-k3-fix-out-of-bounds-access-through-dt-alias.patch