Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp1766738ybb; Sat, 21 Mar 2020 05:29:19 -0700 (PDT) X-Google-Smtp-Source: ADFU+vuccRmPX1+MgLe/ZS7RYlyqIVWVPUAEiJcp1HTosssON3wjuxTUX552y6ESM5z2Gnwswx18 X-Received: by 2002:aca:170c:: with SMTP id j12mr9916032oii.50.1584793758979; Sat, 21 Mar 2020 05:29:18 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1584793758; cv=none; d=google.com; s=arc-20160816; b=sYTxCwzLGFMfTHFZnhIqnSHFMgPMWyzMr4+h19JFxCRf2cAqLBGLhDRwYcu+urehIN CXVMo50PFk5engZ/iiOnvFaMtp4mUnEgvGCJDzipZD7t7wlBw/HZQzj1a24lERdHf1WT sbDikc9AhBV0fPsiDewoSEPb++KW8QLmohDIXbI4sQ+9Bkz9stnTlr/jOsIKhGWHAHAO 3fvXwC+OSLvblNcN374JgacNpCshGXJDIhYy3jMZhiPAlqaxnF0Y3AWm4VbvJmy5e/hW iDTlhMhBhxzcvXEllYIyQbuuPAiUPlKMKwgcsrsZG2PgGlkm0sEdILZTR4dhDzQkeM9G +W+g== 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 :user-agent:references:in-reply-to:date:cc:to:from:subject :message-id; bh=qNo5HRFq2rlWEnkaR0Oua4jxnv/+fudNSJBI1cS6rUg=; b=fvdOuAN9Su57eufskJCYAkGgG+YiVnFNLe/4aAz7n7n82hnBiirsZ5+qkejwjTnWlm fetPB9s7sAktg5XP2ZPe9CJHDS98f87x0ABTHXmD8p2ijNeN5bUFfEe0CgbNq3zclcrL aD1XXwG9irNFHSYkztgm7Y6vomaKTHf2wToPYmBW0dqlLJznjQEQLW3T1lnv/5W720bd Fgb7u1ivTx6oYpUha/fLHHmEqux3Cxptxacxxg9EtO2yoRztpZyhlRW0ZTtVHfGqAWRU I6IuSGb85TI12FTCiO47k6gCek7KEDL6HaRQxlosVURZIGJCxjlTb2t5YAp5hF5s9cQc SDeg== 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 e5si4861740otp.317.2020.03.21.05.29.05; Sat, 21 Mar 2020 05:29:18 -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 S1727033AbgCUM2m (ORCPT + 99 others); Sat, 21 Mar 2020 08:28:42 -0400 Received: from smtprelay0077.hostedemail.com ([216.40.44.77]:50760 "EHLO smtprelay.hostedemail.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726192AbgCUM2m (ORCPT ); Sat, 21 Mar 2020 08:28:42 -0400 Received: from filter.hostedemail.com (clb03-v110.bra.tucows.net [216.40.38.60]) by smtprelay03.hostedemail.com (Postfix) with ESMTP id 76636837F24F; Sat, 21 Mar 2020 12:28:41 +0000 (UTC) X-Session-Marker: 6A6F6540706572636865732E636F6D X-Spam-Summary: 2,0,0,,d41d8cd98f00b204,joe@perches.com,,RULES_HIT:41:355:379:599:988:989:1260:1277:1311:1313:1314:1345:1359:1437:1515:1516:1518:1534:1539:1593:1594:1711:1714:1730:1747:1777:1792:2393:2559:2562:2828:3138:3139:3140:3141:3142:3350:3622:3865:3866:3867:3868:4321:4384:5007:10004:10400:10848:11026:11232:11658:11914:12043:12297:12438:12740:12760:12895:13069:13311:13357:13439:13972:14659:14721:21080:21627:30034:30054:30091,0,RBL:none,CacheIP:none,Bayesian:0.5,0.5,0.5,Netcheck:none,DomainCache:0,MSF:not bulk,SPF:,MSBL:0,DNSBL:none,Custom_rules:0:0:0,LFtime:15,LUA_SUMMARY:none X-HE-Tag: wall25_68ce15f06c463 X-Filterd-Recvd-Size: 1554 Received: from XPS-9350.home (unknown [47.151.143.254]) (Authenticated sender: joe@perches.com) by omf05.hostedemail.com (Postfix) with ESMTPA; Sat, 21 Mar 2020 12:28:40 +0000 (UTC) Message-ID: Subject: Re: [PATCH] drivers: iio: Drop unnecessary explicit casting From: Joe Perches To: Nishant Malpani , jic23@kernel.org Cc: knaack.h@gmx.de, lars@metafoo.de, pmeerw@pmeerw.net, linux-iio@vger.kernel.org, linux-kernel@vger.kernel.org Date: Sat, 21 Mar 2020 05:26:52 -0700 In-Reply-To: <20200318100754.25667-1-nish.malpani25@gmail.com> References: <20200318100754.25667-1-nish.malpani25@gmail.com> Content-Type: text/plain; charset="ISO-8859-1" User-Agent: Evolution 3.34.1-2 MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 2020-03-18 at 15:37 +0530, Nishant Malpani wrote: > Provide correct specifiers while printing error logs to discard the use > of unnecessary explicit casting. [] > diff --git a/drivers/iio/accel/kxsd9-i2c.c b/drivers/iio/accel/kxsd9-i2c.c [] > @@ -21,8 +21,8 @@ static int kxsd9_i2c_probe(struct i2c_client *i2c, > > regmap = devm_regmap_init_i2c(i2c, &config); > if (IS_ERR(regmap)) { > - dev_err(&i2c->dev, "Failed to register i2c regmap %d\n", > - (int)PTR_ERR(regmap)); > + dev_err(&i2c->dev, "Failed to register i2c regmap %ld\n", > + PTR_ERR(regmap)); Another option would be to use %pe to print the error identifier and not the error number etc...