Received: by 2002:ac0:a594:0:0:0:0:0 with SMTP id m20-v6csp3633026imm; Sun, 13 May 2018 16:34:35 -0700 (PDT) X-Google-Smtp-Source: AB8JxZrzlnm6MpBVM1fFi1YlJQ9dB68xy/0vEMQDdD6dGqhHmjr3Ypu0ns9cfvnMKCWyroTOYkwP X-Received: by 2002:a63:9302:: with SMTP id b2-v6mr6544843pge.263.1526254475700; Sun, 13 May 2018 16:34:35 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1526254475; cv=none; d=google.com; s=arc-20160816; b=QKXI3Ig1ptFln8ZxJvv4OjSFowI06f5saRKvy44dClvBthGAz4Av0WWZyaCoxBpbHS eYTxMSAQuzuH5/Uh6TS+CehFjQdgyCTqFsnTsztx+WVeqBk2GwrbwV287xW1h4eZvn9W 6ksboSf1WWPLoEew31JaUx3byHMK8dgYRloEDXCj9tdj0zguEHga0UcYNW4sw1j+ZFUQ aouGyPFcRhkTWNQqJZ1xZF880GcBSV/WD2sWKLnfsIndR3uZFpkmK1fOGO/JqxWheb/p pmbGmTF7I5Rsvj8eWl7Oq3dTHFoinH+gB55iksCfXZaJSvZYzsH4ElU8DvHfrTdGhE6c QOvw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature :arc-authentication-results; bh=jAUYtBtaHV7QjN6tIs2TxyKAttgYsrFTyPm3Oa0lAVQ=; b=ocRLNb5FWdWy6HFNAfJ0d00XOLe3zOFzC+nfBM8O9J6/waR9g4eguKfupd/FCUMaoX 9g/NX0/aHbWe0vDUeCZuoiO72ccF5Rjugwpqn4l/dnnMk2eMXlxRc4aVsHxA7CrsEgB5 f0srJkud1ccUDUQzipB4mm6xPpMqklMAjjRAkrnQKRGOpU1iMbqfYNA0TOiH+08OjqQm Wu0uuDdQTbsm2CXNoOLS5lUNHAAwkWaOzRxJdGYMe/csXtx1O6J80QxEF+FtqtHha0Uw TpZpuV07S52frEQwR1N3DPpht0vc57p+9Vh6LbmhJlxIy9eA8G1NRwEYZ89Yv83B1R4X k+BA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@vanguardiasur-com-ar.20150623.gappssmtp.com header.s=20150623 header.b=qjD7rWRQ; 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 e71-v6si8979299pfj.250.2018.05.13.16.34.20; Sun, 13 May 2018 16:34:35 -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; dkim=pass header.i=@vanguardiasur-com-ar.20150623.gappssmtp.com header.s=20150623 header.b=qjD7rWRQ; 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 S1751871AbeEMXeD (ORCPT + 99 others); Sun, 13 May 2018 19:34:03 -0400 Received: from mail-qt0-f194.google.com ([209.85.216.194]:37067 "EHLO mail-qt0-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751022AbeEMXeC (ORCPT ); Sun, 13 May 2018 19:34:02 -0400 Received: by mail-qt0-f194.google.com with SMTP id q13-v6so13958692qtp.4 for ; Sun, 13 May 2018 16:34:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=vanguardiasur-com-ar.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=jAUYtBtaHV7QjN6tIs2TxyKAttgYsrFTyPm3Oa0lAVQ=; b=qjD7rWRQ79Y1PlycOM2WaCKsun+9YzHiNTZyChKsl422IF4MTpFXDJT1hDFkCZoK50 5bLajyKkwtyXU8rVunm76mKmP5VTKXwjL8RBQwBeDM2K75kLhB+1k3U9ABbVjVvOk1bw lHHM1lv/a7K6jFMlnb42WyFQUALsbv9VIcMvTULX71egoAZxuLNrvdXCPEgCayqUu3Gt Pp04Laxgck1iSBTw85AoFNJQZT/wQ3aX5uUTeUos6g3Yj2eIRZBrCyiMeQYqqeFUCZzD OgNrXXnOFWnZmfkfCSgc56O7wbReFvDonxFKzwZ59JSYJausok2USfV3YjG7uzilCauv zbsg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=jAUYtBtaHV7QjN6tIs2TxyKAttgYsrFTyPm3Oa0lAVQ=; b=XYiYBHl15ePPLCd9vr4aZjU0vhq7kllj76dwbHQXQoiIeAMu+gFGH5vyezPaIreOKq iY/Cw5aRueI1fgzVKGQc866XFTkNwr2q8Qw/xz3HoiZh93p9fGgkgw70mzlk9SPy4rg0 a03YS6fiUdkTpfQcgEuVEpktwYWWpIpYHCVNEK/HbJ0d0eo2jqqEke6wDtyd/I4u/Om5 ZuMsbdRQZTWRzB7ridi8LIbd4IwXe7bpRv2BXCtDZoVpva1zY4DeQO3TUxoAxkWiFPSk CU0yjcdWTbymolaJrOpwF8T9u60Ex2nAaUUv7XgkryG2R+lBTWbH7K1ODEn2i57njoRb DEQg== X-Gm-Message-State: ALKqPwfTMIKNvSnB0WbgbtBdC9TyvYf7imhaeC8/q74g/WA2v3GNXs4h bLf1+HuyYVtpMfgMjRRhz21+TA== X-Received: by 2002:ac8:330e:: with SMTP id t14-v6mr6729594qta.263.1526254441486; Sun, 13 May 2018 16:34:01 -0700 (PDT) Received: from hlaptop.cpe.express.com.ar ([181.199.145.157]) by smtp.gmail.com with ESMTPSA id 1-v6sm6839994qkw.12.2018.05.13.16.33.59 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Sun, 13 May 2018 16:34:01 -0700 (PDT) From: =?UTF-8?q?Hern=C3=A1n=20Gonzalez?= To: davem@davemloft.net Cc: grygorii.strashko@ti.com, richardcochran@gmail.com, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, =?UTF-8?q?Hern=C3=A1n=20Gonzalez?= Subject: [PATCH] net: ethernet: ti: Use ERR_CAST instead of ERR_PTR(PTR_ERR()) Date: Sun, 13 May 2018 20:33:49 -0300 Message-Id: <1526254429-4276-1-git-send-email-hernan@vanguardiasur.com.ar> X-Mailer: git-send-email 2.7.4 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Use ERR_CAST inlined function instead of ERR_PTR(PTR_ERR(...)). drivers/net/ethernet/ti/cpts.c:567:9-16: WARNING: ERR_CAST can be used with cpts->refclk Generated by: scripts/coccinelle/api/err_cast.cocci Signed-off-by: HernĂ¡n Gonzalez --- drivers/net/ethernet/ti/cpts.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/ti/cpts.c b/drivers/net/ethernet/ti/cpts.c index e7b76f6..7842f09 100644 --- a/drivers/net/ethernet/ti/cpts.c +++ b/drivers/net/ethernet/ti/cpts.c @@ -564,7 +564,7 @@ struct cpts *cpts_create(struct device *dev, void __iomem *regs, cpts->refclk = devm_clk_get(dev, "cpts"); if (IS_ERR(cpts->refclk)) { dev_err(dev, "Failed to get cpts refclk\n"); - return ERR_PTR(PTR_ERR(cpts->refclk)); + return ERR_CAST(cpts->refclk); } clk_prepare(cpts->refclk); -- 2.7.4