All of lore.kernel.org
 help / color / mirror / Atom feed
From: Fengguang Wu <fengguang.wu@intel.com>
To: "David S. Miller" <davem@davemloft.net>
Cc: kernel-janitors@vger.kernel.org, netdev@vger.kernel.org
Subject: [net-next:master 90/102] net/ipv4/route.c:1283:9: warning: unused variable 'saddr'
Date: Thu, 12 Jul 2012 14:34:49 +0000	[thread overview]
Message-ID: <20120712143449.GA19890@localhost> (raw)

Hi David,

There are new compile warnings show up in

tree:   git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next.git master
head:   3ec5a261aef55a32664bffd335e5c32aeadf3215
commit: e47a185b31dd2acd424fac7dc0efb96fc5b31a33 [90/102] ipv4: Generalize ip_do_redirect() and hook into new dst_ops->redirect.

All warnings:

net/ipv4/route.c: In function 'ip_do_redirect':
net/ipv4/route.c:1283:9: warning: unused variable 'saddr' [-Wunused-variable]
net/ipv4/route.c:1282:9: warning: unused variable 'daddr' [-Wunused-variable]

vim +1283 net/ipv4/route.c
  1280		__be32 old_gw = ip_hdr(skb)->saddr;
  1281		struct net_device *dev = skb->dev;
  1282		__be32 daddr = iph->daddr;
> 1283		__be32 saddr = iph->saddr;
  1284		struct in_device *in_dev;
  1285		struct neighbour *n;
  1286		struct rtable *rt;

..because the saddr/daddr variables are used inside

#ifdef CONFIG_IP_ROUTE_VERBOSE
        if (IN_DEV_LOG_MARTIANS(in_dev))
                net_info_ratelimited("Redirect from %pI4 on %s about %pI4 ignored\n"
                                     "  Advised path = %pI4 -> %pI4\n",
                                     &old_gw, dev->name, &new_gw,
                                     &saddr, &daddr);
#endif

---
0-DAY kernel build testing backend         Open Source Technology Centre
Fengguang Wu <wfg@linux.intel.com>                     Intel Corporation

WARNING: multiple messages have this Message-ID (diff)
From: Fengguang Wu <fengguang.wu@intel.com>
To: "David S. Miller" <davem@davemloft.net>
Cc: kernel-janitors@vger.kernel.org, netdev@vger.kernel.org
Subject: [net-next:master 90/102] net/ipv4/route.c:1283:9: warning: unused variable 'saddr'
Date: Thu, 12 Jul 2012 22:34:49 +0800	[thread overview]
Message-ID: <20120712143449.GA19890@localhost> (raw)

Hi David,

There are new compile warnings show up in

tree:   git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next.git master
head:   3ec5a261aef55a32664bffd335e5c32aeadf3215
commit: e47a185b31dd2acd424fac7dc0efb96fc5b31a33 [90/102] ipv4: Generalize ip_do_redirect() and hook into new dst_ops->redirect.

All warnings:

net/ipv4/route.c: In function 'ip_do_redirect':
net/ipv4/route.c:1283:9: warning: unused variable 'saddr' [-Wunused-variable]
net/ipv4/route.c:1282:9: warning: unused variable 'daddr' [-Wunused-variable]

vim +1283 net/ipv4/route.c
  1280		__be32 old_gw = ip_hdr(skb)->saddr;
  1281		struct net_device *dev = skb->dev;
  1282		__be32 daddr = iph->daddr;
> 1283		__be32 saddr = iph->saddr;
  1284		struct in_device *in_dev;
  1285		struct neighbour *n;
  1286		struct rtable *rt;

..because the saddr/daddr variables are used inside

#ifdef CONFIG_IP_ROUTE_VERBOSE
        if (IN_DEV_LOG_MARTIANS(in_dev))
                net_info_ratelimited("Redirect from %pI4 on %s about %pI4 ignored\n"
                                     "  Advised path = %pI4 -> %pI4\n",
                                     &old_gw, dev->name, &new_gw,
                                     &saddr, &daddr);
#endif

---
0-DAY kernel build testing backend         Open Source Technology Centre
Fengguang Wu <wfg@linux.intel.com>                     Intel Corporation

             reply	other threads:[~2012-07-12 14:34 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-07-12 14:34 Fengguang Wu [this message]
2012-07-12 14:34 ` [net-next:master 90/102] net/ipv4/route.c:1283:9: warning: unused variable 'saddr' Fengguang Wu
2012-07-12 14:40 ` David Miller
2012-07-12 14:40   ` David Miller
2012-07-12 14:54   ` Fengguang Wu
2012-07-12 14:54     ` Fengguang Wu
2012-07-12 15:47   ` Dan Carpenter
2012-07-12 15:47     ` Dan Carpenter

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=20120712143449.GA19890@localhost \
    --to=fengguang.wu@intel.com \
    --cc=davem@davemloft.net \
    --cc=kernel-janitors@vger.kernel.org \
    --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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.