arch: arm: mach-socfpga: Mailbox buffer and SDM doorbell improvement
authorAlif Zakuan Yuslaimi <alif.zakuan.yuslaimi@altera.com>
Wed, 22 Jan 2025 02:21:02 +0000 (10:21 +0800)
committerTien Fong Chee <tien.fong.chee@intel.com>
Fri, 24 Jan 2025 01:55:42 +0000 (09:55 +0800)
commitdd18d65ff02841f5efb341df7aea0198ec0a08cf
tree7fc68c9cca9a10172ac4e83b35e3aa21d696917f
parent5a77a0b0399f7287a42a8faa21600df3b9d47a5a
arch: arm: mach-socfpga: Mailbox buffer and SDM doorbell improvement

The current write and notify SDM to read mechanism has a flaw where
SDM is not notified enough to be able to read all the data in the buffer.

This is caused by SDM doorbell will only be sent out once the command
buffer overflow check is satisfied. If the command buffer does not reach
overflow status, no SDM doorbell will be sent out, which may cause a
timeout as the mailbox driver will be waiting for the SDM to read the
buffer to empty even though SDM is not notified to do so.

The solution is to remove the command buffer overflow check
and set the SDM doorbell to always trigger at the end of the command
buffer.

This will ensure that the SDM is able to read all of the data.

Signed-off-by: Alif Zakuan Yuslaimi <alif.zakuan.yuslaimi@altera.com>
arch/arm/mach-socfpga/mailbox_s10.c