From: Joe Perches <joe@perches.com>
To: netdev@vger.kernel.org
Subject: [PATCH net-2.6.25 2/8] include/net: Use ipv4_is_<type>
Date: Thu, 13 Dec 2007 15:38:55 -0800 [thread overview]
Message-ID: <1197589141-7020-2-git-send-email-joe@perches.com> (raw)
Message-ID: <40bae850207de9257479a535ea5ab4e7d1cdeab5.1197432867.git.joe@perches.com> (raw)
In-Reply-To: <1197589141-7020-1-git-send-email-joe@perches.com>
In-Reply-To: <e2ebcbf24539c0a3ef2ac77147dbfa55d8ac9e33.1197432867.git.joe@perches.com>
Signed-off-by: Joe Perches <joe@perches.com>
---
include/net/addrconf.h | 10 ++++++----
1 files changed, 6 insertions(+), 4 deletions(-)
diff --git a/include/net/addrconf.h b/include/net/addrconf.h
index c56827d..1c3a560 100644
--- a/include/net/addrconf.h
+++ b/include/net/addrconf.h
@@ -252,10 +252,12 @@ static inline int ipv6_addr_is_ll_all_routers(const struct in6_addr *addr)
static inline int ipv6_isatap_eui64(u8 *eui, __be32 addr)
{
- eui[0] = (ZERONET(addr) || PRIVATE_10(addr) || LOOPBACK(addr) ||
- LINKLOCAL_169(addr) || PRIVATE_172(addr) || TEST_192(addr) ||
- ANYCAST_6TO4(addr) || PRIVATE_192(addr) || TEST_198(addr) ||
- MULTICAST(addr) || BADCLASS(addr)) ? 0x00 : 0x02;
+ eui[0] = (ipv4_is_zeronet(addr) || ipv4_is_private_10(addr) ||
+ ipv4_is_loopback(addr) || ipv4_is_linklocal_169(addr) ||
+ ipv4_is_private_172(addr) || ipv4_is_test_192(addr) ||
+ ipv4_is_anycast_6to4(addr) || ipv4_is_private_192(addr) ||
+ ipv4_is_test_198(addr) || ipv4_is_multicast(addr) ||
+ ipv4_is_badclass(addr)) ? 0x00 : 0x02;
eui[1] = 0;
eui[2] = 0x5E;
eui[3] = 0xFE;
--
1.5.3.7.949.g2221a6
next prev parent reply other threads:[~2007-12-13 23:39 UTC|newest]
Thread overview: 31+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <e2ebcbf24539c0a3ef2ac77147dbfa55d8ac9e33.1197432867.git.joe@perches.com>
2007-12-13 23:38 ` [PATCH net-2.6.25 1/8] Create ipv4_is_<type>(__be32 addr) functions Joe Perches
2007-12-16 21:42 ` David Miller
2007-12-17 22:37 ` Jan Engelhardt
2007-12-17 22:41 ` David Miller
2007-12-17 22:42 ` Joe Perches
2007-12-17 22:43 ` David Miller
2007-12-17 23:02 ` Jan Engelhardt
2007-12-13 23:38 ` Joe Perches
[not found] ` <40bae850207de9257479a535ea5ab4e7d1cdeab5.1197432867.git.joe@perches.com>
2007-12-13 23:38 ` Joe Perches [this message]
2007-12-16 21:43 ` [PATCH net-2.6.25 2/8] include/net: Use ipv4_is_<type> David Miller
[not found] ` <63aaea4664a57e3b9a0b7454da94e72b6d462e22.1197432867.git.joe@perches.com>
2007-12-13 23:38 ` [PATCH net-2.6.25 3/8] net/core: " Joe Perches
2007-12-16 21:44 ` David Miller
[not found] ` <9ab25b88c4c02bb7ba14ff68a8e99bdf4bdef9dd.1197432867.git.joe@perches.com>
2007-12-13 23:38 ` [PATCH net-2.6.25 4/8] net/ipv4: " Joe Perches
2007-12-16 21:45 ` David Miller
[not found] ` <350bda1cfd4ac57b354451157b9009b3c8ce334e.1197432867.git.joe@perches.com>
2007-12-13 23:38 ` [PATCH net-2.6.25 5/8] net/netfilter: " Joe Perches
2007-12-13 23:38 ` Joe Perches
2007-12-16 21:46 ` David Miller
2007-12-13 23:38 ` Joe Perches
[not found] ` <1bb329b93a1f75766b7b89afdfa5ae673e9355ec.1197432867.git.joe@perches.com>
2007-12-13 23:38 ` [PATCH net-2.6.25 6/8] sctp: " Joe Perches
2007-12-14 19:11 ` Vlad Yasevich
2007-12-14 19:14 ` David Miller
2007-12-14 19:17 ` Vlad Yasevich
2007-12-16 21:47 ` David Miller
[not found] ` <aaf1cd18672fdabaa410bff09200c6a74534bdb0.1197432867.git.joe@perches.com>
2007-12-13 23:39 ` [PATCH net-2.6.25 7/8] drivers/infiniband: " Joe Perches
2007-12-13 23:39 ` [ofa-general] " Joe Perches
2007-12-16 21:47 ` David Miller
[not found] ` <885ea24008e2b1c07e6bff0344f260a0ff104a35.1197432867.git.joe@perches.com>
2007-12-13 23:39 ` [PATCH net-2.6.25 8/8] Remove unused IPV4TYPE macros Joe Perches
2007-12-13 23:39 ` Joe Perches
2007-12-16 21:48 ` David Miller
2007-12-17 4:01 ` Joe Perches
2007-12-17 4:28 ` David Miller
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1197589141-7020-2-git-send-email-joe@perches.com \
--to=joe@perches.com \
--cc=netdev@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).