From: Dan Carpenter <dan.carpenter@oracle.com>
To: Kalle Valo <kvalo@codeaurora.org>,
Rakesh Pillai <pillair@codeaurora.org>
Cc: linux-wireless@vger.kernel.org, kernel-janitors@vger.kernel.org,
ath10k@lists.infradead.org
Subject: [PATCH] ath10k: remove an unnecessary NULL check
Date: Thu, 29 Nov 2018 17:24:06 +0300 [thread overview]
Message-ID: <20181129142406.GV3073@unbuntlaptop> (raw)
In-Reply-To: <20181129103214.5tudci6izlfaasqx@kili.mountain>
The "survey" pointer is the address of an array element. We know that
it can't be NULL so this check can be removed.
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
---
Resending with linux-wireless Cc for patchwork.
drivers/net/wireless/ath/ath10k/wmi.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/wireless/ath/ath10k/wmi.c b/drivers/net/wireless/ath/ath10k/wmi.c
index 659513bf4ddc..6a04727b63ce 100644
--- a/drivers/net/wireless/ath/ath10k/wmi.c
+++ b/drivers/net/wireless/ath/ath10k/wmi.c
@@ -2578,7 +2578,7 @@ static void ath10k_wmi_event_chan_info_unpaired(struct ath10k *ar,
survey = &ar->survey[idx];
- if (!params->mac_clk_mhz || !survey)
+ if (!params->mac_clk_mhz)
return;
memset(survey, 0, sizeof(*survey));
--
2.11.0
_______________________________________________
ath10k mailing list
ath10k@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/ath10k
WARNING: multiple messages have this Message-ID (diff)
From: Dan Carpenter <dan.carpenter@oracle.com>
To: Kalle Valo <kvalo@codeaurora.org>,
Rakesh Pillai <pillair@codeaurora.org>
Cc: linux-wireless@vger.kernel.org, kernel-janitors@vger.kernel.org,
ath10k@lists.infradead.org
Subject: [PATCH] ath10k: remove an unnecessary NULL check
Date: Thu, 29 Nov 2018 14:24:06 +0000 [thread overview]
Message-ID: <20181129142406.GV3073@unbuntlaptop> (raw)
In-Reply-To: <20181129103214.5tudci6izlfaasqx@kili.mountain>
In-Reply-To: <20181129103214.5tudci6izlfaasqx@kili.mountain>
The "survey" pointer is the address of an array element. We know that
it can't be NULL so this check can be removed.
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
---
Resending with linux-wireless Cc for patchwork.
drivers/net/wireless/ath/ath10k/wmi.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/wireless/ath/ath10k/wmi.c b/drivers/net/wireless/ath/ath10k/wmi.c
index 659513bf4ddc..6a04727b63ce 100644
--- a/drivers/net/wireless/ath/ath10k/wmi.c
+++ b/drivers/net/wireless/ath/ath10k/wmi.c
@@ -2578,7 +2578,7 @@ static void ath10k_wmi_event_chan_info_unpaired(struct ath10k *ar,
survey = &ar->survey[idx];
- if (!params->mac_clk_mhz || !survey)
+ if (!params->mac_clk_mhz)
return;
memset(survey, 0, sizeof(*survey));
--
2.11.0
WARNING: multiple messages have this Message-ID (diff)
From: Dan Carpenter <dan.carpenter@oracle.com>
To: Kalle Valo <kvalo@codeaurora.org>,
Rakesh Pillai <pillair@codeaurora.org>
Cc: ath10k@lists.infradead.org, kernel-janitors@vger.kernel.org,
linux-wireless@vger.kernel.org
Subject: [PATCH] ath10k: remove an unnecessary NULL check
Date: Thu, 29 Nov 2018 17:24:06 +0300 [thread overview]
Message-ID: <20181129142406.GV3073@unbuntlaptop> (raw)
In-Reply-To: <20181129103214.5tudci6izlfaasqx@kili.mountain>
The "survey" pointer is the address of an array element. We know that
it can't be NULL so this check can be removed.
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
---
Resending with linux-wireless Cc for patchwork.
drivers/net/wireless/ath/ath10k/wmi.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/wireless/ath/ath10k/wmi.c b/drivers/net/wireless/ath/ath10k/wmi.c
index 659513bf4ddc..6a04727b63ce 100644
--- a/drivers/net/wireless/ath/ath10k/wmi.c
+++ b/drivers/net/wireless/ath/ath10k/wmi.c
@@ -2578,7 +2578,7 @@ static void ath10k_wmi_event_chan_info_unpaired(struct ath10k *ar,
survey = &ar->survey[idx];
- if (!params->mac_clk_mhz || !survey)
+ if (!params->mac_clk_mhz)
return;
memset(survey, 0, sizeof(*survey));
--
2.11.0
next prev parent reply other threads:[~2018-11-29 14:24 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-11-29 10:32 [PATCH] ath10k: remove an unnecessary NULL check Dan Carpenter
2018-11-29 10:32 ` Dan Carpenter
2018-11-29 13:51 ` Kalle Valo
2018-11-29 13:51 ` Kalle Valo
2018-11-29 13:51 ` Kalle Valo
2018-11-29 14:21 ` Dan Carpenter
2018-11-29 14:21 ` Dan Carpenter
2018-11-29 14:21 ` Dan Carpenter
2018-11-29 14:24 ` Dan Carpenter [this message]
2018-11-29 14:24 ` Dan Carpenter
2018-11-29 14:24 ` Dan Carpenter
2018-12-20 17:07 ` Kalle Valo
2018-12-20 17:07 ` Kalle Valo
2018-12-20 17:07 ` Kalle Valo
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=20181129142406.GV3073@unbuntlaptop \
--to=dan.carpenter@oracle.com \
--cc=ath10k@lists.infradead.org \
--cc=kernel-janitors@vger.kernel.org \
--cc=kvalo@codeaurora.org \
--cc=linux-wireless@vger.kernel.org \
--cc=pillair@codeaurora.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.