mmc: debugfs: expose the SDCLK frq in sys ios
authorGiuseppe CAVALLARO <peppe.cavallaro@st.com>
Fri, 4 Nov 2011 12:53:19 +0000 (13:53 +0100)
committerChris Ball <cjb@laptop.org>
Thu, 12 Jan 2012 04:58:40 +0000 (23:58 -0500)
commitdf16219f365f7f5a2d88a6e123251d57255cca3f
tree0eca076f1abf8a0161f8fb66e1f98b5a003c900b
parent052d81da6e6f0f8839ef6d5a46f215fc8cd99d5a
mmc: debugfs: expose the SDCLK frq in sys ios

This patch is to expose the actual SDCLK frequency in
/sys/kernel/debug/mmcX/ios entry.

For example, if the max clk for a normal speed card is 20MHz this
is reported in /sys/kernel/debug/mmcX/ios.  Unfortunately the actual
SDCLK frequency (i.e. Baseclock / divisor) is not reported at all:
for example, in that case, on Arasan HC, it should be 48/4=12 (MHz).

Signed-off-by: Giuseppe Cavallaro <peppe.cavallaro@st.com>
Acked-by: Adrian Hunter <adrian.hunter@intel.com>
Signed-off-by: Chris Ball <cjb@laptop.org>
drivers/mmc/core/debugfs.c
drivers/mmc/host/sdhci.c
include/linux/mmc/host.h