ktime_get_boottime_ns(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… ktime_get_boottime_ns(9)

okay so welcome to the Kernel API Manual bestie, today's main character is ktime_get_boottime_ns β€” the function that tells you how long it's been since boot, in nanoseconds. yes, nanoseconds. she's precise. periodt. ✨


🌸 NAME 🌸

ktime_get_boottime_ns β€” get the monotonic time since boot in nanoseconds πŸ•


πŸŽ€ SYNOPSIS πŸŽ€

u64 ktime_get_boottime_ns (void );

like, that's the whole vibe. returns a u64, takes nothing. no cap. πŸ’–


πŸ¦‹ ARGUMENTS πŸ¦‹

  • void β€” no arguments, bestie. it literally needs nothing from you. she's low maintenance like that. πŸ™ˆ

✨ RETURN ✨

the current boottime converted to nanoseconds ⭐

that's it, that's the return value. a u64 full of nanoseconds since boot. iconic behavior honestly. πŸ‘‘


🌈 SEE ALSO 🌈

like a whole friend group of time functions fr fr 🫢 go say hi to all of them.


ngl if you're doing timing stuff in the kernel, read the whole timekeeping.h file β€” she's got lore and it's all documented. πŸ’€

anyway that's the page!! tysm for reading, mwah πŸ’‹

source path: ./include/linux Β· version date: October 2026 Β· and yes we're still shipping ktime_get_boottime_ns(9) in this economy πŸ’…βœ¨

πŸ“¦ where this page comes from