Attention is currently required from: Rex-BC Chen, Paul Menzel, Angel Pons, Yu-Ping Wu, Jianjun Wang. Hung-Te Lin has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/62933 )
Change subject: soc/mediatek: Add timestamp to measure PERST# time ......................................................................
Patch Set 3:
(1 comment)
File src/soc/mediatek/common/pcie.c:
https://review.coreboot.org/c/coreboot/+/62933/comment/1ece871d_777f76ea PS3, Line 238: perst_time_us = mtk_pcie_perst_elapsed_time(); : printk(BIOS_DEBUG, "%s: %lld us elapsed since assert PERST#\n", : __func__, perst_time_us); : : /* : * Described in PCIe CEM specification sections 2.2 : * (PERST# Signal) and 2.2.1 (Initial Power-Up (G3 to S0)). : * The deassertion of PERST# should be delayed 100ms (TPVPERL) : * for the power and clock to become stable. : */ : if (perst_time_us < 100000) : printk(BIOS_WARNING, "%s: PERST# assert time %lld us may not enough for link up\n", : __func__, perst_time_us); : I think we should do it like:
perst_time_us = mtk_pcie_perst_elapsed_time(); if (!perst_time_us) { /* enable the prest */ } if (perst_time_us > 100000) perst_time_us = 100000; sleep(100000 - perst_time_us);
So the PCIE link would work no matter if people did early init or not.