[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAHA+R7N7_Aim_dvs2mdGaPWk59qYbuafzW8WUd2PRLT=Yc7K8g@mail.gmail.com>
Date: Mon, 6 Oct 2014 17:42:11 -0700
From: Cong Wang <cwang@...pensource.com>
To: Tom Herbert <therbert@...gle.com>
Cc: David Miller <davem@...emloft.net>,
Stephen Hemminger <stephen@...workplumber.org>,
netdev <netdev@...r.kernel.org>
Subject: Re: [PATCH iproute2 1/5] iplink: Fix setting of -1 as ifindex
On Fri, Oct 3, 2014 at 8:55 AM, Tom Herbert <therbert@...gle.com> wrote:
> Commit 3c682146aeff157ec3540 ("iplink: forbid negative ifindex and
> modifying ifindex") initializes index to -1 in iplink_modify. When
> creating a link, req.i.ifi_index is then set to -1 if the link option is
> not used. In the kernel this is then used to set dev->ifindex. For
> dev->ifindex, zero is considered to be unset and -1 is treated as
> a set index, so when a second tunnel is create the new device conflicts
> with the old one (both have ifindex of -1) so -EBUSY is returned.
>
> This patch set zero in req.i.ifi_index is index is unset (still -1).
There was a patch before yours:
https://patchwork.ozlabs.org/patch/395404/
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists