1 /* 2 * Copyright (c) 2017-2018, STMicroelectronics - All Rights Reserved 3 * 4 * SPDX-License-Identifier: BSD-3-Clause 5 */ 6 7 #ifndef STM32_SDMMC2_H 8 #define STM32_SDMMC2_H 9 10 #include <mmc.h> 11 #include <stdbool.h> 12 13 struct stm32_sdmmc2_params { 14 uintptr_t reg_base; 15 unsigned int clk_rate; 16 unsigned int bus_width; 17 unsigned int flags; 18 struct mmc_device_info *device_info; 19 unsigned int pin_ckin; 20 unsigned int negedge; 21 unsigned int dirpol; 22 unsigned int clock_id; 23 unsigned int reset_id; 24 bool use_dma; 25 }; 26 27 unsigned long long stm32_sdmmc2_mmc_get_device_size(void); 28 int stm32_sdmmc2_mmc_init(struct stm32_sdmmc2_params *params); 29 bool plat_sdmmc2_use_dma(unsigned int instance, unsigned int memory); 30 31 #endif /* STM32_SDMMC2_H */ 32