From a8980b4598b3aaf6123d31e40a88e247c7b68e23 Mon Sep 17 00:00:00 2001 From: Greg Kroah-Hartman Date: Mon, 8 May 2023 15:17:14 +0200 Subject: [PATCH] 6.3-stable patches added patches: spi-bcm63xx-use-macro-define_simple_dev_pm_ops.patch --- queue-6.3/series | 1 + ...x-use-macro-define_simple_dev_pm_ops.patch | 41 +++++++++++++++++++ 2 files changed, 42 insertions(+) create mode 100644 queue-6.3/spi-bcm63xx-use-macro-define_simple_dev_pm_ops.patch diff --git a/queue-6.3/series b/queue-6.3/series index 3cc267fd528..08b95326b5a 100644 --- a/queue-6.3/series +++ b/queue-6.3/series @@ -692,3 +692,4 @@ cifs-fix-potential-race-when-tree-connecting-ipc.patch cifs-protect-access-of-tcp_server_info-origin-leaf-_fullpath.patch cifs-avoid-potential-races-when-handling-multiple-dfs-tcons.patch debugobject-ensure-pool-refill-again.patch +spi-bcm63xx-use-macro-define_simple_dev_pm_ops.patch diff --git a/queue-6.3/spi-bcm63xx-use-macro-define_simple_dev_pm_ops.patch b/queue-6.3/spi-bcm63xx-use-macro-define_simple_dev_pm_ops.patch new file mode 100644 index 00000000000..cf901be8e58 --- /dev/null +++ b/queue-6.3/spi-bcm63xx-use-macro-define_simple_dev_pm_ops.patch @@ -0,0 +1,41 @@ +From cc5f6fa4f6590e3b9eb8d34302ea43af4a3cfed7 Mon Sep 17 00:00:00 2001 +From: Dhruva Gole +Date: Mon, 24 Apr 2023 15:55:46 +0530 +Subject: spi: bcm63xx: use macro DEFINE_SIMPLE_DEV_PM_OPS + +From: Dhruva Gole + +commit cc5f6fa4f6590e3b9eb8d34302ea43af4a3cfed7 upstream. + +Using this macro makes the code more readable. +It also inits the members of dev_pm_ops in the following manner +without us explicitly needing to: + +.suspend = bcm63xx_spi_suspend, \ +.resume = bcm63xx_spi_resume, \ +.freeze = bcm63xx_spi_suspend, \ +.thaw = bcm63xx_spi_resume, \ +.poweroff = bcm63xx_spi_suspend, \ +.restore = bcm63xx_spi_resume + +Signed-off-by: Dhruva Gole +Link: https://lore.kernel.org/r/20230424102546.1604484-1-d-gole@ti.com +Signed-off-by: Mark Brown +Signed-off-by: Greg Kroah-Hartman +--- + drivers/spi/spi-bcm63xx.c | 4 +--- + 1 file changed, 1 insertion(+), 3 deletions(-) + +--- a/drivers/spi/spi-bcm63xx.c ++++ b/drivers/spi/spi-bcm63xx.c +@@ -656,9 +656,7 @@ static int bcm63xx_spi_resume(struct dev + return 0; + } + +-static const struct dev_pm_ops bcm63xx_spi_pm_ops = { +- SET_SYSTEM_SLEEP_PM_OPS(bcm63xx_spi_suspend, bcm63xx_spi_resume) +-}; ++static DEFINE_SIMPLE_DEV_PM_OPS(bcm63xx_spi_pm_ops, bcm63xx_spi_suspend, bcm63xx_spi_resume); + + static struct platform_driver bcm63xx_spi_driver = { + .driver = { -- 2.47.3