Skip to content

Commit

Permalink
usb: use TICKS_READ() as get_ticks() now returns a 64-bit counter
Browse files Browse the repository at this point in the history
  • Loading branch information
rasky committed Oct 11, 2023
1 parent aadffbc commit 44d03a6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/usb.c
Original file line number Diff line number Diff line change
Expand Up @@ -385,7 +385,7 @@ static u32 usb_timeout_start(void)
#ifndef LIBDRAGON
return osGetCount();
#else
return get_ticks();
return TICKS_READ();
#endif
}

Expand All @@ -404,7 +404,7 @@ static char usb_timeout_check(u32 start_ticks, u32 duration)
u64 current_ticks = (u64)osGetCount();
u64 timeout_ticks = OS_USEC_TO_CYCLES((u64)duration * 1000);
#else
u64 current_ticks = (u64)get_ticks();
u64 current_ticks = (u64)TICKS_READ();
u64 timeout_ticks = (u64)TICKS_FROM_MS(duration);
#endif
if (current_ticks < start_ticks)
Expand Down

0 comments on commit 44d03a6

Please sign in to comment.