All of lore.kernel.org
 help / color / mirror / Atom feed
From: Dan Carpenter <dan.carpenter@oracle.com>
To: "Gabriel L. Somlo" <somlo@cmu.edu>
Cc: "Michael S. Tsirkin" <mst@redhat.com>,
	qemu-devel@nongnu.org, linux-kernel@vger.kernel.org,
	kernel-janitors@vger.kernel.org
Subject: Re: [patch] firmware: qemu_fw_cfg.c: potential unintialized variable
Date: Thu, 14 Apr 2016 20:05:00 +0000	[thread overview]
Message-ID: <20160414200500.GI4247@mwanda> (raw)
In-Reply-To: <20160414193614.GE7821@HEDWIG.INI.CMU.EDU>

Ah...  I see now.  You're right.  Thanks for the explanation.

On my config those functions are no-ops so the variable isn't
initialized.  If they were enabled then *probably* it wouldn't generate
a warning.

Probably just silencing the warning is the way to go though...  I bet
GCC optimizes it away.  Let me think about this some more...

regards,
dan carpenter


WARNING: multiple messages have this Message-ID (diff)
From: Dan Carpenter <dan.carpenter@oracle.com>
To: "Gabriel L. Somlo" <somlo@cmu.edu>
Cc: "Michael S. Tsirkin" <mst@redhat.com>,
	qemu-devel@nongnu.org, linux-kernel@vger.kernel.org,
	kernel-janitors@vger.kernel.org
Subject: Re: [patch] firmware: qemu_fw_cfg.c: potential unintialized variable
Date: Thu, 14 Apr 2016 23:05:00 +0300	[thread overview]
Message-ID: <20160414200500.GI4247@mwanda> (raw)
In-Reply-To: <20160414193614.GE7821@HEDWIG.INI.CMU.EDU>

Ah...  I see now.  You're right.  Thanks for the explanation.

On my config those functions are no-ops so the variable isn't
initialized.  If they were enabled then *probably* it wouldn't generate
a warning.

Probably just silencing the warning is the way to go though...  I bet
GCC optimizes it away.  Let me think about this some more...

regards,
dan carpenter

WARNING: multiple messages have this Message-ID (diff)
From: Dan Carpenter <dan.carpenter@oracle.com>
To: "Gabriel L. Somlo" <somlo@cmu.edu>
Cc: "Michael S. Tsirkin" <mst@redhat.com>,
	qemu-devel@nongnu.org, linux-kernel@vger.kernel.org,
	kernel-janitors@vger.kernel.org
Subject: Re: [Qemu-devel] [patch] firmware: qemu_fw_cfg.c: potential unintialized variable
Date: Thu, 14 Apr 2016 23:05:00 +0300	[thread overview]
Message-ID: <20160414200500.GI4247@mwanda> (raw)
In-Reply-To: <20160414193614.GE7821@HEDWIG.INI.CMU.EDU>

Ah...  I see now.  You're right.  Thanks for the explanation.

On my config those functions are no-ops so the variable isn't
initialized.  If they were enabled then *probably* it wouldn't generate
a warning.

Probably just silencing the warning is the way to go though...  I bet
GCC optimizes it away.  Let me think about this some more...

regards,
dan carpenter

  reply	other threads:[~2016-04-14 20:05 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-04-14  9:33 [patch] firmware: qemu_fw_cfg.c: potential unintialized variable Dan Carpenter
2016-04-14  9:33 ` [Qemu-devel] " Dan Carpenter
2016-04-14  9:33 ` Dan Carpenter
2016-04-14 18:40 ` Gabriel L. Somlo
2016-04-14 18:40   ` [Qemu-devel] " Gabriel L. Somlo
2016-04-14 18:40   ` Gabriel L. Somlo
2016-04-14 19:12   ` Dan Carpenter
2016-04-14 19:12     ` [Qemu-devel] " Dan Carpenter
2016-04-14 19:12     ` Dan Carpenter
2016-04-14 19:36     ` Gabriel L. Somlo
2016-04-14 19:36       ` [Qemu-devel] " Gabriel L. Somlo
2016-04-14 19:36       ` Gabriel L. Somlo
2016-04-14 20:05       ` Dan Carpenter [this message]
2016-04-14 20:05         ` [Qemu-devel] " Dan Carpenter
2016-04-14 20:05         ` Dan Carpenter
2016-04-14 19:51 ` Gabriel L. Somlo
2016-04-14 19:51   ` [Qemu-devel] " Gabriel L. Somlo
2016-04-14 19:51   ` Gabriel L. Somlo

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=20160414200500.GI4247@mwanda \
    --to=dan.carpenter@oracle.com \
    --cc=kernel-janitors@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mst@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=somlo@cmu.edu \
    /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.