[PATCH 2/2] spi: fix controller cleanup() documentation
From: Johan Hovold
Date: Fri Apr 10 2026 - 12:10:41 EST
The controller cleanup() callback is no longer called when releasing a
device, but rather when deregistering it (and on registration failures).
Fixes: c7299fea6769 ("spi: Fix spi device unregister flow")
Cc: Saravana Kannan <saravanak@xxxxxxxxxx>
Signed-off-by: Johan Hovold <johan@xxxxxxxxxx>
---
include/linux/spi/spi.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/include/linux/spi/spi.h b/include/linux/spi/spi.h
index 0dc671c07d3a..0de636484f3d 100644
--- a/include/linux/spi/spi.h
+++ b/include/linux/spi/spi.h
@@ -700,7 +700,7 @@ struct spi_controller {
int (*transfer)(struct spi_device *spi,
struct spi_message *mesg);
- /* Called on release() to free memory provided by spi_controller */
+ /* Called on deregistration to free memory provided by spi_controller */
void (*cleanup)(struct spi_device *spi);
/*
--
2.52.0