Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753723AbbGNLkD (ORCPT ); Tue, 14 Jul 2015 07:40:03 -0400 Received: from mail-pd0-f170.google.com ([209.85.192.170]:32974 "EHLO mail-pd0-f170.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752611AbbGNLkA (ORCPT ); Tue, 14 Jul 2015 07:40:00 -0400 Message-ID: <55A4F509.6010009@linaro.org> Date: Tue, 14 Jul 2015 17:09:53 +0530 From: Vaibhav Hiremath User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.7.0 MIME-Version: 1.0 To: Wolfram Sang CC: linux-i2c@vger.kernel.org, robh+dt@kernel.org, robert.jarzmik@free.fr, yizhang@marvell.com, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH-v4 06/11] i2c:pxa: Use devm_ variants in probe function References: <1436859410-28878-1-git-send-email-vaibhav.hiremath@linaro.org> <1436859410-28878-7-git-send-email-vaibhav.hiremath@linaro.org> <20150714113556.GE1517@katana> In-Reply-To: <20150714113556.GE1517@katana> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 953 Lines: 32 On Tuesday 14 July 2015 05:05 PM, Wolfram Sang wrote: >> + i2c->reg_base = devm_ioremap_resource(&dev->dev, res); >> + if (IS_ERR(i2c->reg_base)) { >> + dev_err(&dev->dev, "failed to map resource: %ld\n", >> + PTR_ERR(i2c->reg_base)); >> + return PTR_ERR(i2c->reg_base); >> + } > > One change I did when applying: removed this error message. > devm_ioremap_resource prints out the errors it finds. > devm_ioremap_resource doesn't print return value. So this additional error message would print one of, -EINVAL, -EBUSY or -ENOMEM. That was the reason I kept it. If you feel it is not required, I am OK to remove it. Thanks for the update, it certainly saved one more version :) . Thanks, Vaibhav -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/