Re: [PATCH RFC] cmd: fix net list command

2021-11-16 Thread Wolfgang Denk
Dear Tom, In message <2026141030.GC24579@bill-the-cat> you wrote: > > One thing I'm not totally sure on yet is, looking at the README I see: > "If Ethernet drivers implement the 'write_hwaddr' function, valid MAC > addresses will be programmed into hardware as part of the initialization >

Re: [PATCH RFC] cmd: fix net list command

2021-11-16 Thread Tom Rini
On Tue, Nov 16, 2021 at 02:33:01PM +0100, Wolfgang Denk wrote: > Dear Ramon, > > In message > you > wrote: > > > > It appears that Michael has some board and a scenario that *this* bug > > was working for his best interest, where he can have two distinct MAC > > addresses, one in U-boot and

Re: [PATCH RFC] cmd: fix net list command

2021-11-16 Thread Wolfgang Denk
Dear Ramon, In message you wrote: > > It appears that Michael has some board and a scenario that *this* bug > was working for his best interest, where he can have two distinct MAC > addresses, one in U-boot and one in Linux. If the Linux environment is supposed to be a specific MAC address

Re: [PATCH RFC] cmd: fix net list command

2021-11-16 Thread Wolfgang Denk
Dear Michal, In message you wrote: > > In perfect world u-boot will just get it and use. And if manufacturer > doesn't do it properly but want to enable ethernet in u-boot random > address could be a solution for them. > And then in Linux where drivers are available you will use the right

Re: [PATCH RFC] cmd: fix net list command

2021-11-16 Thread Wolfgang Denk
Dear Tom, In message <2025154516.GR24579@bill-the-cat> you wrote: > > > One practical use case is board provisioning in the factory, which > > includes setting up valid produt data like serial number, MAC > > address etc. Yes, this can be done over serial consone as well, but > > 1) this is

Re: [PATCH RFC] cmd: fix net list command

2021-11-15 Thread Ramon Fried
On Mon, Nov 15, 2021 at 6:45 PM Marek Vasut wrote: > > On 11/15/21 4:21 PM, Michael Walle wrote: > > Hi, > > > > Am 2021-11-15 16:15, schrieb Wolfgang Denk: > > > >> | And if you don't want to use this feature just don't enable it via > >> | CONFIG_NET_RANDOM_ETHADDR. > >> > >> This say all, no

Re: [PATCH RFC] cmd: fix net list command

2021-11-15 Thread Marek Vasut
On 11/15/21 4:21 PM, Michael Walle wrote: Hi, Am 2021-11-15 16:15, schrieb Wolfgang Denk: | And if you don't want to use this feature just don't enable it via | CONFIG_NET_RANDOM_ETHADDR. This say all, no patches needed. Yes, I'm giving up. I'll just deactivate that option then and open

Re: [PATCH RFC] cmd: fix net list command

2021-11-15 Thread Michal Simek
On 11/15/21 16:20, Wolfgang Denk wrote: Dear Michal, In message <2a51974b-41cf-56e4-c9c9-e6b699f27...@xilinx.com> you wrote: As we discussed in previous thread. I think there shouldn't be a problem when u-boot passes random mac address (in whatever way) but if Linux driver know how to get

Re: [PATCH RFC] cmd: fix net list command

2021-11-15 Thread Tom Rini
On Mon, Nov 15, 2021 at 04:25:55PM +0100, Wolfgang Denk wrote: > Dear Tom, > > In message <2025151956.GN24579@bill-the-cat> you wrote: > > > > Well, what I mean is, where are the real MAC addresses? What is the > > rationale for setting NET_RANDOM_ETHADDR? > > One practical use case is

Re: [PATCH RFC] cmd: fix net list command

2021-11-15 Thread Tom Rini
On Mon, Nov 15, 2021 at 04:22:39PM +0100, Wolfgang Denk wrote: > Dear Tom, > > In message <2025150753.GL24579@bill-the-cat> you wrote: > > > > It might also be the case that in U-Boot some systems that are using > > NET_RANDOM_ETHADDR that really probably shouldn't? A quick grep shows > >

Re: [PATCH RFC] cmd: fix net list command

2021-11-15 Thread Wolfgang Denk
Dear Tom, In message <2025151956.GN24579@bill-the-cat> you wrote: > > Well, what I mean is, where are the real MAC addresses? What is the > rationale for setting NET_RANDOM_ETHADDR? One practical use case is board provisioning in the factory, which includes setting up valid produt data

Re: [PATCH RFC] cmd: fix net list command

2021-11-15 Thread Wolfgang Denk
Dear Tom, In message <2025150753.GL24579@bill-the-cat> you wrote: > > It might also be the case that in U-Boot some systems that are using > NET_RANDOM_ETHADDR that really probably shouldn't? A quick grep shows > 253 platforms enabling it today, which feels high for the number of > boards

Re: [PATCH RFC] cmd: fix net list command

2021-11-15 Thread Michael Walle
Hi, Am 2021-11-15 16:15, schrieb Wolfgang Denk: | And if you don't want to use this feature just don't enable it via | CONFIG_NET_RANDOM_ETHADDR. This say all, no patches needed. Yes, I'm giving up. I'll just deactivate that option then and open code it in my board. -michael

Re: [PATCH RFC] cmd: fix net list command

2021-11-15 Thread Wolfgang Denk
Dear Michal, In message <2a51974b-41cf-56e4-c9c9-e6b699f27...@xilinx.com> you wrote: > > As we discussed in previous thread. I think there shouldn't be a problem > when u-boot passes random mac address (in whatever way) but if Linux > driver know how to get correct one it should be tried

Re: [PATCH RFC] cmd: fix net list command

2021-11-15 Thread Tom Rini
On Mon, Nov 15, 2021 at 04:15:31PM +0100, Michael Walle wrote: > Am 2021-11-15 16:12, schrieb Tom Rini: > > On Mon, Nov 15, 2021 at 03:52:51PM +0100, Michael Walle wrote: > > > Hi, > > > > > > Am 2021-11-15 15:31, schrieb Wolfgang Denk: > > > > In message you wrote: > > > > > > > > > > And again

Re: [PATCH RFC] cmd: fix net list command

2021-11-15 Thread Michael Walle
Am 2021-11-15 16:12, schrieb Tom Rini: On Mon, Nov 15, 2021 at 03:52:51PM +0100, Michael Walle wrote: Hi, Am 2021-11-15 15:31, schrieb Wolfgang Denk: > In message you wrote: > > > > And again you're masking the error and possible fixes by linux itself. > > Seems like this isn't an argument. >

Re: [PATCH RFC] cmd: fix net list command

2021-11-15 Thread Wolfgang Denk
Dear Michael, In message you wrote: > > What is the will of the user in this case? In which case? When the user does not bother to set a specific MAC address and let the system gernerate a random one? Well it is his (maybe concious, maybe not) decision... > It is the will of the > developer

Re: [PATCH RFC] cmd: fix net list command

2021-11-15 Thread Tom Rini
On Mon, Nov 15, 2021 at 03:52:51PM +0100, Michael Walle wrote: > Hi, > > Am 2021-11-15 15:31, schrieb Wolfgang Denk: > > In message you wrote: > > > > > > And again you're masking the error and possible fixes by linux itself. > > > Seems like this isn't an argument. > > > > Respecting the

Re: [PATCH RFC] cmd: fix net list command

2021-11-15 Thread Tom Rini
On Mon, Nov 15, 2021 at 03:57:51PM +0100, Michal Simek wrote: > > > On 11/15/21 15:52, Michael Walle wrote: > > Hi, > > > > Am 2021-11-15 15:31, schrieb Wolfgang Denk: > > > In message you wrote: > > > > > > > > And again you're masking the error and possible fixes by linux itself. > > > >

Re: [PATCH RFC] cmd: fix net list command

2021-11-15 Thread Michal Simek
On 11/15/21 15:52, Michael Walle wrote: Hi, Am 2021-11-15 15:31, schrieb Wolfgang Denk: In message you wrote: And again you're masking the error and possible fixes by linux itself. Seems like this isn't an argument. Respecting the explicit will of the user (i. e using what he

Re: [PATCH RFC] cmd: fix net list command

2021-11-15 Thread Michael Walle
Am 2021-11-15 14:57, schrieb Tom Rini: On Mon, Nov 15, 2021 at 01:24:34PM +0100, Michael Walle wrote: Am 2021-11-15 13:15, schrieb Marek Vasut: > On 11/15/21 1:11 PM, Michael Walle wrote: > > Don't get the MAC address by the environment, but by the platform data > > of the udevice. This will

Re: [PATCH RFC] cmd: fix net list command

2021-11-15 Thread Michal Simek
On 11/15/21 13:11, Michael Walle wrote: Don't get the MAC address by the environment, but by the platform data of the udevice. This will fix "net list" if the MAC address is randomly generated and won't change behavior when linux is booted. Signed-off-by: Michael Walle thanks for looking

Re: [PATCH RFC] cmd: fix net list command

2021-11-15 Thread Michael Walle
Hi, Am 2021-11-15 15:31, schrieb Wolfgang Denk: In message you wrote: And again you're masking the error and possible fixes by linux itself. Seems like this isn't an argument. Respecting the explicit will of the user (i. e using what he configured in U-Boot and passed to the kernel) is not

Re: [PATCH RFC] cmd: fix net list command

2021-11-15 Thread Wolfgang Denk
Dear Michael, In message you wrote: > > And again you're masking the error and possible fixes by linux itself. > Seems like this isn't an argument. Respecting the explicit will of the user (i. e using what he configured in U-Boot and passed to the kernel) is not an error. it is intended and

Re: [PATCH RFC] cmd: fix net list command

2021-11-15 Thread Tom Rini
On Mon, Nov 15, 2021 at 01:24:34PM +0100, Michael Walle wrote: > Am 2021-11-15 13:15, schrieb Marek Vasut: > > On 11/15/21 1:11 PM, Michael Walle wrote: > > > Don't get the MAC address by the environment, but by the platform data > > > of the udevice. This will fix "net list" if the MAC address is

Re: [PATCH RFC] cmd: fix net list command

2021-11-15 Thread Michael Walle
Am 2021-11-15 14:17, schrieb Marek Vasut: On 11/15/21 1:24 PM, Michael Walle wrote: Am 2021-11-15 13:15, schrieb Marek Vasut: On 11/15/21 1:11 PM, Michael Walle wrote: Don't get the MAC address by the environment, but by the platform data of the udevice. This will fix "net list" if the MAC

Re: [PATCH RFC] cmd: fix net list command

2021-11-15 Thread Marek Vasut
On 11/15/21 1:24 PM, Michael Walle wrote: Am 2021-11-15 13:15, schrieb Marek Vasut: On 11/15/21 1:11 PM, Michael Walle wrote: Don't get the MAC address by the environment, but by the platform data of the udevice. This will fix "net list" if the MAC address is randomly generated and won't

Re: [PATCH RFC] cmd: fix net list command

2021-11-15 Thread Michael Walle
Am 2021-11-15 13:15, schrieb Marek Vasut: On 11/15/21 1:11 PM, Michael Walle wrote: Don't get the MAC address by the environment, but by the platform data of the udevice. This will fix "net list" if the MAC address is randomly generated and won't change behavior when linux is booted.

Re: [PATCH RFC] cmd: fix net list command

2021-11-15 Thread Marek Vasut
On 11/15/21 1:11 PM, Michael Walle wrote: Don't get the MAC address by the environment, but by the platform data of the udevice. This will fix "net list" if the MAC address is randomly generated and won't change behavior when linux is booted. Signed-off-by: Michael Walle --- Hi, this is a

[PATCH RFC] cmd: fix net list command

2021-11-15 Thread Michael Walle
Don't get the MAC address by the environment, but by the platform data of the udevice. This will fix "net list" if the MAC address is randomly generated and won't change behavior when linux is booted. Signed-off-by: Michael Walle --- Hi, this is a proposal to fix the "net list" in a way that