aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStephen Boyd <[email protected]>2023-09-13 14:27:21 -0700
committerHans de Goede <[email protected]>2023-09-18 15:15:02 +0200
commitefce78584e583226e9a1f6cb2fb555d6ff47c3e7 (patch)
treedb3339bffaaf60bb6e579d3bad97bf6012608d0e
parent427fada620733e6474d783ae6037a66eae42bf8c (diff)
platform/x86: intel_scu_ipc: Don't override scu in intel_scu_ipc_dev_simple_command()
Andy discovered this bug during patch review. The 'scu' argument to this function shouldn't be overridden by the function itself. It doesn't make any sense. Looking at the commit history, we see that commit f57fa18583f5 ("platform/x86: intel_scu_ipc: Introduce new SCU IPC API") removed the setting of the scu to ipcdev in other functions, but not this one. That was an oversight. Remove this line so that we stop overriding the scu instance that is used by this function. Reported-by: Andy Shevchenko <[email protected]> Closes: https://lore.kernel.org/r/[email protected] Cc: Prashant Malani <[email protected]> Reviewed-by: Andy Shevchenko <[email protected]> Reviewed-by: Mika Westerberg <[email protected]> Fixes: f57fa18583f5 ("platform/x86: intel_scu_ipc: Introduce new SCU IPC API") Signed-off-by: Stephen Boyd <[email protected]> Link: https://lore.kernel.org/r/[email protected] Reviewed-by: Ilpo Järvinen <[email protected]> Reviewed-by: Hans de Goede <[email protected]> Signed-off-by: Hans de Goede <[email protected]>
-rw-r--r--drivers/platform/x86/intel_scu_ipc.c1
1 files changed, 0 insertions, 1 deletions
diff --git a/drivers/platform/x86/intel_scu_ipc.c b/drivers/platform/x86/intel_scu_ipc.c
index 299c15312acb..3271f81a9c00 100644
--- a/drivers/platform/x86/intel_scu_ipc.c
+++ b/drivers/platform/x86/intel_scu_ipc.c
@@ -443,7 +443,6 @@ int intel_scu_ipc_dev_simple_command(struct intel_scu_ipc_dev *scu, int cmd,
mutex_unlock(&ipclock);
return -ENODEV;
}
- scu = ipcdev;
cmdval = sub << 12 | cmd;
ipc_command(scu, cmdval);
err = intel_scu_ipc_check_status(scu);