Use stopwatch_wait_until_expired where applicable
Change-Id: I4d6c6810b91294a7e401a4a1a446218c04c98e55 Signed-off-by: Jonathan Neuschäfer <j.neuschaefer@gmx.net> Reviewed-on: https://review.coreboot.org/21590 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Mario Scheithauer <mario.scheithauer@siemens.com>
This commit is contained in:
committed by
Martin Roth
parent
109ba284a1
commit
c966075f46
@@ -51,8 +51,9 @@ static int crosec_spi_io(size_t req_size, size_t resp_size, void *context)
|
||||
struct spi_slave *slave = (struct spi_slave *)context;
|
||||
int ret = 0;
|
||||
|
||||
while (!stopwatch_expired(&cs_cooldown_sw))
|
||||
/* Wait minimum delay between CS assertions. */;
|
||||
/* Wait minimum delay between CS assertions. */
|
||||
stopwatch_wait_until_expired(&cs_cooldown_sw);
|
||||
|
||||
spi_claim_bus(slave);
|
||||
|
||||
/* Allow EC to ramp up clock after being awaken.
|
||||
|
Reference in New Issue
Block a user