mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2025-12-30 01:30:12 +01:00
For certain options, kernel stores the numeric values in jiffies scale, while the user space value is in USER_HZ (1/100th of a second) scale. Jiffies scale depends on HZ setting (CONFIG_HZ), and depending on kernel configuration its 100, 250, 300, or 1000. That means, the round trip of clock_t_to_jiffies()/jiffies_to_clock_t() has different rounding errors, depending on CONFIG_HZ and it maybe be +/- 1 of the requested value. Since the rounding error depends on CONFIG_HZ, we cannot find "good" values for testing, that always behave the same. So we need to workaround that. Normalize the bridge values, if they look as if the value was mangled due to rounding. Related: https://gitlab.freedesktop.org/NetworkManager/NetworkManager/-/issues/665 |
||
|---|---|---|
| .. | ||
| tests | ||
| nm-fake-platform.c | ||
| nm-fake-platform.h | ||