From patchwork Tue Apr 10 05:49:40 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Julia Lawall X-Patchwork-Id: 10332343 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 D1F506028A for ; Tue, 10 Apr 2018 05:49:48 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id B444A28BF6 for ; Tue, 10 Apr 2018 05:49:48 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id A4DE428C8F; Tue, 10 Apr 2018 05:49:48 +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=-5.2 required=2.0 tests=BAYES_00, MAILING_LIST_MULTI, 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 D85A228BF6 for ; Tue, 10 Apr 2018 05:49:47 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 579246E02E; Tue, 10 Apr 2018 05:49:46 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail3-relais-sop.national.inria.fr (mail3-relais-sop.national.inria.fr [192.134.164.104]) by gabe.freedesktop.org (Postfix) with ESMTPS id D23C66E02E for ; Tue, 10 Apr 2018 05:49:44 +0000 (UTC) X-IronPort-AV: E=Sophos;i="5.48,430,1517871600"; d="scan'208";a="261452898" Received: from ip-146.net-89-2-7.rev.numericable.fr (HELO [192.168.0.15]) ([89.2.7.146]) by mail3-relais-sop.national.inria.fr with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 10 Apr 2018 07:49:41 +0200 Date: Tue, 10 Apr 2018 07:49:40 +0200 (CEST) From: Julia Lawall X-X-Sender: jll@hadrien To: Hyun Kwon Subject: [PATCH] drm: xlnx: pl_disp: fix odd_ptr_err.cocci warnings Message-ID: User-Agent: Alpine 2.20 (DEB 67 2015-01-07) MIME-Version: 1.0 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Michal Simek , David Airlie , linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, Laurent Pinchart , linux-arm-kernel@lists.infradead.org, kbuild-all@01.org Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Virus-Scanned: ClamAV using ClamSMTP From: Fengguang Wu PTR_ERR should normally access the value just tested by IS_ERR Generated by: scripts/coccinelle/tests/odd_ptr_err.cocci Fixes: 742243a44a73 ("drm: xlnx: pl_disp: Use xlnx pipeline calls") CC: Hyun Kwon Signed-off-by: Fengguang Wu Signed-off-by: Julia Lawall Reviewed-by: Laurent Pinchart --- tree: https://github.com/Xilinx/linux-xlnx xlnx_rebase_v4.14 head: fe04d2ee0dfea6b5fdbb04f4f6dbcaa13bfd2fda commit: 742243a44a738b165f8da5cbdb6662139e85a5c5 [651/842] drm: xlnx: pl_disp: Use xlnx pipeline calls xlnx_pl_disp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/drivers/gpu/drm/xlnx/xlnx_pl_disp.c +++ b/drivers/gpu/drm/xlnx/xlnx_pl_disp.c @@ -482,7 +482,7 @@ static int xlnx_pl_disp_probe(struct pla xlnx_pl_disp->master = xlnx_drm_pipeline_init(pdev); if (IS_ERR(xlnx_pl_disp->master)) { - ret = PTR_ERR(xlnx_pl_disp->dev); + ret = PTR_ERR(xlnx_pl_disp->master); dev_err(dev, "failed to initialize the drm pipeline\n"); goto err_component; }