From patchwork Tue May 11 08:51:26 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Zhen Lei X-Patchwork-Id: 434180 Delivered-To: patch@linaro.org Received: by 2002:a02:c901:0:0:0:0:0 with SMTP id t1csp3622301jao; Tue, 11 May 2021 01:51:44 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx2wvzt3HY3rBN4DZ8NfCkUa8R+USnDdsFySMg4Bectc/708Cb/x5Xtv7bmUhf4PiTHo0xg X-Received: by 2002:a50:da88:: with SMTP id q8mr35513333edj.256.1620723104420; Tue, 11 May 2021 01:51:44 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1620723104; cv=none; d=google.com; s=arc-20160816; b=a8JIh2EuUb6PklJzJIRjlHqU//IY0MBDSWu9HxKxh8m0BHrJNJ6C8Fvdwfo5+BDDXa tBE5aNp1D2acfPi8IoIQPgEvgYE6IvimLg4dqYP5aqzo2tNJliQtRTghGB8WTZtioS4v Q/wm9EjIjuxr9GXfrypkD/N4eAqJPl5PafqQS20FFKKVvKfsZvH31e76ugRBQEFBKAud P46zOKxDgwgB+VrG7r09PjblUY6+PxxmpqNTipS8PaUS2ycXNPIhkM2p9dcBkO0/JIsm SQUbzSLaAIO2pdktqZDwyAXyTGJV1F1vRCCpJPp8hV69gvEPzF/r9IDBIDVZ7e/ekewV IzzA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from; bh=zAxXpOXKnLKHZTuVaEqIHq9p1njZ/92dhaj0pB9I9rM=; b=rArrQAx9SC0SM7Py08dUkpzBcPF0gUP6P5/tC3ym3TpDyGqxp+eAxXpx9ME1yInzxL dMvEYkqgOjtb+7f+N0LXApDLzFzR/++Aaw6aQb2ysDhqSn2E+UyWXUbjjGhinrvCGCag JZRVqfY+I8Qsuj14irgporuxZy2MeMkg76OwdFhl9a32QznUHZbiWKE3Ng2EgRzR52Nw lWNf/0i6K/0QvNVAM11Fsf1FjAsYPtB+RIYTtVjzOMh3K93EnkKQm99kRJt/UFAaqy6m 2GMvE4M7G5ermRGnNv7YVcBCzjXuZiJ6FjR1bkFTHy12AKNUF/qXGpPs0u+ZjnVRi36b blNw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-gpio-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-gpio-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=huawei.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id c95si19787007edf.464.2021.05.11.01.51.44; Tue, 11 May 2021 01:51:44 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-gpio-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-gpio-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-gpio-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=huawei.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231176AbhEKIws (ORCPT + 3 others); Tue, 11 May 2021 04:52:48 -0400 Received: from szxga05-in.huawei.com ([45.249.212.191]:2619 "EHLO szxga05-in.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230518AbhEKIws (ORCPT ); Tue, 11 May 2021 04:52:48 -0400 Received: from DGGEMS414-HUB.china.huawei.com (unknown [172.30.72.60]) by szxga05-in.huawei.com (SkyGuard) with ESMTP id 4FfWm25wHQzPwZY; Tue, 11 May 2021 16:48:18 +0800 (CST) Received: from thunder-town.china.huawei.com (10.174.177.72) by DGGEMS414-HUB.china.huawei.com (10.3.19.214) with Microsoft SMTP Server id 14.3.498.0; Tue, 11 May 2021 16:51:32 +0800 From: Zhen Lei To: Linus Walleij , Ray Jui , Scott Branden , bcm-kernel-feedback-list , linux-gpio , linux-arm-kernel CC: Zhen Lei Subject: [PATCH 1/1] pinctrl: iproc-gpio: Remove redundant error printing in iproc_gpio_probe() Date: Tue, 11 May 2021 16:51:26 +0800 Message-ID: <20210511085126.4287-1-thunder.leizhen@huawei.com> X-Mailer: git-send-email 2.26.0.windows.1 MIME-Version: 1.0 X-Originating-IP: [10.174.177.72] X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: linux-gpio@vger.kernel.org When devm_ioremap_resource() fails, a clear enough error message will be printed by its subfunction __devm_ioremap_resource(). The error information contains the device name, failure cause, and possibly resource information. Therefore, remove the error printing here to simplify code and reduce the binary size. Reported-by: Hulk Robot Signed-off-by: Zhen Lei Acked-by: Ray Jui --- drivers/pinctrl/bcm/pinctrl-iproc-gpio.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) -- 2.26.0.106.g9fadedd diff --git a/drivers/pinctrl/bcm/pinctrl-iproc-gpio.c b/drivers/pinctrl/bcm/pinctrl-iproc-gpio.c index e2bd2dce6bb4154..dc511b9a6b43f1b 100644 --- a/drivers/pinctrl/bcm/pinctrl-iproc-gpio.c +++ b/drivers/pinctrl/bcm/pinctrl-iproc-gpio.c @@ -813,10 +813,8 @@ static int iproc_gpio_probe(struct platform_device *pdev) res = platform_get_resource(pdev, IORESOURCE_MEM, 1); if (res) { chip->io_ctrl = devm_ioremap_resource(dev, res); - if (IS_ERR(chip->io_ctrl)) { - dev_err(dev, "unable to map I/O memory\n"); + if (IS_ERR(chip->io_ctrl)) return PTR_ERR(chip->io_ctrl); - } if (of_device_is_compatible(dev->of_node, "brcm,cygnus-ccm-gpio")) io_ctrl_type = IOCTRL_TYPE_CDRU;