]> www.infradead.org Git - users/jedix/linux-maple.git/commit
firmware: arm_scmi: Add support for platform to agent channel completion
authorPeng Fan <peng.fan@nxp.com>
Fri, 10 May 2024 03:19:48 +0000 (11:19 +0800)
committerSudeep Holla <sudeep.holla@arm.com>
Fri, 14 Jun 2024 11:14:19 +0000 (12:14 +0100)
commitfa8b28ba22d95be4d2dd3c37fbdbdc066af82941
treebfabcdc187147392d97605336c17b8488f3b987d
parentd0398f51ffb3f706f38b235c7bb17da8658e3392
firmware: arm_scmi: Add support for platform to agent channel completion

On some systems the SCMI platform to agent(p2a) communication can be fully
interrupt driven. The notification(p2a) channel needs completion interrupt
to drive its notification queue at the platform. Without it, the platform
notification will not work as the platform will wait for agent indication
of clearing the channel via interrupt unlike few platforms which can poll
instead.

To support such systems, an optional unidirectional mailbox channel for
p2a reply communication. If the platform sets channel INTR flag set
indicating that it expects the agent to trigger the interrupt to acknowledge
the reciept of the notification or any p2a message, and the completion
interrupt channel is provided, send a mailbox message to the platform
after the p2a message is read and channel is freed to accept new
notifications or p2a messages.

Signed-off-by: Peng Fan <peng.fan@nxp.com>
Link: https://lore.kernel.org/r/20240510-scmi-notify-v2-2-e994cf14ef86@nxp.com
Reviewed-by: Cristian Marussi <cristian.marussi@arm.com>
Signed-off-by: Sudeep Holla <sudeep.holla@arm.com>
drivers/firmware/arm_scmi/common.h
drivers/firmware/arm_scmi/mailbox.c
drivers/firmware/arm_scmi/shmem.c