diff options
author | Nicolas Ferre <nicolas.ferre@atmel.com> | 2012-07-06 06:11:51 -0400 |
---|---|---|
committer | Chris Ball <cjb@laptop.org> | 2012-07-22 15:25:50 -0400 |
commit | 8a4de07e05e7bedc894c2de3b3b04673d6d840ec (patch) | |
tree | f65af9892c70618f9fab2f0af718538657ef96d9 /drivers/mmc | |
parent | 41b4e9a194f69b1c945038c559ea407a6b383e81 (diff) |
mmc: atmel-mci: modify CLKDIV displaying in debugfs
Modify clock division displaying in debugfs for matching
the new CLKDIV,CLKODD user interface arrangement.
Is using the has_odd_clk_div property to choose the proper format.
Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com>
Acked-by: Ludovic Desroches <ludovic.desroches@atmel.com>
Signed-off-by: Chris Ball <cjb@laptop.org>
Diffstat (limited to 'drivers/mmc')
-rw-r--r-- | drivers/mmc/host/atmel-mci.c | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/drivers/mmc/host/atmel-mci.c b/drivers/mmc/host/atmel-mci.c index 84c4ac4d5192..322412cec4ee 100644 --- a/drivers/mmc/host/atmel-mci.c +++ b/drivers/mmc/host/atmel-mci.c | |||
@@ -391,11 +391,17 @@ static int atmci_regs_show(struct seq_file *s, void *v) | |||
391 | clk_disable(host->mck); | 391 | clk_disable(host->mck); |
392 | spin_unlock_bh(&host->lock); | 392 | spin_unlock_bh(&host->lock); |
393 | 393 | ||
394 | seq_printf(s, "MR:\t0x%08x%s%s CLKDIV=%u\n", | 394 | seq_printf(s, "MR:\t0x%08x%s%s ", |
395 | buf[ATMCI_MR / 4], | 395 | buf[ATMCI_MR / 4], |
396 | buf[ATMCI_MR / 4] & ATMCI_MR_RDPROOF ? " RDPROOF" : "", | 396 | buf[ATMCI_MR / 4] & ATMCI_MR_RDPROOF ? " RDPROOF" : "", |
397 | buf[ATMCI_MR / 4] & ATMCI_MR_WRPROOF ? " WRPROOF" : "", | 397 | buf[ATMCI_MR / 4] & ATMCI_MR_WRPROOF ? " WRPROOF" : ""); |
398 | buf[ATMCI_MR / 4] & 0xff); | 398 | if (host->caps.has_odd_clk_div) |
399 | seq_printf(s, "{CLKDIV,CLKODD}=%u\n", | ||
400 | ((buf[ATMCI_MR / 4] & 0xff) << 1) | ||
401 | | ((buf[ATMCI_MR / 4] >> 16) & 1)); | ||
402 | else | ||
403 | seq_printf(s, "CLKDIV=%u\n", | ||
404 | (buf[ATMCI_MR / 4] & 0xff)); | ||
399 | seq_printf(s, "DTOR:\t0x%08x\n", buf[ATMCI_DTOR / 4]); | 405 | seq_printf(s, "DTOR:\t0x%08x\n", buf[ATMCI_DTOR / 4]); |
400 | seq_printf(s, "SDCR:\t0x%08x\n", buf[ATMCI_SDCR / 4]); | 406 | seq_printf(s, "SDCR:\t0x%08x\n", buf[ATMCI_SDCR / 4]); |
401 | seq_printf(s, "ARGR:\t0x%08x\n", buf[ATMCI_ARGR / 4]); | 407 | seq_printf(s, "ARGR:\t0x%08x\n", buf[ATMCI_ARGR / 4]); |