secs_to_jiffies(9)
π secs_to_jiffies(9) β the Kernel API Manual bestie edition β¨
Okay so picture this: you're in the kernel, you've got a number of seconds in your hand, and everyone around you is speaking jiffies. Rude, honestly. That's where secs_to_jiffies comes in β she's the translator friend, and she's iconic for it. π
(Manual section 9, kernel API, iykyk.)
β¨ SYNOPSIS β¨
secs_to_jiffies (_secs );
That's it. One argument, zero drama. π
πΈ ARGUMENTS πΈ
_secsβ your time, in seconds. Just seconds. That's the whole vibe check. β±οΈ
π DESCRIPTION π
So the conversion lowkey could not be simpler: it's a simple multiplication with HZ. That's the entire trick. Multiply by HZ, done, slay. π₯
Now here's the part that's actually kind of genius: secs_to_jiffies is defined as a macro rather than a static inline function β not to be quirky, but specifically so it can be used in static initializers. Yes bestie, that's the whole reason. Main character design choice fr fr. π
π¦ RETURN π¦
The jiffies value. That's what you get back. π«Ά
β SEE ALSO β
Grab a snack, this list is long and honestly she ate:
- The kernel file
./include/linux/jiffies.h get_jiffies_64(9)- General information about
time_*inlines(9) time_after(9)time_before(9)time_after_eq(9)time_before_eq(9)time_in_range(9)time_in_range_open(9)time_after64(9)time_before64(9)time_after_eq64(9)time_before_eq64(9)time_in_range64(9)time_is_before_jiffies(9)time_is_before_jiffies64(9)time_is_after_jiffies(9)time_is_after_jiffies64(9)time_is_before_eq_jiffies(9)time_is_before_eq_jiffies64(9)time_is_after_eq_jiffies(9)time_is_after_eq_jiffies64(9)jiffies_to_msecs(9)jiffies_to_usecs(9)jiffies_to_nsecs(9)msecs_to_jiffies(9)usecs_to_jiffies(9)
Like I said: a whole friend group. Go say hi. π
ngl the whole time-conversion family is worth a scroll β but you didn't hear it from me. π
And that's the page! π This one lives over in ./include/linux and it's dated October 2026 β that's the source and the date, bestie, noted and cherished. Byeee, go convert some seconds. πππ§
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms