Re: [PATCH] mailbox: Clarify multi-thread is not supported in blocking mode
From: Jassi Brar
Date: Mon May 18 2026 - 15:03:44 EST
On Tue, Apr 21, 2026 at 5:46 AM Joonwon Kang <joonwonkang@xxxxxxxxxx> wrote:
>
> Unlike in non-blocking mode, multi-thread has not been supported in
> blocking mode. This commit is to prevent clients from having wrong
> assumption by explicitly specifying this fact to the API doc.
>
> Cc: stable@xxxxxxxxxxxxxxx
> Signed-off-by: Joonwon Kang <joonwonkang@xxxxxxxxxx>
> ---
> v1: Abandon the previous attempts to support multi-thread in blocking
> mode and instead declare it is not supported.
>
> drivers/mailbox/mailbox.c | 4 ++++
> 1 file changed, 4 insertions(+)
>
> diff --git a/drivers/mailbox/mailbox.c b/drivers/mailbox/mailbox.c
> index bbc9fd75a95f..b00f7a32e866 100644
> --- a/drivers/mailbox/mailbox.c
> +++ b/drivers/mailbox/mailbox.c
> @@ -258,6 +258,10 @@ EXPORT_SYMBOL_GPL(mbox_chan_tx_slots_available);
> * over the chan, i.e, tx_done() is made.
> * This function could be called from atomic context as it simply
> * queues the data and returns a token against the request.
> + * In blocking mode, it is caller's responsibility to serialize threads'
> + * access to a channel if multi-threads are to send messages through the
> + * same channel, i.e. caller should not call this function until any
> + * previous call returns.
> *
> * Return: Non-negative integer for successful submission (non-blocking mode)
> * or transmission over chan (blocking mode).
> --
> 2.54.0.rc1.555.g9c883467ad-goog
>
Documentation fixes don't go to stable, so removed the cc to stable.
Applied to mailbox/for-next
Thanks
Jassi