From 6a28a69ae8c51069c05f0a479be609fabef11790 Mon Sep 17 00:00:00 2001 From: Bartlomiej Zolnierkiewicz Date: Sun, 26 Apr 2009 16:05:46 +0200 Subject: Staging: rt2860: remove CONFIG_STA_SUPPORT ifdefs Signed-off-by: Bartlomiej Zolnierkiewicz Signed-off-by: Greg Kroah-Hartman --- drivers/staging/rt2860/rt_main_dev.c | 35 ----------------------------------- 1 file changed, 35 deletions(-) (limited to 'drivers/staging/rt2860/rt_main_dev.c') diff --git a/drivers/staging/rt2860/rt_main_dev.c b/drivers/staging/rt2860/rt_main_dev.c index e5b246bb5cea..f5797f19725b 100644 --- a/drivers/staging/rt2860/rt_main_dev.c +++ b/drivers/staging/rt2860/rt_main_dev.c @@ -72,9 +72,7 @@ INT rt28xx_send_packets(IN struct sk_buff *skb_p, IN struct net_device *net_dev) static void CfgInitHook(PRTMP_ADAPTER pAd); -#ifdef CONFIG_STA_SUPPORT extern const struct iw_handler_def rt28xx_iw_handler_def; -#endif // CONFIG_STA_SUPPORT // #if WIRELESS_EXT >= 12 // This function will be called when query /proc @@ -199,7 +197,6 @@ int rt28xx_close(IN PNET_DEV dev) if (pAd == NULL) return 0; // close ok -#ifdef CONFIG_STA_SUPPORT IF_DEV_CONFIG_OPMODE_ON_STA(pAd) { // If dirver doesn't wake up firmware here, @@ -259,7 +256,6 @@ int rt28xx_close(IN PNET_DEV dev) MlmeRadioOff(pAd); pAd->bPCIclkOff = FALSE; } -#endif // CONFIG_STA_SUPPORT // RTMP_SET_FLAG(pAd, fRTMP_ADAPTER_HALT_IN_PROGRESS); @@ -278,13 +274,10 @@ int rt28xx_close(IN PNET_DEV dev) // Close kernel threads or tasklets kill_thread_task(pAd); - -#ifdef CONFIG_STA_SUPPORT IF_DEV_CONFIG_OPMODE_ON_STA(pAd) { MacTableReset(pAd); } -#endif // CONFIG_STA_SUPPORT // MeasureReqTabExit(pAd); @@ -404,10 +397,8 @@ static int rt28xx_init(IN struct net_device *net_dev) CfgInitHook(pAd); -#ifdef CONFIG_STA_SUPPORT IF_DEV_CONFIG_OPMODE_ON_STA(pAd) NdisAllocateSpinLock(&pAd->MacTabLock); -#endif // CONFIG_STA_SUPPORT // MeasureReqTabInit(pAd); TpcReqTabInit(pAd); @@ -585,13 +576,11 @@ int rt28xx_open(IN PNET_DEV dev) if (rt28xx_init(net_dev) == FALSE) goto err; -#ifdef CONFIG_STA_SUPPORT IF_DEV_CONFIG_OPMODE_ON_STA(pAd) { NdisZeroMemory(pAd->StaCfg.dev_name, 16); NdisMoveMemory(pAd->StaCfg.dev_name, net_dev->name, strlen(net_dev->name)); } -#endif // CONFIG_STA_SUPPORT // // Set up the Mac address NdisMoveMemory(net_dev->dev_addr, (void *) pAd->CurrentAddress, 6); @@ -601,7 +590,6 @@ int rt28xx_open(IN PNET_DEV dev) // Various AP function init -#ifdef CONFIG_STA_SUPPORT IF_DEV_CONFIG_OPMODE_ON_STA(pAd) { #ifdef WPA_SUPPLICANT_SUPPORT @@ -617,7 +605,6 @@ int rt28xx_open(IN PNET_DEV dev) #endif // WPA_SUPPLICANT_SUPPORT // } -#endif // CONFIG_STA_SUPPORT // // Enable Interrupt RT28XX_IRQ_ENABLE(pAd); @@ -632,10 +619,8 @@ int rt28xx_open(IN PNET_DEV dev) printk("0x1300 = %08x\n", reg); } -#ifdef CONFIG_STA_SUPPORT IF_DEV_CONFIG_OPMODE_ON_STA(pAd) RTMPInitPCIeLinkCtrlValue(pAd); -#endif // CONFIG_STA_SUPPORT // return (retval); @@ -669,14 +654,12 @@ static NDIS_STATUS rt_ieee80211_if_setup(struct net_device *dev, PRTMP_ADAPTER p //ether_setup(dev); -#ifdef CONFIG_STA_SUPPORT #if WIRELESS_EXT >= 12 if (pAd->OpMode == OPMODE_STA) { dev->wireless_handlers = &rt28xx_iw_handler_def; } #endif //WIRELESS_EXT >= 12 -#endif // CONFIG_STA_SUPPORT // #if WIRELESS_EXT < 21 dev->get_wireless_stats = rt28xx_get_wireless_stats; @@ -740,9 +723,7 @@ INT __devinit rt28xx_probe( struct pci_dev *dev_p = (struct pci_dev *)_dev_p; -#ifdef CONFIG_STA_SUPPORT DBGPRINT(RT_DEBUG_TRACE, ("STA Driver version-%s\n", STA_DRIVER_VERSION)); -#endif // CONFIG_STA_SUPPORT // net_dev = alloc_etherdev(sizeof(PRTMP_ADAPTER)); if (net_dev == NULL) @@ -774,17 +755,13 @@ INT __devinit rt28xx_probe( RT28XXNetDevInit(_dev_p, net_dev, pAd); -#ifdef CONFIG_STA_SUPPORT pAd->StaCfg.OriDevType = net_dev->type; -#endif // CONFIG_STA_SUPPORT // // Post config if (RT28XXProbePostConfig(_dev_p, pAd, 0) == FALSE) goto err_out_unmap; -#ifdef CONFIG_STA_SUPPORT pAd->OpMode = OPMODE_STA; -#endif // CONFIG_STA_SUPPORT // // sample move if (rt_ieee80211_if_setup(net_dev, pAd) != NDIS_STATUS_SUCCESS) @@ -841,7 +818,6 @@ int rt28xx_packet_xmit(struct sk_buff *skb) int status = 0; PNDIS_PACKET pPacket = (PNDIS_PACKET) skb; -#ifdef CONFIG_STA_SUPPORT IF_DEV_CONFIG_OPMODE_ON_STA(pAd) { // Drop send request since we are in monitor mode @@ -851,7 +827,6 @@ int rt28xx_packet_xmit(struct sk_buff *skb) goto done; } } -#endif // CONFIG_STA_SUPPORT // // EapolStart size is 18 if (skb->len < 14) @@ -869,17 +844,12 @@ int rt28xx_packet_xmit(struct sk_buff *skb) } #endif - - -#ifdef CONFIG_STA_SUPPORT IF_DEV_CONFIG_OPMODE_ON_STA(pAd) { STASendPackets((NDIS_HANDLE)pAd, (PPNDIS_PACKET) &pPacket, 1); } -#endif // CONFIG_STA_SUPPORT // - status = 0; done: @@ -947,10 +917,8 @@ struct iw_statistics *rt28xx_get_wireless_stats( if(pAd->iw_stats.qual.qual > 100) pAd->iw_stats.qual.qual = 100; -#ifdef CONFIG_STA_SUPPORT if (pAd->OpMode == OPMODE_STA) pAd->iw_stats.qual.level = RTMPMaxRssi(pAd, pAd->StaCfg.RssiSample.LastRssi0, pAd->StaCfg.RssiSample.LastRssi1, pAd->StaCfg.RssiSample.LastRssi2); -#endif // CONFIG_STA_SUPPORT // pAd->iw_stats.qual.noise = pAd->BbpWriteLatch[66]; // noise level (dBm) @@ -1002,13 +970,10 @@ INT rt28xx_ioctl( return -ENETDOWN; } - -#ifdef CONFIG_STA_SUPPORT IF_DEV_CONFIG_OPMODE_ON_STA(pAd) { ret = rt28xx_sta_ioctl(net_dev, rq, cmd); } -#endif // CONFIG_STA_SUPPORT // return ret; } -- cgit v1.2.3-59-g8ed1b