staging: vt6655: Replace C99 comments in power.c and upc.h.
This patch fixes the following checkpatch.pl warnings: ERROR: do not use C99 // comments +// ERROR: do not use C99 // comments +// For memory mapped IO ERROR: do not use C99 // comments +// ERROR: do not use C99 // comments +#endif // __UPC_H__ ERROR: do not use C99 // comments + // set period of power up before TBTT ERROR: do not use C99 // comments + // set AID ERROR: do not use C99 // comments + // set ATIM Window ERROR: do not use C99 // comments + // Set AutoSleep ERROR: do not use C99 // comments + // Set HWUTSF ERROR: do not use C99 // comments + // clear always listen beacon ERROR: do not use C99 // comments + // first time set listen next beacon ERROR: do not use C99 // comments + // always listen beacon ERROR: do not use C99 // comments + // enable power saving hw function ERROR: do not use C99 // comments + // disable power saving hw function ERROR: do not use C99 // comments + //clear AutoSleep ERROR: do not use C99 // comments + //clear HWUTSF ERROR: do not use C99 // comments + // set always listen beacon Signed-off-by: Nicholas Parkanyi <n.parkanyi@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
Родитель
73c4c6eee1
Коммит
c3dd5a08d7
|
@ -71,33 +71,33 @@ PSvEnablePowerSaving(
|
||||||
struct vnt_private *pDevice = hDeviceContext;
|
struct vnt_private *pDevice = hDeviceContext;
|
||||||
u16 wAID = pDevice->current_aid | BIT(14) | BIT(15);
|
u16 wAID = pDevice->current_aid | BIT(14) | BIT(15);
|
||||||
|
|
||||||
// set period of power up before TBTT
|
/* set period of power up before TBTT */
|
||||||
VNSvOutPortW(pDevice->PortOffset + MAC_REG_PWBT, C_PWBT);
|
VNSvOutPortW(pDevice->PortOffset + MAC_REG_PWBT, C_PWBT);
|
||||||
if (pDevice->op_mode != NL80211_IFTYPE_ADHOC) {
|
if (pDevice->op_mode != NL80211_IFTYPE_ADHOC) {
|
||||||
// set AID
|
/* set AID */
|
||||||
VNSvOutPortW(pDevice->PortOffset + MAC_REG_AIDATIM, wAID);
|
VNSvOutPortW(pDevice->PortOffset + MAC_REG_AIDATIM, wAID);
|
||||||
} else {
|
} else {
|
||||||
// set ATIM Window
|
/* set ATIM Window */
|
||||||
#if 0 /* TODO atim window */
|
#if 0 /* TODO atim window */
|
||||||
MACvWriteATIMW(pDevice->PortOffset, pMgmt->wCurrATIMWindow);
|
MACvWriteATIMW(pDevice->PortOffset, pMgmt->wCurrATIMWindow);
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
// Set AutoSleep
|
/* Set AutoSleep */
|
||||||
MACvRegBitsOn(pDevice->PortOffset, MAC_REG_PSCFG, PSCFG_AUTOSLEEP);
|
MACvRegBitsOn(pDevice->PortOffset, MAC_REG_PSCFG, PSCFG_AUTOSLEEP);
|
||||||
// Set HWUTSF
|
/* Set HWUTSF */
|
||||||
MACvRegBitsOn(pDevice->PortOffset, MAC_REG_TFTCTL, TFTCTL_HWUTSF);
|
MACvRegBitsOn(pDevice->PortOffset, MAC_REG_TFTCTL, TFTCTL_HWUTSF);
|
||||||
|
|
||||||
if (wListenInterval >= 2) {
|
if (wListenInterval >= 2) {
|
||||||
// clear always listen beacon
|
/* clear always listen beacon */
|
||||||
MACvRegBitsOff(pDevice->PortOffset, MAC_REG_PSCTL, PSCTL_ALBCN);
|
MACvRegBitsOff(pDevice->PortOffset, MAC_REG_PSCTL, PSCTL_ALBCN);
|
||||||
// first time set listen next beacon
|
/* first time set listen next beacon */
|
||||||
MACvRegBitsOn(pDevice->PortOffset, MAC_REG_PSCTL, PSCTL_LNBCN);
|
MACvRegBitsOn(pDevice->PortOffset, MAC_REG_PSCTL, PSCTL_LNBCN);
|
||||||
} else {
|
} else {
|
||||||
// always listen beacon
|
/* always listen beacon */
|
||||||
MACvRegBitsOn(pDevice->PortOffset, MAC_REG_PSCTL, PSCTL_ALBCN);
|
MACvRegBitsOn(pDevice->PortOffset, MAC_REG_PSCTL, PSCTL_ALBCN);
|
||||||
}
|
}
|
||||||
|
|
||||||
// enable power saving hw function
|
/* enable power saving hw function */
|
||||||
MACvRegBitsOn(pDevice->PortOffset, MAC_REG_PSCTL, PSCTL_PSEN);
|
MACvRegBitsOn(pDevice->PortOffset, MAC_REG_PSCTL, PSCTL_PSEN);
|
||||||
pDevice->bEnablePSMode = true;
|
pDevice->bEnablePSMode = true;
|
||||||
|
|
||||||
|
@ -122,13 +122,13 @@ PSvDisablePowerSaving(
|
||||||
{
|
{
|
||||||
struct vnt_private *pDevice = hDeviceContext;
|
struct vnt_private *pDevice = hDeviceContext;
|
||||||
|
|
||||||
// disable power saving hw function
|
/* disable power saving hw function */
|
||||||
MACbPSWakeup(pDevice->PortOffset);
|
MACbPSWakeup(pDevice->PortOffset);
|
||||||
//clear AutoSleep
|
/* clear AutoSleep */
|
||||||
MACvRegBitsOff(pDevice->PortOffset, MAC_REG_PSCFG, PSCFG_AUTOSLEEP);
|
MACvRegBitsOff(pDevice->PortOffset, MAC_REG_PSCFG, PSCFG_AUTOSLEEP);
|
||||||
//clear HWUTSF
|
/* clear HWUTSF */
|
||||||
MACvRegBitsOff(pDevice->PortOffset, MAC_REG_TFTCTL, TFTCTL_HWUTSF);
|
MACvRegBitsOff(pDevice->PortOffset, MAC_REG_TFTCTL, TFTCTL_HWUTSF);
|
||||||
// set always listen beacon
|
/* set always listen beacon */
|
||||||
MACvRegBitsOn(pDevice->PortOffset, MAC_REG_PSCTL, PSCTL_ALBCN);
|
MACvRegBitsOn(pDevice->PortOffset, MAC_REG_PSCTL, PSCTL_ALBCN);
|
||||||
|
|
||||||
pDevice->bEnablePSMode = false;
|
pDevice->bEnablePSMode = false;
|
||||||
|
|
|
@ -33,9 +33,9 @@
|
||||||
|
|
||||||
/*--------------------- Export Definitions -------------------------*/
|
/*--------------------- Export Definitions -------------------------*/
|
||||||
|
|
||||||
//
|
|
||||||
// For memory mapped IO
|
/* For memory mapped IO */
|
||||||
//
|
|
||||||
|
|
||||||
#define VNSvInPortB(dwIOAddress, pbyData) \
|
#define VNSvInPortB(dwIOAddress, pbyData) \
|
||||||
do { \
|
do { \
|
||||||
|
@ -86,4 +86,4 @@ do { \
|
||||||
|
|
||||||
/*--------------------- Export Functions --------------------------*/
|
/*--------------------- Export Functions --------------------------*/
|
||||||
|
|
||||||
#endif // __UPC_H__
|
#endif /* __UPC_H__ */
|
||||||
|
|
Загрузка…
Ссылка в новой задаче