Quellcode durchsuchen

[BSP][DM365] update mmcsd driver.

weety vor 7 Jahren
Ursprung
Commit
db41e7e30e
3 geänderte Dateien mit 5 neuen und 5 gelöschten Zeilen
  1. 0 3
      bsp/dm365/applications/application.c
  2. 4 1
      bsp/dm365/drivers/mmcsd.c
  3. 1 1
      bsp/dm365/drivers/mmcsd.h

+ 0 - 3
bsp/dm365/applications/application.c

@@ -67,9 +67,6 @@ int main(void)
 #endif
 
 #ifdef RT_USING_SDIO
-	rt_mmcsd_core_init();
-	rt_mmcsd_blk_init();
-	rt_hw_mmcsd_init();
 	timeout = 0;
 	while ((rt_device_find("sd0") == RT_NULL) && (timeout++ < RT_TICK_PER_SECOND*2))
 	{

+ 4 - 1
bsp/dm365/drivers/mmcsd.c

@@ -1388,7 +1388,7 @@ static void rt_hw_edma_init(void)
 ** µ÷ÓÃÄ£¿é: ÎÞ
 **
 ********************************************************************************************************/
-rt_int32_t rt_hw_mmcsd_init(void)
+int rt_hw_mmcsd_init(void)
 {
 	struct clk  *clk;
 	struct mmc_dm365_host *dm365_host;
@@ -1477,3 +1477,6 @@ err:
 
 	return -RT_ENOMEM;
 }
+
+INIT_DEVICE_EXPORT(rt_hw_mmcsd_init);
+

+ 1 - 1
bsp/dm365/drivers/mmcsd.h

@@ -140,6 +140,6 @@ typedef struct {
 	volatile rt_uint32_t MMCFIFOCTL;
 }mmcsd_regs_t;
 
-extern rt_int32_t rt_hw_mmcsd_init(void);
+extern int rt_hw_mmcsd_init(void);
 
 #endif