[gPXE git] mainline commit to stable-1.0.1: [pcnet32] Fix uninitialised variable
git at etherboot.org
git at etherboot.org
Tue Jun 29 03:17:38 EDT 2010
In the Main gPXE repository, branch stable-1.0.1 has been updated.
adds 3804638 [pcnet32] Fix uninitialised variable
from b70afba [release] Update version to 1.0.1-rc1 for release
Summary of changes:
src/drivers/net/pcnet32.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
- Log -----------------------------------------------------------------
------
commit 3804638d35133db3da90b32b5393cee7e26c3edd
Author: Geoff Lywood <glywood at vmware.com>
Date: Tue Jun 29 07:51:51 2010 +0100
Committer: Stefan Hajnoczi <stefanha at gmail.com>
[pcnet32] Fix uninitialised variable
Using gcc 4.1.2, I get the following error when running 'make bin/pcnet32.rom':
[BUILD] bin/pcnet32.o
cc1: warnings being treated as errors
drivers/net/pcnet32.c: In function 'pcnet32_probe':
drivers/net/pcnet32.c:516: warning: 'phycount' may be used uninitialized in this function
make: *** [bin/pcnet32.o] Error 1
This patch fixes the problem.
Signed-off-by: Geoff Lywood <glywood at vmware.com>
Signed-off-by: Stefan Hajnoczi <stefanha at gmail.com>
diff --git a/src/drivers/net/pcnet32.c b/src/drivers/net/pcnet32.c
index 6bb2c1a..f845aa9 100644
--- a/src/drivers/net/pcnet32.c
+++ b/src/drivers/net/pcnet32.c
@@ -513,7 +513,7 @@ static void
pcnet32_setup_probe_phy ( struct pcnet32_private *priv )
{
unsigned long ioaddr = priv->pci_dev->ioaddr;
- char phycount;
+ char phycount = 0;
int phy_id;
int i;
-----------------------------------------------------------------------
--
Main gPXE repository
More information about the gPXE-commits
mailing list