Skip to content

Commit

Permalink
core: spmc: fix direct request handler
Browse files Browse the repository at this point in the history
The FF-A direct request handling has an error: if the destination ID is
the SPMC ID, the handler is trying to forward the message to an SP with
this ID, which is obviously non-existent so this gives an error.

Fixes: 19ad526 ("core: spmc, sp: cleanup FF-A ID handling")
Acked-by: Jens Wiklander <[email protected]>
Signed-off-by: Balint Dobszay <[email protected]>
  • Loading branch information
balint-dobszay-arm authored and jforissier committed May 10, 2024
1 parent 6e4bc5d commit 9b1d1cf
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions core/arch/arm/kernel/thread_spmc.c
Original file line number Diff line number Diff line change
Expand Up @@ -836,6 +836,7 @@ static void handle_direct_request(struct thread_smc_args *args,
uint32_t direct_resp_fid = 0;

if (IS_ENABLED(CFG_SECURE_PARTITION) &&
FFA_DST(args->a1) != spmc_id &&
FFA_DST(args->a1) != optee_endpoint_id) {
spmc_sp_start_thread(args);
return;
Expand Down

0 comments on commit 9b1d1cf

Please sign in to comment.