rpmsg: rockchip: fix mailbox txdone method to polling

Since there is no txdone irq in the Rockchip mailbox IP, invoking
    mbox_chan_txdone()/mbox_client_txdone() after mbox_send_message()
    to tick the TX would be free the active request which have not been
    sent out if the controller returned the EBUSY state before. So amend
    the txdone method to polling to fix it.

The TX polling interval can specify in mailbox DT with
    set "rockchip,txpoll-period-ms" property to 1 milliseconds.

Fixes: b5795e81ec ("rpmsg: rockchip: add Rockchip RPMsg Platform Support")
Signed-off-by: Steven Liu <steven.liu@rock-chips.com>
Change-Id: I9d15ed4a61cda049c7804e2688e79f157de1c5a2
This commit is contained in:
Steven Liu
2023-07-21 16:59:27 +08:00
committed by Tao Huang
parent e79df5fa17
commit 0013ee06a1

View File

@@ -114,7 +114,6 @@ static bool rk_rpmsg_notify(struct virtqueue *vq)
dev_err(dev, "mbox send failed!\n");
return false;
}
mbox_chan_txdone(rpdev->mbox_tx_chan, 0);
return true;
}