[PATCH 5/8][SRU][Noble] UBUNTU: SAUCE: mei: vsc: Enhance IVSC chipset stability during warm reboot
You-Sheng Yang
vicamo.yang at canonical.com
Tue Jun 25 09:31:35 UTC 2024
From: Wentong Wu <wentong.wu at intel.com>
BugLink: https://bugs.launchpad.net/bugs/2067364
During system shutdown, incorporate reset logic to ensure the IVSC
chipset remains in a valid state. This adjustment guarantees that
the IVSC chipset operates in a known state following a warm reboot.
Fixes: 566f5ca97680 ("mei: Add transport driver for IVSC device")
Cc: stable at vger.kernel.org # for 6.8+
Signed-off-by: Wentong Wu <wentong.wu at intel.com>
Tested-by: Jason Chen <jason.z.chen at intel.com>
(cherry picked from https://lore.kernel.org/all/20240624014223.4171341-2-wentong.wu@intel.com/)
Signed-off-by: You-Sheng Yang <vicamo.yang at canonical.com>
---
drivers/misc/mei/vsc-tp.c | 14 ++++++++++++++
1 file changed, 14 insertions(+)
diff --git a/drivers/misc/mei/vsc-tp.c b/drivers/misc/mei/vsc-tp.c
index 870c70ef3bb8..452946120b81 100644
--- a/drivers/misc/mei/vsc-tp.c
+++ b/drivers/misc/mei/vsc-tp.c
@@ -568,6 +568,19 @@ static void vsc_tp_remove(struct spi_device *spi)
free_irq(spi->irq, tp);
}
+static void vsc_tp_shutdown(struct spi_device *spi)
+{
+ struct vsc_tp *tp = spi_get_drvdata(spi);
+
+ platform_device_unregister(tp->pdev);
+
+ mutex_destroy(&tp->mutex);
+
+ vsc_tp_reset(tp);
+
+ free_irq(spi->irq, tp);
+}
+
static const struct acpi_device_id vsc_tp_acpi_ids[] = {
{ "INTC1009" }, /* Raptor Lake */
{ "INTC1058" }, /* Tiger Lake */
@@ -580,6 +593,7 @@ MODULE_DEVICE_TABLE(acpi, vsc_tp_acpi_ids);
static struct spi_driver vsc_tp_driver = {
.probe = vsc_tp_probe,
.remove = vsc_tp_remove,
+ .shutdown = vsc_tp_shutdown,
.driver = {
.name = "vsc-tp",
.acpi_match_table = vsc_tp_acpi_ids,
--
2.43.0
More information about the kernel-team
mailing list