sh_mobile_sdhi.h 1.0 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. #ifndef LINUX_MMC_SH_MOBILE_SDHI_H
  2. #define LINUX_MMC_SH_MOBILE_SDHI_H
  3. #include <linux/types.h>
  4. struct platform_device;
  5. struct tmio_mmc_data;
  6. #define SH_MOBILE_SDHI_IRQ_CARD_DETECT "card_detect"
  7. #define SH_MOBILE_SDHI_IRQ_SDCARD "sdcard"
  8. #define SH_MOBILE_SDHI_IRQ_SDIO "sdio"
  9. /**
  10. * struct sh_mobile_sdhi_ops - SDHI driver callbacks
  11. * @cd_wakeup: trigger a card-detection run
  12. */
  13. struct sh_mobile_sdhi_ops {
  14. void (*cd_wakeup)(const struct platform_device *pdev);
  15. };
  16. struct sh_mobile_sdhi_info {
  17. int dma_slave_tx;
  18. int dma_slave_rx;
  19. unsigned long tmio_flags;
  20. unsigned long tmio_caps;
  21. unsigned long tmio_caps2;
  22. u32 tmio_ocr_mask; /* available MMC voltages */
  23. unsigned int cd_gpio;
  24. struct tmio_mmc_data *pdata;
  25. void (*set_pwr)(struct platform_device *pdev, int state);
  26. int (*get_cd)(struct platform_device *pdev);
  27. /* callbacks for board specific setup code */
  28. int (*init)(struct platform_device *pdev,
  29. const struct sh_mobile_sdhi_ops *ops);
  30. void (*cleanup)(struct platform_device *pdev);
  31. };
  32. #endif /* LINUX_MMC_SH_MOBILE_SDHI_H */