Message ID | 20250103-wake_irq-v2-4-e3aeff5e9966@nxp.com (mailing list archive) |
---|---|
State | New |
Headers | show
Return-Path: <linux-riscv-bounces+linux-riscv=archiver.kernel.org@lists.infradead.org> X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 95BDBE77188 for <linux-riscv@archiver.kernel.org>; Fri, 3 Jan 2025 08:49:27 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Cc:To:In-Reply-To: References:Message-Id:Subject:Date:From:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Owner; bh=CPYpGJONvPzTWPRPrywWiNt1uPIgnnmzOhZHbWxkU5I=; b=fJh7uAjefxPz899HOlQR/sIH8P 6HoGIofLzCdyqBIcOGGP7b8D6aGjIkx30uolFpVM1triEgdudyS5MqIgszn7LR8iO5IqsSqEQCMwU BsGk8FPJh4VN6G+muMeSPIE34MN8IMO8T8ycSOnjl1fNVDRZwEY3uLy3q5L/mAzz26IvnL0kAM+dR iRbhaeXEn8PJoKaz5LvcsXFMXpGmm5sP8eGSti3FJUsWwk4CsAzdw9H2FWS7BWvznWrGI/+Vkbpf2 ccaENVg6Gp7/23tjR2/h9PYB0ZORmT7A8fwf0ylCfho3va0gnrXlh5mFClR5jQ0oxAz5h6/fVrOcy EoRyqYmw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98 #2 (Red Hat Linux)) id 1tTdMw-0000000CVaL-0yN6; Fri, 03 Jan 2025 08:49:22 +0000 Received: from mail-northeuropeazlp170110001.outbound.protection.outlook.com ([2a01:111:f403:c200::1] helo=DB3PR0202CU003.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.98 #2 (Red Hat Linux)) id 1tTdGD-0000000CTpY-312t; Fri, 03 Jan 2025 08:42:26 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=x8tm0uvqhIf6eroM2HkdsD8BVwwRNYKIWwxjflnKELkq4poS1y+SHTdOD/JbLRK7kdBOQyQbfsNcLPfo1hOZSTtPt5e1mi0rtop5qPSlm06knOFNBiamsQLESAqhzu2CF3UHPzl2YYaC3Q5CLZwL0aYMQTShWL9c+LQM1VqR3y914G0F0/IOvYPhREeGpSEX/evzRg9+B+ArlNJlbMVq0eT7+pvuQEc9jxtNuos2gcb4ih4KlQE2voew2TrAmBpcMYjnVnhJfYdQjAZ8O4J9Q41q5bGl44GQrViGRdduWe56nlu3fXILxclWzgLHRUy6vZMTcOn60+23ojiwCI01Qw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=eLJ6/6T287sMFeFzpA8pzl4U0kUK+AHmoE0BEwYo/f4=; b=Ja/dB4ugHm6Vcl2ZZFuh1oA4BY9dX6PnHP4jpoR9vZyCMvsIO7JxrqPRgVzI4UlOFhPFF1XPNGla9fiSCRM7FQx4F8xL4Lzh+1qCaXFjRAsKVsuQ3yXFRkHnuSrps6lpJy8JcU8HTe+5wwUDYngFhaNw6iGk3CuMK1pM480D9lGv0EWXNwqT3m1SkKIuve7P39kyDYdntx0EhGZ523+GI3mcUa3PE3SGxjhFkzBLhNla8BC66neUXhvLmfBH6iHx9781FFrQneffCTMmAd3ugdeslrMjd8tt4ASgEtHQwSxE5NQUg/8skI+qBQFozCx9fnMc0icKdQxe7LyBUdWvCw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=oss.nxp.com; dmarc=pass action=none header.from=oss.nxp.com; dkim=pass header.d=oss.nxp.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=NXP1.onmicrosoft.com; s=selector1-NXP1-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=eLJ6/6T287sMFeFzpA8pzl4U0kUK+AHmoE0BEwYo/f4=; b=cts5C0Oi00MJZmoRNM4haR+LCAm5msTkmn2uRXN/MAT6bD6ZTGs/SBu52cdodHHB7vKd7FaMjQ2K9jHz+keG2LH14/Nqe4eA82YhsqEkt+SxAqjt/S4HJRA+V61N9dzyGMgN7Wg7QbX6E1t6khUDIbatBQjOjUejj98LsYWe2WPfED5u46ztmLhk6zL8sWN/R9EhVpO1D9x05ndsgpOqGSra5cosXwk64TbT5jAPP4qpDU4O1Byr2+rZ9DjhkL2oLL70okzc1a53/V43vnCM7bxKBgtxoazTqDslAPi8SCh9bNkv44kIctxuMaDcMqTiqSMb7K9oxW1JF2hy4zA1tA== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=oss.nxp.com; Received: from PAXPR04MB8459.eurprd04.prod.outlook.com (2603:10a6:102:1da::15) by GV1PR04MB9101.eurprd04.prod.outlook.com (2603:10a6:150:20::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8314.14; Fri, 3 Jan 2025 08:42:18 +0000 Received: from PAXPR04MB8459.eurprd04.prod.outlook.com ([fe80::165a:30a2:5835:9630]) by PAXPR04MB8459.eurprd04.prod.outlook.com ([fe80::165a:30a2:5835:9630%5]) with mapi id 15.20.8314.013; Fri, 3 Jan 2025 08:42:18 +0000 From: "Peng Fan (OSS)" <peng.fan@oss.nxp.com> Date: Fri, 03 Jan 2025 16:41:16 +0800 Subject: [PATCH v2 04/12] input: misc: nxp-bbnsm-pwrkey: Use resource managed API to simplify code Message-Id: <20250103-wake_irq-v2-4-e3aeff5e9966@nxp.com> References: <20250103-wake_irq-v2-0-e3aeff5e9966@nxp.com> In-Reply-To: <20250103-wake_irq-v2-0-e3aeff5e9966@nxp.com> To: "Rafael J. Wysocki" <rafael@kernel.org>, Len Brown <len.brown@intel.com>, Pavel Machek <pavel@ucw.cz>, Greg Kroah-Hartman <gregkh@linuxfoundation.org>, Dmitry Torokhov <dmitry.torokhov@gmail.com>, Alexandre Belloni <alexandre.belloni@bootlin.com>, Maxime Coquelin <mcoquelin.stm32@gmail.com>, Alexandre Torgue <alexandre.torgue@foss.st.com>, Linus Walleij <linus.walleij@linaro.org>, Conor Dooley <conor.dooley@microchip.com>, Daire McNamara <daire.mcnamara@microchip.com> Cc: linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org, linux-input@vger.kernel.org, linux-rtc@vger.kernel.org, linux-stm32@st-md-mailman.stormreply.com, linux-arm-kernel@lists.infradead.org, linux-arm-msm@vger.kernel.org, linux-riscv@lists.infradead.org, Peng Fan <peng.fan@nxp.com> X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1735893689; l=1523; i=peng.fan@nxp.com; s=20230812; h=from:subject:message-id; bh=g2vZhAdAlG59tJHA7zmPtBw4oLxwHW1tSbJmlo9rLyg=; b=+I6HRtno9tO1xMt9Xr1J/+5hT5bkBUElXdcTiUS7rB914jnH7yIGafGxTvgx5xbyGDYPREEEM qgLQ9gN7uKRA7a2DGATSZHotKncPnzAyRgYkI8jhhuEYvA3TZtkEnlB X-Developer-Key: i=peng.fan@nxp.com; a=ed25519; pk=I4sJg7atIT1g63H7bb5lDRGR2gJW14RKDD0wFL8TT1g= X-ClientProxiedBy: SI2PR02CA0003.apcprd02.prod.outlook.com (2603:1096:4:194::13) To PAXPR04MB8459.eurprd04.prod.outlook.com (2603:10a6:102:1da::15) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: PAXPR04MB8459:EE_|GV1PR04MB9101:EE_ X-MS-Office365-Filtering-Correlation-Id: 9d65fc1e-2bc8-41dd-7b0c-08dd2bd287f7 X-MS-Exchange-SharedMailbox-RoutingAgent-Processed: True X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|376014|7416014|52116014|366016|1800799024|921020|38350700014; X-Microsoft-Antispam-Message-Info: =?utf-8?q?GiATRaze0neRkDt8PMxNziufpXQtDiG?= =?utf-8?q?0jvAyn1kCCFxP8qQ1gKX7hRE5PxLX+cNVigg5+lfJnN6LV3TtzQztaR2OeHjFD9cv?= =?utf-8?q?IMjGRYjFbesm0S3/ZcKjjx4DPkdnHE9F9uRXwkJehDtLsEoaEqO8Ku/SufeQz82Up?= =?utf-8?q?a+cpO0jvdNNeMmuY6j5dHBtbCmJ/N+sXKtgnsI6js/rcqrZ/z+ULaMStKqRMisDC4?= =?utf-8?q?JHp6iI8oT3mApbYrBUwnZXcuQGtNgqk7O9aPy6bJx4UKMupq3nMoPLKQxGwq2yR2d?= =?utf-8?q?jQU6FhlnqhSXgnyL9NGUSkO7el+Yr9olL5yk1gSqqb1eSvpgUDu8MK+3dKgXSOWHB?= =?utf-8?q?wzzCzrQUOSw4ss16LFeL3UEWcvUKPEQPSi3lLdxgZllXdYsDvtFMl10+FJi7KgG4f?= =?utf-8?q?sH69YQ/YG4Grsetf1mfMzxBgKCgywB2Pdx8AWQkN0GwYHZ+tkrVSbV6jFLzz8VmS2?= =?utf-8?q?AwJ2ASLG7XXZ+TUyzJP3atDi3G3+S06yEXViSwquvWOu0GU2qieKCfFaJcfMlpiuN?= =?utf-8?q?6Pv0yz76xHvc3TochiHtJiFgSpdV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am-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:PAXPR04MB8459.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230040)(376014)(7416014)(52116014)(366016)(1800799024)(921020)(38350700014);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?q?7afgsJqcyCfKQA22SJPVZlfgGmlS?= =?utf-8?q?6h9zlubKXsEQzGlWHUw0wPMIHDzWO7CDJZW3ZHeu/IIA1TTrmAcz2/3ivA8rSGtHc?= =?utf-8?q?wiJZraw9ObHSMiwM9YXdaZ1UO5corJEZfzdD9oCd6eIWLa9mVQeOf7mH5PkMY+glq?= =?utf-8?q?CusJ6zHFX9Up5PfddtoqLmLHgcm9YN3VZCIWhAAUWr4Dj/UaUOmR+B8yXi3sAp/wQ?= =?utf-8?q?q+YX5/pmmzFqapubzpxAP6n8DeYQFXy1nd917ntAMIclqyeAMfVhk8alF+rqIIKsy?= =?utf-8?q?spu9csDS1hnMyPw6k1oLRxD9+/1+ZHD2D40Q1VDzmmRAWsEJXWzXNDwlR2FOxzuUF?= =?utf-8?q?H8C0w0xe3I4xW93OlFRuMvoaHiBYeemkHIvQP69NNM0PCcdeU0lR27AABlglxZsuO?= =?utf-8?q?GhFFvUW0rbiwLL9Di2gym19B4HWWdAFhcVhUsoBV9fONQiyyCMghRPLD6PjRXCE7/?= =?utf-8?q?QejGPDdN/5fhFzaTV46wrHJToW/WazSBV3NCxk4CXFgnttLEP+QUxfgNHFuonUpus?= =?utf-8?q?DGpVcm+zY+Ca9w9E3ICF/IJqos12SDPwGmfDOgtWrmujTit7Zg2X4YmnLEA5qoAaj?= =?utf-8?q?1XUx14sIV166HKFUVnlmAJMVs9VnZ21+fCGxImpunKtr3K3crz7efOpO3e9QpyN6K?= =?utf-8?q?MvpKH2xuv67zS0WxM9/nzGZessdmNY8gW9B5T54q06fiCQ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Tenant-Network-Message-Id: 9d65fc1e-2bc8-41dd-7b0c-08dd2bd287f7 X-MS-Exchange-CrossTenant-AuthSource: PAXPR04MB8459.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 03 Jan 2025 08:42:18.1998 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: guPTvljsyGYzXe5O5VBVaJ2FUhM0XZRUy80MXfIHCNgH5u1s4/qtkgJW/BSEtHw/7k87VIluKfuvxEiml5HPqA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: GV1PR04MB9101 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20250103_004225_751292_78895278 X-CRM114-Status: GOOD ( 11.19 ) X-BeenThere: linux-riscv@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: <linux-riscv.lists.infradead.org> List-Unsubscribe: <http://lists.infradead.org/mailman/options/linux-riscv>, <mailto:linux-riscv-request@lists.infradead.org?subject=unsubscribe> List-Archive: <http://lists.infradead.org/pipermail/linux-riscv/> List-Post: <mailto:linux-riscv@lists.infradead.org> List-Help: <mailto:linux-riscv-request@lists.infradead.org?subject=help> List-Subscribe: <http://lists.infradead.org/mailman/listinfo/linux-riscv>, <mailto:linux-riscv-request@lists.infradead.org?subject=subscribe> Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-riscv" <linux-riscv-bounces@lists.infradead.org> Errors-To: linux-riscv-bounces+linux-riscv=archiver.kernel.org@lists.infradead.org |
Series |
pm: Introduce devm_pm_set_wake_irq
|
expand
|
Context | Check | Description |
---|---|---|
conchuod/vmtest-fixes-PR | fail | merge-conflict |
diff --git a/drivers/input/misc/nxp-bbnsm-pwrkey.c b/drivers/input/misc/nxp-bbnsm-pwrkey.c index 7ba8d166d68c18b396e616f6f9074ae98c4629b7..5faad2c98af35c52dcacbf25728dbaf2cbb3c625 100644 --- a/drivers/input/misc/nxp-bbnsm-pwrkey.c +++ b/drivers/input/misc/nxp-bbnsm-pwrkey.c @@ -179,20 +179,17 @@ static int bbnsm_pwrkey_probe(struct platform_device *pdev) return error; } - device_init_wakeup(&pdev->dev, true); - error = dev_pm_set_wake_irq(&pdev->dev, bbnsm->irq); + error = devm_device_init_wakeup(&pdev->dev); + if (error) + return error; + + error = devm_pm_set_wake_irq(&pdev->dev, bbnsm->irq); if (error) dev_warn(&pdev->dev, "irq wake enable failed.\n"); return 0; } -static void bbnsm_pwrkey_remove(struct platform_device *pdev) -{ - dev_pm_clear_wake_irq(&pdev->dev); - device_init_wakeup(&pdev->dev, false); -} - static int __maybe_unused bbnsm_pwrkey_suspend(struct device *dev) { struct platform_device *pdev = to_platform_device(dev); @@ -229,8 +226,6 @@ static struct platform_driver bbnsm_pwrkey_driver = { .of_match_table = bbnsm_pwrkey_ids, }, .probe = bbnsm_pwrkey_probe, - .remove = bbnsm_pwrkey_remove, - }; module_platform_driver(bbnsm_pwrkey_driver);