| 601 | } |
| 602 | |
| 603 | static void bootstrap_pause(uint64_t deadline) { |
| 604 | uint64_t now = cbm_now_ms(); |
| 605 | if (now >= deadline) { |
| 606 | return; |
| 607 | } |
| 608 | uint64_t remaining_ms = deadline - now; |
| 609 | struct timespec pause = { |
| 610 | .tv_sec = 0, |
| 611 | .tv_nsec = remaining_ms > 1 ? BOOTSTRAP_RETRY_NS : (long)(remaining_ms * 1000000ULL), |
| 612 | }; |
| 613 | (void)cbm_nanosleep(&pause, NULL); |
| 614 | } |
| 615 | |
| 616 | static void bootstrap_startup_lock_release_complete(const cbm_daemon_bootstrap_ops_t *ops, |
| 617 | cbm_daemon_bootstrap_lock_t *lock_io) { |
no test coverage detected