From: <sean.wang@mediatek.com>
To: <nbd@nbd.name>, <lorenzo.bianconi@redhat.com>
Cc: <sean.wang@mediatek.com>, <Soul.Huang@mediatek.com>,
<YN.Chen@mediatek.com>, <Leon.Yen@mediatek.com>,
<Eric-SY.Chang@mediatek.com>, <Deren.Wu@mediatek.com>,
<km.lin@mediatek.com>, <robin.chiu@mediatek.com>,
<ch.yeh@mediatek.com>, <posh.sun@mediatek.com>,
<Eric.Liang@mediatek.com>, <Stella.Chang@mediatek.com>,
<jemele@google.com>, <yenlinlai@google.com>,
<linux-wireless@vger.kernel.org>,
<linux-mediatek@lists.infradead.org>,
Lorenzo Bianconi <lorenzo@kernel.org>
Subject: [PATCH 7/7] mt76: mt7921: enable runtime pm by default
Date: Thu, 20 May 2021 11:46:41 +0800 [thread overview]
Message-ID: <1621482401-29025-7-git-send-email-sean.wang@mediatek.com> (raw)
In-Reply-To: <1621482401-29025-1-git-send-email-sean.wang@mediatek.com>
From: Lorenzo Bianconi <lorenzo@kernel.org>
mt7921 is mainly used in CE/IoT market so enable runtime-pm by default
Signed-off-by: Lorenzo Bianconi <lorenzo@kernel.org>
Signed-off-by: Sean Wang <sean.wang@mediatek.com>
---
drivers/net/wireless/mediatek/mt76/mt7921/init.c | 2 +-
drivers/net/wireless/mediatek/mt76/mt7921/mcu.c | 2 --
2 files changed, 1 insertion(+), 3 deletions(-)
diff --git a/drivers/net/wireless/mediatek/mt76/mt7921/init.c b/drivers/net/wireless/mediatek/mt76/mt7921/init.c
index d78eb4ec4b8a..7f5589cd8213 100644
--- a/drivers/net/wireless/mediatek/mt76/mt7921/init.c
+++ b/drivers/net/wireless/mediatek/mt76/mt7921/init.c
@@ -185,7 +185,6 @@ int mt7921_register_device(struct mt7921_dev *dev)
mutex_init(&dev->pm.mutex);
init_waitqueue_head(&dev->pm.wait);
spin_lock_init(&dev->pm.txq_lock);
- set_bit(MT76_STATE_PM, &dev->mphy.state);
INIT_LIST_HEAD(&dev->phy.stats_list);
INIT_DELAYED_WORK(&dev->mphy.mac_work, mt7921_mac_work);
INIT_DELAYED_WORK(&dev->phy.scan_work, mt7921_scan_work);
@@ -200,6 +199,7 @@ int mt7921_register_device(struct mt7921_dev *dev)
dev->pm.idle_timeout = MT7921_PM_TIMEOUT;
dev->pm.stats.last_wake_event = jiffies;
dev->pm.stats.last_doze_event = jiffies;
+ dev->pm.enable = true;
ret = mt7921_init_hardware(dev);
if (ret)
diff --git a/drivers/net/wireless/mediatek/mt76/mt7921/mcu.c b/drivers/net/wireless/mediatek/mt76/mt7921/mcu.c
index 486e5593d99a..b7957f4cc321 100644
--- a/drivers/net/wireless/mediatek/mt76/mt7921/mcu.c
+++ b/drivers/net/wireless/mediatek/mt76/mt7921/mcu.c
@@ -942,8 +942,6 @@ static int mt7921_load_firmware(struct mt7921_dev *dev)
dev->mt76.hw->wiphy->wowlan = &mt76_connac_wowlan_support;
#endif /* CONFIG_PM */
- clear_bit(MT76_STATE_PM, &dev->mphy.state);
-
dev_err(dev->mt76.dev, "Firmware init done\n");
return 0;
--
2.25.1
prev parent reply other threads:[~2021-05-20 3:47 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <1621482401-29025-1-git-send-email-sean.wang@mediatek.com>
2021-05-20 3:46 ` [PATCH 2/7] mt76: connac: update BA win size in Rx direction sean.wang
2021-05-20 3:46 ` [PATCH 3/7] mt76: mt7921: fix reset under the deep sleep is enabled sean.wang
2021-05-23 21:14 ` Lorenzo Bianconi
2021-05-20 3:46 ` [PATCH 4/7] mt76: mt7921: avoid unnecessary consecutive WiFi resets sean.wang
2021-05-20 3:46 ` [PATCH 5/7] mt76: mt7921: fix invalid register access in wake_work sean.wang
2021-05-20 3:46 ` [PATCH 6/7] mt76: mt7921: fix OMAC idx usage sean.wang
2021-05-20 3:46 ` sean.wang [this message]
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=1621482401-29025-7-git-send-email-sean.wang@mediatek.com \
--to=sean.wang@mediatek.com \
--cc=Deren.Wu@mediatek.com \
--cc=Eric-SY.Chang@mediatek.com \
--cc=Eric.Liang@mediatek.com \
--cc=Leon.Yen@mediatek.com \
--cc=Soul.Huang@mediatek.com \
--cc=Stella.Chang@mediatek.com \
--cc=YN.Chen@mediatek.com \
--cc=ch.yeh@mediatek.com \
--cc=jemele@google.com \
--cc=km.lin@mediatek.com \
--cc=linux-mediatek@lists.infradead.org \
--cc=linux-wireless@vger.kernel.org \
--cc=lorenzo.bianconi@redhat.com \
--cc=lorenzo@kernel.org \
--cc=nbd@nbd.name \
--cc=posh.sun@mediatek.com \
--cc=robin.chiu@mediatek.com \
--cc=yenlinlai@google.com \
/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