Thread (6 messages) 6 messages, 3 authors, 2007-03-29

Re: [PATCH 1/2] mv643xx_eth: Fix use of uninitialized port_num field

From: Jeff Garzik <hidden>
Date: 2007-03-28 06:19:24

Dale Farnsworth wrote:
From: Gabriel Paubert <redacted>

In this driver, the default ethernet address is first set by by calling
eth_port_uc_addr_get() which reads the relevant registers of the
corresponding port as initially set by firmware. However that function
used the port_num field accessed through the private area of net_dev
before it was set.

The result was that one board I have ended up with the unicast address
set to 00:00:00:00:00:00 (only port 1 is connected on this board). The
problem appeared after commit 84dd619e4dc3b0b1c40dafd98c90fd950bce7bc5.

This patch fixes the bug by setting mp->port_num prior to calling
eth_port_uc_get_addr().

Signed-off-by: Gabriel Paubert <redacted>
Signed-off-by: Dale Farnsworth <redacted>
---
applied #1 to upstream-fixes

Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help