All of lore.kernel.org
 help / color / mirror / Atom feed
From: Art Nikpal <email2tema@gmail.com>
To: u-boot@lists.denx.de
Subject: [PATCH] board: amlogic: vim3: ethernet mac fixed from serial
Date: Mon, 11 Jan 2021 09:42:10 +0800	[thread overview]
Message-ID: <CAKaHn9JzNReCax8=46ZhRtx7gh+xdFuaBkNK7LdGs_X-6N=ibQ@mail.gmail.com> (raw)
In-Reply-To: <CAKaHn9+1O1YFigaX-7EUmF_MBgYsOAknn6jZ=D2Nhjx7fAHa3w@mail.gmail.com>

plz ignore my prev emails

> AFAIK, it's fixed with Marek's patch
>
https://patchwork.ozlabs.org/project/uboot/patch/20201217072642.1319-1-m.szyprowski at samsung.com/

look like yes ! u right

Best regards Art


On Mon, Jan 11, 2021 at 9:27 AM Art Nikpal <email2tema@gmail.com> wrote:

> > AFAIK, it's fixed with Marek's patch
> >
> https://patchwork.ozlabs.org/project/uboot/patch/20201217072642.1319-1-m.szyprowski at samsung.com/
>
> not solve !
> because mac which must stored in mcu is empty by default
> and by default we have random mac every time
>
> i think i will make new complex patch from both patches
>
> On Mon, Jan 11, 2021 at 6:46 AM Jaehoon Chung <jh80.chung@samsung.com>
> wrote:
>
>> Hi,
>>
>> On 1/8/21 2:43 PM, Artem Lapkin wrote:
>> > Fixed randomly generated ethernet mac address!
>> >
>> > Used meson_generate_serial_ethaddr for generate mac address from
>> > board serial number, if ethaddr variable not defined.
>>
>> AFAIK, it's fixed with Marek's patch
>>
>>
>> https://patchwork.ozlabs.org/project/uboot/patch/20201217072642.1319-1-m.szyprowski at samsung.com/
>>
>> Best Regards,
>> Jaehoon CHung
>>
>> >
>> > Signed-off-by: Artem Lapkin <art@khadas.com>
>> > ---
>> >  board/amlogic/vim3/vim3.c | 9 +++++++++
>> >  1 file changed, 9 insertions(+)
>> >
>> > diff --git a/board/amlogic/vim3/vim3.c b/board/amlogic/vim3/vim3.c
>> > index 09ef39ff30..0315eaf569 100644
>> > --- a/board/amlogic/vim3/vim3.c
>> > +++ b/board/amlogic/vim3/vim3.c
>> > @@ -133,5 +133,14 @@ int misc_init_r(void)
>> >  {
>> >       meson_eth_init(PHY_INTERFACE_MODE_RGMII, 0);
>> >
>> > +     u8 mac_addr[6];
>> > +     if (!eth_env_get_enetaddr("ethaddr", mac_addr)) {
>> > +             meson_generate_serial_ethaddr();
>> > +             eth_env_get_enetaddr("ethaddr", mac_addr);
>> > +             printf("[i] serial eth mac
>> %02X:%02X:%02X:%02X:%02X:%02X\n",
>> > +                     mac_addr[0],mac_addr[1],mac_addr[2],
>> > +                     mac_addr[3],mac_addr[4],mac_addr[5]);
>> > +     }
>> > +
>> >       return 0;
>> >  }
>> >
>>
>>

WARNING: multiple messages have this Message-ID (diff)
From: Art Nikpal <email2tema@gmail.com>
To: Jaehoon Chung <jh80.chung@samsung.com>
Cc: Neil Armstrong <narmstrong@baylibre.com>,
	u-boot-amlogic@groups.io, u-boot@lists.denx.de,
	khilman@baylibre.com,
	Christian Hewitt <christianshewitt@gmail.com>,
	Martin Blumenstingl <martin.blumenstingl@googlemail.com>,
	Artem Lapkin <art@khadas.com>,
	nick@khadas.com, Gouwa Wang <gouwa@khadas.com>
Subject: Re: [PATCH] board: amlogic: vim3: ethernet mac fixed from serial
Date: Mon, 11 Jan 2021 09:42:10 +0800	[thread overview]
Message-ID: <CAKaHn9JzNReCax8=46ZhRtx7gh+xdFuaBkNK7LdGs_X-6N=ibQ@mail.gmail.com> (raw)
In-Reply-To: <CAKaHn9+1O1YFigaX-7EUmF_MBgYsOAknn6jZ=D2Nhjx7fAHa3w@mail.gmail.com>

[-- Attachment #1: Type: text/plain, Size: 2054 bytes --]

plz ignore my prev emails

> AFAIK, it's fixed with Marek's patch
>
https://patchwork.ozlabs.org/project/uboot/patch/20201217072642.1319-1-m.szyprowski@samsung.com/

look like yes ! u right

Best regards Art


On Mon, Jan 11, 2021 at 9:27 AM Art Nikpal <email2tema@gmail.com> wrote:

> > AFAIK, it's fixed with Marek's patch
> >
> https://patchwork.ozlabs.org/project/uboot/patch/20201217072642.1319-1-m.szyprowski@samsung.com/
>
> not solve !
> because mac which must stored in mcu is empty by default
> and by default we have random mac every time
>
> i think i will make new complex patch from both patches
>
> On Mon, Jan 11, 2021 at 6:46 AM Jaehoon Chung <jh80.chung@samsung.com>
> wrote:
>
>> Hi,
>>
>> On 1/8/21 2:43 PM, Artem Lapkin wrote:
>> > Fixed randomly generated ethernet mac address!
>> >
>> > Used meson_generate_serial_ethaddr for generate mac address from
>> > board serial number, if ethaddr variable not defined.
>>
>> AFAIK, it's fixed with Marek's patch
>>
>>
>> https://patchwork.ozlabs.org/project/uboot/patch/20201217072642.1319-1-m.szyprowski@samsung.com/
>>
>> Best Regards,
>> Jaehoon CHung
>>
>> >
>> > Signed-off-by: Artem Lapkin <art@khadas.com>
>> > ---
>> >  board/amlogic/vim3/vim3.c | 9 +++++++++
>> >  1 file changed, 9 insertions(+)
>> >
>> > diff --git a/board/amlogic/vim3/vim3.c b/board/amlogic/vim3/vim3.c
>> > index 09ef39ff30..0315eaf569 100644
>> > --- a/board/amlogic/vim3/vim3.c
>> > +++ b/board/amlogic/vim3/vim3.c
>> > @@ -133,5 +133,14 @@ int misc_init_r(void)
>> >  {
>> >       meson_eth_init(PHY_INTERFACE_MODE_RGMII, 0);
>> >
>> > +     u8 mac_addr[6];
>> > +     if (!eth_env_get_enetaddr("ethaddr", mac_addr)) {
>> > +             meson_generate_serial_ethaddr();
>> > +             eth_env_get_enetaddr("ethaddr", mac_addr);
>> > +             printf("[i] serial eth mac
>> %02X:%02X:%02X:%02X:%02X:%02X\n",
>> > +                     mac_addr[0],mac_addr[1],mac_addr[2],
>> > +                     mac_addr[3],mac_addr[4],mac_addr[5]);
>> > +     }
>> > +
>> >       return 0;
>> >  }
>> >
>>
>>

[-- Attachment #2: Type: text/html, Size: 3673 bytes --]

  reply	other threads:[~2021-01-11  1:42 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CGME20210108124343epcas1p46dccb0f4dd6dad4bc177a560f4b1cb26@epcas1p4.samsung.com>
2021-01-08  5:43 ` [PATCH] board: amlogic: vim3: ethernet mac fixed from serial Artem Lapkin
2021-01-08  5:43   ` Artem Lapkin
2021-01-10 22:46   ` Jaehoon Chung
2021-01-10 22:46     ` Jaehoon Chung
2021-01-11  1:27     ` Art Nikpal
2021-01-11  1:27       ` Art Nikpal
2021-01-11  1:42       ` Art Nikpal [this message]
2021-01-11  1:42         ` Art Nikpal

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAKaHn9JzNReCax8=46ZhRtx7gh+xdFuaBkNK7LdGs_X-6N=ibQ@mail.gmail.com' \
    --to=email2tema@gmail.com \
    --cc=u-boot@lists.denx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.