From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from list by lists.gnu.org with archive (Exim 4.90_1) id 1mKKBF-0006s5-Nz for mharc-grub-devel@gnu.org; Sun, 29 Aug 2021 08:44:57 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:53410) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mKKBE-0006rw-5n for grub-devel@gnu.org; Sun, 29 Aug 2021 08:44:56 -0400 Received: from air.basealt.ru ([194.107.17.39]:35210) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mKKB7-00041K-NL for grub-devel@gnu.org; Sun, 29 Aug 2021 08:44:55 -0400 Received: by air.basealt.ru (Postfix, from userid 490) id 8A2E2589892; Sun, 29 Aug 2021 12:44:45 +0000 (UTC) Received: from mail-lj1-f170.google.com (mail-lj1-f170.google.com [209.85.208.170]) by air.basealt.ru (Postfix) with ESMTPSA id 2E29B589898 for ; Sun, 29 Aug 2021 12:44:41 +0000 (UTC) Received: by mail-lj1-f170.google.com with SMTP id w4so20571113ljh.13 for ; Sun, 29 Aug 2021 05:44:41 -0700 (PDT) X-Gm-Message-State: AOAM533e/D+bdni29yTuAXjzUhzvpGD78aQrfVsgci7bSas0mcy0lVHr 3K7FePWHgs65YxFAl5mxcok6fT1OQI6pQtveiBQ= X-Google-Smtp-Source: ABdhPJxnIHSkgPU5CPiE3k86Pz7vaZJ3CHr/FL1631tunIG20fKq5be4b5HgL6plqewJ8NRBSJdEf6TAN2Tzg+Rt+Qc= X-Received: by 2002:a2e:bd09:: with SMTP id n9mr16167680ljq.76.1630241080787; Sun, 29 Aug 2021 05:44:40 -0700 (PDT) MIME-Version: 1.0 References: <20210602211235.377366-1-arei@altlinux.org> In-Reply-To: From: Nikita Ermakov Date: Sun, 29 Aug 2021 15:44:04 +0300 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH v2 0/7] Add LoadFile2 and riscv Linux loader To: Fu Wei Cc: Atish Patra , The development of GNU GRUB , Ard Biesheuvel , Atish Patra , Daniel Kiper , Heinrich Schuchardt , Leif Lindholm Content-Type: multipart/alternative; boundary="00000000000084c5f405cab21454" Received-SPF: pass client-ip=194.107.17.39; envelope-from=arei@altlinux.org; helo=air.basealt.ru X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, HTML_MESSAGE=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: The development of GNU GRUB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 29 Aug 2021 12:44:56 -0000 --00000000000084c5f405cab21454 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Btw, I have a minor suggestion [1] for your patch. AFAIK hartid terminology and /chosen/boot-hartid are RISC-V specifics. So, I think, we should not emit the warning and change DTB with a null boot-hartid value. If get_hartid is not defined then we should, probably, just skip this boot-hartid thing. What do you think? If it is alright I can change your patch with these changes and send V3 or you can change it by yourself. [1] https://github.com/sh1r4s3/grub/commit/af66530842dd3058e1ac0acd8e4ddfd51671= fa6c -- Thanks, Nikita B8 4C 00 CD 21 =D0=BD=D0=B4, 29 =D1=81=D0=B5=D1=80=D0=BF. 2021, 05:30 =D0=BA=D0=BE=D1=80= =D0=B8=D1=81=D1=82=D1=83=D0=B2=D0=B0=D1=87 Fu Wei = =D0=BF=D0=B8=D1=88=D0=B5: > Hi Nikita, > > Nikita Ermakov =E4=BA=8E2021=E5=B9=B48=E6=9C=8828=E6= =97=A5=E5=91=A8=E5=85=AD =E4=B8=8B=E5=8D=888:22=E5=86=99=E9=81=93=EF=BC=9A > > > > Hi Atish, Fu, > > > > On Fri, 27 Aug 2021 at 19:29, Fu Wei wrote: > > > > > > Hi Atish, > > > > > > Great thanks for adding me the loop! > > > > > > I have tested this these whole patchset on Starlight board and > Allwinner D1 , > > > > > > https://github.com/tekkamanninja/grub/tree/riscv_devel_Nikita_V2 > > > > > > I would be nice If you can add my Tested-by for this patchset! > > > > > > Tested-by: Wei Fu > > > > > Fu, thank you for the test and the patch regarding boot-hartid. > > I can send V3 with "Tested-by: Wei Fu " > > appended to the patchset and add the 8'th patch to set boot-hartid. > > Is it ok? > > Sure , NP :-) . > Please add my Tested-by :-) > > > > > > Atish Patra =E4=BA=8E2021=E5=B9=B48=E6=9C=882= 8=E6=97=A5=E5=91=A8=E5=85=AD =E4=B8=8A=E5=8D=8812:22=E5=86=99=E9=81=93=EF= =BC=9A > > > > > > > > On Wed, Jun 2, 2021 at 2:13 PM Nikita Ermakov > wrote: > > > > > > > > > > Hello, > > > > > > > > > > This is the second version of the patch series. The patch series > is almost the > > > > > same as the previous one except that the Heinrich's suggestions > were > > > > > implemented. > > > > > > > > > > This series contains patches to add support for LoadFile2 protoco= l > to load > > > > > initrd on EFI systems. Also it contains patches to load Linux > kernel with EFI > > > > > stub on riscv platforms and unites arm and riscv codes together > into common > > > > > loader code for EFI systems. > > > > > > > > + Wei Fu who tested this series on Beagleboard. > > > > > > > > According to Wei we do another patch to add a boot-hartid entry in > the > > > > chosen node if DTB is > > > > loaded from grub instead of U-Boot [1]. > > > > > > > > [1] > https://github.com/tekkamanninja/grub/commit/99c5dc1ba897e506f185eb19d4da= dc6d41937214 > > > > > > > > > > Ard Biesheuvel (3): > > > > > efi: add definition of LoadFile2 protocol > > > > > efi: implemented LoadFile2 initrd loading protocol for Linux > > > > > linux: ignore FDT unless we need to modify it > > > > > > > > > > Atish Patra (3): > > > > > loader: Move arm64 linux loader to common code > > > > > RISC-V: Update image header > > > > > RISC-V: Use common linux loader > > > > > > > > > > Nikita Ermakov (1): > > > > > loader: drop argv[] argument in grub_initrd_load() > > > > > > > > > > grub-core/Makefile.core.def | 8 +- > > > > > grub-core/commands/efi/lsefi.c | 1 + > > > > > grub-core/loader/arm/linux.c | 2 +- > > > > > grub-core/loader/efi/fdt.c | 7 +- > > > > > grub-core/loader/{arm64 =3D> efi}/linux.c | 143 > +++++++++++++++++++--- > > > > > grub-core/loader/i386/linux.c | 2 +- > > > > > grub-core/loader/i386/pc/linux.c | 2 +- > > > > > grub-core/loader/i386/xen.c | 3 +- > > > > > grub-core/loader/ia64/efi/linux.c | 2 +- > > > > > grub-core/loader/linux.c | 4 +- > > > > > grub-core/loader/mips/linux.c | 2 +- > > > > > grub-core/loader/powerpc/ieee1275/linux.c | 2 +- > > > > > grub-core/loader/riscv/linux.c | 59 --------- > > > > > grub-core/loader/sparc64/ieee1275/linux.c | 2 +- > > > > > include/grub/arm/linux.h | 2 +- > > > > > include/grub/arm64/linux.h | 2 +- > > > > > include/grub/efi/api.h | 15 +++ > > > > > include/grub/linux.h | 2 +- > > > > > include/grub/riscv32/linux.h | 16 +-- > > > > > include/grub/riscv64/linux.h | 16 +-- > > > > > 20 files changed, 185 insertions(+), 107 deletions(-) > > > > > rename grub-core/loader/{arm64 =3D> efi}/linux.c (72%) > > > > > delete mode 100644 grub-core/loader/riscv/linux.c > > > > > > > > > > -- > > > > > 2.29.3 > > > > > > > > > > > > > > > _______________________________________________ > > > > > Grub-devel mailing list > > > > > Grub-devel@gnu.org > > > > > https://lists.gnu.org/mailman/listinfo/grub-devel > > > > > > > > > > > > > > > > -- > > > > Regards, > > > > Atish > > > > -- > > Thanks, > > Nikita > > B8 00 4C CD 21 > --00000000000084c5f405cab21454 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Btw, I have a minor suggestion [1] = for your patch.
AFAIK hartid terminology and /chosen/boot-hartid = are RISC-V specifics. So, I think, we should not emit the warning and chang= e DTB with a null boot-hartid value. If get_hartid is not defined then we s= hould, probably, just skip this boot-hartid thing.

What do you think? If it is alright I can change your patch with these cha= nges and send V3 or you can change it by yourself.

=

--
Thanks,
Nikita
B8 4C 00 CD 21

=D0=BD=D0=B4, 29 =D1= =81=D0=B5=D1=80=D0=BF. 2021, 05:30 =D0=BA=D0=BE=D1=80=D0=B8=D1=81=D1=82=D1= =83=D0=B2=D0=B0=D1=87 Fu Wei <tekkamanninja@gmail.com> =D0=BF=D0=B8=D1=88=D0=B5= :
Hi Nikita,

Nikita Ermakov <arei@altlinux.org> =E4=BA=8E2021=E5=B9=B48=E6=9C= =8828=E6=97=A5=E5=91=A8=E5=85=AD =E4=B8=8B=E5=8D=888:22=E5=86=99=E9=81=93= =EF=BC=9A
>
> Hi Atish, Fu,
>
> On Fri, 27 Aug 2021 at 19:29, Fu Wei <tekkamanninja@gmail.com<= /a>> wrote:
> >
> > Hi Atish,
> >
> > Great thanks for adding me the loop!
> >
> > I have tested this these whole patchset on Starlight board and Al= lwinner D1 ,
> >
> >
https://github.= com/tekkamanninja/grub/tree/riscv_devel_Nikita_V2
> >
> > I would be nice If you can add my Tested-by for this patchset! > >
> > Tested-by: Wei Fu <tekkamanninja@gmail.com>
> >
> Fu, thank you for the test and the patch regarding boot-hartid.
> I can send V3 with "Tested-by: Wei Fu <tekkamanninja@gmai= l.com>"
> appended to the patchset and add the 8'th patch to set boot-hartid= .
> Is it ok?

Sure , NP :-) .
Please add my Tested-by :-)

>
> > Atish Patra <atishp@atishpatra.org> =E4=BA=8E2021=E5= =B9=B48=E6=9C=8828=E6=97=A5=E5=91=A8=E5=85=AD =E4=B8=8A=E5=8D=8812:22=E5=86= =99=E9=81=93=EF=BC=9A
> > >
> > > On Wed, Jun 2, 2021 at 2:13 PM Nikita Ermakov <arei@altlin= ux.org> wrote:
> > > >
> > > > Hello,
> > > >
> > > > This is the second version of the patch series. The pat= ch series is almost the
> > > > same as the previous one except that the Heinrich's= suggestions were
> > > > implemented.
> > > >
> > > > This series contains patches to add support for LoadFil= e2 protocol to load
> > > > initrd on EFI systems. Also it contains patches to load= Linux kernel with EFI
> > > > stub on riscv platforms and unites arm and riscv codes = together into common
> > > > loader code for EFI systems.
> > >
> > > + Wei Fu who tested this series on Beagleboard.
> > >
> > > According to Wei we do another patch to add a boot-hartid en= try in the
> > > chosen node if DTB is
> > > loaded from grub instead of U-Boot [1].
> > >
> > > [1] https://github.com/tekkamanninja/grub/commit/99c5dc1ba897e50= 6f185eb19d4dadc6d41937214
> > > >
> > > > Ard Biesheuvel (3):
> > > >=C2=A0 =C2=A0efi: add definition of LoadFile2 protocol > > > >=C2=A0 =C2=A0efi: implemented LoadFile2 initrd loading p= rotocol for Linux
> > > >=C2=A0 =C2=A0linux: ignore FDT unless we need to modify = it
> > > >
> > > > Atish Patra (3):
> > > >=C2=A0 =C2=A0loader: Move arm64 linux loader to common c= ode
> > > >=C2=A0 =C2=A0RISC-V: Update image header
> > > >=C2=A0 =C2=A0RISC-V: Use common linux loader
> > > >
> > > > Nikita Ermakov (1):
> > > >=C2=A0 =C2=A0loader: drop argv[] argument in grub_initrd= _load()
> > > >
> > > >=C2=A0 grub-core/Makefile.core.def=C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0|=C2=A0 =C2=A08 +-
> > > >=C2=A0 grub-core/commands/efi/lsefi.c=C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A0 =C2=A0 |=C2=A0 =C2=A01 +
> > > >=C2=A0 grub-core/loader/arm/linux.c=C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0 =C2=A0 |=C2=A0 =C2=A02 +-
> > > >=C2=A0 grub-core/loader/efi/fdt.c=C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 |=C2=A0 =C2=A07 +-
> > > >=C2=A0 grub-core/loader/{arm64 =3D> efi}/linux.c=C2= =A0 =C2=A0| 143 +++++++++++++++++++---
> > > >=C2=A0 grub-core/loader/i386/linux.c=C2=A0 =C2=A0 =C2=A0= =C2=A0 =C2=A0 =C2=A0 =C2=A0|=C2=A0 =C2=A02 +-
> > > >=C2=A0 grub-core/loader/i386/pc/linux.c=C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A0 |=C2=A0 =C2=A02 +-
> > > >=C2=A0 grub-core/loader/i386/xen.c=C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0|=C2=A0 =C2=A03 +-
> > > >=C2=A0 grub-core/loader/ia64/efi/linux.c=C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0|=C2=A0 =C2=A02 +-
> > > >=C2=A0 grub-core/loader/linux.c=C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 |=C2=A0 =C2=A04 +-
> > > >=C2=A0 grub-core/loader/mips/linux.c=C2=A0 =C2=A0 =C2=A0= =C2=A0 =C2=A0 =C2=A0 =C2=A0|=C2=A0 =C2=A02 +-
> > > >=C2=A0 grub-core/loader/powerpc/ieee1275/linux.c |=C2=A0= =C2=A02 +-
> > > >=C2=A0 grub-core/loader/riscv/linux.c=C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A0 =C2=A0 |=C2=A0 59 ---------
> > > >=C2=A0 grub-core/loader/sparc64/ieee1275/linux.c |=C2=A0= =C2=A02 +-
> > > >=C2=A0 include/grub/arm/linux.h=C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 |=C2=A0 =C2=A02 +-
> > > >=C2=A0 include/grub/arm64/linux.h=C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 |=C2=A0 =C2=A02 +-
> > > >=C2=A0 include/grub/efi/api.h=C2=A0 =C2=A0 =C2=A0 =C2=A0= =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 |=C2=A0 15 +++
> > > >=C2=A0 include/grub/linux.h=C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 |=C2=A0 =C2=A02 +-
> > > >=C2=A0 include/grub/riscv32/linux.h=C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0 =C2=A0 |=C2=A0 16 +--
> > > >=C2=A0 include/grub/riscv64/linux.h=C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0 =C2=A0 |=C2=A0 16 +--
> > > >=C2=A0 20 files changed, 185 insertions(+), 107 deletion= s(-)
> > > >=C2=A0 rename grub-core/loader/{arm64 =3D> efi}/linux= .c (72%)
> > > >=C2=A0 delete mode 100644 grub-core/loader/riscv/linux.c=
> > > >
> > > > --
> > > > 2.29.3
> > > >
> > > >
> > > > _______________________________________________
> > > > Grub-devel mailing list
> > > > Grub-devel@gnu.org
> > > > https://lists.gnu.or= g/mailman/listinfo/grub-devel
> > >
> > >
> > >
> > > --
> > > Regards,
> > > Atish
>
> --
> Thanks,
> Nikita
> B8 00 4C CD 21
--00000000000084c5f405cab21454--