summaryrefslogtreecommitdiff
path: root/libbb/kernel_version.c
diff options
context:
space:
mode:
authorBernhard Reutner-Fischer2006-05-19 11:54:02 +0000
committerBernhard Reutner-Fischer2006-05-19 11:54:02 +0000
commite2e56c7c4129de7d20df42e8239fd304c81ef29b (patch)
tree0f9eb8281fac2f87c79a888dac49b27a1965b366 /libbb/kernel_version.c
parente3c150bc67cb158ee854ffb498f0066c79cd842c (diff)
downloadbusybox-e2e56c7c4129de7d20df42e8239fd304c81ef29b.zip
busybox-e2e56c7c4129de7d20df42e8239fd304c81ef29b.tar.gz
- single KERNEL_VERSION(a,b,c) macro in platform.h
- rename get_kernel_revision() to get_linux_version_code from Robert P. J. Day
Diffstat (limited to 'libbb/kernel_version.c')
-rw-r--r--libbb/kernel_version.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/libbb/kernel_version.c b/libbb/kernel_version.c
index 5f5d36d..310da2f 100644
--- a/libbb/kernel_version.c
+++ b/libbb/kernel_version.c
@@ -26,11 +26,12 @@
#include "libbb.h"
-/* Returns kernel version encoded as major*65536 + minor*256 + patch,
+/* Returns current kernel version encoded as major*65536 + minor*256 + patch,
* so, for example, to check if the kernel is greater than 2.2.11:
- * if (get_kernel_revision() <= 2*65536+2*256+11) { <stuff> }
+ *
+ * if (get_linux_version_code() > KERNEL_VERSION(2,2,11)) { <stuff> }
*/
-int get_kernel_revision(void)
+int get_linux_version_code(void)
{
struct utsname name;
char *s;