diff options
Diffstat (limited to 'include/linux/inetdevice.h')
-rw-r--r-- | include/linux/inetdevice.h | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/include/linux/inetdevice.h b/include/linux/inetdevice.h index a4328cea376a..ee971f335a8b 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, | |||
171 | __be32 local, int scope); | 171 | __be32 local, int scope); |
172 | struct in_ifaddr *inet_ifa_byprefix(struct in_device *in_dev, __be32 prefix, | 172 | struct in_ifaddr *inet_ifa_byprefix(struct in_device *in_dev, __be32 prefix, |
173 | __be32 mask); | 173 | __be32 mask); |
174 | static __inline__ int inet_ifa_match(__be32 addr, struct in_ifaddr *ifa) | 174 | static __inline__ bool inet_ifa_match(__be32 addr, struct in_ifaddr *ifa) |
175 | { | 175 | { |
176 | return !((addr^ifa->ifa_address)&ifa->ifa_mask); | 176 | return !((addr^ifa->ifa_address)&ifa->ifa_mask); |
177 | } | 177 | } |
@@ -180,15 +180,15 @@ static __inline__ int inet_ifa_match(__be32 addr, struct in_ifaddr *ifa) | |||
180 | * Check if a mask is acceptable. | 180 | * Check if a mask is acceptable. |
181 | */ | 181 | */ |
182 | 182 | ||
183 | static __inline__ int bad_mask(__be32 mask, __be32 addr) | 183 | static __inline__ bool bad_mask(__be32 mask, __be32 addr) |
184 | { | 184 | { |
185 | __u32 hmask; | 185 | __u32 hmask; |
186 | if (addr & (mask = ~mask)) | 186 | if (addr & (mask = ~mask)) |
187 | return 1; | 187 | return true; |
188 | hmask = ntohl(mask); | 188 | hmask = ntohl(mask); |
189 | if (hmask & (hmask+1)) | 189 | if (hmask & (hmask+1)) |
190 | return 1; | 190 | return true; |
191 | return 0; | 191 | return false; |
192 | } | 192 | } |
193 | 193 | ||
194 | #define for_primary_ifa(in_dev) { struct in_ifaddr *ifa; \ | 194 | #define for_primary_ifa(in_dev) { struct in_ifaddr *ifa; \ |