From: Brian Haley <brian.haley@hp.com>
To: "YOSHIFUJI Hideaki / ????" <yoshfuji@linux-ipv6.org>
Cc: davem@davemloft.net, netdev@vger.kernel.org
Subject: Re: [PATCH 4/4] Add loopback address type inline
Date: Fri, 06 Apr 2007 02:38:18 -0400 [thread overview]
Message-ID: <4615EADA.5090802@hp.com> (raw)
In-Reply-To: <20070406.125154.73441979.yoshfuji@linux-ipv6.org>
YOSHIFUJI Hideaki / ???? wrote:
>> diff --git a/net/ipv6/route.c b/net/ipv6/route.c
>> index 32c6398..06ee92d 100644
>> --- a/net/ipv6/route.c
>> +++ b/net/ipv6/route.c
>> @@ -1067,7 +1067,6 @@ int ip6_route_add(struct fib6_config *cfg)
>> struct net_device *dev = NULL;
>> struct inet6_dev *idev = NULL;
>> struct fib6_table *table;
>> - int addr_type;
>>
>> if (cfg->fc_dst_len > 128 || cfg->fc_src_len > 128)
>> return -EINVAL;
>> @@ -1108,9 +1107,7 @@ int ip6_route_add(struct fib6_config *cfg)
>> cfg->fc_protocol = RTPROT_BOOT;
>> rt->rt6i_protocol = cfg->fc_protocol;
>>
>> - addr_type = ipv6_addr_type(&cfg->fc_dst);
>> -
>> - if (addr_type & IPV6_ADDR_MULTICAST)
>> + if (ipv6_addr_type_multicast(&cfg->fc_dst))
>> rt->u.dst.input = ip6_mc_input;
>> else
>> rt->u.dst.input = ip6_forward;
>
> different commit...
This and the previous patch were layered, and I couldn't add the rest of
this change without the loopback inline:
> @@ -1133,7 +1130,8 @@ int ip6_route_add(struct fib6_config *cfg)
> they would result in kernel looping; promote them to reject routes
> */
> if ((cfg->fc_flags & RTF_REJECT) ||
> - (dev && (dev->flags&IFF_LOOPBACK) && !(addr_type&IPV6_ADDR_LOOPBACK))) {
> + (dev && (dev->flags&IFF_LOOPBACK) &&
> + !ipv6_addr_loopback(&cfg->fc_dst))) {
> /* hold loopback dev/idev if we haven't done so. */
> if (dev != &loopback_dev) {
> if (dev) {
because they both used addr_type.
I'll put this all in one patch together next time so it's more obvious.
-Brian
prev parent reply other threads:[~2007-04-06 7:11 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <11758281863002-git-send-email-brian.haley@hp.com>
2007-04-06 3:21 ` [PATCH 1/4] [IPv6] Add link and site-local scope inline Brian Haley
2007-04-06 3:24 ` YOSHIFUJI Hideaki / 吉藤英明
2007-04-06 6:37 ` Brian Haley
2007-04-06 7:00 ` YOSHIFUJI Hideaki / 吉藤英明
[not found] ` <117582818660-git-send-email-brian.haley@hp.com>
[not found] ` <11758281864173-git-send-email-brian.haley@hp.com>
[not found] ` <151538c13022864224f5ff440e1147f884abb492.1175794415.git.brian.haley@hp.com>
2007-04-06 3:21 ` [PATCH 2/4] [IPv6] Add multicast address type inline Brian Haley
2007-04-06 3:42 ` YOSHIFUJI Hideaki / 吉藤英明
2007-04-06 3:21 ` [PATCH 3/4] Add mapped " Brian Haley
2007-04-06 3:47 ` YOSHIFUJI Hideaki / 吉藤英明
2007-04-06 3:21 ` [PATCH 4/4] Add loopback " Brian Haley
2007-04-06 3:51 ` YOSHIFUJI Hideaki / 吉藤英明
2007-04-06 6:38 ` Brian Haley [this message]
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=4615EADA.5090802@hp.com \
--to=brian.haley@hp.com \
--cc=davem@davemloft.net \
--cc=netdev@vger.kernel.org \
--cc=yoshfuji@linux-ipv6.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).