0001
0002
0003
0004
0005
0006
0007
0008 #ifndef MMC_SLOT_GPIO_H
0009 #define MMC_SLOT_GPIO_H
0010
0011 #include <linux/types.h>
0012 #include <linux/irqreturn.h>
0013
0014 struct mmc_host;
0015
0016 int mmc_gpio_get_ro(struct mmc_host *host);
0017 int mmc_gpio_get_cd(struct mmc_host *host);
0018 int mmc_gpiod_request_cd(struct mmc_host *host, const char *con_id,
0019 unsigned int idx, bool override_active_level,
0020 unsigned int debounce);
0021 int mmc_gpiod_request_ro(struct mmc_host *host, const char *con_id,
0022 unsigned int idx, unsigned int debounce);
0023 void mmc_gpio_set_cd_isr(struct mmc_host *host,
0024 irqreturn_t (*isr)(int irq, void *dev_id));
0025 int mmc_gpio_set_cd_wake(struct mmc_host *host, bool on);
0026 void mmc_gpiod_request_cd_irq(struct mmc_host *host);
0027 bool mmc_can_gpio_cd(struct mmc_host *host);
0028 bool mmc_can_gpio_ro(struct mmc_host *host);
0029
0030 #endif