From: Malcolm Priestley <tvboxspy@gmail.com>
To: gregkh@linuxfoundation.org
Cc: linux-wireless@vger.kernel.org, Malcolm Priestley <tvboxspy@gmail.com>
Subject: [PATCH 08/17] staging: vt6656: mac80211 conversion: enable power saving
Date: Wed, 25 Jun 2014 21:14:29 +0100 [thread overview]
Message-ID: <1403727278-6666-9-git-send-email-tvboxspy@gmail.com> (raw)
In-Reply-To: <1403727278-6666-1-git-send-email-tvboxspy@gmail.com>
Convert vnt_enable_power_saving and vnt_disable_power_saving
Remove mgmt->wCurrAID and use priv->current_aid
We nolonger send the PSbSendNullPacket from vnt_enable_power_saving
Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
---
drivers/staging/vt6656/power.c | 23 +----------------------
1 file changed, 1 insertion(+), 22 deletions(-)
diff --git a/drivers/staging/vt6656/power.c b/drivers/staging/vt6656/power.c
index cc28192..6c34d36 100644
--- a/drivers/staging/vt6656/power.c
+++ b/drivers/staging/vt6656/power.c
@@ -60,8 +60,7 @@ static int msglevel = MSG_LEVEL_INFO;
void vnt_enable_power_saving(struct vnt_private *priv, u16 listen_interval)
{
- struct vnt_manager *mgmt = &priv->vnt_mgmt;
- u16 aid = mgmt->wCurrAID | BIT14 | BIT15;
+ u16 aid = priv->current_aid | BIT(14) | BIT(15);
/* set period of power up before TBTT */
vnt_mac_write_word(priv, MAC_REG_PWBT, C_PWBT);
@@ -92,26 +91,12 @@ void vnt_enable_power_saving(struct vnt_private *priv, u16 listen_interval)
/* first time set listen next beacon */
vnt_mac_reg_bits_on(priv, MAC_REG_PSCTL, PSCTL_LNBCN);
-
- mgmt->wCountToWakeUp = listen_interval;
-
} else {
/* always listen beacon */
vnt_mac_reg_bits_on(priv, MAC_REG_PSCTL, PSCTL_ALBCN);
-
- mgmt->wCountToWakeUp = 0;
}
- priv->bEnablePSMode = true;
-
- /* We don't send null pkt in ad hoc mode
- * since beacon will handle this.
- */
- if (priv->op_mode == NL80211_IFTYPE_STATION)
- PSbSendNullPacket(priv);
-
- priv->bPWBitOn = true;
DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO "PS:Power Saving Mode Enable...\n");
}
@@ -137,12 +122,6 @@ void vnt_disable_power_saving(struct vnt_private *priv)
/* set always listen beacon */
vnt_mac_reg_bits_on(priv, MAC_REG_PSCTL, PSCTL_ALBCN);
- priv->bEnablePSMode = false;
-
- if (priv->op_mode == NL80211_IFTYPE_STATION)
- PSbSendNullPacket(priv);
-
- priv->bPWBitOn = false;
}
/*
--
1.9.1
next prev parent reply other threads:[~2014-06-25 20:15 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-06-25 20:14 [PATCH 00/17] staging: vt6656: conversion to mac80211 Malcolm Priestley
2014-06-25 20:14 ` [PATCH 01/17] staging: vt6656: mac80211 conversion: create rx function Malcolm Priestley
2014-06-25 20:14 ` [PATCH 02/17] staging: vt6656: mac80211 conversion: Create tx functions Malcolm Priestley
2014-06-25 20:14 ` [PATCH 03/17] staging: vt6656: mac80211 conversion: add key functions Malcolm Priestley
2014-06-25 20:14 ` [PATCH 04/17] staging: vt6656: mac80211 conversion: main_usb add functions and change usb_driver functions Malcolm Priestley
2014-06-25 20:14 ` [PATCH 05/17] staging: vt6656: mac80211 conversion: add channel bands Malcolm Priestley
2014-06-25 20:14 ` [PATCH 06/17] staging: vt6656: mac80211 conversion: add vnt_init to bScheduleCommand Malcolm Priestley
2014-06-25 20:14 ` [PATCH 07/17] staging: vt6656: mac80211 conversion: vnt_update_ifs change basic rates Malcolm Priestley
2014-06-25 20:14 ` Malcolm Priestley [this message]
2014-06-25 20:14 ` [PATCH 09/17] staging: vt6656: mac80211 conversion: vRunCommand change beacon Malcolm Priestley
2014-06-25 20:14 ` [PATCH 10/17] staging: vt6656: mac80211 conversion: change vnt_next_tbtt_wakeup Malcolm Priestley
2014-06-25 20:14 ` [PATCH 11/17] staging: vt6656: mac80211 conversion: int.c changes Malcolm Priestley
2014-06-25 20:14 ` [PATCH 12/17] staging: vt6656: mac80211 conversion: vRunCommand channel changes Malcolm Priestley
2014-06-25 20:14 ` [PATCH 13/17] staging: vt6656: mac80211 conversion: move data rates to device.h Malcolm Priestley
2014-06-25 20:14 ` [PATCH 14/17] staging: vt6656: mac80211 conversion: change vnt_rf_set_txpower Malcolm Priestley
2014-06-25 20:14 ` [PATCH 15/17] staging: vt6656: vnt_mac_set_keyentry remove byLocalID check Malcolm Priestley
2014-06-25 20:14 ` [PATCH 16/17] staging: vt6656: mac80211 conversion: device_alloc_bufs use dev_err Malcolm Priestley
2014-06-25 20:14 ` [PATCH 17/17] staging: vt6656: mac80211 conversion: rxtx implement power save poll Malcolm Priestley
2014-06-26 6:29 ` [PATCH 00/17] staging: vt6656: conversion to mac80211 Johannes Berg
2014-06-27 0:20 ` Greg KH
2014-06-27 18:50 ` Malcolm Priestley
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1403727278-6666-9-git-send-email-tvboxspy@gmail.com \
--to=tvboxspy@gmail.com \
--cc=gregkh@linuxfoundation.org \
--cc=linux-wireless@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).