Received: by 2002:a6b:500f:0:0:0:0:0 with SMTP id e15csp219707iob; Wed, 18 May 2022 00:12:25 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzB7NIMe4uTdWffxSrFK/RTFKVcBG/RMn3gNW1+GB/AARt5P/Uq9eE1V7TCCVifpS39bCnB X-Received: by 2002:a05:6a00:ad0:b0:4e1:2d96:2ab0 with SMTP id c16-20020a056a000ad000b004e12d962ab0mr26376533pfl.3.1652857945225; Wed, 18 May 2022 00:12:25 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1652857945; cv=none; d=google.com; s=arc-20160816; b=XbZHbw+6sGc76wA4zABsVfFmtZQNSo1ZH5xpx0xA6vRbOckUaaFVmAkPspeF2Kjkk/ vHSrh5f93I2jIU5jntthXODRZfgPIRvNf/AMhpWtD+QgSJAEasxR3vN4XJ1jm8o9hhh3 qFjwxK/No/FVx7fqWANM57C0bFW8vtLBbunMI/O+FHiO9LGp79btB2cvZpsFwCUQ3Nr8 9ueW1HoWxMedUR9SDw6VI1nTj1A9c2RcPD2xKS7xqX0SnHvpVBttkA9iAG0OkdTM6hF8 mFe38c0y6ZT3mQZmbJzvgOqtqza6I8c4CNl48d3E0aLMVm647Gt9TY7uc4mNO6muol5b vlDg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:message-id:date:subject:cc:to:from; bh=H2990scL3jmrcwLD+t3PfrmhiveYfcKshw92YAZtA0w=; b=sZ/5vFwQ+Ugdn54ifqTN0+O3xpFUNKIjyFof8dzir9QcC2KQe82z2TwWRkJEVGw7m0 IoFZ0ar267tYpn6ncLHf6qh/YtCDcZb87cC9qNywizY9RqIB05iNipamWJb6czvqivYT s4iOTFV0rTqN3gZACHYvYJhf7KjdYZ/M82SPfVVfKatNCXbWk83Ik4EgSAc3YchmJSYH xJ8XnYQNgij3oNGxG/yIQMQ7Y+r+C7WAQ3V8uN6yVP4FnnaDj5lMqNGF1DcGn3xdI9oa IZ5IlHqEgwYzhxlTMAdyyI5bazx7HngseCSvhJeGno5TF04p4ewef2vMNGlrAdpLKCJx VqJw== ARC-Authentication-Results: i=1; mx.google.com; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [23.128.96.19]) by mx.google.com with ESMTPS id bj8-20020a056a02018800b003db25584b0bsi1715308pgb.92.2022.05.18.00.12.24 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 18 May 2022 00:12:25 -0700 (PDT) Received-SPF: softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) client-ip=23.128.96.19; Authentication-Results: mx.google.com; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 4367A2F013; Tue, 17 May 2022 23:58:03 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231645AbiERG5v (ORCPT + 99 others); Wed, 18 May 2022 02:57:51 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36486 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231689AbiERG5q (ORCPT ); Wed, 18 May 2022 02:57:46 -0400 Received: from mail.meizu.com (edge05.meizu.com [157.122.146.251]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1704C28E1B; Tue, 17 May 2022 23:57:42 -0700 (PDT) Received: from IT-EXMB-1-125.meizu.com (172.16.1.125) by mz-mail12.meizu.com (172.16.1.108) with Microsoft SMTP Server (TLS) id 14.3.487.0; Wed, 18 May 2022 14:57:40 +0800 Received: from meizu.meizu.com (172.16.137.70) by IT-EXMB-1-125.meizu.com (172.16.1.125) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.14; Wed, 18 May 2022 14:57:39 +0800 From: Haowen Bai To: Jassi Brar , Thierry Reding , Jonathan Hunter CC: Haowen Bai , , Subject: [PATCH] mailbox: tegra-hsp: Drop unnecessary null test @list_for_each_entry Date: Wed, 18 May 2022 14:57:37 +0800 Message-ID: <1652857058-5220-1-git-send-email-baihaowen@meizu.com> X-Mailer: git-send-email 2.7.4 MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [172.16.137.70] X-ClientProxiedBy: IT-EXMB-1-126.meizu.com (172.16.1.126) To IT-EXMB-1-125.meizu.com (172.16.1.125) X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,RDNS_NONE, SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 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 --- 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