Commit [933705]  Maximize  Restore  History

um: Proper Fix for f25c80a4: remove duplicate structure field initialization

uml_net_set_mac() was broken and luckily it was never used, before.
What it was trying to do is spin_lock before memcopy the mac address.
Linus attempted to fix it in assumption that someone decided the
lock was needed. But since it was never ever used at all, and was
just dead code, I think we can assume that it is not needed, after

On the other hand patch [f25c80a4] was trying to use eth_mac_addr()
in eth_configure(), *which was the real fallout*. Because of state
checks done inside eth_mac_addr() the address was never set. I have
not reintroduced the memcpy wrapper, but I've put a comment for future

The code now is back to exactly as it was before [f25c80a4]. With
the cleanup applied. If the spin_lock is indeed needed then a contender
should supply a test case that fails, then fix it with the proper
locking, as a separate unrelated patch.

CC: Julia Lawall <>
CC: David S. Miller <>
CC: Andrew Morton <>
CC: Al Viro <>
Tested-by: Boaz Harrosh <>
Signed-off-by: Boaz Harrosh <>
Signed-off-by: David S. Miller <>

Boaz Harrosh Boaz Harrosh 2010-09-29

David S. Miller David S. Miller 2010-09-30

changed arch
changed arch/um
changed arch/um/drivers
changed arch/um/drivers/net_kern.c
arch/um/drivers/net_kern.c Diff Switch to side-by-side view