All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] powerpc/iommu/debug: Remove redundant NULL check
@ 2021-03-22  9:43 ` Jiapeng Chong
  0 siblings, 0 replies; 4+ messages in thread
From: Jiapeng Chong @ 2021-03-22  9:43 UTC (permalink / raw)
  To: mpe; +Cc: benh, paulus, linuxppc-dev, linux-kernel, Jiapeng Chong

Fix the following coccicheck warnings:

./fs/io_uring.c:5989:4-9: WARNING: NULL check before some freeing
functions is not needed.

Reported-by: Abaci Robot <abaci@linux.alibaba.com>
Signed-off-by: Jiapeng Chong <jiapeng.chong@linux.alibaba.com>
---
 arch/powerpc/kernel/iommu.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/arch/powerpc/kernel/iommu.c b/arch/powerpc/kernel/iommu.c
index c00214a..2168714 100644
--- a/arch/powerpc/kernel/iommu.c
+++ b/arch/powerpc/kernel/iommu.c
@@ -72,8 +72,7 @@ static void iommu_debugfs_del(struct iommu_table *tbl)
 
 	sprintf(name, "%08lx", tbl->it_index);
 	liobn_entry = debugfs_lookup(name, iommu_debugfs_dir);
-	if (liobn_entry)
-		debugfs_remove(liobn_entry);
+	debugfs_remove(liobn_entry);
 }
 #else
 static void iommu_debugfs_add(struct iommu_table *tbl){}
-- 
1.8.3.1


^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2021-03-26  6:13 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-03-22  9:43 [PATCH] powerpc/iommu/debug: Remove redundant NULL check Jiapeng Chong
2021-03-22  9:43 ` Jiapeng Chong
2021-03-26  5:53 ` Daniel Axtens
2021-03-26  6:12   ` Daniel Axtens

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.