Skip to content

Commit 8b44f0d

Browse files
alexaringholtmann
authored andcommitted
at86rf230: remove hrtimer on 1 usec delay
According Documentation/timers/timers-howto.txt the usually case for setting up a hrtimer takes > ~10us. So we should use udelay in this case so we are sure that the state change was done, before doing the state change assert. Signed-off-by: Alexander Aring <[email protected]> Signed-off-by: Marcel Holtmann <[email protected]>
1 parent 54c9ee3 commit 8b44f0d

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

drivers/net/ieee802154/at86rf230.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -545,7 +545,9 @@ at86rf230_async_state_delay(void *context)
545545
}
546546

547547
/* Default delay is 1us in the most cases */
548-
tim = ktime_set(0, NSEC_PER_USEC);
548+
udelay(1);
549+
at86rf230_async_state_timer(&ctx->timer);
550+
return;
549551

550552
change:
551553
hrtimer_start(&ctx->timer, tim, HRTIMER_MODE_REL);

0 commit comments

Comments
 (0)