From: hjc Date: Fri, 22 Feb 2013 08:11:06 +0000 (+0800) Subject: rk3168_86v: xbw SDMMC IO voltage X-Git-Tag: firefly_0821_release~7573 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=e3efe344cbfb856fe3ce633339960ef4a915d65f;p=firefly-linux-kernel-4.4.55.git rk3168_86v: xbw SDMMC IO voltage --- diff --git a/arch/arm/mach-rk30/board-rk3168-86v-sdmmc-config.c b/arch/arm/mach-rk30/board-rk3168-86v-sdmmc-config.c index d7a110af3df4..b873bba667bb 100755 --- a/arch/arm/mach-rk30/board-rk3168-86v-sdmmc-config.c +++ b/arch/arm/mach-rk30/board-rk3168-86v-sdmmc-config.c @@ -38,6 +38,21 @@ */ #define RK29SDK_SD_CARD_PWR_EN RK30_PIN3_PA1 #define RK29SDK_SD_CARD_PWR_EN_LEVEL GPIO_LOW +int rk31sdk_get_sdmmc0_pin_io_voltage(void) +{ + int voltage; +#define RK31SDK_SET_SDMMC0_PIN_VOLTAGE + + /************************************************************************************** + ** Please tell me how much voltage of your SDMMC0-pin in your project. + ** + ** ÀýÈç: ÓеÄÏîÄ¿£¬ËüµÄSDMMC0ËùÔÚµÄRKÖ÷¿ØµÄIO×飬ÏëÓÃ1.8V, ¶ø¿¨±¾ÉíÓÃ3.3V, + ** ¶øÖмäͨ¹ý¸öµçƽת»».ÄÇô£¬Äú´Ëʱ£¬Ó¦¸ÃÉèÖÃÏÂÃæµÄvoltageֵΪ 1.8V(¼´1800mv) + ***************************************************************************************/ + voltage = 3300; //default the voltage 3300mv. + + return voltage; +} /* * define the card-detect-pin. @@ -117,23 +132,25 @@ #endif // #if COMBO_MODULE_MT6620_CDT--#endif #endif -double rk31sdk_get_sdio_wifi_voltage(void) +int rk31sdk_get_sdio_wifi_voltage(void) { - double voltage; + int voltage; /****************************************************************************** ** Please tell me how much wifi-module uses voltage in your project. ******************************************************************************/ #if defined(CONFIG_BCM4329) || defined(CONFIG_BCM4319) || defined(CONFIG_RK903) || defined(CONFIG_RK901) - voltage = 1.8 ; //power 1.8V + voltage = 1800 ; //power 1800mV -#elif defined(CONFIG_MT5931_MT6622)||defined(CONFIG_MT5931)||defined(CONFIG_MT6620) - voltage = 2.8 ; //power 2.8V +#elif defined(CONFIG_MT5931_MT6622)||defined(CONFIG_MT5931) + voltage = 1800 ; //power 1800V +#elif defined(CONFIG_MT6620) + voltage = 2800 ; //power 2800V #elif defined(CONFIG_RDA5990)||defined(CONFIG_RTL8723AS) - voltage = 3.3 ; //power 3.3V + voltage = 3300 ; //power 3300V #else //default, sdio use 3.0V - voltage = 3.0 ; //power 3.0V + voltage = 3000 ; //power 3000V #endif return voltage;