Received: by 2002:a05:6358:45e:b0:b5:b6eb:e1f9 with SMTP id 30csp38139rwe; Thu, 25 Aug 2022 23:33:47 -0700 (PDT) X-Google-Smtp-Source: AA6agR7S/aCK+pg0sFb/GjFndIUFA5PRd1ol49zNAO1lA2fViDFwcMACvysLPAL4Kxf4XrS3Muk0 X-Received: by 2002:a17:90b:1d91:b0:1fb:4f7f:852e with SMTP id pf17-20020a17090b1d9100b001fb4f7f852emr2813499pjb.126.1661495627504; Thu, 25 Aug 2022 23:33:47 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1661495627; cv=none; d=google.com; s=arc-20160816; b=GG8P50VrYvNwBtr2iADzyyl+vVzc8uJ2Ug/KRI/9bHOIIMAGcWl0pRf39hH5arU5s8 ZDfgtY4xoeP8nW5FIgT8azOVnR2+apK7WgKplHBspFDuC2vCMebKDvohEDdd0dRbjDU+ uAl+N4f3Iq1pXXTVpK4D89y7nmlAq5Wp07gCGGt/LIg8hIRGXUViiwMqplBmeNmWSkz8 GOM78rj36cmtA8LbSXocqe343o3N2JW5pZOMPsRVIoBZAhWUbx6SrdLKJlFM17cIhxXj QxiKq8duxNC412ahkzMAw5ahg2B+egeMfBFGcB7eamNpv3u8cOs7UDwmbmktbYyb7ZOO 1K1w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id; bh=hp400gKx4OPKQoViuOT0BncKEvqar2zWmeFx70NmTNM=; b=e4mLiBL3W6UDrkmo54OQYDYXzXCo//gdfzoCeBwoTWoiFmhk+ZhhaHkUcowqDrnYpu iYBNaTc/U/fGrJWEZiS+KPcSp+6klN/qcB9Pjj+q8wJiVyV9Cma1CadFmu22XNL2Di9w Zyrgr12+b2fmn+thd6CZOIOt08G0Gw7zqXB1L2kQw1JkyFC3fOxN0ZEJDCjo1BUQthFd 4x5l8ruH+HHp5erp/4uhfMPLEbXrmERd6PmppW/5GEOeL44CVJE2KIxdNGyyYQKvjDPs TzJCzM/fn3ZG1hG7HnD+mQrIlVrUalD5hmTUDed7aj+HpG3uW01qYiQDAzD2YNo06/AB 8oLw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id q1-20020a170902f34100b00171e397f820si800207ple.309.2022.08.25.23.33.22; Thu, 25 Aug 2022 23:33:47 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S243938AbiHZGKe (ORCPT + 99 others); Fri, 26 Aug 2022 02:10:34 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:56306 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229701AbiHZGKc (ORCPT ); Fri, 26 Aug 2022 02:10:32 -0400 Received: from smtp.smtpout.orange.fr (smtp01.smtpout.orange.fr [80.12.242.123]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 99BD82E9E4 for ; Thu, 25 Aug 2022 23:10:31 -0700 (PDT) Received: from [192.168.1.18] ([90.11.190.129]) by smtp.orange.fr with ESMTPA id RSXzoogIBBDYDRSXzooGkT; Fri, 26 Aug 2022 08:10:29 +0200 X-ME-Helo: [192.168.1.18] X-ME-Auth: Y2hyaXN0b3BoZS5qYWlsbGV0QHdhbmFkb28uZnI= X-ME-Date: Fri, 26 Aug 2022 08:10:29 +0200 X-ME-IP: 90.11.190.129 Message-ID: Date: Fri, 26 Aug 2022 08:10:26 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.11.0 Subject: Re: [PATCH -next] regulator: drivers: Remove unnecessary print function dev_err() Content-Language: en-US To: Yang Li , tony@atomide.com Cc: lgirdwood@gmail.com, broonie@kernel.org, linux-omap@vger.kernel.org, linux-kernel@vger.kernel.org, Abaci Robot References: <20220825070438.128093-1-yang.lee@linux.alibaba.com> From: Christophe JAILLET In-Reply-To: <20220825070438.128093-1-yang.lee@linux.alibaba.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,NICE_REPLY_A, RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Le 25/08/2022 à 09:04, Yang Li a écrit : > The print function dev_err() is redundant because > platform_get_irq_byname() already prints an error. > > Link: https://bugzilla.openanolis.cn/show_bug.cgi?id=1986 > Reported-by: Abaci Robot > Signed-off-by: Yang Li > --- > drivers/regulator/tps65219-regulator.c | 6 ++---- > 1 file changed, 2 insertions(+), 4 deletions(-) > > diff --git a/drivers/regulator/tps65219-regulator.c b/drivers/regulator/tps65219-regulator.c > index 7ba2594e437c..ab16e6665625 100644 > --- a/drivers/regulator/tps65219-regulator.c > +++ b/drivers/regulator/tps65219-regulator.c > @@ -363,11 +363,9 @@ static int tps65219_regulator_probe(struct platform_device *pdev) > irq_type = &tps65219_regulator_irq_types[i]; > > irq = platform_get_irq_byname(pdev, irq_type->irq_name); > - if (irq < 0) { > - dev_err(tps->dev, "Failed to get IRQ %s: %d\n", > - irq_type->irq_name, irq); > + if (irq < 0) > return -EINVAL; > - } > + > irq_data[i].dev = tps->dev; > irq_data[i].type = irq_type; > Hi, just in case it has an importance, this is not exactly the same. Previously, the error was related to 'pdev', now it is related to 'tps' and we have: 'struct tps65219 *tps = dev_get_drvdata(pdev->dev.parent);' I don't think it really matters, but just in case... CJ