From: Hauke Mehrtens Date: Wed, 21 Sep 2011 17:04:24 +0000 (+0200) Subject: compat: add lower_32_bits X-Git-Tag: compat-2011-09-28~2 X-Git-Url: https://openfabrics.org/gitweb/?a=commitdiff_plain;h=8331446ead4dd43ffffbe0c8db16c5103d8a8c28;p=~tnikolova%2Fcompat%2F.git compat: add lower_32_bits Signed-off-by: Hauke Mehrtens --- diff --git a/include/linux/compat-2.6.27.h b/include/linux/compat-2.6.27.h index ed2035c..22fadcd 100644 --- a/include/linux/compat-2.6.27.h +++ b/include/linux/compat-2.6.27.h @@ -250,6 +250,12 @@ static inline __u32 ethtool_cmd_speed(const struct ethtool_cmd *ep) return ep->speed; } +/** + * lower_32_bits - return bits 0-31 of a number + * @n: the number we're accessing + */ +#define lower_32_bits(n) ((u32)(n)) + #endif /* (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,27)) */ #endif /* LINUX_26_27_COMPAT_H */