wifi: nxpwifi: return timeout error from nxpwifi_sdio_poll_card_status()

nxpwifi_sdio_poll_card_status() returns the result of the last
register read when polling times out.

If the final register read succeeds, the timeout is incorrectly
reported as success.

Return -ETIMEDOUT when polling runs out of retries.

Fixes: 73b01e57ed ("wifi: nxp: add nxpwifi driver for IW61x")
Assisted-by: LLM
Signed-off-by: Karl Mehltretter <kmehltretter@gmail.com>
Signed-off-by: Jeff Chen <jeff.chen_1@nxp.com>
This commit is contained in:
Karl Mehltretter 2026-10-03 21:22:56 +02:00 committed by Jeff Chen
parent cd026e68fd
commit f86bc8a742

View File

@ -680,7 +680,7 @@ nxpwifi_sdio_poll_card_status(struct nxpwifi_adapter *adapter, u8 bits)
nxpwifi_dbg(adapter, ERROR, "poll card status failed, tries = %d\n", tries);
return ret;
return ret ?: -ETIMEDOUT;
}
/* Disable SDIO host interrupt and release IRQ. */