Commit a30393b3 authored by David E. Box's avatar David E. Box Committed by Hans de Goede

platform/x86/intel/sdsi: Poll on ready bit for writes

Due to change in firmware flow, update mailbox writes to poll on ready bit
instead of run_busy bit. This change makes the polling method consistent
for both writes and reads, which also uses the ready bit.

Fixes: 2546c600 ("platform/x86: Add Intel Software Defined Silicon driver")
Signed-off-by: default avatarDavid E. Box <david.e.box@linux.intel.com>
Link: https://lore.kernel.org/r/20220420155622.1763633-3-david.e.box@linux.intel.comReviewed-by: default avatarHans de Goede <hdegoede@redhat.com>
Signed-off-by: default avatarHans de Goede <hdegoede@redhat.com>
parent 679c7a3f
...@@ -245,8 +245,8 @@ static int sdsi_mbox_cmd_write(struct sdsi_priv *priv, struct sdsi_mbox_info *in ...@@ -245,8 +245,8 @@ static int sdsi_mbox_cmd_write(struct sdsi_priv *priv, struct sdsi_mbox_info *in
FIELD_PREP(CTRL_PACKET_SIZE, info->size); FIELD_PREP(CTRL_PACKET_SIZE, info->size);
writeq(control, priv->control_addr); writeq(control, priv->control_addr);
/* Poll on run_busy bit */ /* Poll on ready bit */
ret = readq_poll_timeout(priv->control_addr, control, !(control & CTRL_RUN_BUSY), ret = readq_poll_timeout(priv->control_addr, control, control & CTRL_READY,
MBOX_POLLING_PERIOD_US, MBOX_TIMEOUT_US); MBOX_POLLING_PERIOD_US, MBOX_TIMEOUT_US);
if (ret) if (ret)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment