From patchwork Sat Jun 1 09:58:31 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thomas Meyer X-Patchwork-Id: 248068 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from mail-wg0-x23d.google.com (mail-wg0-x23d.google.com [IPv6:2a00:1450:400c:c00::23d]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority" (not verified)) by ozlabs.org (Postfix) with ESMTPS id 665EB2C00B1 for ; Sat, 1 Jun 2013 19:58:41 +1000 (EST) Received: by mail-wg0-f61.google.com with SMTP id z11sf513873wgg.6 for ; Sat, 01 Jun 2013 02:58:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlegroups.com; s=20120806; h=x-beenthere:message-id:subject:from:to:date:x-mailer:mime-version :x-authenticated-sender:x-virus-scanned:x-original-sender :x-original-authentication-results:reply-to:precedence:mailing-list :list-id:x-google-group-id:list-post:list-help:list-archive:sender :list-subscribe:list-unsubscribe:content-type; bh=c8kM/N+rcW1wKCropZnmQ2ITCVZZ0ly41qvUJZhHgHU=; b=xvSElPDBoKSslte4BE7cfg5Kg/zPZbmmJ420IlzXg6Upp9FpYT7LSKnFYsBfxyaxt6 zXUpxeihkCjV/t1H0mxqWsiBS/qBkZbXcOtCdh8TwDe2Ewp/vsWY2HCT4b6Y2PAnFNP8 z0nkd/WCMTplV8XovOg0qsLJWaiW69m6YKzq/Am/lKNbkmKJ2abKnaTpXHwx5VUdHe7V UkH8iWHWsLdZRhWGPGtmwo9ThetgBBn/6nwhJ5iPCyLjNAlrILaLgac/lz1YRvQ/7x5E k5oLekkZpgPLwbI9ra+vbyigEC+JLQK/Z0Kypi61SMS5W+TzKHtyvByvNgBD1n1YrLi4 W2hQ== X-Received: by 10.180.81.194 with SMTP id c2mr608648wiy.18.1370080716427; Sat, 01 Jun 2013 02:58:36 -0700 (PDT) X-BeenThere: rtc-linux@googlegroups.com Received: by 10.180.38.52 with SMTP id d20ls482147wik.21.gmail; Sat, 01 Jun 2013 02:58:35 -0700 (PDT) X-Received: by 10.15.44.65 with SMTP id y41mr19051218eev.5.1370080715562; Sat, 01 Jun 2013 02:58:35 -0700 (PDT) Received: from www17.your-server.de (www17.your-server.de. [213.133.104.17]) by gmr-mx.google.com with ESMTPS id bj52si11778588eeb.1.2013.06.01.02.58.35 for (version=TLSv1 cipher=RC4-SHA bits=128/128); Sat, 01 Jun 2013 02:58:35 -0700 (PDT) Received-SPF: neutral (google.com: 213.133.104.17 is neither permitted nor denied by best guess record for domain of thomas@m3y3r.de) client-ip=213.133.104.17; Received: from [88.68.124.133] (helo=[192.168.2.108]) by www17.your-server.de with esmtpsa (TLSv1:AES256-SHA:256) (Exim 4.74) (envelope-from ) id 1Uiia3-0002OQ-4a; Sat, 01 Jun 2013 11:58:35 +0200 Message-ID: <1370080711.29224.34.camel@localhost.localdomain> Subject: [rtc-linux] [PATCH] rtc: Cocci spatch "ptr_ret.spatch" From: Thomas Meyer To: a.zummo@towertech.it, rtc-linux@googlegroups.com, linux-kernel@vger.kernel.org Date: Sat, 01 Jun 2013 11:58:31 +0200 X-Mailer: Evolution 3.6.4 (3.6.4-3.fc18) Mime-Version: 1.0 X-Authenticated-Sender: thomas@m3y3r.de X-Virus-Scanned: Clear (ClamAV 0.97.6/17282/Sat Jun 1 04:12:14 2013) X-Original-Sender: thomas@m3y3r.de X-Original-Authentication-Results: gmr-mx.google.com; spf=neutral (google.com: 213.133.104.17 is neither permitted nor denied by best guess record for domain of thomas@m3y3r.de) smtp.mail=thomas@m3y3r.de Reply-To: rtc-linux@googlegroups.com Precedence: list Mailing-list: list rtc-linux@googlegroups.com; contact rtc-linux+owners@googlegroups.com List-ID: X-Google-Group-Id: 712029733259 List-Post: , List-Help: , List-Archive: Sender: rtc-linux@googlegroups.com List-Subscribe: , List-Unsubscribe: , Signed-off-by: Thomas Meyer diff -u -p a/drivers/rtc/rtc-da9052.c b/drivers/rtc/rtc-da9052.c --- a/drivers/rtc/rtc-da9052.c +++ b/drivers/rtc/rtc-da9052.c @@ -249,10 +249,7 @@ static int da9052_rtc_probe(struct platf rtc->rtc = devm_rtc_device_register(&pdev->dev, pdev->name, &da9052_rtc_ops, THIS_MODULE); - if (IS_ERR(rtc->rtc)) - return PTR_ERR(rtc->rtc); - - return 0; + return PTR_RET(rtc->rtc); } static int da9052_rtc_remove(struct platform_device *pdev) diff -u -p a/drivers/rtc/rtc-isl12022.c b/drivers/rtc/rtc-isl12022.c --- a/drivers/rtc/rtc-isl12022.c +++ b/drivers/rtc/rtc-isl12022.c @@ -267,10 +267,7 @@ static int isl12022_probe(struct i2c_cli isl12022->rtc = devm_rtc_device_register(&client->dev, isl12022_driver.driver.name, &isl12022_rtc_ops, THIS_MODULE); - if (IS_ERR(isl12022->rtc)) - return PTR_ERR(isl12022->rtc); - - return 0; + return PTR_RET(isl12022->rtc); } static int isl12022_remove(struct i2c_client *client) diff -u -p a/drivers/rtc/rtc-m48t35.c b/drivers/rtc/rtc-m48t35.c --- a/drivers/rtc/rtc-m48t35.c +++ b/drivers/rtc/rtc-m48t35.c @@ -174,10 +174,7 @@ static int m48t35_probe(struct platform_ priv->rtc = devm_rtc_device_register(&pdev->dev, "m48t35", &m48t35_ops, THIS_MODULE); - if (IS_ERR(priv->rtc)) - return PTR_ERR(priv->rtc); - - return 0; + return PTR_RET(priv->rtc); } static int m48t35_remove(struct platform_device *pdev) diff -u -p a/drivers/rtc/rtc-pcf8563.c b/drivers/rtc/rtc-pcf8563.c --- a/drivers/rtc/rtc-pcf8563.c +++ b/drivers/rtc/rtc-pcf8563.c @@ -263,10 +263,7 @@ static int pcf8563_probe(struct i2c_clie pcf8563_driver.driver.name, &pcf8563_rtc_ops, THIS_MODULE); - if (IS_ERR(pcf8563->rtc)) - return PTR_ERR(pcf8563->rtc); - - return 0; + return PTR_RET(pcf8563->rtc); } static int pcf8563_remove(struct i2c_client *client) diff -u -p a/drivers/rtc/rtc-pcf8583.c b/drivers/rtc/rtc-pcf8583.c --- a/drivers/rtc/rtc-pcf8583.c +++ b/drivers/rtc/rtc-pcf8583.c @@ -283,10 +283,7 @@ static int pcf8583_probe(struct i2c_clie pcf8583_driver.driver.name, &pcf8583_rtc_ops, THIS_MODULE); - if (IS_ERR(pcf8583->rtc)) - return PTR_ERR(pcf8583->rtc); - - return 0; + return PTR_RET(pcf8583->rtc); } static int pcf8583_remove(struct i2c_client *client)