Message ID | 20240201180102.70395-9-afd@ti.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel+bounces-48648-ouuuleilei=gmail.com@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7301:2719:b0:106:209c:c626 with SMTP id hl25csp342462dyb; Thu, 1 Feb 2024 10:07:23 -0800 (PST) X-Google-Smtp-Source: AGHT+IHxj3L5hvD50AnWM4+A6eoVz8njONKz9eiOcNa1cd6O4/5q2L/4QBTkKC6RF+KOrWhoYpxJ X-Received: by 2002:a05:6102:ad9:b0:46b:119c:17eb with SMTP id m25-20020a0561020ad900b0046b119c17ebmr4803132vsh.1.1706810842966; Thu, 01 Feb 2024 10:07:22 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1706810842; cv=pass; d=google.com; s=arc-20160816; b=ZX+euQiRkNcHZrvlj9mGla+eWQATGGIWnRukW/DqgtxwI5pDeYB1HsLXI0lRM0JbGQ b/snb2oiIE/Qz8GnSlPf9l7m+eMNUvUuy/NoBK7NAaMkrNpwVmt48wfrcgqJSpp1kPq+ /JY9B3qy9U/2nRvbRc0Mn8YsYEkRP4PQzqISWGIuTDzaRqpTLAS98Zep72v1ISfw/UoJ zCqapQkW5N5x0fkdvLP2KSG/IrWS4EbM5WaCvoML2Zr7SKBJL2tLFC+ZjcsC3MJklt+a LOjvMZm1hBhAnLIw6DH4PFat6WYfCh4MnbMnQsI3PbFcMYYm39fYyHnVdOHa0rQ4bUcO +67A== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=cEd9h6ts7ZA9SmxTtqXrV1X3OAdroJfb+pEHlYKYQq0=; fh=HT+FnIs0I4ANTd+DcHN+9ZdpwOfg7H0WObK/m9iytX0=; b=lVQWnsDQ6SszG0UgfOhySHR+XWB3ZojMach3BIo8zBJLgEF5gKB7YVS9ZiA5cr7o/Z eEsHJimQkiSKwGG8Q8OaOLDWFnGYIM0tvpXMMtreSrZMxLfnYRNzedgNex+sX5BU8yAH oQNz1R6LPLgHoDV07V6KdPNwTPFSWEPF3I4hr6IsqWhmLhHMBHdi+8wSHaH+W9t1yQg8 fI/l+1PwHVEvTqQtchgq2ccdd7DmEGQpgRCUwT0rX3T/N1fa6cMC3ZlPY3Y1dg9OW9K4 I2PRuoXRZc8WDgZh/bhLTT1vs4XR3odL8ZhT5vtr6W+xW0dJqrgIVwHMEntRbF3fN4Ku ahXw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b=O4waO+1u; arc=pass (i=1 spf=pass spfdomain=ti.com dkim=pass dkdomain=ti.com dmarc=pass fromdomain=ti.com); spf=pass (google.com: domain of linux-kernel+bounces-48648-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-48648-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com X-Forwarded-Encrypted: i=1; AJvYcCXNUQxS2rQr0Rp8EvFLH0M18ikpfORw6sLViqmETt3KYEQCIbGP3oumrsL6au4YL5OKVSCV4V6WCQugQo2GzYotcTIspA== Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id dh5-20020a056102578500b00466f93264a5si502896vsb.424.2024.02.01.10.07.22 for <ouuuleilei@gmail.com> (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 01 Feb 2024 10:07:22 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-48648-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b=O4waO+1u; arc=pass (i=1 spf=pass spfdomain=ti.com dkim=pass dkdomain=ti.com dmarc=pass fromdomain=ti.com); spf=pass (google.com: domain of linux-kernel+bounces-48648-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-48648-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id AA7011C24952 for <ouuuleilei@gmail.com>; Thu, 1 Feb 2024 18:06:42 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 8920012EBDF; Thu, 1 Feb 2024 18:01:42 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=ti.com header.i=@ti.com header.b="O4waO+1u" Received: from lelv0142.ext.ti.com (lelv0142.ext.ti.com [198.47.23.249]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 21DAD12B159; Thu, 1 Feb 2024 18:01:38 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=198.47.23.249 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706810499; cv=none; b=EXReYGvj5an1M/il5mIY02RhH4Lr/kvtqf8EPCGT9IUs8bAUUGH1gfsrGm8SaMUkypdwIHxS0oCNWx2Rtw8bx1DLMCAX3utiXb/ICF4N62HHKv7sDilsyOjiEwn/kvSV5vHI3AJ/wFFLS/FzTZcEghJ8HDbYp3tPVfwEjkdJsVM= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706810499; c=relaxed/simple; bh=/wWLg9daNT6pfazjCLsyzkG8hTMGV8b457Vt9N+MIYA=; h=From:To:CC:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=h6qH1o2bfnJNbiNL/BPec9ej74j/Ufo4JGALMNfqhEPn6EiT/7bYxEJmAdV1xHCUlmlZH3Fal0tIQMbGygn8cyylRnMJ0VyZn2qI/GrYWI+9L22lkUj/0CihW0LAzpzylMFvru4Fvr1UC74leeCIunqUZLCLPQkbKL6VCI+mcF8= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=ti.com; spf=pass smtp.mailfrom=ti.com; dkim=pass (1024-bit key) header.d=ti.com header.i=@ti.com header.b=O4waO+1u; arc=none smtp.client-ip=198.47.23.249 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=ti.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=ti.com Received: from fllv0035.itg.ti.com ([10.64.41.0]) by lelv0142.ext.ti.com (8.15.2/8.15.2) with ESMTP id 411I18QG127771; Thu, 1 Feb 2024 12:01:08 -0600 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1706810468; bh=cEd9h6ts7ZA9SmxTtqXrV1X3OAdroJfb+pEHlYKYQq0=; h=From:To:CC:Subject:Date:In-Reply-To:References; b=O4waO+1uqN59VsePrSEG4VCsJCg8ZXHl2rWEqwvUo0vLM6/7b6H4sn8iU8og4Q4EE WN/ucJbGJPby/S76a+f0aCGZBfsYcJtDB2+V5uhoj5NjvjxBJy1VJcYuDFBoKt8nl5 UbWCUym9TB69TmC4GeCftprH5gCfidGs3LpcMgrk= Received: from DFLE112.ent.ti.com (dfle112.ent.ti.com [10.64.6.33]) by fllv0035.itg.ti.com (8.15.2/8.15.2) with ESMTPS id 411I18S6047536 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL); Thu, 1 Feb 2024 12:01:08 -0600 Received: from DFLE112.ent.ti.com (10.64.6.33) by DFLE112.ent.ti.com (10.64.6.33) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.23; Thu, 1 Feb 2024 12:01:08 -0600 Received: from lelvsmtp5.itg.ti.com (10.180.75.250) by DFLE112.ent.ti.com (10.64.6.33) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.23 via Frontend Transport; Thu, 1 Feb 2024 12:01:08 -0600 Received: from lelvsmtp6.itg.ti.com ([10.249.42.149]) by lelvsmtp5.itg.ti.com (8.15.2/8.15.2) with ESMTP id 411I12Gm117221; Thu, 1 Feb 2024 12:01:07 -0600 From: Andrew Davis <afd@ti.com> To: Sebastian Reichel <sre@kernel.org>, Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>, Cristian Ciocaltea <cristian.ciocaltea@gmail.com>, Florian Fainelli <florian.fainelli@broadcom.com>, Ray Jui <rjui@broadcom.com>, Scott Branden <sbranden@broadcom.com>, Bjorn Andersson <andersson@kernel.org>, Konrad Dybcio <konrad.dybcio@linaro.org>, Sean Wang <sean.wang@mediatek.com>, Matthias Brugger <matthias.bgg@gmail.com>, AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com> CC: <linux-pm@vger.kernel.org>, <linux-kernel@vger.kernel.org>, <linux-actions@lists.infradead.org>, <linux-arm-msm@vger.kernel.org>, <linux-arm-kernel@lists.infradead.org>, <linux-mediatek@lists.infradead.org>, Andrew Davis <afd@ti.com> Subject: [PATCH 08/18] power: reset: rmobile-reset: Use devm_platform_ioremap_resource() helper Date: Thu, 1 Feb 2024 12:00:52 -0600 Message-ID: <20240201180102.70395-9-afd@ti.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240201180102.70395-1-afd@ti.com> References: <20240201180102.70395-1-afd@ti.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: <linux-kernel.vger.kernel.org> List-Subscribe: <mailto:linux-kernel+subscribe@vger.kernel.org> List-Unsubscribe: <mailto:linux-kernel+unsubscribe@vger.kernel.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1789720886440722748 X-GMAIL-MSGID: 1789720886440722748 |
Series |
Remove pm_power_off use in drivers/power/reset
|
|
Commit Message
Andrew Davis
Feb. 1, 2024, 6 p.m. UTC
Use device life-cycle managed ioremap function to simplify probe and
exit paths.
Signed-off-by: Andrew Davis <afd@ti.com>
---
drivers/power/reset/rmobile-reset.c | 13 ++++---------
1 file changed, 4 insertions(+), 9 deletions(-)
diff --git a/drivers/power/reset/rmobile-reset.c b/drivers/power/reset/rmobile-reset.c index 5df9b41c68c79..29c17ed2d4de9 100644 --- a/drivers/power/reset/rmobile-reset.c +++ b/drivers/power/reset/rmobile-reset.c @@ -41,28 +41,23 @@ static int rmobile_reset_probe(struct platform_device *pdev) { int error; - sysc_base2 = of_iomap(pdev->dev.of_node, 1); - if (!sysc_base2) - return -ENODEV; + sysc_base2 = devm_platform_ioremap_resource(pdev, 0); + if (IS_ERR(sysc_base2)) + return PTR_ERR(sysc_base2); error = register_restart_handler(&rmobile_reset_nb); if (error) { dev_err(&pdev->dev, "cannot register restart handler (err=%d)\n", error); - goto fail_unmap; + return error; } return 0; - -fail_unmap: - iounmap(sysc_base2); - return error; } static void rmobile_reset_remove(struct platform_device *pdev) { unregister_restart_handler(&rmobile_reset_nb); - iounmap(sysc_base2); } static const struct of_device_id rmobile_reset_of_match[] = {