From patchwork Fri Oct 25 16:03:56 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dario Binacchi X-Patchwork-Id: 3588 Return-Path: X-Original-To: linux-amarula@patchwork.amarulasolutions.com Delivered-To: linux-amarula@patchwork.amarulasolutions.com Received: from mail-lj1-f199.google.com (mail-lj1-f199.google.com [209.85.208.199]) by ganimede.amarulasolutions.com (Postfix) with ESMTPS id EC6563FA04 for ; Fri, 25 Oct 2024 18:04:39 +0200 (CEST) Received: by mail-lj1-f199.google.com with SMTP id 38308e7fff4ca-2fb55e100b0sf15086391fa.1 for ; Fri, 25 Oct 2024 09:04:39 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1729872279; cv=pass; d=google.com; s=arc-20240605; b=kEzDo4U9hHwg8TkHTZcWDc865AcxPyS1XAAQAyaZ7TUlfwci8YdUjUaFDXAWvt+28u k9q7EojDD77ks8RfCXpyL0bhR1BnFErhnguV5CyPak0c3MbmyJ8yQhKgCuxihHawgs8m eI4l/269y8kaLgmC7IkrUq7TsCRZ/BRO8ysF+H0dfZJOd8TUMgTbyuBNvXE23/MjBsc0 mwIVTN1Q2K0SxD4tl3qTY4mQQx0prwfhPqSSlII2qjcdUns5V8fK2sEluIghj27PGve1 ELwOhyDsQxhZ+Z82+bmw43+h3SEJEsEzk9SId15I6+Nk8h/Oro0dF1Rx4PD0TVNT8/E3 mjNA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=list-unsubscribe:list-archive:list-help:list-post:list-id :mailing-list:precedence:mime-version:message-id:date:subject:cc:to :from:dkim-signature; bh=iOhnVxMdTXetYzlgNb8ubhewDKPYHXoQRbzwlMLOZwA=; fh=XPo7kxdaQ58y2W0qkUuo9F+PIYXH6ZMQnUvpTnSRl6I=; b=U5lbBF1/Rq3lLR8gBfrLrkg0xeRC/ZIMv2WBz2NguyHsicxAFQ13zCOwUCkQ4gcNCr Z6336iJkuINwhvKe+fNouItxLYRhYlGYGE662CgOls8wuhkBYqnTBGa8kF2ZfkfF/HoY G8R+FbR8WYGS9Ms/2F8JmJ4Mdv22GfmjbF/wXOqATdCHNiL6oqv2e/7AgpjslnySXxT2 j7Xwn8eV03BCOyLG91Dm6iHVpIctFSRB1gNOsEYdSwyWsTrIaGWAiuFQpaJDG7D/LjjH KA8tR80mM1hB15NCRZCNChjda0O0RiyR+2q1BOWeZcgGim9Y1tP3UKTBzJy/x+gzZSPJ br+A==; darn=patchwork.amarulasolutions.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b="DjzAUW/l"; spf=pass (google.com: domain of dario.binacchi@amarulasolutions.com designates 209.85.220.41 as permitted sender) smtp.mailfrom=dario.binacchi@amarulasolutions.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=amarulasolutions.com; dara=pass header.i=@amarulasolutions.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amarulasolutions.com; s=google; t=1729872279; x=1730477079; darn=patchwork.amarulasolutions.com; h=list-unsubscribe:list-archive:list-help:list-post:list-id :mailing-list:precedence:x-original-authentication-results :x-original-sender:mime-version:message-id:date:subject:cc:to:from :from:to:cc:subject:date:message-id:reply-to; bh=iOhnVxMdTXetYzlgNb8ubhewDKPYHXoQRbzwlMLOZwA=; b=czHuHU7gG8HyfopDwNR11aFW4js8Wj0OSiE/uMzqkZUu3thOUjJp1+t2L1eHgrmGW+ AuulmohYzICNnOiOzKekW8feX9EA80OUXV5DjtHSPwqwxMTvJl3kwh7PYNsIHylPY7xs Yz3b5UuYbsTrGK0IBJqpBcMSD3Mgrff5pho7g= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1729872279; x=1730477079; h=list-unsubscribe:list-archive:list-help:list-post :x-spam-checked-in-group:list-id:mailing-list:precedence :x-original-authentication-results:x-original-sender:mime-version :message-id:date:subject:cc:to:from:x-beenthere:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=iOhnVxMdTXetYzlgNb8ubhewDKPYHXoQRbzwlMLOZwA=; b=BMZC/Rg3TXS1Imk7KxPgZ475N0whhsq1ERxOt/k4RdTMy1FmVw19cMnPgAjQSGn5zb zV/ccE5XSftdJDx8LxUy/+P4gfxQgv8iMirzQKe5OSKA7JQ2aBxG+k6eLiKCAC/pjACJ u0jOgsxS3PK6lyrS3FT26dp3bOSiXc6Y/rraiaZIvcVDzdusMftQOH/YhRmi6VWekKsG XKba570C3Jz7C18QNQHhxXABz/PSmSODQ5Q4NZl5w/Pn9id+V6qB9itbESrNLG6K8zSn omfvBWTSwhsi1buEFeZebHWCrx3dZb0rO5oUBEo4ngWkxHW+4yMb9ESBskb+g6M1K/CN RqqQ== X-Forwarded-Encrypted: i=2; AJvYcCUMgOC9WsdJW2Eex9lp3UlttuipZMf1dWNj+l4g2XdUWuloeCD4IqeqNkj8gNSh4a36yFOYSYpWk1WV19yY@patchwork.amarulasolutions.com X-Gm-Message-State: AOJu0YyEIQn118SprxDyEZkjarUL/arKlSe05CgUbSSzVAt25TZXNjVN YwjkPsT3QlvS+u/sBrQFA6tDIJupkFJkYB3S+XJz7zQ1FN9uL3nxfwK+uNSzM0ia5g== X-Google-Smtp-Source: AGHT+IFVUvf4Q5Chu0UYsNqKkqGF2Ar6AFrqsf/xmosuDcL3THG4bE2KoYB2FYqZkvfQm04V/XMH4w== X-Received: by 2002:ac2:4e06:0:b0:539:e7f8:7bf1 with SMTP id 2adb3069b0e04-53b1a2faff1mr5558235e87.2.1729872279053; Fri, 25 Oct 2024 09:04:39 -0700 (PDT) X-BeenThere: linux-amarula@amarulasolutions.com Received: by 2002:a05:6512:e88:b0:539:fbe2:28a0 with SMTP id 2adb3069b0e04-53b213a5d0els94600e87.0.-pod-prod-03-eu; Fri, 25 Oct 2024 09:04:37 -0700 (PDT) X-Received: by 2002:a05:6512:400d:b0:539:e0e6:cf44 with SMTP id 2adb3069b0e04-53b1a2fad09mr5770809e87.4.1729872277244; Fri, 25 Oct 2024 09:04:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1729872277; cv=none; d=google.com; s=arc-20240605; b=PmkV48ozoXJiI6IQhBp/xmpggXf/Se3ImI5DGIkmQGZdYdYxK+wMG1MU6msE2i1yLn KztWp7+lbFsJu1UegenF0BlW2a5EOgpmiMT9xw23Jp00/Qa9J36GXGwD+Sz+Lk2bCR+A I5wzeMIGl7orctaMrW+qhp1GNcK4D9wN2Nir6zStwW69XWUErP7+kilB9S1BSfBBG+6p PBxH/e1P6eiLxHhoKYmj5E34EQ/4VT57Gvc/0R6hc84laZWcsLrv9kdhIMwv5uA49Dx6 QFaw354qKGeKssiKcUz5qD9cyLlFkD1xwV1smp63Wg6KIYMeRxbqVrlTHynJY74SUCRH pIaA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:dkim-signature; bh=1xCM1ACcR+e8vZp8ZeWNxMr9lABciJDnozk61Zgoap0=; fh=gij5qzQ3G3/w7oxYEvWiek03bQBy5z8yn3pBFfcLVYo=; b=Te0/z20N7KavLTm3e08PxV5JoBIOiNAXgf8BKFTvAVPx4ymWT5VXnTEw8DGIozHhmf d6mzCN842zyNYun1NEjoQDQeqdJtET3H/8H8DAAsXNWLskzZTXXfSF1rLmtYuR3ZSzhW e5/cpWM0zDF0BxU1T/qiefek/ReMSFDIGTwbkLk3/Zk5N+Td+FrKsSMzXCjVcM4yJY0u Jx5sYcTPB82wxfgaOOBtfqy2ZBojMlqM5lj+vZGMwYBXLg9ToK0xGis9ke27PpqrAthC pAnw9bHS6wVwOcngnCFZGPxYGGiWeJvYOgjAwxxEoOwmFbmPwgcarxu14NtOtRdd/D8B vJmQ==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b="DjzAUW/l"; spf=pass (google.com: domain of dario.binacchi@amarulasolutions.com designates 209.85.220.41 as permitted sender) smtp.mailfrom=dario.binacchi@amarulasolutions.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=amarulasolutions.com; dara=pass header.i=@amarulasolutions.com Received: from mail-sor-f41.google.com (mail-sor-f41.google.com. [209.85.220.41]) by mx.google.com with SMTPS id 2adb3069b0e04-53b2e109ce2sor473102e87.6.2024.10.25.09.04.37 for (Google Transport Security); Fri, 25 Oct 2024 09:04:37 -0700 (PDT) Received-SPF: pass (google.com: domain of dario.binacchi@amarulasolutions.com designates 209.85.220.41 as permitted sender) client-ip=209.85.220.41; X-Received: by 2002:a2e:bc09:0:b0:2f7:6653:8046 with SMTP id 38308e7fff4ca-2fc9d37468fmr61995861fa.25.1729872276573; Fri, 25 Oct 2024 09:04:36 -0700 (PDT) Received: from dario-ThinkPad-T14s-Gen-2i.. ([2.196.43.251]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-38058bb4348sm1848614f8f.111.2024.10.25.09.04.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 25 Oct 2024 09:04:36 -0700 (PDT) From: Dario Binacchi To: linux-kernel@vger.kernel.org Cc: linux-amarula@amarulasolutions.com, Dario Binacchi , Michael Trimarchi , Marco Felsch , Fabio Estevam , Krzysztof Kozlowski , Pengutronix Kernel Team , Sascha Hauer , Shawn Guo , Shengjiu Wang , Ulf Hansson , =?utf-8?q?Uwe_Kleine-K=C3=B6nig?= , imx@lists.linux.dev, linux-arm-kernel@lists.infradead.org, linux-pm@vger.kernel.org Subject: [PATCH v2] pmdomain: imx: gpcv2: replace dev_err() with dev_err_probe() Date: Fri, 25 Oct 2024 18:03:56 +0200 Message-ID: <20241025160430.4113467-1-dario.binacchi@amarulasolutions.com> X-Mailer: git-send-email 2.43.0 MIME-Version: 1.0 X-Original-Sender: dario.binacchi@amarulasolutions.com X-Original-Authentication-Results: mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b="DjzAUW/l"; spf=pass (google.com: domain of dario.binacchi@amarulasolutions.com designates 209.85.220.41 as permitted sender) smtp.mailfrom=dario.binacchi@amarulasolutions.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=amarulasolutions.com; dara=pass header.i=@amarulasolutions.com Content-Type: text/plain; charset="UTF-8" Precedence: list Mailing-list: list linux-amarula@amarulasolutions.com; contact linux-amarula+owners@amarulasolutions.com List-ID: X-Spam-Checked-In-Group: linux-amarula@amarulasolutions.com X-Google-Group-Id: 476853432473 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , The patch standardizes the probe() code by replacing the two occurrences of dev_err() with dev_err_probe(). Indeed, dev_err_probe() was used in all other error paths of the probe() function. Note that dev_err_probe() has advantages even if the error code is not EPROBE_DEFER, such as the symbolic output of the error code. Therefore, it should generally be preferred over dev_err(). Co-developed-by: Michael Trimarchi Signed-off-by: Michael Trimarchi Signed-off-by: Dario Binacchi Reviewed-by: Marco Felsch --- Changes in v2: - Improve the commit message. - Add 'Reviewed-by' tag of Marco Felsch. drivers/pmdomain/imx/gpcv2.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/pmdomain/imx/gpcv2.c b/drivers/pmdomain/imx/gpcv2.c index 963d61c5af6d..6e6ecbf2e152 100644 --- a/drivers/pmdomain/imx/gpcv2.c +++ b/drivers/pmdomain/imx/gpcv2.c @@ -1356,7 +1356,7 @@ static int imx_pgc_domain_probe(struct platform_device *pdev) ret = pm_genpd_init(&domain->genpd, NULL, true); if (ret) { - dev_err(domain->dev, "Failed to init power domain\n"); + dev_err_probe(domain->dev, ret, "Failed to init power domain\n"); goto out_domain_unmap; } @@ -1367,7 +1367,7 @@ static int imx_pgc_domain_probe(struct platform_device *pdev) ret = of_genpd_add_provider_simple(domain->dev->of_node, &domain->genpd); if (ret) { - dev_err(domain->dev, "Failed to add genpd provider\n"); + dev_err_probe(domain->dev, ret, "Failed to add genpd provider\n"); goto out_genpd_remove; }