aboutsummaryrefslogtreecommitdiff
path: root/lib/util.h
diff options
context:
space:
mode:
authorBen Pfaff <blp@nicira.com>2011-07-22 10:20:52 -0700
committerEthan Jackson <ethan@nicira.com>2011-07-22 17:46:48 -0700
commit711e0157cf345f1473247ec90c6ff39eb9f7743c (patch)
treef65665a1ea974b7dd5484dec7fefc000e1e01204 /lib/util.h
parent897b9afc123aec3b9e8950797b53909754e748bc (diff)
util: New function log_2_floor().
Calculates the position of the most significant bit in a 32 bit word.
Diffstat (limited to 'lib/util.h')
-rw-r--r--lib/util.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/util.h b/lib/util.h
index 7615288d..601f49f1 100644
--- a/lib/util.h
+++ b/lib/util.h
@@ -194,6 +194,7 @@ char *base_name(const char *file_name);
char *abs_file_name(const char *dir, const char *file_name);
void ignore(bool x OVS_UNUSED);
+int log_2_floor(uint32_t n);
#ifdef __cplusplus
}