linux-ide.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH]: ata: fix unused variable warning in sil_host_intr()
@ 2010-05-27 17:35 Prarit Bhargava
  2010-05-27 17:48 ` Sergei Shtylyov
  0 siblings, 1 reply; 3+ messages in thread
From: Prarit Bhargava @ 2010-05-27 17:35 UTC (permalink / raw)
  To: linux-ide, jgarzik; +Cc: Prarit Bhargava

Warning seen with 'make -j24 CONFIG_DEBUG_SECTION_MISMATCH=y':

drivers/ata/sata_sil.c: In function ‘sil_host_intr’:
drivers/ata/sata_sil.c:442: error: ‘serror’ may be used uninitialized in this function

Signed-off-by: Prarit Bhargava <prarit@redhat.com>

diff --git a/drivers/ata/sata_sil.c b/drivers/ata/sata_sil.c
index 3cb69d5..d7c616c 100644
--- a/drivers/ata/sata_sil.c
+++ b/drivers/ata/sata_sil.c
@@ -439,7 +439,7 @@ static void sil_host_intr(struct ata_port *ap, u32 bmdma2)
 	u8 status;
 
 	if (unlikely(bmdma2 & SIL_DMA_SATA_IRQ)) {
-		u32 serror;
+		u32 uninitialized_var(serror);
 
 		/* SIEN doesn't mask SATA IRQs on some 3112s.  Those
 		 * controllers continue to assert IRQ as long as


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH]: ata: fix unused variable warning in sil_host_intr()
  2010-05-27 17:35 [PATCH]: ata: fix unused variable warning in sil_host_intr() Prarit Bhargava
@ 2010-05-27 17:48 ` Sergei Shtylyov
  2010-05-27 18:02   ` Prarit Bhargava
  0 siblings, 1 reply; 3+ messages in thread
From: Sergei Shtylyov @ 2010-05-27 17:48 UTC (permalink / raw)
  To: Prarit Bhargava; +Cc: linux-ide, jgarzik

Hello.

Prarit Bhargava wrote:

    s/unused/uninitialized/ in the subject. Unused variable is a 
different thing.

> Warning seen with 'make -j24 CONFIG_DEBUG_SECTION_MISMATCH=y':

    I don't think any of these matters here...

> drivers/ata/sata_sil.c: In function ‘sil_host_intr’:
> drivers/ata/sata_sil.c:442: error: ‘serror’ may be used uninitialized in this function

> Signed-off-by: Prarit Bhargava <prarit@redhat.com>

MBR, Sergei


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH]: ata: fix unused variable warning in sil_host_intr()
  2010-05-27 17:48 ` Sergei Shtylyov
@ 2010-05-27 18:02   ` Prarit Bhargava
  0 siblings, 0 replies; 3+ messages in thread
From: Prarit Bhargava @ 2010-05-27 18:02 UTC (permalink / raw)
  To: Sergei Shtylyov; +Cc: linux-ide, jgarzik

> Hello.
>
> Prarit Bhargava wrote:
>
>    s/unused/uninitialized/ in the subject. Unused variable is a 
> different thing.

Oops.  Sorry for the typo.

P.


>
>> Warning seen with 'make -j24 CONFIG_DEBUG_SECTION_MISMATCH=y':
>
>    I don't think any of these matters here...
>
>> drivers/ata/sata_sil.c: In function ‘sil_host_intr’:
>> drivers/ata/sata_sil.c:442: error: ‘serror’ may be used 
>> uninitialized in this function
>
>> Signed-off-by: Prarit Bhargava <prarit@redhat.com>
>
> MBR, Sergei
>

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2010-05-27 18:06 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-05-27 17:35 [PATCH]: ata: fix unused variable warning in sil_host_intr() Prarit Bhargava
2010-05-27 17:48 ` Sergei Shtylyov
2010-05-27 18:02   ` Prarit Bhargava

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).