From 76e0fa71849640d628bc6619185a6e12f96e2ba3 Mon Sep 17 00:00:00 2001 From: hwg Date: Mon, 17 Sep 2012 15:59:41 +0800 Subject: [PATCH] wifi: modify power control for usb wifi in rk2928 --- arch/arm/mach-rk2928/board-rk2928-sdk-sdmmc.c | 28 +++++++++---------- 1 file changed, 13 insertions(+), 15 deletions(-) diff --git a/arch/arm/mach-rk2928/board-rk2928-sdk-sdmmc.c b/arch/arm/mach-rk2928/board-rk2928-sdk-sdmmc.c index 8512e1e06314..f6ab8ed2532d 100755 --- a/arch/arm/mach-rk2928/board-rk2928-sdk-sdmmc.c +++ b/arch/arm/mach-rk2928/board-rk2928-sdk-sdmmc.c @@ -363,7 +363,19 @@ static int __init rk29sdk_wifi_bt_gpio_control_init(void) return 0; } -#ifndef CONFIG_MACH_RK2928_A720 +#if defined(CONFIG_RTL8192CU) || defined(CONFIG_RTL8188EU) +int rk29sdk_wifi_power(int on) +{ + /*pr_info("%s: %d\n", __func__, on); + if (on){ + pr_info("wifi turn on power\n"); + }else{ + pr_info("wifi shut off power\n"); + }*/ + + return 0; +} +#else int rk29sdk_wifi_power(int on) { pr_info("%s: %d\n", __func__, on); @@ -403,20 +415,6 @@ int rk29sdk_wifi_power(int on) //rk29sdk_wifi_power_state = on; return 0; } -#else -int rk29sdk_wifi_power(int on) -{ - pr_info("%s: %d\n", __func__, on); - if (on){ - rk2928_usb_wifi_on(); - pr_info("wifi turn on power\n"); - }else{ - rk2928_usb_wifi_off(); - pr_info("wifi shut off power\n"); - } - - return 0; -} #endif EXPORT_SYMBOL(rk29sdk_wifi_power); -- 2.34.1