From: Beleswar Prasad Padhi <b-padhi@ti.com>
To: Hari Nagalla <hnagalla@ti.com>, <andersson@kernel.org>,
<mathieu.poirier@linaro.org>
Cc: <afd@ti.com>, <u-kumar1@ti.com>, <s-vadapalli@ti.com>,
<srk@ti.com>, <jan.kiszka@siemens.com>,
<christophe.jaillet@wanadoo.fr>, <jkangas@redhat.com>,
<eballetbo@redhat.com>, <linux-remoteproc@vger.kernel.org>,
<linux-kernel@vger.kernel.org>
Subject: Re: [PATCH 1/3] remoteproc: k3-r5: Fix checks in k3_r5_rproc_{mbox_callback/kick}
Date: Mon, 30 Dec 2024 09:36:49 +0530 [thread overview]
Message-ID: <31b95870-2405-4f1f-bdee-3d635e169c13@ti.com> (raw)
In-Reply-To: <ecba03f8-db97-24d8-8a10-1b4d98d0e1be@ti.com>
Hi Hari,
On 27/12/24 20:08, Hari Nagalla wrote:
> On 12/24/24 03:14, Beleswar Padhi wrote:
>> /**
>> @@ -194,8 +196,11 @@ static void k3_r5_rproc_mbox_callback(struct
>> mbox_client *client, void *data)
>> const char *name = kproc->rproc->name;
>> u32 msg = omap_mbox_message(data);
>> - /* Do not forward message from a detached core */
>> - if (kproc->rproc->state == RPROC_DETACHED)
>> + /*
>> + * Do not forward messages from a detached core, except when the
>> core
>> + * is in the process of being attached in IPC-only mode.
>> + */
>> + if (!kproc->core->is_attach_ongoing && kproc->rproc->state ==
>> RPROC_DETACHED)
>> return;
> Instead of introducing a new state variable, is it possible to use
> device virtio status?
See below related comment.
> And i wonder what if you remove this conditional check altogether? If
> the device is detached and with no virtio queues, does not the mailbox
> message gets dropped?
This check is necessary for mailbox level communication between cores.
Some Mbox messages directly use payloads like
RP_MBOX_ECHO_REQUEST/RP_MBOX_CRASH etc. which do not rely on virtqueue
read/writes for communication (see omap_remoteproc.h). In that case,
mailbox message won't be dropped even if virtio queues are not
initialized. IMO, when we say core is detached in "IPC-only" mode, this
mbox communication should also not happen. What do you think?
next prev parent reply other threads:[~2024-12-30 4:07 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-12-24 9:14 [PATCH 0/3] Rework TI K3 R5F remoteproc driver Beleswar Padhi
2024-12-24 9:14 ` [PATCH 1/3] remoteproc: k3-r5: Fix checks in k3_r5_rproc_{mbox_callback/kick} Beleswar Padhi
2024-12-27 14:38 ` Hari Nagalla
2024-12-30 4:06 ` Beleswar Prasad Padhi [this message]
2025-01-03 6:05 ` Siddharth Vadapalli
2025-01-03 10:48 ` Kumar, Udit
2025-01-03 10:57 ` Beleswar Prasad Padhi
2025-01-03 13:04 ` Kumar, Udit
2025-01-21 18:47 ` Andrew Davis
2025-01-23 4:43 ` Beleswar Prasad Padhi
2024-12-24 9:14 ` [PATCH 2/3] remoteproc: k3-dsp: Fix checks in k3_dsp_rproc_{mbox_callback/kick} Beleswar Padhi
2025-01-03 6:06 ` Siddharth Vadapalli
2024-12-24 9:14 ` [PATCH v2 3/3] remoteproc: k3-r5: Refactor sequential core power up/down operations Beleswar Padhi
2025-01-03 10:48 ` Kumar, Udit
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=31b95870-2405-4f1f-bdee-3d635e169c13@ti.com \
--to=b-padhi@ti.com \
--cc=afd@ti.com \
--cc=andersson@kernel.org \
--cc=christophe.jaillet@wanadoo.fr \
--cc=eballetbo@redhat.com \
--cc=hnagalla@ti.com \
--cc=jan.kiszka@siemens.com \
--cc=jkangas@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-remoteproc@vger.kernel.org \
--cc=mathieu.poirier@linaro.org \
--cc=s-vadapalli@ti.com \
--cc=srk@ti.com \
--cc=u-kumar1@ti.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).