Skip to contentSkip to conversation

slimbus: fixes for 7.3

PATCH New [email protected] 1 participant 2 messages Oct 2

Subsystems (2)
lore
Share & tools
lore

[email protected]

author maintainer
#0 lore raw

cover slimbus: fixes for 7.3

From: Srinivas Kandagatla <[email protected]>

Hi Greg,

Here is a slimbus fix for 7.3, Could you please queue this for 7.3.

Patches include
- messaging: fix leaked PM vote when slim_alloc_txn_tid() fails in slim_do_transfer()

Thanks,
Srini

Zongmin Zhou (1):
slimbus: messaging: fix leaked PM vote on tid allocation failure

 drivers/slimbus/messaging.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
Signature · 1 line
2.53.0
author maintainer
#1 lore raw

PATCH 1/1 slimbus: messaging: fix leaked PM vote on tid allocation failure

From: Zongmin Zhou <[email protected]>

In slim_do_transfer(), when a transaction needs a tid and slim_alloc_txn_tid() fails, the function returns directly instead of jumping to slim_xfer_err. The runtime PM vote taken earlier with pm_runtime_get_sync() is then never released, leaving the controller permanently powered up.

As txn->tid is still 0 at that point, jumping to slim_xfer_err drops the vote exactly like it is done for other failed transactions.

Fixes d3062a2109309 ("slimbus: messaging: add slim_alloc/free_txn_tid()")
---
 drivers/slimbus/messaging.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/slimbus/messaging.c +1 -1
index e2dbe4a66b70..ee127ef42046 100644
@@ -139,7 +139,7 @@ int slim_do_transfer(struct slim_controller *ctrl, struct slim_msg_txn *txn)
 	if (need_tid) {
 		ret = slim_alloc_txn_tid(ctrl, txn);
 		if (ret)
-			return ret;
+			goto slim_xfer_err;
 
 		if (!txn->msg->comp)
 			txn->comp = &done;
Signature · 1 line
2.53.0