[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1444310942-4428-8-git-send-email-bywxiaobai@163.com>
Date: Thu, 8 Oct 2015 21:29:00 +0800
From: Yaowei Bai <bywxiaobai@....com>
To: davem@...emloft.net, tgraf@...g.ch, herbert@...dor.apana.org.au,
johannes.berg@...el.com, daniel@...earbox.net,
gerrit@....abdn.ac.uk, socketcan@...tkopp.net, mkl@...gutronix.de
Cc: netdev@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: [PATCH 7/9] net/inetdevice: inet_ifa_match can be boolean
This patch makes inet_ifa_match return bool due to this
particular function only using either one or zero as its return
value.
No functional change.
Signed-off-by: Yaowei Bai <bywxiaobai@....com>
---
include/linux/inetdevice.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/include/linux/inetdevice.h b/include/linux/inetdevice.h
index a4328ce..3b0999e 100644
--- a/include/linux/inetdevice.h
+++ b/include/linux/inetdevice.h
@@ -171,7 +171,7 @@ __be32 inet_confirm_addr(struct net *net, struct in_device *in_dev, __be32 dst,
__be32 local, int scope);
struct in_ifaddr *inet_ifa_byprefix(struct in_device *in_dev, __be32 prefix,
__be32 mask);
-static __inline__ int inet_ifa_match(__be32 addr, struct in_ifaddr *ifa)
+static __inline__ bool inet_ifa_match(__be32 addr, struct in_ifaddr *ifa)
{
return !((addr^ifa->ifa_address)&ifa->ifa_mask);
}
--
1.9.1
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists