Re: [PATCH V3 2/2] usb: gadget: u_ether: Don't warn in gether_setup_name_default()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




On 19/01/2023 10:46, Greg Kroah-Hartman wrote:

...

In looking at this further, you are right, the structures are not
initialized properly yet.

So move these to a different function entirely, they should be in
gether_register_netdev() instead, after the device is registered with
the system.


I wonder if this is even necessary. Looking at gether_register_netdev() it already has ...

 status = register_netdev(net);
 if (status < 0) {
         dev_dbg(&g->dev, "register_netdev failed, %d\n", status);
         return status;
 } else {
         INFO(dev, "HOST MAC %pM\n", dev->host_mac);
         INFO(dev, "MAC %pM\n", dev->dev_mac);
         ...
 }


Any objection to just removing completely from gether_setup_name_default()? If we move to gether_register_netdev() then I believe we also have to deal with gether_register_netdev().

Jon

--
nvpublic



[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux