# \[PATCH v3 1/2\] HID: spi-hid: propagate reset assertion errors during initialization

- From: Jizhou Tong \<hidden\>
- Date: 2026-11-05 19:15:57 
- List: linux-input
- Page: https://ratatoskr.run/linux-input/2026/11/17873305
- Thread: https://ratatoskr.run/linux-input/2026/10/17717024/t.md

```text
Stop initialization before power-up or IRQ enablement if asserting reset
fails. Return the platform error through the core probe and frontend.
This initialization path still ignores the assertion error in v7.

Signed-off-by: Jizhou Tong <redacted>
---
 drivers/hid/spi-hid/spi-hid-core.c | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/drivers/hid/spi-hid/spi-hid-core.c b/drivers/hid/spi-hid/spi-hid-core.c
index 496b33cdf3..fd64d2d2cb 100644
--- a/drivers/hid/spi-hid/spi-hid-core.c
+++ b/drivers/hid/spi-hid/spi-hid-core.c
@@ -1468,7 +1468,11 @@ static int spi_hid_dev_init(struct spi_hid *shid)
 
 	guard(mutex)(&shid->power_lock);
 
-	shid->ops->assert_reset(shid->ops);
+	error = shid->ops->assert_reset(shid->ops);
+	if (error) {
+		dev_err(dev, "failed to assert reset: %d\n", error);
+		return error;
+	}
 
 	shid->ops->sleep_minimal_reset_delay(shid->ops);
 
```
