From: Luca Coelho <luca@coelho.fi>
To: kvalo@codeaurora.org
Cc: linux-wireless@vger.kernel.org
Subject: [PATCH 10/11] iwlwifi: remove TRANS_PM_OPS
Date: Sun, 17 Jan 2021 13:10:37 +0200 [thread overview]
Message-ID: <iwlwifi.20210117130510.8f8a735f39dd.If5716eaae0df5e6295a2af927bf3ab0ee074f0a0@changeid> (raw)
In-Reply-To: <20210117111038.1402870-1-luca@coelho.fi>
From: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Those were needed for a slave bus that is not longer supported.
Remove code that is mainly useless stubs.
Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
---
.../net/wireless/intel/iwlwifi/iwl-trans.h | 16 --------------
drivers/net/wireless/intel/iwlwifi/mvm/d3.c | 7 -------
.../net/wireless/intel/iwlwifi/pcie/trans.c | 21 -------------------
3 files changed, 44 deletions(-)
diff --git a/drivers/net/wireless/intel/iwlwifi/iwl-trans.h b/drivers/net/wireless/intel/iwlwifi/iwl-trans.h
index eb6430c69e67..ee97e2df3a1d 100644
--- a/drivers/net/wireless/intel/iwlwifi/iwl-trans.h
+++ b/drivers/net/wireless/intel/iwlwifi/iwl-trans.h
@@ -580,8 +580,6 @@ struct iwl_trans_ops {
unsigned long *flags);
void (*set_bits_mask)(struct iwl_trans *trans, u32 reg, u32 mask,
u32 value);
- int (*suspend)(struct iwl_trans *trans);
- void (*resume)(struct iwl_trans *trans);
struct iwl_trans_dump_data *(*dump_data)(struct iwl_trans *trans,
u32 dump_mask);
@@ -1075,20 +1073,6 @@ static inline int iwl_trans_d3_resume(struct iwl_trans *trans,
return trans->ops->d3_resume(trans, status, test, reset);
}
-static inline int iwl_trans_suspend(struct iwl_trans *trans)
-{
- if (!trans->ops->suspend)
- return 0;
-
- return trans->ops->suspend(trans);
-}
-
-static inline void iwl_trans_resume(struct iwl_trans *trans)
-{
- if (trans->ops->resume)
- trans->ops->resume(trans);
-}
-
static inline struct iwl_trans_dump_data *
iwl_trans_dump_data(struct iwl_trans *trans, u32 dump_mask)
{
diff --git a/drivers/net/wireless/intel/iwlwifi/mvm/d3.c b/drivers/net/wireless/intel/iwlwifi/mvm/d3.c
index c025188fa9bc..550755fb7c2f 100644
--- a/drivers/net/wireless/intel/iwlwifi/mvm/d3.c
+++ b/drivers/net/wireless/intel/iwlwifi/mvm/d3.c
@@ -1104,16 +1104,11 @@ int iwl_mvm_suspend(struct ieee80211_hw *hw, struct cfg80211_wowlan *wowlan)
{
struct iwl_mvm *mvm = IWL_MAC80211_GET_MVM(hw);
struct iwl_trans *trans = mvm->trans;
- int ret;
iwl_mvm_pause_tcm(mvm, true);
iwl_fw_runtime_suspend(&mvm->fwrt);
- ret = iwl_trans_suspend(trans);
- if (ret)
- return ret;
-
trans->system_pm_mode = IWL_PLAT_PM_MODE_D3;
return __iwl_mvm_suspend(hw, wowlan, false);
@@ -2171,8 +2166,6 @@ static int __iwl_mvm_resume(struct iwl_mvm *mvm, bool test)
static int iwl_mvm_resume_d3(struct iwl_mvm *mvm)
{
- iwl_trans_resume(mvm->trans);
-
return __iwl_mvm_resume(mvm, false);
}
diff --git a/drivers/net/wireless/intel/iwlwifi/pcie/trans.c b/drivers/net/wireless/intel/iwlwifi/pcie/trans.c
index 44e738e8537e..9fd1e699292c 100644
--- a/drivers/net/wireless/intel/iwlwifi/pcie/trans.c
+++ b/drivers/net/wireless/intel/iwlwifi/pcie/trans.c
@@ -3308,17 +3308,6 @@ static void iwl_trans_pcie_sync_nmi(struct iwl_trans *trans)
iwl_trans_sync_nmi_with_addr(trans, inta_addr, sw_err_bit);
}
-#ifdef CONFIG_PM_SLEEP
-static int iwl_trans_pcie_suspend(struct iwl_trans *trans)
-{
- return 0;
-}
-
-static void iwl_trans_pcie_resume(struct iwl_trans *trans)
-{
-}
-#endif /* CONFIG_PM_SLEEP */
-
#define IWL_TRANS_COMMON_OPS \
.op_mode_leave = iwl_trans_pcie_op_mode_leave, \
.write8 = iwl_trans_pcie_write8, \
@@ -3341,17 +3330,8 @@ static void iwl_trans_pcie_resume(struct iwl_trans *trans)
.interrupts = iwl_trans_pci_interrupts, \
.sync_nmi = iwl_trans_pcie_sync_nmi \
-#ifdef CONFIG_PM_SLEEP
-#define IWL_TRANS_PM_OPS \
- .suspend = iwl_trans_pcie_suspend, \
- .resume = iwl_trans_pcie_resume,
-#else
-#define IWL_TRANS_PM_OPS
-#endif /* CONFIG_PM_SLEEP */
-
static const struct iwl_trans_ops trans_ops_pcie = {
IWL_TRANS_COMMON_OPS,
- IWL_TRANS_PM_OPS
.start_hw = iwl_trans_pcie_start_hw,
.fw_alive = iwl_trans_pcie_fw_alive,
.start_fw = iwl_trans_pcie_start_fw,
@@ -3378,7 +3358,6 @@ static const struct iwl_trans_ops trans_ops_pcie = {
static const struct iwl_trans_ops trans_ops_pcie_gen2 = {
IWL_TRANS_COMMON_OPS,
- IWL_TRANS_PM_OPS
.start_hw = iwl_trans_pcie_start_hw,
.fw_alive = iwl_trans_pcie_gen2_fw_alive,
.start_fw = iwl_trans_pcie_gen2_start_fw,
--
2.29.2
next prev parent reply other threads:[~2021-01-17 11:13 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-01-17 11:10 [PATCH 00/11] iwlwifi: updates intended for v5.12 2021-01-17 Luca Coelho
2021-01-17 11:10 ` [PATCH 01/11] iwlwifi: mvm: add notification size checks Luca Coelho
2021-02-05 9:53 ` Luca Coelho
2021-01-17 11:10 ` [PATCH 02/11] iwlwifi: mvm: check more notification sizes Luca Coelho
2021-01-17 11:10 ` [PATCH 03/11] iwlwifi: mvm: remove debugfs injection limitations Luca Coelho
2021-01-17 11:10 ` [PATCH 04/11] iwlwifi: mvm: scan: fix scheduled scan restart handling Luca Coelho
2021-01-17 11:10 ` [PATCH 05/11] iwlwifi: mvm: handle CCA-EXT delay firmware notification Luca Coelho
2021-01-17 11:10 ` [PATCH 06/11] iwlwifi: mvm: add support for new flush queue response Luca Coelho
2021-01-17 11:10 ` [PATCH 07/11] iwlwifi: pcie: properly implement NAPI Luca Coelho
2021-01-17 11:10 ` [PATCH 08/11] iwl-trans: iwlwifi: move sync NMI logic to trans Luca Coelho
2021-01-17 11:10 ` [PATCH 09/11] iwlwifi: dbg: dump paged memory from index 1 Luca Coelho
2021-01-17 11:10 ` Luca Coelho [this message]
2021-01-17 11:10 ` [PATCH 11/11] iwlwifi: mvm: don't check system_pm_mode without mutex held Luca Coelho
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=iwlwifi.20210117130510.8f8a735f39dd.If5716eaae0df5e6295a2af927bf3ab0ee074f0a0@changeid \
--to=luca@coelho.fi \
--cc=kvalo@codeaurora.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).