Received: by 2002:ac0:a594:0:0:0:0:0 with SMTP id m20-v6csp3545590imm; Fri, 25 May 2018 07:31:53 -0700 (PDT) X-Google-Smtp-Source: AB8JxZqnEbwEPujdsIJRqLA5BPz3bvEQQswCZRrmrsFtSTjHhLXWB9sXeedvfpYc5MDCYzvgU7Cf X-Received: by 2002:a17:902:b492:: with SMTP id y18-v6mr2889524plr.2.1527258713027; Fri, 25 May 2018 07:31:53 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1527258713; cv=none; d=google.com; s=arc-20160816; b=BhURjAQL/rZ0uh8XqsnvPHAjjnSaR/Rs50k3S/kzkENH3hYSS9TMdVt4ZW0/EXVlA3 xXGkxhW1O5+p3Gwd7d5XXUy+0wYlPlf2u4xz2O7UFgWd7eeLsmESEPH7G1H7aoSDKmXW KGlcA9q1H9sL5CC5CT/t//8wrUIM0U0Hh3iobnVT5xTU61NOOakzEuYUmPz6XEf3aYpf 8fnFizY6qkdzbKybNlrQfcS8R0suN63A/jwzIJORnBVhkG/8pkvUhFPHYQlkwku82Gub wUboeXO4kraZmy8JHpQX0/Ph7B//ukVFo6MdAdzricIYrsW6g9d2KQdSkRonlXPDapvD PF9A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:message-id :subject:cc:to:from:date:arc-authentication-results; bh=AarliZUKL+GjgMhlem7FU/HmxHuMoH0eGkwKSrNue5E=; b=SL21L6exf9LYYmBYEorX45m+/v6AEJzhdvrwjMn51/jh+qTjOs+m2M372NtCzJNkCi LMd1FiUIuiBoc6O+tzVe2pTLftEubMKGEDx+oQlHP/wJxFypReaocaBrpMpJjtpE7y1K 8FGaS/2SbCmZNXoN+X4752QlZq+OgIurpUfE5k00cWPEq9R5282+b3mPTqvIlMxcCb5Y ky9aTqdyLSscv89NBVlYlgmbyibT1wNMFogZ16YTQh8R9K6FpdVwsfQDITqpH5Z4ov2D 5JOxwy68D1dsJvYoChphlPPggvkT52TpwAoq8ka2FqTmNXKDpEGgMqgrhD3ALCCkizGR m/ng== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id t14-v6si834443ply.102.2018.05.25.07.31.38; Fri, 25 May 2018 07:31:52 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S936277AbeEYO3y (ORCPT + 99 others); Fri, 25 May 2018 10:29:54 -0400 Received: from mail3-relais-sop.national.inria.fr ([192.134.164.104]:43808 "EHLO mail3-relais-sop.national.inria.fr" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S936050AbeEYO3x (ORCPT ); Fri, 25 May 2018 10:29:53 -0400 X-IronPort-AV: E=Sophos;i="5.49,440,1520895600"; d="scan'208";a="266468150" Received: from vaio-julia.rsr.lip6.fr ([132.227.76.33]) by mail3-relais-sop.national.inria.fr with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 25 May 2018 16:29:51 +0200 Date: Fri, 25 May 2018 16:29:50 +0200 (CEST) From: Julia Lawall X-X-Sender: jll@hadrien To: Gerd Hoffmann cc: kbuild-all@01.org, linux-media@vger.kernel.org, Sumit Semwal , dri-devel@lists.freedesktop.org, linaro-mm-sig@lists.linaro.org, linux-kernel@vger.kernel.org Subject: [PATCH] udmabuf: fix odd_ptr_err.cocci warnings Message-ID: User-Agent: Alpine 2.20 (DEB 67 2015-01-07) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: kbuild test robot drivers/dma-buf/udmabuf.c:167:6-12: inconsistent IS_ERR and PTR_ERR on line 168. PTR_ERR should access the value just tested by IS_ERR Semantic patch information: There can be false positives in the patch case, where it is the call to IS_ERR that is wrong. Generated by: scripts/coccinelle/tests/odd_ptr_err.cocci Fixes: cc2d0e91bc15 ("udmabuf: driver update") Signed-off-by: kbuild test robot Signed-off-by: linux-kernel@vger.kernel.org --- tree: git://git.kraxel.org/linux udmabuf head: cc2d0e91bc15849baff695d175bfb8fba35f1465 commit: cc2d0e91bc15849baff695d175bfb8fba35f1465 [6/6] udmabuf: driver update udmabuf.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/drivers/dma-buf/udmabuf.c +++ b/drivers/dma-buf/udmabuf.c @@ -165,7 +165,7 @@ static long udmabuf_ioctl_create(struct page = shmem_read_mapping_page( file_inode(ubuf->filp)->i_mapping, pgoff + pgidx); if (IS_ERR(page)) { - ret = PTR_ERR(buf); + ret = PTR_ERR(page); goto err_put_pages; } ubuf->pages[pgidx] = page;