From: Stephen Hemminger <shemminger@vyatta.com>
To: Mike Frysinger <vapier@gentoo.org>
Cc: netdev@vger.kernel.org
Subject: Re: iproute2-3.5.0: `ip a s` no longer shows addresses
Date: Mon, 13 Aug 2012 08:11:25 -0700 [thread overview]
Message-ID: <20120813081125.275937fb@nehalam.linuxnetplumber.net> (raw)
In-Reply-To: <201208071503.01261.vapier@gentoo.org>
[-- Attachment #1: Type: text/plain, Size: 1677 bytes --]
On Tue, 7 Aug 2012 15:03:00 -0400
Mike Frysinger <vapier@gentoo.org> wrote:
> since 3.4.0 works, but 3.5.0, a quick bisect shows the bad commit:
> http://git.kernel.org/?p=linux/kernel/git/shemminger/iproute2.git;a=commit;h=8d07e5f7d995171ee8834eae268e300560de5d4f
>
> the simple test case:
> make clean && make -j -s && ./ip/ip a s lo
>
> before that change, i would get:
> 1: lo: <LOOPBACK,UP,LOWER_UP> mtu 16436 qdisc noqueue state UNKNOWN
> link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
> inet 127.0.0.1/8 scope host lo
> inet6 ::1/128 scope host
> valid_lft forever preferred_lft forever
>
> but after, i now get:
> 1: lo: <LOOPBACK,UP,LOWER_UP> mtu 16436 qdisc noqueue state UNKNOWN
> link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
>
> seems like the bug was introduced in the middle of that patch:
>
> - if (filter.family != AF_PACKET) {
> + if (filter.family && filter.family != AF_PACKET) {
> + if (filter.oneline)
> + no_link = 1;
> +
> if (rtnl_wilddump_request(&rth, filter.family, RTM_GETADDR) < 0) {
> perror("Cannot send dump request");
> exit(1);
>
> if i revert the change to the if statement there, `ip a s` works for me again.
> (see below)
> -mike
>
> diff --git a/ip/ipaddress.c b/ip/ipaddress.c
> index 37deda5..69a63b3 100644
> --- a/ip/ipaddress.c
> +++ b/ip/ipaddress.c
> @@ -1018,7 +1018,7 @@ static int ipaddr_list_or_flush(int argc, char **argv, int flush)
> exit(1);
> }
>
> - if (filter.family && filter.family != AF_PACKET) {
> + if (filter.family != AF_PACKET) {
> if (filter.oneline)
> no_link = 1;
>
Ok. Applied
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 836 bytes --]
prev parent reply other threads:[~2012-08-13 15:11 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-08-07 19:03 iproute2-3.5.0: `ip a s` no longer shows addresses Mike Frysinger
2012-08-13 15:11 ` Stephen Hemminger [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=20120813081125.275937fb@nehalam.linuxnetplumber.net \
--to=shemminger@vyatta.com \
--cc=netdev@vger.kernel.org \
--cc=vapier@gentoo.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