From 798682e236893a20e5674de02ede474373dd342d Mon Sep 17 00:00:00 2001
From: Hans de Goede <hdegoede@redhat.com>
Date: Sun, 21 Nov 2021 20:11:27 +0100
Subject: [PATCH] platform/x86: thinkpad_acpi: Properly indent code in tpacpi_dytc_profile_init()
Git-commit: 798682e236893a20e5674de02ede474373dd342d
Patch-mainline: v5.17-rc1
References: bsc#1210050
The previous refactoring of some code in tpacpi_dytc_profile_init() left
a weirdly indented code-block behind.
Remove the unnecessary '{}' and reduce the indent level one step,
other then changing the indentation the code is completely unchanged.
Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com>
Tested-by: Mark Pearson <mpearson@lenovo.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Link: https://lore.kernel.org/r/20211121191129.256713-6-hdegoede@redhat.com
Acked-by: Takashi Iwai <tiwai@suse.de>
---
drivers/platform/x86/thinkpad_acpi.c | 47 ++++++++++++++--------------
1 file changed, 23 insertions(+), 24 deletions(-)
diff --git a/drivers/platform/x86/thinkpad_acpi.c b/drivers/platform/x86/thinkpad_acpi.c
index 7b7667b1a6fb..ca86e6c2b546 100644
--- a/drivers/platform/x86/thinkpad_acpi.c
+++ b/drivers/platform/x86/thinkpad_acpi.c
@@ -10095,31 +10095,30 @@ static int tpacpi_dytc_profile_init(struct ibm_init_struct *iibm)
if (dytc_version < 5)
return -ENODEV;
- {
- dbg_printk(TPACPI_DBG_INIT,
- "DYTC version %d: thermal mode available\n", dytc_version);
- /*
- * Check if MMC_GET functionality available
- * Version > 6 and return success from MMC_GET command
- */
- dytc_mmc_get_available = false;
- if (dytc_version >= 6) {
- err = dytc_command(DYTC_CMD_MMC_GET, &output);
- if (!err && ((output & DYTC_ERR_MASK) == DYTC_ERR_SUCCESS))
- dytc_mmc_get_available = true;
- }
- /* Create platform_profile structure and register */
- err = platform_profile_register(&dytc_profile);
- /*
- * If for some reason platform_profiles aren't enabled
- * don't quit terminally.
- */
- if (err)
- return -ENODEV;
-
- /* Ensure initial values are correct */
- dytc_profile_refresh();
+ dbg_printk(TPACPI_DBG_INIT,
+ "DYTC version %d: thermal mode available\n", dytc_version);
+ /*
+ * Check if MMC_GET functionality available
+ * Version > 6 and return success from MMC_GET command
+ */
+ dytc_mmc_get_available = false;
+ if (dytc_version >= 6) {
+ err = dytc_command(DYTC_CMD_MMC_GET, &output);
+ if (!err && ((output & DYTC_ERR_MASK) == DYTC_ERR_SUCCESS))
+ dytc_mmc_get_available = true;
}
+ /* Create platform_profile structure and register */
+ err = platform_profile_register(&dytc_profile);
+ /*
+ * If for some reason platform_profiles aren't enabled
+ * don't quit terminally.
+ */
+ if (err)
+ return -ENODEV;
+
+ /* Ensure initial values are correct */
+ dytc_profile_refresh();
+
return 0;
}
--
2.35.3