You've already forked wifi-rtl8852bs
mirror of
https://github.com/armbian/wifi-rtl8852bs.git
synced 2026-01-06 11:09:01 -08:00
fix missing linux/rfkill-wlan.h in mainline kernel
This commit is contained in:
@@ -2125,7 +2125,9 @@ void rtw_macaddr_cfg(u8 *out, const u8 *hw_mac_addr)
|
||||
}
|
||||
|
||||
err_chk:
|
||||
#ifdef CONFIG_PLATFORM_ROCKCHIP
|
||||
platform_wifi_mac_addr(mac);
|
||||
#endif
|
||||
|
||||
if (rtw_check_invalid_mac_address(mac, _TRUE) == _TRUE) {
|
||||
#if DEFAULT_RANDOM_MACADDR
|
||||
|
||||
@@ -1018,12 +1018,14 @@ static int __init rtw_drv_entry(void)
|
||||
|
||||
rtw_android_wifictrl_func_add();
|
||||
|
||||
#ifdef CONFIG_PLATFORM_ROCKCHIP
|
||||
ret = platform_wifi_power_on();
|
||||
if (ret) {
|
||||
RTW_INFO("%s: power on failed!!(%d)\n", __FUNCTION__, ret);
|
||||
ret = -1;
|
||||
goto exit;
|
||||
}
|
||||
#endif
|
||||
|
||||
sdio_drvpriv.drv_registered = _TRUE;
|
||||
rtw_suspend_lock_init();
|
||||
@@ -1047,7 +1049,9 @@ static int __init rtw_drv_entry(void)
|
||||
goto exit;
|
||||
|
||||
poweroff:
|
||||
#ifdef CONFIG_PLATFORM_ROCKCHIP
|
||||
platform_wifi_power_off();
|
||||
#endif
|
||||
|
||||
exit:
|
||||
RTW_PRINT("module init ret=%d\n", ret);
|
||||
@@ -1064,7 +1068,9 @@ static void __exit rtw_drv_halt(void)
|
||||
|
||||
rtw_android_wifictrl_func_del();
|
||||
|
||||
#ifdef CONFIG_PLATFORM_ROCKCHIP
|
||||
platform_wifi_power_off();
|
||||
#endif
|
||||
|
||||
rtw_suspend_lock_uninit();
|
||||
rtw_drv_proc_deinit();
|
||||
|
||||
@@ -13,6 +13,7 @@
|
||||
*
|
||||
*****************************************************************************/
|
||||
#include <drv_types.h>
|
||||
#ifdef CONFIG_PLATFORM_ROCKCHIP
|
||||
#include <linux/rfkill-wlan.h>
|
||||
extern int get_wifi_chip_type(void);
|
||||
extern int rockchip_wifi_power(int on);
|
||||
@@ -52,3 +53,4 @@ void platform_wifi_power_off(void)
|
||||
rockchip_wifi_power(0);
|
||||
|
||||
}
|
||||
#endif
|
||||
|
||||
@@ -39,8 +39,10 @@ void pci_free_cache_mem(struct pci_dev *pdev, void *vir_addr,
|
||||
void pci_free_noncache_mem(struct pci_dev *pdev, void *vir_addr,
|
||||
dma_addr_t *bus_addr, size_t size);
|
||||
#endif
|
||||
#ifdef CONFIG_PLATFORM_ROCKCHIP
|
||||
int platform_wifi_power_on(void);
|
||||
void platform_wifi_power_off(void);
|
||||
void platform_wifi_get_oob_irq(int *oob_irq);
|
||||
void platform_wifi_mac_addr(u8 *mac_addr);
|
||||
#endif
|
||||
#endif /* __PLATFORM_OPS_H__ */
|
||||
|
||||
Reference in New Issue
Block a user