From: Luca Coelho <luca@coelho.fi>
To: kvalo@codeaurora.org
Cc: linux-wireless@vger.kernel.org
Subject: [PATCH 01/12] iwlwifi: pcie: move iwl_pcie_ctxt_info_alloc_dma() to user
Date: Sat, 18 Apr 2020 11:08:46 +0300 [thread overview]
Message-ID: <iwlwifi.20200418110539.818a06457888.Ib4f55280cd14d7edab37f2992b381c9b6ca4cd7a@changeid> (raw)
In-Reply-To: <20200418080857.2232093-1-luca@coelho.fi>
From: Johannes Berg <johannes.berg@intel.com>
There's no need for this to be an inline in the header file,
only the context-info.c file ever uses it. Move it there.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
---
.../net/wireless/intel/iwlwifi/pcie/ctxt-info.c | 15 +++++++++++++++
.../net/wireless/intel/iwlwifi/pcie/internal.h | 16 ----------------
2 files changed, 15 insertions(+), 16 deletions(-)
diff --git a/drivers/net/wireless/intel/iwlwifi/pcie/ctxt-info.c b/drivers/net/wireless/intel/iwlwifi/pcie/ctxt-info.c
index acd01d86f101..b65405009d02 100644
--- a/drivers/net/wireless/intel/iwlwifi/pcie/ctxt-info.c
+++ b/drivers/net/wireless/intel/iwlwifi/pcie/ctxt-info.c
@@ -93,6 +93,21 @@ static void *iwl_pcie_ctxt_info_dma_alloc_coherent(struct iwl_trans *trans,
return _iwl_pcie_ctxt_info_dma_alloc_coherent(trans, size, phys, 0);
}
+static int iwl_pcie_ctxt_info_alloc_dma(struct iwl_trans *trans,
+ const struct fw_desc *sec,
+ struct iwl_dram_data *dram)
+{
+ dram->block = iwl_pcie_ctxt_info_dma_alloc_coherent(trans, sec->len,
+ &dram->physical);
+ if (!dram->block)
+ return -ENOMEM;
+
+ dram->size = sec->len;
+ memcpy(dram->block, sec->data, sec->len);
+
+ return 0;
+}
+
void iwl_pcie_ctxt_info_free_paging(struct iwl_trans *trans)
{
struct iwl_self_init_dram *dram = &trans->init_dram;
diff --git a/drivers/net/wireless/intel/iwlwifi/pcie/internal.h b/drivers/net/wireless/intel/iwlwifi/pcie/internal.h
index 595e6873d56e..abe649af689c 100644
--- a/drivers/net/wireless/intel/iwlwifi/pcie/internal.h
+++ b/drivers/net/wireless/intel/iwlwifi/pcie/internal.h
@@ -792,22 +792,6 @@ static inline int iwl_pcie_get_num_sections(const struct fw_img *fw,
return i;
}
-static inline int iwl_pcie_ctxt_info_alloc_dma(struct iwl_trans *trans,
- const struct fw_desc *sec,
- struct iwl_dram_data *dram)
-{
- dram->block = dma_alloc_coherent(trans->dev, sec->len,
- &dram->physical,
- GFP_KERNEL);
- if (!dram->block)
- return -ENOMEM;
-
- dram->size = sec->len;
- memcpy(dram->block, sec->data, sec->len);
-
- return 0;
-}
-
static inline void iwl_pcie_ctxt_info_free_fw_img(struct iwl_trans *trans)
{
struct iwl_self_init_dram *dram = &trans->init_dram;
--
2.25.1
next prev parent reply other threads:[~2020-04-18 8:09 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-04-18 8:08 [PATCH 00/12] iwlwifi: updates intended for v5.8 2020-04-18 Luca Coelho
2020-04-18 8:08 ` Luca Coelho [this message]
2020-04-18 8:08 ` [PATCH 02/12] iwlwifi: mvm: add framework for specific phy configuration Luca Coelho
2020-04-18 8:08 ` [PATCH 03/12] iwlwifi: remove deprecated and unused iwl_mvm_keyinfo struct Luca Coelho
2020-04-18 8:08 ` [PATCH 04/12] iwlwifi: remove fw_monitor module parameter Luca Coelho
2020-04-18 8:08 ` [PATCH 05/12] iwlwifi: acpi: read TAS table from ACPI and send it to the FW Luca Coelho
2020-04-18 8:08 ` [PATCH 06/12] iwlwifi: add new cards for AX family Luca Coelho
2020-04-18 8:08 ` [PATCH 07/12] iwlwifi: pcie: add cfgs for SoCs with device ID 0x4FD0 Luca Coelho
2020-04-18 8:08 ` [PATCH 08/12] iwlwifi: update few product names in AX family Luca Coelho
2020-04-18 8:08 ` [PATCH 09/12] iwlwifi: mvm: tell firmware about required LTR delay Luca Coelho
2020-04-18 8:08 ` [PATCH 10/12] iwlwifi: pcie: add new structure for Qu devices with medium latency Luca Coelho
2020-04-18 8:08 ` [PATCH 11/12] iwlwifi: pcie: add new structs for So devices with long latency Luca Coelho
2020-04-18 8:08 ` [PATCH 12/12] iwlwifi: debug: set NPK buffer in context info 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.20200418110539.818a06457888.Ib4f55280cd14d7edab37f2992b381c9b6ca4cd7a@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).