tc_counter_mask is an unsigned int and in the TSC timecounter is equal
to UINT_MAX, so the addition tc->tc_counter_mask + 1 can overflow to 0,
resulting in a hang during boot.
Fixes: c2705ceaeb09 ("x86: Speed up clock calibration")
Differential D33956
clockcalib: Fix an overflow bug markj on Jan 19 2022, 10:49 PM. Authored by Tags None Referenced Files
Subscribers
Details
tc_counter_mask is an unsigned int and in the TSC timecounter is equal Fixes: c2705ceaeb09 ("x86: Speed up clock calibration")
Diff Detail
Event TimelineComment Actions @markj could it be possible to backport this fix to the FreeBSD 13.1 while there is still time? Comment Actions Oh. Ugh. I didn't realize that this was never backported. :( And of course RC6 is already building. Ok, I'll see what I can do. Thanks for the report. |