Skip to content
Commit 001dde94 authored by Shawn Nematbakhsh's avatar Shawn Nematbakhsh Committed by Lee Jones
Browse files

mfd: cros ec: spi: Fix "in progress" error signaling



For host commands that take a long time to process, cros ec can return
early by signaling a EC_RES_IN_PROGRESS result. The host must then poll
status with EC_CMD_GET_COMMS_STATUS until completion of the command.

None of the above applies when data link errors are encountered. When
errors such as EC_SPI_PAST_END are encountered during command
transmission, it usually means the command was not received by the EC.
Treating such errors as if they were 'EC_RES_IN_PROGRESS' results is
almost always the wrong decision, and can result in host commands
silently being lost.

Reported-by: default avatarJon Hunter <jonathanh@nvidia.com>
Signed-off-by: default avatarShawn Nematbakhsh <shawnn@chromium.org>
Reviewed-by: default avatarBrian Norris <briannorris@chromium.org>
Tested-by: default avatarJon Hunter <jonathanh@nvidia.com>
Signed-off-by: default avatarLee Jones <lee.jones@linaro.org>
parent 85e9b13c
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment