From: Jiri Pirko <jiri@resnulli.us>
To: Arnd Bergmann <arnd@arndb.de>
Cc: Jamal Hadi Salim <jhs@mojatatu.com>,
Cong Wang <xiyou.wangcong@gmail.com>,
"David S. Miller" <davem@davemloft.net>,
David Ahern <dsa@cumulusnetworks.com>,
netdev@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] [net-next] net: sched: avoid uninitialized variable use
Date: Thu, 18 Jan 2018 14:49:10 +0100 [thread overview]
Message-ID: <20180118134910.GA2063@nanopsycho.orion> (raw)
In-Reply-To: <20180118131747.920324-1-arnd@arndb.de>
Thu, Jan 18, 2018 at 02:17:28PM CET, arnd@arndb.de wrote:
>gcc has identified a code path in which we pass uninitialized
>data into tc_dump_tfilter():
>
>net/sched/cls_api.c: In function 'tc_dump_tfilter':
>net/sched/cls_api.c:1268:8: error: 'parent' may be used uninitialized in this function [-Werror=maybe-uninitialized]
>
>This initializes the variable to the value it had before the previous
>change.
>
>Fixes: 7960d1daf278 ("net: sched: use block index as a handle instead of qdisc when block is shared")
>Signed-off-by: Arnd Bergmann <arnd@arndb.de>
>----
>I don't know if my patch is the best way to address the issue, but
>if not, then at least it helps show what the warning is about
>and lets someone else come up with a better solution.
I already sent a fix for this:
http://patchwork.ozlabs.org/patch/862787/
next prev parent reply other threads:[~2018-01-18 13:49 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-01-18 13:17 [PATCH] [net-next] net: sched: avoid uninitialized variable use Arnd Bergmann
2018-01-18 13:49 ` Jiri Pirko [this message]
2018-01-18 14:19 ` Arnd Bergmann
2018-01-18 14:32 ` Jiri Pirko
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=20180118134910.GA2063@nanopsycho.orion \
--to=jiri@resnulli.us \
--cc=arnd@arndb.de \
--cc=davem@davemloft.net \
--cc=dsa@cumulusnetworks.com \
--cc=jhs@mojatatu.com \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=xiyou.wangcong@gmail.com \
/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