public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [U-Boot] [PATCH v2 0/4] mmc: Implement central card-detection.
@ 2011-12-09  7:11 Thierry Reding
  2011-12-09  7:11 ` [U-Boot] [PATCH v2 1/4] mmc: Change board_mmc_getcd() signature Thierry Reding
                   ` (3 more replies)
  0 siblings, 4 replies; 8+ messages in thread
From: Thierry Reding @ 2011-12-09  7:11 UTC (permalink / raw)
  To: u-boot

This series of patches implements central card-detection within the MMC
framework. Before this patch series, many boards actually did implement
the board_mmc_getcd() function, but it wasn't used except by one driver
(fsl_esdhc). Unfortunately, implementations interpreted the meaning of
the cd parameter differently, some taking it to signal card absence and
others using it to detect card presence. Furthermore, the signature of
the board_mmc_getcd() function was not at all consistent with other MMC
related functions.

The first patch in this series therefore changes the board_mmc_getcd()
function signature and consolidates all current implementations. The
second patch adds a central card-detection implementation within the
MMC framework by using the new board_mmc_getcd() function and adds a
hook that can be provided by drivers to serve as a default card-detect
mechanism if no board-specific implementation is provided. The third
and fourth patches implement this driver hook for the fsl_esdhc and the
tegra2 MMC drivers.

For reference, the following email thread contains the discussion that
led to this patch series:

	http://lists.denx.de/pipermail/u-boot/2011-November/110180.html

Changes in v2:
  - add a better rationale for the series and a reference to the email
    thread that started it
  - add an explanation to patch 3 why the call to board_mmc_getcd() is
    removed from the fsl_esdhc driver
  - add a cover letter which explains the series' goal

Thierry Reding (4):
  mmc: Change board_mmc_getcd() signature.
  mmc: Implement card detection.
  mmc: fsl_esdhc: Implement card-detect hook.
  mmc: tegra2: Implement card-detect hook.

 board/efikamx/efikamx.c             |    8 +++-----
 board/emk/top9000/top9000.c         |   12 ++----------
 board/freescale/mx51evk/mx51evk.c   |    8 +++-----
 board/freescale/mx53ard/mx53ard.c   |    8 +++-----
 board/freescale/mx53evk/mx53evk.c   |    8 +++-----
 board/freescale/mx53loco/mx53loco.c |    8 +++-----
 board/freescale/mx53smd/mx53smd.c   |    6 ++----
 doc/README.atmel_mci                |   12 ++----------
 drivers/mmc/arm_pl180_mmci.c        |    1 +
 drivers/mmc/bfin_sdh.c              |    1 +
 drivers/mmc/davinci_mmc.c           |    1 +
 drivers/mmc/fsl_esdhc.c             |   27 ++++++++++++---------------
 drivers/mmc/ftsdc010_esdhc.c        |    1 +
 drivers/mmc/gen_atmel_mci.c         |    1 +
 drivers/mmc/mmc.c                   |   22 ++++++++++++++++++++--
 drivers/mmc/mmc_spi.c               |    1 +
 drivers/mmc/mxcmmc.c                |    1 +
 drivers/mmc/mxsmmc.c                |    1 +
 drivers/mmc/omap_hsmmc.c            |    1 +
 drivers/mmc/pxa_mmc_gen.c           |    1 +
 drivers/mmc/s5p_mmc.c               |    1 +
 drivers/mmc/sdhci.c                 |    1 +
 drivers/mmc/sh_mmcif.c              |    1 +
 drivers/mmc/tegra2_mmc.c            |   28 +++++++++++++---------------
 include/mmc.h                       |    4 +++-
 25 files changed, 82 insertions(+), 82 deletions(-)

-- 
1.7.8

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2011-12-09  9:12 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-12-09  7:11 [U-Boot] [PATCH v2 0/4] mmc: Implement central card-detection Thierry Reding
2011-12-09  7:11 ` [U-Boot] [PATCH v2 1/4] mmc: Change board_mmc_getcd() signature Thierry Reding
2011-12-09  8:32   ` Marek Vasut
2011-12-09  8:42     ` Thierry Reding
2011-12-09  9:12       ` Marek Vasut
2011-12-09  7:11 ` [U-Boot] [PATCH v2 2/4] mmc: Implement card detection Thierry Reding
2011-12-09  7:11 ` [U-Boot] [PATCH v2 3/4] mmc: fsl_esdhc: Implement card-detect hook Thierry Reding
2011-12-09  7:11 ` [U-Boot] [PATCH v2 4/4] mmc: tegra2: " Thierry Reding

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox