mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-08 11:50:43 +09:00
net: wireless: rockchip_wlan: update realtek wifi support
support wifi driver work as ko module or compile into kernel 1. wifi driver work as ko module, configs show as below: CONFIG_WIFI_LOAD_DRIVER_WHEN_KERNEL_BOOTUP=n CONFIG_RTL8188EU = m and CONFIG_RTL8188FU = m 2. wifi driver compile into kernel, configs show as below: ps: Only one Realtek driver can be compiled into the kernel CONFIG_WIFI_LOAD_DRIVER_WHEN_KERNEL_BOOTUP=y CONFIG_RTL8188EU = y or CONFIG_RTL8188FU = y Change-Id: I40e33a6f27597f9f90d9987d189b74fb637c40c1 Signed-off-by: Xu Xuehui <xxh@rock-chips.com>
This commit is contained in:
@@ -7,7 +7,7 @@ if WL_ROCKCHIP
|
||||
|
||||
config WIFI_LOAD_DRIVER_WHEN_KERNEL_BOOTUP
|
||||
bool "Wifi load driver when kernel bootup"
|
||||
default y
|
||||
default n
|
||||
---help---
|
||||
Wifi driver will be load (use late_initcall) when kernel bootup
|
||||
|
||||
@@ -17,17 +17,8 @@ menuconfig RTL_WIRELESS_SOLUTION
|
||||
bool "Realtek Wireless Device Driver Support"
|
||||
default y
|
||||
|
||||
if RTL_WIRELESS_SOLUTION
|
||||
choice
|
||||
prompt "Realtek WiFi Device Driver Support"
|
||||
default RTL8188EU
|
||||
|
||||
config RTL_WIFI_NONE
|
||||
bool "No Realtek WiFi"
|
||||
|
||||
source "drivers/net/wireless/rockchip_wlan/rtl8188eu/Kconfig"
|
||||
source "drivers/net/wireless/rockchip_wlan/rtl8188fu/Kconfig"
|
||||
endchoice
|
||||
endif # RTL_WIRELESS_SOLUTION
|
||||
|
||||
|
||||
endif # WL_ROCKCHIP
|
||||
|
||||
@@ -1696,8 +1696,8 @@ void rockchip_wifi_exit_module_rtkwifi(void)
|
||||
late_initcall(rockchip_wifi_init_module_rtkwifi);
|
||||
module_exit(rockchip_wifi_exit_module_rtkwifi);
|
||||
#else
|
||||
EXPORT_SYMBOL(rockchip_wifi_init_module_rtkwifi);
|
||||
EXPORT_SYMBOL(rockchip_wifi_exit_module_rtkwifi);
|
||||
module_init(rockchip_wifi_init_module_rtkwifi);
|
||||
module_exit(rockchip_wifi_exit_module_rtkwifi);
|
||||
#endif
|
||||
//module_init(rtw_drv_entry);
|
||||
//module_exit(rtw_drv_halt);
|
||||
|
||||
@@ -1250,7 +1250,7 @@ EXTRA_CFLAGS += -DCONFIG_CONCURRENT_MODE
|
||||
ARCH := arm
|
||||
CROSS_COMPILE := /home/android_sdk/Rockchip/Rk3188/prebuilts/gcc/linux-x86/arm/arm-eabi-4.6/bin/arm-eabi-
|
||||
KSRC := /home/android_sdk/Rockchip/Rk3188/kernel
|
||||
MODULE_NAME := wlan
|
||||
MODULE_NAME := 8188fu
|
||||
endif
|
||||
|
||||
ifeq ($(CONFIG_PLATFORM_ARM_RK3066), y)
|
||||
|
||||
@@ -1717,8 +1717,8 @@ void rockchip_wifi_exit_module(void)
|
||||
late_initcall(rockchip_wifi_init_module_rtkwifi);
|
||||
module_exit(rockchip_wifi_exit_module_rtkwifi);
|
||||
#else
|
||||
EXPORT_SYMBOL(rockchip_wifi_init_module_rtkwifi);
|
||||
EXPORT_SYMBOL(rockchip_wifi_exit_module_rtkwifi);
|
||||
module_init(rockchip_wifi_init_module_rtkwifi);
|
||||
module_exit(rockchip_wifi_exit_module_rtkwifi);
|
||||
#endif
|
||||
#else
|
||||
#ifdef CONFIG_ANDROID_4_2
|
||||
|
||||
@@ -153,31 +153,25 @@ static int wifi_driver_insmod = 0;
|
||||
static int wifi_init_exit_module(int enable)
|
||||
{
|
||||
int ret = 0;
|
||||
int type = 0;
|
||||
#ifdef CONFIG_WIFI_LOAD_DRIVER_WHEN_KERNEL_BOOTUP
|
||||
int type = 0;
|
||||
type = get_wifi_chip_type();
|
||||
#else
|
||||
type = get_wifi_chip_type();
|
||||
//#ifdef CONFIG_RKWIFI
|
||||
if (type < WIFI_AP6XXX_SERIES) {
|
||||
if (enable > 0)
|
||||
ret = rockchip_wifi_init_module_rkwifi();
|
||||
else
|
||||
rockchip_wifi_exit_module_rkwifi();
|
||||
return ret;
|
||||
}
|
||||
//#endif
|
||||
//#ifdef CONFIG_RTL_WIRELESS_SOLUTION
|
||||
if (type < WIFI_RTL_SERIES) {
|
||||
if (enable > 0)
|
||||
ret = rockchip_wifi_init_module_rtkwifi();
|
||||
else
|
||||
rockchip_wifi_exit_module_rtkwifi();
|
||||
return ret;
|
||||
}
|
||||
//#endif
|
||||
if (enable > 0)
|
||||
ret = rockchip_wifi_init_module_rkwifi();
|
||||
else
|
||||
rockchip_wifi_exit_module_rkwifi();
|
||||
return ret;
|
||||
}
|
||||
if (type < WIFI_RTL_SERIES) {
|
||||
if (enable > 0)
|
||||
ret = rockchip_wifi_init_module_rtkwifi();
|
||||
else
|
||||
rockchip_wifi_exit_module_rtkwifi();
|
||||
return ret;
|
||||
}
|
||||
#endif
|
||||
return ret;
|
||||
return ret;
|
||||
}
|
||||
|
||||
static ssize_t wifi_driver_write(struct class *cls, struct class_attribute *attr, const char *_buf, size_t _count)
|
||||
|
||||
Reference in New Issue
Block a user