From patchwork Mon Jan 22 07:31:59 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Julia Lawall X-Patchwork-Id: 10177429 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 75FDF60353 for ; Mon, 22 Jan 2018 07:32:05 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 5F90B27165 for ; Mon, 22 Jan 2018 07:32:05 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 4F11F27816; Mon, 22 Jan 2018 07:32:05 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.2 required=2.0 tests=BAYES_00, RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 8F39227165 for ; Mon, 22 Jan 2018 07:32:04 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 60B4F6E0E3; Mon, 22 Jan 2018 07:32:03 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail2-relais-roc.national.inria.fr (mail2-relais-roc.national.inria.fr [192.134.164.83]) by gabe.freedesktop.org (Postfix) with ESMTPS id B3C0A6E0E4 for ; Mon, 22 Jan 2018 07:32:01 +0000 (UTC) X-IronPort-AV: E=Sophos;i="5.46,395,1511823600"; d="scan'208";a="310050773" Received: from abo-202-111-68.mrs.modulonet.fr (HELO [192.168.0.15]) ([85.68.111.202]) by mail2-relais-roc.national.inria.fr with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 22 Jan 2018 08:31:59 +0100 Date: Mon, 22 Jan 2018 08:31:59 +0100 (CET) From: Julia Lawall X-X-Sender: jll@hadrien To: Laurent Pinchart Subject: [PATCH v2] drm: zte: fix device_node_continue.cocci warnings Message-ID: User-Agent: Alpine 2.20 (DEB 67 2015-01-07) MIME-Version: 1.0 Cc: kbuild-all@01.org, dri-devel@lists.freedesktop.org X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Virus-Scanned: ClamAV using ClamSMTP From: Fengguang Wu Device node iterators put the previous value of the index variable, so an explicit put causes a double put. Generated by: scripts/coccinelle/iterators/device_node_continue.cocci Fixes: 88e6e13dd66c ("drm: vc4: Use drm_atomic_helper_shutdown() to disable planes on removal") Signed-off-by: Fengguang Wu Signed-off-by: Julia Lawall --- v2: correct driver name in subject line url: https://github.com/0day-ci/linux/commits/Laurent-Pinchart/Cargo-cult-cleanup-in-atomic-drivers/20180120-183018 base: git://people.freedesktop.org/~airlied/linux.git drm-next :::::: branch date: 3 hours ago :::::: commit date: 3 hours ago Please take the patch only if it's a positive warning. Thanks! zx_drm_drv.c | 1 - 1 file changed, 1 deletion(-) --- a/drivers/gpu/drm/zte/zx_drm_drv.c +++ b/drivers/gpu/drm/zte/zx_drm_drv.c @@ -163,7 +163,6 @@ static int zx_drm_probe(struct platform_ for_each_available_child_of_node(parent, child) { component_match_add(dev, &match, compare_of, child); - of_node_put(child); } return component_master_add_with_match(dev, &zx_drm_master_ops, match);