[<prev] [next>] [day] [month] [year] [list]
Message-ID: <1652857058-5220-1-git-send-email-baihaowen@meizu.com>
Date: Wed, 18 May 2022 14:57:37 +0800
From: Haowen Bai <baihaowen@...zu.com>
To: Jassi Brar <jassisinghbrar@...il.com>,
Thierry Reding <thierry.reding@...il.com>,
Jonathan Hunter <jonathanh@...dia.com>
CC: Haowen Bai <baihaowen@...zu.com>, <linux-kernel@...r.kernel.org>,
<linux-tegra@...r.kernel.org>
Subject: [PATCH] mailbox: tegra-hsp: Drop unnecessary null test @list_for_each_entry
list_for_each_entry binds its first argument to a non-null value, and thus
any null test on the value of that argument is superfluous.
Signed-off-by: Haowen Bai <baihaowen@...zu.com>
---
drivers/mailbox/tegra-hsp.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/mailbox/tegra-hsp.c b/drivers/mailbox/tegra-hsp.c
index 78f7265039c6..a55d6df99697 100644
--- a/drivers/mailbox/tegra-hsp.c
+++ b/drivers/mailbox/tegra-hsp.c
@@ -804,7 +804,7 @@ static int __maybe_unused tegra_hsp_resume(struct device *dev)
struct tegra_hsp_doorbell *db;
list_for_each_entry(db, &hsp->doorbells, list) {
- if (db && db->channel.chan)
+ if (db->channel.chan)
tegra_hsp_doorbell_startup(db->channel.chan);
}
--
2.7.4
Powered by blists - more mailing lists