aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/staging/rt2860/rt_profile.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/staging/rt2860/rt_profile.c')
-rw-r--r--drivers/staging/rt2860/rt_profile.c44
1 files changed, 4 insertions, 40 deletions
diff --git a/drivers/staging/rt2860/rt_profile.c b/drivers/staging/rt2860/rt_profile.c
index d92b14328d40..3bc41f83f624 100644
--- a/drivers/staging/rt2860/rt_profile.c
+++ b/drivers/staging/rt2860/rt_profile.c
@@ -710,7 +710,7 @@ static int rtmp_parse_key_buffer_from_file(IN PRTMP_ADAPTER pAd,IN char *buffe
CipherAlg = CIPHER_WEP128;
pAd->SharedKey[i][idx].CipherAlg = CipherAlg;
- DBGPRINT(RT_DEBUG_TRACE, ("I/F(ra%d) Key%dStr=%s and type=%s\n", i, idx+1, keybuff, (KeyType == 0) ? "Hex":"Ascii"));
+ DBGPRINT(RT_DEBUG_TRACE, ("I/F(wlan%d) Key%dStr=%s and type=%s\n", i, idx+1, keybuff, (KeyType == 0) ? "Hex":"Ascii"));
return 1;
}
else
@@ -731,12 +731,12 @@ static int rtmp_parse_key_buffer_from_file(IN PRTMP_ADAPTER pAd,IN char *buffe
CipherAlg = CIPHER_WEP128;
pAd->SharedKey[i][idx].CipherAlg = CipherAlg;
- DBGPRINT(RT_DEBUG_TRACE, ("I/F(ra%d) Key%dStr=%s and type=%s\n", i, idx+1, keybuff, (KeyType == 0) ? "Hex":"Ascii"));
+ DBGPRINT(RT_DEBUG_TRACE, ("I/F(wlan%d) Key%dStr=%s and type=%s\n", i, idx+1, keybuff, (KeyType == 0) ? "Hex":"Ascii"));
return 1;
}
else
{//Invalid key length
- DBGPRINT(RT_DEBUG_ERROR, ("I/F(ra%d) Key%dStr is Invalid key length! KeyLen = %ld!\n", i, idx+1, KeyLen));
+ DBGPRINT(RT_DEBUG_ERROR, ("I/F(wlan%d) Key%dStr is Invalid key length! KeyLen = %ld!\n", i, idx+1, KeyLen));
return 0;
}
}
@@ -860,7 +860,7 @@ NDIS_STATUS RTMPReadParametersHook(
{
PUCHAR src = NULL;
struct file *srcf;
- INT retval, orgfsuid, orgfsgid;
+ INT retval;
mm_segment_t orgfs;
CHAR *buffer;
CHAR *tmpbuf;
@@ -884,15 +884,6 @@ NDIS_STATUS RTMPReadParametersHook(
src = STA_PROFILE_PATH;
- // Save uid and gid used for filesystem access.
- // Set user and group to 0 (root)
-#ifndef RT30xx
- orgfsuid = current_fsuid();
- orgfsgid = current_fsgid();
- /* Hm, can't really do this nicely anymore, so rely on these files
- * being set to the proper permission to read them... */
- /* current->cred->fsuid = current->cred->fsgid = 0; */
-#endif
orgfs = get_fs();
set_fs(KERNEL_DS);
@@ -1230,14 +1221,10 @@ NDIS_STATUS RTMPReadParametersHook(
//WirelessEvent
if(RTMPGetKeyParameter("WirelessEvent", tmpbuf, 10, buffer))
{
-#if WIRELESS_EXT >= 15
if(simple_strtol(tmpbuf, 0, 10) != 0)
pAd->CommonCfg.bWirelessEvent = simple_strtol(tmpbuf, 0, 10);
else
pAd->CommonCfg.bWirelessEvent = 0; // disable
-#else
- pAd->CommonCfg.bWirelessEvent = 0; // disable
-#endif
DBGPRINT(RT_DEBUG_TRACE, ("WirelessEvent=%d\n", pAd->CommonCfg.bWirelessEvent));
}
if(RTMPGetKeyParameter("WiFiTest", tmpbuf, 10, buffer))
@@ -1442,23 +1429,6 @@ NDIS_STATUS RTMPReadParametersHook(
DBGPRINT(RT_DEBUG_TRACE, ("TGnWifiTest=%d\n", pAd->StaCfg.bTGnWifiTest));
}
}
-
-#ifdef RT30xx
- {
- if(RTMPGetKeyParameter("AntDiversity", tmpbuf, 10, buffer))
- {
- for (i = 0, macptr = rstrtok(tmpbuf,";"); macptr; macptr = rstrtok(NULL,";"), i++)
- {
- if(simple_strtol(macptr, 0, 10) != 0) //Enable
- pAd->CommonCfg.bRxAntDiversity = TRUE;
- else //Disable
- pAd->CommonCfg.bRxAntDiversity = FALSE;
-
- DBGPRINT(RT_DEBUG_ERROR, ("AntDiversity=%d\n", pAd->CommonCfg.bRxAntDiversity));
- }
- }
- }
-#endif // RT30xx //
}
}
else
@@ -1571,21 +1541,15 @@ static void HTParametersHook(
if (Value == 0)
{
pAd->CommonCfg.BACapability.field.AutoBA = FALSE;
-#ifdef RT30xx
pAd->CommonCfg.BACapability.field.Policy = BA_NOTUSE;
-#endif
}
else
{
pAd->CommonCfg.BACapability.field.AutoBA = TRUE;
-#ifdef RT30xx
pAd->CommonCfg.BACapability.field.Policy = IMMED_BA;
-#endif
}
pAd->CommonCfg.REGBACapability.field.AutoBA = pAd->CommonCfg.BACapability.field.AutoBA;
-#ifdef RT30xx
pAd->CommonCfg.REGBACapability.field.Policy = pAd->CommonCfg.BACapability.field.Policy;
-#endif
DBGPRINT(RT_DEBUG_TRACE, ("HT: Auto BA = %s\n", (Value==0) ? "Disable" : "Enable"));
}