net: usb: ax88179_178a: write mac to hardware in get_mac_addr
Subsystems (3)
PATCH 1/1 net: usb: ax88179_178a: write mac to hardware in get_mac_addr
From: Peter Fink <[email protected]>
When the MAC address is supplied via device tree or a random MAC is generated it has to be written to the asix chip in order to receive any data.
In the previous commit (9fb137a) this line was omitted because it seemed to work perfectly fine without it. But it was simply not detected because the chip keeps the mac stored even beyond a reset and it was tested on a hardware with an integrated UPS where the asix chip was permanently powered on even throughout power cycles.
--- drivers/net/usb/ax88179_178a.c | 3 +++ 1 file changed, 3 insertions(+)
drivers/net/usb/ax88179_178a.c +3 -0
@@ -1235,6 +1235,9 @@ static void ax88179_get_mac_addr(struct usbnet *dev)netdev_info (dev->net,"invalid MAC address, using random\n" );eth_hw_addr_random (dev->net); } + +ax88179_write_cmd (dev,AX_ACCESS_MAC ,AX_NODE_ID ,ETH_ALEN ,ETH_ALEN , + dev->net->dev_addr); }static int ax88179_bind (struct usbnet *dev,struct usb_interface *intf)
Signature · 1 line
2.7.4
Hello!
Quoted 7 lines · Peter Fink
From: Peter Fink <[email protected]>
When the MAC address is supplied via device tree or a random MAC is generated it has to be written to the asix chip in order to receive any data.
In the previous commit (9fb137a) this line was omitted
It's not how you should cite the commit, here's how:
<12-digit SHA1> ("<commit-summary>")
Quoted 7 lines
because it seemed to work perfectly fine without it. But it was simply not detected because the chip keeps the mac stored even beyond a reset and it was tested on a hardware with an integrated UPS where the asix chip was permanently powered on even throughout power cycles.
Signed-off-by Peter Fink <[email protected]>
[...]
MBR, Sergei
Hello Sergei,
thanks for the hint. Will correct it and send a v2.
Best regards, Peter
Am 10.10.19 um 12:38 schrieb Sergei Shtylyov:
Quoted 27 lines
Hello!
Quoted 7 lines · Peter Fink
From: Peter Fink <[email protected]>
When the MAC address is supplied via device tree or a random MAC is generated it has to be written to the asix chip in order to receive any data.
In the previous commit (9fb137a) this line was omitted
It's not how you should cite the commit, here's how:
<12-digit SHA1> ("<commit-summary>")
Quoted 7 lines
because it seemed to work perfectly fine without it. But it was simply not detected because the chip keeps the mac stored even beyond a reset and it was tested on a hardware with an integrated UPS where the asix chip was permanently powered on even throughout power cycles.
Signed-off-by Peter Fink <[email protected]>[...]
MBR, Sergei