Linux wireless drivers development
 help / color / mirror / Atom feed
From: Luca Coelho <luca@coelho.fi>
To: kvalo@codeaurora.org
Cc: linux-wireless@vger.kernel.org,
	Shahar S Matityahu <shahar.s.matityahu@intel.com>,
	Luca Coelho <luciano.coelho@intel.com>
Subject: [PATCH 1/8] iwlwifi: dbg_ini: add print to iwl_dump_ini_mem in case of invalid range
Date: Wed, 20 Feb 2019 14:03:53 +0200	[thread overview]
Message-ID: <20190220120400.8814-2-luca@coelho.fi> (raw)
In-Reply-To: <20190220120400.8814-1-luca@coelho.fi>

From: Shahar S Matityahu <shahar.s.matityahu@intel.com>

Add informative print in case the range is not available.

Signed-off-by: Shahar S Matityahu <shahar.s.matityahu@intel.com>
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
---
 drivers/net/wireless/intel/iwlwifi/fw/dbg.c | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

diff --git a/drivers/net/wireless/intel/iwlwifi/fw/dbg.c b/drivers/net/wireless/intel/iwlwifi/fw/dbg.c
index 5e5c4e8c4a69..e4e50d598377 100644
--- a/drivers/net/wireless/intel/iwlwifi/fw/dbg.c
+++ b/drivers/net/wireless/intel/iwlwifi/fw/dbg.c
@@ -1300,14 +1300,18 @@ iwl_dump_ini_mem(struct iwl_fw_runtime *fwrt,
 	memcpy(header->name, reg->name, le32_to_cpu(header->name_len));
 
 	range = ops->fill_mem_hdr(fwrt, header);
-	if (!range)
+	if (!range) {
+		IWL_ERR(fwrt, "Failed to fill region header: id=%d, type=%d\n",
+			le32_to_cpu(reg->region_id), type);
 		return;
+	}
 
 	for (i = 0; i < num_of_ranges; i++) {
 		int range_data_size = ops->fill_range(fwrt, range, reg, i);
 
 		if (range_data_size < 0) {
-			IWL_ERR(fwrt, "Failed to dump region type %d\n", type);
+			IWL_ERR(fwrt, "Failed to dump region: id=%d, type=%d\n",
+				le32_to_cpu(reg->region_id), type);
 			return;
 		}
 		range = ((void *)range) + sizeof(*range) + range_data_size;
-- 
2.20.1


  reply	other threads:[~2019-02-20 12:04 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-02-20 12:03 [PATCH 0/8] iwlwifi: updates intended for v5.1 2019-02-20 Luca Coelho
2019-02-20 12:03 ` Luca Coelho [this message]
2019-02-20 12:03 ` [PATCH 2/8] iwlwifi: dbg_ini: make memory dump get_size handler include headers Luca Coelho
2019-02-20 12:03 ` [PATCH 3/8] iwlwifi: dbg_ini: make fill_range handler accept generic range pointer Luca Coelho
2019-02-20 12:03 ` [PATCH 4/8] iwlwifi: dbg_ini: add region to fill_header handler Luca Coelho
2019-02-20 12:03 ` [PATCH 5/8] iwlwifi: dbg_ini: implement Tx fifos dump Luca Coelho
2019-02-20 12:03 ` [PATCH 6/8] iwlwifi: dbg_ini: implement Rx " Luca Coelho
2019-02-20 12:03 ` [PATCH 7/8] iwlwifi: add new card for 9260 series Luca Coelho
2019-02-20 12:04 ` [PATCH 8/8] iwlwifi: add new cards for 22000 and killer series and change the market name 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=20190220120400.8814-2-luca@coelho.fi \
    --to=luca@coelho.fi \
    --cc=kvalo@codeaurora.org \
    --cc=linux-wireless@vger.kernel.org \
    --cc=luciano.coelho@intel.com \
    --cc=shahar.s.matityahu@intel.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