Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CurrentRelease ¶
CurrentRelease returns the current kernel release ensuring that ubuntu and debian release numbers are accurate.
func CurrentVersion ¶
CurrentVersion returns the current kernel version in LINUX_VERSION_CODE format (see VersionFromRelease())
func Version ¶
Version implements KERNEL_VERSION equivalent macro #define KERNEL_VERSION(a,b,c) (((a) << 16) + ((b) << 8) + ((c) > 255 ? 255 : (c)))
func VersionFromRelease ¶
VersionFromRelease converts a release string with format 4.4.2[-1] to a kernel version number in LINUX_VERSION_CODE format. That is, for kernel "a.b.c", the version number will be (a<<16 + b<<8 + c)
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.