Per-CPU BMan portals keep their configuration for use by the CPU hotplug
callbacks. Manually unbinding a built-in portal driver frees the
configuration while the portal is still reachable. Suppress its bind and
unbind attributes.
This issue was found by our static analysis tool under development.
Fixes: fce77c3562ec ("soc/fsl/qbman: Convert to hotplug state machine")
Signed-off-by: Guangshuo Li <[email protected]>
---
drivers/soc/fsl/qbman/bman_portal.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/soc/fsl/qbman/bman_portal.c
b/drivers/soc/fsl/qbman/bman_portal.c
index 046034a7cba3..7ff6f76ea458 100644
--- a/drivers/soc/fsl/qbman/bman_portal.c
+++ b/drivers/soc/fsl/qbman/bman_portal.c
@@ -216,6 +216,7 @@ MODULE_DEVICE_TABLE(of, bman_portal_ids);
static struct platform_driver bman_portal_driver = {
.driver = {
.name = KBUILD_MODNAME,
+ .suppress_bind_attrs = true,
.of_match_table = bman_portal_ids,
},
.probe = bman_portal_probe,
--
2.43.0