• Sudeep Holla's avatar
    firmware: arm_scpi: decrease Tx timeout to 20ms · 3bdd8843
    Sudeep Holla authored
    
    
    Currently we have Tx timeout of 50ms while Rx timeout of 20 ms. Tx state
    machine is maintained by the mailbox framework and Rx by SCPI driver.
    
    It is possible that before msg_submit call tx_prepare(because of other
    message in the queue and the channel being active), wait for completion
    in scpi_send_message times out and the buffers are freed. In that case
    when Tx state machine timer goes off later, poll_txdone calls
    scpi_tx_prepare on that message, which adds it to the rx_pending list,
    corrupting link pointers.
    
    This patch reduces the Tx timeout to 20ms and increases Rx timeout to
    30ms to avoid the above mentioned issue.
    Reported-by: default avatarJon Medhurst (Tixy) <tixy@linaro.org>
    Signed-off-by: default avatarSudeep Holla <sudeep.holla@arm.com>
    3bdd8843
arm_scpi.c 19.8 KB