diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2014-04-09 11:39:39 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2014-04-09 11:39:39 -0400 |
commit | 97e18dc007546fce8e99098480b921a02ebb3037 (patch) | |
tree | f38c022d034e0172e83f6972983577f790f24dac /include/linux/mmc | |
parent | 042f7b7cbd1e531278a09c449563165ba1f07673 (diff) | |
parent | c67480173f72e883235dd0ad09d90156c8f87600 (diff) |
Merge tag 'mmc-updates-for-3.15-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/cjb/mmc
Pull MMC updates from Chris Ball:
"MMC highlights for 3.15:
Core:
- CONFIG_MMC_UNSAFE_RESUME=y is now default behavior
- DT bindings for SDHCI UHS, eMMC HS200, high-speed DDR, at 1.8/1.2V
- Add GPIO descriptor based slot-gpio card detect API
Drivers:
- dw_mmc: Refactor SOCFPGA support as a variant inside dw_mmc-pltfm.c
- mmci: Support HW busy detection on ux500
- omap: Support MMC_ERASE
- omap_hsmmc: Support MMC_PM_KEEP_POWER, MMC_PM_WAKE_SDIO_IRQ, (a)cmd23
- rtsx: Support pre-req/post-req async
- sdhci: Add support for Realtek RTS5250 controllers
- sdhci-acpi: Add support for 80860F16, fix 80860F14/SDIO card detect
- sdhci-msm: Add new driver for Qualcomm SDHCI chipset support
- sdhci-pxav3: Add support for Marvell Armada 380 and 385 SoCs"
* tag 'mmc-updates-for-3.15-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/cjb/mmc: (102 commits)
mmc: sdhci-acpi: Intel SDIO has broken card detect
mmc: sdhci-pxav3: add support for the Armada 38x SDHCI controller
mmc: sdhci-msm: Add platform_execute_tuning implementation
mmc: sdhci-msm: Initial support for Qualcomm chipsets
mmc: sdhci-msm: Qualcomm SDHCI binding documentation
sdhci: only reprogram retuning timer when flag is set
mmc: rename ARCH_BCM to ARCH_BCM_MOBILE
mmc: sdhci: Allow for irq being shared
mmc: sdhci-acpi: Add device id 80860F16
mmc: sdhci-acpi: Fix broken card detect for ACPI HID 80860F14
mmc: slot-gpio: Add GPIO descriptor based CD GPIO API
mmc: slot-gpio: Split out CD IRQ request into a separate function
mmc: slot-gpio: Record GPIO descriptors instead of GPIO numbers
Revert "dts: socfpga: Add support for SD/MMC on the SOCFPGA platform"
mmc: sdhci-spear: use generic card detection gpio support
mmc: sdhci-spear: remove support for power gpio
mmc: sdhci-spear: simplify resource handling
mmc: sdhci-spear: fix platform_data usage
mmc: sdhci-spear: fix error handling paths for DT
mmc: sdhci-bcm-kona: fix build errors when built-in
...
Diffstat (limited to 'include/linux/mmc')
-rw-r--r-- | include/linux/mmc/core.h | 4 | ||||
-rw-r--r-- | include/linux/mmc/host.h | 13 | ||||
-rw-r--r-- | include/linux/mmc/sdhci-spear.h | 8 | ||||
-rw-r--r-- | include/linux/mmc/sdhci.h | 2 | ||||
-rw-r--r-- | include/linux/mmc/slot-gpio.h | 6 |
5 files changed, 12 insertions, 21 deletions
diff --git a/include/linux/mmc/core.h b/include/linux/mmc/core.h index 87079fc38011..f206e29f94d7 100644 --- a/include/linux/mmc/core.h +++ b/include/linux/mmc/core.h | |||
@@ -95,7 +95,7 @@ struct mmc_command { | |||
95 | * actively failing requests | 95 | * actively failing requests |
96 | */ | 96 | */ |
97 | 97 | ||
98 | unsigned int cmd_timeout_ms; /* in milliseconds */ | 98 | unsigned int busy_timeout; /* busy detect timeout in ms */ |
99 | /* Set this flag only for blocking sanitize request */ | 99 | /* Set this flag only for blocking sanitize request */ |
100 | bool sanitize_busy; | 100 | bool sanitize_busy; |
101 | 101 | ||
@@ -152,7 +152,7 @@ extern int mmc_wait_for_app_cmd(struct mmc_host *, struct mmc_card *, | |||
152 | struct mmc_command *, int); | 152 | struct mmc_command *, int); |
153 | extern void mmc_start_bkops(struct mmc_card *card, bool from_exception); | 153 | extern void mmc_start_bkops(struct mmc_card *card, bool from_exception); |
154 | extern int __mmc_switch(struct mmc_card *, u8, u8, u8, unsigned int, bool, | 154 | extern int __mmc_switch(struct mmc_card *, u8, u8, u8, unsigned int, bool, |
155 | bool); | 155 | bool, bool); |
156 | extern int mmc_switch(struct mmc_card *, u8, u8, u8, unsigned int); | 156 | extern int mmc_switch(struct mmc_card *, u8, u8, u8, unsigned int); |
157 | extern int mmc_send_ext_csd(struct mmc_card *card, u8 *ext_csd); | 157 | extern int mmc_send_ext_csd(struct mmc_card *card, u8 *ext_csd); |
158 | 158 | ||
diff --git a/include/linux/mmc/host.h b/include/linux/mmc/host.h index 99f5709ac343..cb61ea4d6945 100644 --- a/include/linux/mmc/host.h +++ b/include/linux/mmc/host.h | |||
@@ -264,15 +264,12 @@ struct mmc_host { | |||
264 | u32 caps2; /* More host capabilities */ | 264 | u32 caps2; /* More host capabilities */ |
265 | 265 | ||
266 | #define MMC_CAP2_BOOTPART_NOACC (1 << 0) /* Boot partition no access */ | 266 | #define MMC_CAP2_BOOTPART_NOACC (1 << 0) /* Boot partition no access */ |
267 | #define MMC_CAP2_CACHE_CTRL (1 << 1) /* Allow cache control */ | ||
268 | #define MMC_CAP2_FULL_PWR_CYCLE (1 << 2) /* Can do full power cycle */ | 267 | #define MMC_CAP2_FULL_PWR_CYCLE (1 << 2) /* Can do full power cycle */ |
269 | #define MMC_CAP2_NO_MULTI_READ (1 << 3) /* Multiblock reads don't work */ | 268 | #define MMC_CAP2_NO_MULTI_READ (1 << 3) /* Multiblock reads don't work */ |
270 | #define MMC_CAP2_NO_SLEEP_CMD (1 << 4) /* Don't allow sleep command */ | ||
271 | #define MMC_CAP2_HS200_1_8V_SDR (1 << 5) /* can support */ | 269 | #define MMC_CAP2_HS200_1_8V_SDR (1 << 5) /* can support */ |
272 | #define MMC_CAP2_HS200_1_2V_SDR (1 << 6) /* can support */ | 270 | #define MMC_CAP2_HS200_1_2V_SDR (1 << 6) /* can support */ |
273 | #define MMC_CAP2_HS200 (MMC_CAP2_HS200_1_8V_SDR | \ | 271 | #define MMC_CAP2_HS200 (MMC_CAP2_HS200_1_8V_SDR | \ |
274 | MMC_CAP2_HS200_1_2V_SDR) | 272 | MMC_CAP2_HS200_1_2V_SDR) |
275 | #define MMC_CAP2_BROKEN_VOLTAGE (1 << 7) /* Use the broken voltage */ | ||
276 | #define MMC_CAP2_HC_ERASE_SZ (1 << 9) /* High-capacity erase size */ | 273 | #define MMC_CAP2_HC_ERASE_SZ (1 << 9) /* High-capacity erase size */ |
277 | #define MMC_CAP2_CD_ACTIVE_HIGH (1 << 10) /* Card-detect signal active high */ | 274 | #define MMC_CAP2_CD_ACTIVE_HIGH (1 << 10) /* Card-detect signal active high */ |
278 | #define MMC_CAP2_RO_ACTIVE_HIGH (1 << 11) /* Write-protect signal active high */ | 275 | #define MMC_CAP2_RO_ACTIVE_HIGH (1 << 11) /* Write-protect signal active high */ |
@@ -281,7 +278,6 @@ struct mmc_host { | |||
281 | #define MMC_CAP2_PACKED_CMD (MMC_CAP2_PACKED_RD | \ | 278 | #define MMC_CAP2_PACKED_CMD (MMC_CAP2_PACKED_RD | \ |
282 | MMC_CAP2_PACKED_WR) | 279 | MMC_CAP2_PACKED_WR) |
283 | #define MMC_CAP2_NO_PRESCAN_POWERUP (1 << 14) /* Don't power up before scan */ | 280 | #define MMC_CAP2_NO_PRESCAN_POWERUP (1 << 14) /* Don't power up before scan */ |
284 | #define MMC_CAP2_SANITIZE (1 << 15) /* Support Sanitize */ | ||
285 | 281 | ||
286 | mmc_pm_flag_t pm_caps; /* supported pm features */ | 282 | mmc_pm_flag_t pm_caps; /* supported pm features */ |
287 | 283 | ||
@@ -304,7 +300,7 @@ struct mmc_host { | |||
304 | unsigned int max_req_size; /* maximum number of bytes in one req */ | 300 | unsigned int max_req_size; /* maximum number of bytes in one req */ |
305 | unsigned int max_blk_size; /* maximum size of one mmc block */ | 301 | unsigned int max_blk_size; /* maximum size of one mmc block */ |
306 | unsigned int max_blk_count; /* maximum number of blocks in one req */ | 302 | unsigned int max_blk_count; /* maximum number of blocks in one req */ |
307 | unsigned int max_discard_to; /* max. discard timeout in ms */ | 303 | unsigned int max_busy_timeout; /* max busy timeout in ms */ |
308 | 304 | ||
309 | /* private data */ | 305 | /* private data */ |
310 | spinlock_t lock; /* lock for claim and bus ops */ | 306 | spinlock_t lock; /* lock for claim and bus ops */ |
@@ -388,8 +384,6 @@ int mmc_power_restore_host(struct mmc_host *host); | |||
388 | void mmc_detect_change(struct mmc_host *, unsigned long delay); | 384 | void mmc_detect_change(struct mmc_host *, unsigned long delay); |
389 | void mmc_request_done(struct mmc_host *, struct mmc_request *); | 385 | void mmc_request_done(struct mmc_host *, struct mmc_request *); |
390 | 386 | ||
391 | int mmc_cache_ctrl(struct mmc_host *, u8); | ||
392 | |||
393 | static inline void mmc_signal_sdio_irq(struct mmc_host *host) | 387 | static inline void mmc_signal_sdio_irq(struct mmc_host *host) |
394 | { | 388 | { |
395 | host->ops->enable_sdio_irq(host, 0); | 389 | host->ops->enable_sdio_irq(host, 0); |
@@ -424,12 +418,9 @@ static inline int mmc_regulator_get_supply(struct mmc_host *mmc) | |||
424 | 418 | ||
425 | int mmc_pm_notify(struct notifier_block *notify_block, unsigned long, void *); | 419 | int mmc_pm_notify(struct notifier_block *notify_block, unsigned long, void *); |
426 | 420 | ||
427 | /* Module parameter */ | ||
428 | extern bool mmc_assume_removable; | ||
429 | |||
430 | static inline int mmc_card_is_removable(struct mmc_host *host) | 421 | static inline int mmc_card_is_removable(struct mmc_host *host) |
431 | { | 422 | { |
432 | return !(host->caps & MMC_CAP_NONREMOVABLE) && mmc_assume_removable; | 423 | return !(host->caps & MMC_CAP_NONREMOVABLE); |
433 | } | 424 | } |
434 | 425 | ||
435 | static inline int mmc_card_keep_power(struct mmc_host *host) | 426 | static inline int mmc_card_keep_power(struct mmc_host *host) |
diff --git a/include/linux/mmc/sdhci-spear.h b/include/linux/mmc/sdhci-spear.h index e78c0e236e9d..8cc095a76cf8 100644 --- a/include/linux/mmc/sdhci-spear.h +++ b/include/linux/mmc/sdhci-spear.h | |||
@@ -18,17 +18,9 @@ | |||
18 | /* | 18 | /* |
19 | * struct sdhci_plat_data: spear sdhci platform data structure | 19 | * struct sdhci_plat_data: spear sdhci platform data structure |
20 | * | 20 | * |
21 | * @card_power_gpio: gpio pin for enabling/disabling power to sdhci socket | ||
22 | * @power_active_high: if set, enable power to sdhci socket by setting | ||
23 | * card_power_gpio | ||
24 | * @power_always_enb: If set, then enable power on probe, otherwise enable only | ||
25 | * on card insertion and disable on card removal. | ||
26 | * card_int_gpio: gpio pin used for card detection | 21 | * card_int_gpio: gpio pin used for card detection |
27 | */ | 22 | */ |
28 | struct sdhci_plat_data { | 23 | struct sdhci_plat_data { |
29 | int card_power_gpio; | ||
30 | int power_active_high; | ||
31 | int power_always_enb; | ||
32 | int card_int_gpio; | 24 | int card_int_gpio; |
33 | }; | 25 | }; |
34 | 26 | ||
diff --git a/include/linux/mmc/sdhci.h b/include/linux/mmc/sdhci.h index 362927c48f97..7be12b883485 100644 --- a/include/linux/mmc/sdhci.h +++ b/include/linux/mmc/sdhci.h | |||
@@ -100,6 +100,8 @@ struct sdhci_host { | |||
100 | #define SDHCI_QUIRK2_BROKEN_HOST_CONTROL (1<<5) | 100 | #define SDHCI_QUIRK2_BROKEN_HOST_CONTROL (1<<5) |
101 | /* Controller does not support HS200 */ | 101 | /* Controller does not support HS200 */ |
102 | #define SDHCI_QUIRK2_BROKEN_HS200 (1<<6) | 102 | #define SDHCI_QUIRK2_BROKEN_HS200 (1<<6) |
103 | /* Controller does not support DDR50 */ | ||
104 | #define SDHCI_QUIRK2_BROKEN_DDR50 (1<<7) | ||
103 | 105 | ||
104 | int irq; /* Device IRQ */ | 106 | int irq; /* Device IRQ */ |
105 | void __iomem *ioaddr; /* Mapped address */ | 107 | void __iomem *ioaddr; /* Mapped address */ |
diff --git a/include/linux/mmc/slot-gpio.h b/include/linux/mmc/slot-gpio.h index b0c73e4cacea..d2433381e828 100644 --- a/include/linux/mmc/slot-gpio.h +++ b/include/linux/mmc/slot-gpio.h | |||
@@ -22,4 +22,10 @@ int mmc_gpio_request_cd(struct mmc_host *host, unsigned int gpio, | |||
22 | unsigned int debounce); | 22 | unsigned int debounce); |
23 | void mmc_gpio_free_cd(struct mmc_host *host); | 23 | void mmc_gpio_free_cd(struct mmc_host *host); |
24 | 24 | ||
25 | int mmc_gpiod_request_cd(struct mmc_host *host, const char *con_id, | ||
26 | unsigned int idx, bool override_active_level, | ||
27 | unsigned int debounce); | ||
28 | void mmc_gpiod_free_cd(struct mmc_host *host); | ||
29 | void mmc_gpiod_request_cd_irq(struct mmc_host *host); | ||
30 | |||
25 | #endif | 31 | #endif |