git: c8db60c0673d - main - Split out the loader efifb setup to a new function

O. Hartmann ohartmann at walstatt.org
Wed Mar 3 15:49:22 UTC 2021


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Am Wed, 3 Mar 2021 14:26:48 GMT
Andrew Turner <andrew at FreeBSD.org> schrieb:

> The branch main has been updated by andrew:
> 
> URL: https://cgit.FreeBSD.org/src/commit/?id=c8db60c0673d4bb7a3a3e2c043804e1ed1108c2f
> 
> commit c8db60c0673d4bb7a3a3e2c043804e1ed1108c2f
> Author:     Andrew Turner <andrew at FreeBSD.org>
> AuthorDate: 2021-02-26 11:47:34 +0000
> Commit:     Andrew Turner <andrew at FreeBSD.org>
> CommitDate: 2021-03-03 14:18:02 +0000
> 
>     Split out the loader efifb setup to a new function
>     
>     This makes bi_load_efi_data cleaner to add common acpi setup code.
>     
>     Reviewed by:    imp, tsoome
>     Sponsored by:   Innovate UK
>     Differential Revision:  https://reviews.freebsd.org/D28936
> ---
>  stand/efi/loader/bootinfo.c | 22 ++++++++++++++++++++++
>  1 file changed, 22 insertions(+)
> 
> diff --git a/stand/efi/loader/bootinfo.c b/stand/efi/loader/bootinfo.c
> index 9924901d29e6..327751e32f0b 100644
> --- a/stand/efi/loader/bootinfo.c
> +++ b/stand/efi/loader/bootinfo.c
> @@ -299,6 +299,9 @@ bi_load_efi_data(struct preloaded_file *kfp, bool exit_bs)
>  	bool do_vmap;
>  
>  #if defined(__amd64__) || defined(__aarch64__)
> +static void
> +bi_load_efifb(struct preloaded_file *kfp)
> +{
>  	struct efi_fb efifb;
>  
>  	efifb.fb_addr = gfx_state.tg_fb.fb_addr;
> @@ -321,6 +324,25 @@ bi_load_efi_data(struct preloaded_file *kfp, bool exit_bs)
>  
>  	if (efifb.fb_addr != 0)
>  		file_addmetadata(kfp, MODINFOMD_EFI_FB, sizeof(efifb), &efifb);
> +}
> +#endif
> +
> +static int
> +bi_load_efi_data(struct preloaded_file *kfp, bool exit_bs)
> +{
> +	EFI_MEMORY_DESCRIPTOR *mm;
> +	EFI_PHYSICAL_ADDRESS addr = 0;
> +	EFI_STATUS status;
> +	const char *efi_novmap;
> +	size_t efisz;
> +	UINTN efi_mapkey;
> +	UINTN dsz, pages, retry, sz;
> +	UINT32 mmver;
> +	struct efi_map_header *efihdr;
> +	bool do_vmap;
> +
> +#if defined(__amd64__) || defined(__aarch64__)
> +	bi_load_efifb(kfp);
>  #endif
>  
>  	do_vmap = true;
> _______________________________________________
> dev-commits-src-main at freebsd.org mailing list
> https://lists.freebsd.org/mailman/listinfo/dev-commits-src-main
> To unsubscribe, send any mail to "dev-commits-src-main-unsubscribe at freebsd.org"

The commit seems to render "make buildworld" failing with the error shown below:

[...]
- --- all_subdir_stand ---
- --- bootinfo.o ---
cc -target x86_64-unknown-freebsd14.0 --sysroot=/usr/obj/usr/src/amd64.amd64/tmp
- -B/usr/obj/usr/src/amd64.amd64/tmp/usr/bin  -O2 -pipe -O3 -fno-common -march=native  -Wformat
- -fshort-wchar -mno-red-zone -nostdinc    -I/usr/obj/usr/src/amd64.amd64/stand/libsa
- -I/usr/src/stand/libsa -D_STANDALONE -I/usr/src/sys -Ddouble=jagged-little-pill
- -Dfloat=floaty-mcfloatface -ffunction-sections -fdata-sections -DLOADER_GELI_SUPPORT
- -I/usr/src/stand/libsa/geli -DLOADER_DISK_SUPPORT -ffreestanding -mno-mmx -mno-sse -mno-avx
- -mno-avx2 -msoft-float -fPIC -mno-red-zone -mno-relax -I. -Iinclude
- -I/usr/src/stand/efi/loader_4th/../loader -I/usr/src/stand/libsa/zfs
- -I/usr/src/sys/contrib/openzfs/include -I/usr/src/sys/contrib/openzfs/include/os/freebsd/zfs
- -DEFI_ZFS_BOOT -fPIC -I/usr/src/stand/efi/loader_4th
- -I/usr/src/stand/efi/loader_4th/arch/amd64 -I/usr/src/stand/efi/include
- -I/usr/src/stand/efi/include/amd64 -I/usr/src/sys/contrib/dev/acpica/include
- -I/usr/src/stand/i386/libi386 -DEFI -DEFI_SECUREBOOT -I/usr/src/stand/common -fPIC
- -I/usr/src/stand/ficl -I/usr/src/stand/ficl/amd64 -I/usr/src/stand/common -DBF_DICTSIZE=30000
- -DLOADER_VERIEXEC -I/usr/src/lib/libsecureboot/h -DLOADER_VERIEXEC
- -I/usr/src/lib/libsecureboot/h -DLOADER_VERIEXEC_VECTX -DLOADER_MSDOS_SUPPORT
- -DLOADER_UFS_SUPPORT -DLOADER_NET_SUPPORT -DLOADER_GPT_SUPPORT -DLOADER_MBR_SUPPORT
- -DLOADER_ZFS_SUPPORT -I/usr/src/stand/libsa/zfs -I/usr/src/sys/cddl/boot/zfs
- -I/usr/src/sys/cddl/contrib/opensolaris/uts/common -DNDEBUG -fPIE -MD  -MF.depend.bootinfo.o
- -MTbootinfo.o -std=gnu99 -Wno-format-zero-length -Wsystem-headers -Wno-pointer-sign
- -Wno-empty-body -Wno-string-plus-int -Wno-unused-const-variable -Wno-tautological-compare
- -Wno-unused-value -Wno-parentheses-equality -Wno-unused-function -Wno-enum-conversion
- -Wno-unused-local-typedef -Wno-address-of-packed-member -Wno-switch -Wno-switch-enum
- -Wno-knr-promoted-parameter -Wno-parentheses  -Oz -Qunused-arguments -I/usr/src/sys/teken
- -I/usr/src/contrib/pnglite   -c /usr/src/stand/efi/loader_4th/../loader/bootinfo.c -o
bootinfo.o --- all_subdir_share --- --- all_subdir_share/i18n/csmapper/BIG5 --- ===>
share/i18n/csmapper/BIG5 (all) --- all_subdir_share/i18n/csmapper/CNS --- ===>
share/i18n/csmapper/CNS (all) --- all_subdir_share/i18n/csmapper/CP --- ===>
share/i18n/csmapper/CP (all) --- all_subdir_stand ---
/usr/src/stand/efi/loader_4th/../loader/bootinfo.c:304:1: error: function definition is not
allowed here --- all_subdir_share --- --- all_subdir_share/examples --- ---
all_subdir_share/examples/ipfilter --- ===> share/examples/ipfilter (all)

make[1]: stopped in /usr/src


- -- 
O. Hartmann

Ich widerspreche der Nutzung oder Übermittlung meiner Daten für
Werbezwecke oder für die Markt- oder Meinungsforschung (§ 28 Abs. 4 BDSG).
-----BEGIN PGP SIGNATURE-----

iHUEARYIAB0WIQSy8IBxAPDkqVBaTJ44N1ZZPba5RwUCYD+v+QAKCRA4N1ZZPba5
RyyYAP0fjxcUTlWs8vcTdLX5FBpYcwVvH3tg7x98i4FyzBLtLgD7Blm0oXXZBJNp
6g96pQeqV/9UECA6kE+rdAu7esRDNAg=
=ey08
-----END PGP SIGNATURE-----


More information about the dev-commits-src-all mailing list