Skip to content

Commit

Permalink
minerva-ag: Fix unexpected sleep at init (#2146)
Browse files Browse the repository at this point in the history
Summary:
- Fix unexpected sleep at init

Pull Request resolved: #2146

Test Plan: - Build code: PASS

Reviewed By: wangx6f

Differential Revision: D67644042

fbshipit-source-id: 6915fdb976dcd68e9fb579b3618b84c661f2666e
  • Loading branch information
Victor-Jhong authored and facebook-github-bot committed Dec 30, 2024
1 parent 429257b commit abfb5ed
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
11 changes: 7 additions & 4 deletions meta-facebook/minerva-ag/src/platform/plat_event.c
Original file line number Diff line number Diff line change
Expand Up @@ -174,9 +174,12 @@ void poll_cpld_registers()

void init_cpld_polling(void)
{
cpld_polling_tid = k_thread_create(
&cpld_polling_thread, cpld_polling_stack, K_THREAD_STACK_SIZEOF(cpld_polling_stack),
poll_cpld_registers, NULL, NULL, NULL, CONFIG_MAIN_THREAD_PRIORITY, 0,
K_MSEC(3000)); //sleep for 3 seconds to prevent dc status changing when reboot BIC
cpld_polling_tid =
k_thread_create(&cpld_polling_thread, cpld_polling_stack,
K_THREAD_STACK_SIZEOF(cpld_polling_stack), poll_cpld_registers,
NULL, NULL, NULL, CONFIG_MAIN_THREAD_PRIORITY, 0,
K_MSEC(2000)); /* Start accessing CPLD 3 seconds after BIC reboot
(2-second thread start delay + 1-second CPLD_POLLING_INTERVAL_MS)
to prevent DC status changes during BIC reboot */
k_thread_name_set(&cpld_polling_thread, "cpld_polling_thread");
}
1 change: 0 additions & 1 deletion meta-facebook/minerva-ag/src/platform/plat_mctp.c
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,6 @@ void plat_mctp_init(void)
mctp_reg_msg_rx_func(p->mctp_inst, mctp_msg_recv);

mctp_start(p->mctp_inst);
k_msleep(5000);
}
}

Expand Down

0 comments on commit abfb5ed

Please sign in to comment.