mmc: omap_hsmmc: simplify cover/card detect logic
Status from this message: Applied patch 1->3, thanks!
Get series with b4
b4 am [email protected]Versions newest first
Patches in v1 Applied
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/6 | mmc: omap_hsmmc: remove unused fields from struct omap_hsmmc_hostdrivers/ | +0 | 0 replies | |
| 2/6 | mmc: omap_hsmmc: use slot-gpio functions to manage read-only pin directlydrivers/ | +1 | 0 replies | |
| 3/6 | mmc: omap_hsmmc: use distinctive code paths for cover / card detect logicdrivers/ | +38 | 0 replies | |
| 4/6 | ARM: OMAP2: HSMMC: platform_data: explicit gpio_cover / gpio_cd fieldsarch/ drivers/ include/ | +33 | 0 replies | |
| 5/6 | mmc: omap_hsmmc: simplify card/cover detect isrdrivers/ | +3 | 1 reply | |
| 6/6 | mmc: omap_hsmmc: use generic slot-gpio isr to manage card detect pindrivers/ | +0 | 1 reply |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.
Cover letter [PATCH 0/6] mmc: omap_hsmmc: simplify cover/card detect logic
These patches are trying to clean up the cover/card detect logic.
Mobile phones (some) have no card detect pin, but can detect if the cover is removed. The purpose is the same; detect if card is being added/removed, but the details differ.
When the cover is removed, it does not mean the card is gone. But it might, since it is accessible now. It's like a warning. All the driver does is to limit write access to the card, see protect_card flag. In contrast, card detect notifies us after the fact, e.g. card is gone, card is inserted.
While cover detect is only used by one platform (rx51), it complicates the card detect logic. By separating the code paths they both become easier to understand and maintain
Patches have been tested by reverting: 95bebb5696ab
'mmc: omap_hsmmc: use mmc_of_parse to parse common mmc configuration' otherwise gpio detection is handled by mmc_of_parse
compile tested
OMAP2:CONFIG_MACH_OMAP2_TUSB6010=yCONFIG_MACH_OMAP3_BEAGLE=yCONFIG_MACH_DEVKIT8000=yCONFIG_MACH_OMAP_LDP=yCONFIG_MACH_OMAP3530_LV_SOM=yCONFIG_MACH_OMAP3_TORPEDO=yCONFIG_MACH_OVERO=yCONFIG_MACH_OMAP3517EVM=yCONFIG_MACH_CRANEBOARD=yCONFIG_MACH_OMAP3_PANDORA=yCONFIG_MACH_TOUCHBOOK=yCONFIG_MACH_OMAP_3430SDP=yCONFIG_MACH_NOKIA_N810=yCONFIG_MACH_NOKIA_N810_WIMAX=yCONFIG_MACH_NOKIA_N8X0=yCONFIG_MACH_NOKIA_RX51=yCONFIG_MACH_CM_T35=yCONFIG_MACH_CM_T3517=yCONFIG_MACH_CM_T3730=yCONFIG_MACH_SBC3530=yCONFIG_MACH_TI8168EVM=yCONFIG_MACH_TI8148EVM=y
Andreas Fenkart (6):
mmc: omap_hsmmc: remove unused fields from struct omap_hsmmc_host
mmc: omap_hsmmc: use slot-gpio functions to manage read-only pin
directly
mmc: omap_hsmmc: use distinctive code paths for cover / card detect
logic
ARM: OMAP2: HSMMC: platform_data: explicit gpio_cover / gpio_cd fields
mmc: omap_hsmmc: simplify card/cover detect isr
mmc: omap_hsmmc: use generic slot-gpio isr to manage card detect pin
arch/arm/mach-omap2/hsmmc.c | 33 +++++++++---- drivers/mmc/host/omap_hsmmc.c | 80 +++++++++----------------------- include/linux/platform_data/hsmmc-omap.h | 6 +-- 3 files changed, 48 insertions(+), 71 deletions(-)
Signature · 1 line
2.1.4