mirror of
https://github.com/lwfinger/rtl8188eu.git
synced 2024-11-25 14:03:40 +00:00
rtl8188eu: Remove CONFIG_EASY_REPLACEMENT - not defined
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
This commit is contained in:
parent
6b0ff2a824
commit
3eb2ca707d
1 changed files with 0 additions and 37 deletions
|
@ -792,47 +792,10 @@ int rtw_init_netdev_name(struct net_device *pnetdev, const char *ifname)
|
||||||
{
|
{
|
||||||
_adapter *padapter = rtw_netdev_priv(pnetdev);
|
_adapter *padapter = rtw_netdev_priv(pnetdev);
|
||||||
|
|
||||||
#ifdef CONFIG_EASY_REPLACEMENT
|
|
||||||
struct net_device *TargetNetdev = NULL;
|
|
||||||
_adapter *TargetAdapter = NULL;
|
|
||||||
struct net *devnet = NULL;
|
|
||||||
|
|
||||||
if (padapter->bDongle == 1) {
|
|
||||||
#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,24))
|
|
||||||
TargetNetdev = dev_get_by_name("wlan0");
|
|
||||||
#else
|
|
||||||
#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,26))
|
|
||||||
devnet = pnetdev->nd_net;
|
|
||||||
#else
|
|
||||||
devnet = dev_net(pnetdev);
|
|
||||||
#endif
|
|
||||||
TargetNetdev = dev_get_by_name(devnet, "wlan0");
|
|
||||||
#endif
|
|
||||||
if (TargetNetdev) {
|
|
||||||
DBG_88E("Force onboard module driver disappear !!!\n");
|
|
||||||
TargetAdapter = rtw_netdev_priv(TargetNetdev);
|
|
||||||
TargetAdapter->DriverState = DRIVER_DISAPPEAR;
|
|
||||||
|
|
||||||
padapter->pid[0] = TargetAdapter->pid[0];
|
|
||||||
padapter->pid[1] = TargetAdapter->pid[1];
|
|
||||||
padapter->pid[2] = TargetAdapter->pid[2];
|
|
||||||
|
|
||||||
dev_put(TargetNetdev);
|
|
||||||
unregister_netdev(TargetNetdev);
|
|
||||||
|
|
||||||
if (TargetAdapter->chip_type == padapter->chip_type)
|
|
||||||
rtw_proc_remove_one(TargetNetdev);
|
|
||||||
|
|
||||||
padapter->DriverState = DRIVER_REPLACE_DONGLE;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
if (dev_alloc_name(pnetdev, ifname) < 0)
|
if (dev_alloc_name(pnetdev, ifname) < 0)
|
||||||
RT_TRACE(_module_os_intfs_c_,_drv_err_,("dev_alloc_name, fail!\n"));
|
RT_TRACE(_module_os_intfs_c_,_drv_err_,("dev_alloc_name, fail!\n"));
|
||||||
|
|
||||||
netif_carrier_off(pnetdev);
|
netif_carrier_off(pnetdev);
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue