RK-RFKILL fix bug: build failure if use other board config
authorCMY <cmy@rock-chips.com>
Fri, 8 Jun 2012 08:46:16 +0000 (16:46 +0800)
committerCMY <cmy@rock-chips.com>
Fri, 8 Jun 2012 08:47:15 +0000 (16:47 +0800)
arch/arm/configs/rk29_ddr3sdk_defconfig
arch/arm/configs/rk30_sdk_defconfig
drivers/bluetooth/hci_ldisc.c
net/rfkill/Kconfig
net/rfkill/rfkill-rk.c

index 4f97bb59402440d3aea4d397f3ab09305687d91b..1319e619a2fd1582a5bde52d2324db7c4eb0947f 100755 (executable)
@@ -174,6 +174,7 @@ CONFIG_BT_HCIBCM4325=y
 CONFIG_BT_AUTOSLEEP=y
 CONFIG_RFKILL=y
 # CONFIG_RFKILL_PM is not set
+CONFIG_RFKILL_RK=y
 CONFIG_DEVTMPFS=y
 CONFIG_DEVTMPFS_MOUNT=y
 # CONFIG_FIRMWARE_IN_KERNEL is not set
index b892d134c5f7062922039effc371d0bdd6445d2d..3796f5fc4f235e2996c400c6fd59d9a5e45e5c66 100644 (file)
@@ -177,6 +177,7 @@ CONFIG_BT_HCIUART_LL=y
 CONFIG_BT_HCIBCM4325=y
 CONFIG_BT_AUTOSLEEP=y
 CONFIG_RFKILL=y
+CONFIG_RFKILL_RK=y
 CONFIG_DEVTMPFS=y
 CONFIG_DEVTMPFS_MOUNT=y
 # CONFIG_FIRMWARE_IN_KERNEL is not set
index 8a5b66980c65f7b486174f1bc15f0ac1fe92bc21..452132a5ebdee946474de19e1698769e5b13ded7 100755 (executable)
 
 #include "hci_uart.h"
 
-#ifdef CONFIG_BT_AUTOSLEEP
-extern int rfkill_rk_sleep_bt(bool bSleep);
-#endif
-
 #define VERSION "2.2"
 
 static int reset = 0;
@@ -138,8 +134,14 @@ int hci_uart_tx_wakeup(struct hci_uart *hu)
 restart:
        clear_bit(HCI_UART_TX_WAKEUP, &hu->tx_state);
 /*added by Barry,for broadcom 4325*/
-#ifdef CONFIG_BT_AUTOSLEEP  
-       rfkill_rk_sleep_bt(false);
+#ifdef CONFIG_BT_AUTOSLEEP
+#ifdef CONFIG_RFKILL_RK
+    extern int rfkill_rk_sleep_bt(bool bSleep);
+    rfkill_rk_sleep_bt(false);
+#else
+    extern void bcm4325_sleep(unsigned long bSleep);
+    bcm4325_sleep(0);
+#endif
 #endif
        while ((skb = hci_uart_dequeue(hu))) {
                int len;
index 224786574160d1235ad3d38a9dd32fc5dea9e523..0576cb0a86e8e127d194a4ae25158e25b23bbb31 100644 (file)
@@ -54,9 +54,8 @@ config RFKILL_RESET
         default n
 
 config RFKILL_RK
-        tristate "Rockchips RFKILL driver"
+        bool "Rockchips RFKILL driver"
         depends on RFKILL
-        default y
         help
           rockchips rfkill driver for rk29/rk30
 
index 31d12b312359c60f4c235a2c54b10328584526cb..d5815ac06955b63de1bee45770ae347cfc248389 100644 (file)
@@ -75,7 +75,7 @@ enum {
 
 // RK29+BCM4329, ÆäwifiÓëbtµÄpower¿ØÖƽÅÊǽÓÔÚÒ»ÆðµÄ
 // ÔÚ¸øbtϵçʱ£¬ÐèÒªÏÈÅжÏwifi״̬
-#if defined(CONFIG_ARCH_RK29) && defined(CONFIG_BCM4329)
+#if defined(CONFIG_BCM4329)
 #define WIFI_BT_POWER_TOGGLE    1
 extern int rk29sdk_bt_power_state;
 extern int rk29sdk_wifi_power_state;