1 /* SPDX-License-Identifier: GPL-2.0 */
2 #ifndef ASMARM_ARCH_MMC_H
3 #define ASMARM_ARCH_MMC_H
5 #include <linux/interrupt.h>
6 #include <linux/mmc/host.h>
10 /* board specific SDHC data, optional.
11 * If not present, a writable card with 3,3V is assumed.
13 struct imxmmc_platform_data
{
14 /* Return values for the get_ro callback should be:
15 * 0 for a read/write card
16 * 1 for a read-only card
17 * -ENOSYS when not supported (equal to NULL callback)
18 * or a negative errno value when something bad happened
20 int (*get_ro
)(struct device
*);
22 /* board specific hook to (de)initialize the SD slot.
23 * The board code can call 'handler' on a card detection
24 * change giving data as argument.
26 int (*init
)(struct device
*dev
, irq_handler_t handler
, void *data
);
27 void (*exit
)(struct device
*dev
, void *data
);
29 /* available voltages. If not given, assume
30 * MMC_VDD_32_33 | MMC_VDD_33_34
32 unsigned int ocr_avail
;
34 /* adjust slot voltage */
35 void (*setpower
)(struct device
*, unsigned int vdd
);
37 /* enable card detect using DAT3 */