├── include └── grub │ ├── boottime.h │ ├── ia64 │ ├── linux.h │ ├── efi │ │ ├── memory.h │ │ └── time.h │ ├── kernel.h │ └── time.h │ ├── mips │ ├── arc │ │ ├── time.h │ │ └── kernel.h │ ├── linux.h │ ├── qemu_mips │ │ ├── loader.h │ │ ├── serial.h │ │ ├── at_keyboard.h │ │ ├── console.h │ │ ├── time.h │ │ └── kernel.h │ ├── pci.h │ ├── cmos.h │ ├── at_keyboard.h │ ├── asm.h │ ├── kernel.h │ ├── loongson │ │ └── at_keyboard.h │ └── mips.h │ ├── powerpc │ ├── linux.h │ ├── kernel.h │ └── time.h │ ├── sparc64 │ ├── linux.h │ └── time.h │ ├── gfxmenu_model.h │ ├── i386 │ ├── efi │ │ ├── kernel.h │ │ ├── serial.h │ │ ├── memory.h │ │ └── console.h │ ├── xen │ │ ├── kernel.h │ │ └── memory.h │ ├── coreboot │ │ ├── kernel.h │ │ ├── boot.h │ │ ├── time.h │ │ └── serial.h │ ├── ieee1275 │ │ ├── kernel.h │ │ ├── memory.h │ │ ├── serial.h │ │ └── ieee1275.h │ ├── xen_pvh │ │ ├── boot.h │ │ ├── time.h │ │ ├── console.h │ │ ├── int.h │ │ └── memory.h │ ├── qemu │ │ ├── time.h │ │ ├── console.h │ │ ├── memory.h │ │ ├── serial.h │ │ └── boot.h │ ├── multiboot │ │ ├── boot.h │ │ ├── time.h │ │ ├── console.h │ │ ├── kernel.h │ │ ├── memory.h │ │ └── serial.h │ ├── relocator_private.h │ ├── pc │ │ ├── biosnum.h │ │ ├── vesa_modes_table.h │ │ ├── time.h │ │ └── chainloader.h │ ├── reboot.h │ ├── at_keyboard.h │ └── time.h │ ├── x86_64 │ ├── efi │ │ ├── boot.h │ │ ├── kernel.h │ │ ├── serial.h │ │ ├── memory.h │ │ ├── console.h │ │ └── loader.h │ ├── xnu.h │ ├── macho.h │ ├── memory.h │ ├── multiboot.h │ ├── relocator.h │ ├── at_keyboard.h │ ├── io.h │ ├── pci.h │ ├── linux.h │ └── time.h │ ├── gcrypt │ ├── .gitignore │ └── gpg-error.h │ ├── riscv32 │ ├── efi │ │ └── memory.h │ └── time.h │ ├── osdep │ └── hostfile.h │ ├── util │ └── ofpath.h │ ├── arm │ ├── efi │ │ ├── memory.h │ │ └── console.h │ ├── startup.h │ ├── system.h │ ├── cros_ec.h │ └── time.h │ ├── arm64 │ ├── efi │ │ ├── memory.h │ │ └── console.h │ └── time.h │ ├── riscv64 │ ├── efi │ │ └── memory.h │ └── time.h │ ├── linux.h │ ├── module_verifier.h │ ├── ieee1275 │ └── obdisk.h │ ├── loongarch64 │ ├── efi │ │ └── memory.h │ └── time.h │ ├── lib │ ├── crc.h │ └── hexdump.h │ ├── fileid.h │ ├── tparm.h │ ├── udf.h │ ├── emu │ └── console.h │ ├── loopback.h │ └── efi │ └── fdtload.h ├── .gitattributes ├── tests ├── file_filter │ ├── file │ ├── keys │ ├── file.gz │ ├── file.xz │ ├── file.lzop │ ├── keys.pub │ ├── file.gz.sig │ ├── file.xz.sig │ ├── file.lzop.sig │ └── test.cfg ├── syslinux │ └── ubuntu10.04 │ │ └── isolinux │ │ ├── adtxt.cfg │ │ ├── exithelp.cfg │ │ ├── isolinux.cfg │ │ ├── rqtxt.cfg │ │ ├── po4a.cfg │ │ ├── prompt.cfg │ │ ├── gfxboot.cfg │ │ ├── menu.cfg │ │ ├── stdmenu.cfg │ │ └── txt.cfg ├── example_scripted_test.in ├── iso9660_ce_loop.iso.gz ├── iso9660_ce_loop2.iso.gz ├── iso9660_early_ce.iso.gz ├── example_grub_script_test.in ├── grub_script_echo_keywords.in ├── grub_script_leading_whitespace.in ├── dfly-mbr-mbexample.mbr.img.gz ├── dfly-mbr-mbexample.dfly.img.gz ├── grub_script_dollar.in ├── test_unset.in ├── tar_test.in ├── grub_script_blanklines.in ├── romfs_test.in ├── grub_script_escape_comma.in ├── grub_script_eval.in ├── grub_script_final_semicolon.in ├── test_asn1.in ├── squashfs_test.in ├── jfs_test.in ├── f2fs_test.in ├── udf_test.in ├── exfat_test.in ├── nilfs2_test.in ├── grub_script_test.in ├── xfs_test.in ├── hfsplus_test.in ├── grub_script_no_commands.in ├── cpio_test.in ├── syslinux_test.in ├── luks1_test.in ├── luks2_test.in ├── hfs_test.in ├── fat_test.in ├── help_test.in ├── reiserfs_test.in ├── grub_script_for1.in ├── ntfs_test.in ├── btrfs_test.in ├── grub_script_while1.in ├── zfs_test.in ├── minixfs_test.in ├── ext234_test.in ├── grub_func_test.in ├── grub_cmd_sleep.in ├── grub_cmd_date.in ├── grub_script_comments.in ├── grub_cmd_set_date.in ├── grub_script_strcmp.in ├── test_sha512sum.in ├── grub_script_vars1.in ├── grub_cmd_echo.in ├── xzcompress_test.in ├── grub_script_if.in ├── gzcompress_test.in └── lzocompress_test.in ├── grub-core ├── lib │ ├── .gitignore │ ├── libgcrypt │ │ ├── mpi │ │ │ ├── powerpc64 │ │ │ │ └── distfiles │ │ │ ├── pentium4 │ │ │ │ ├── distfiles │ │ │ │ ├── mmx │ │ │ │ │ └── distfiles │ │ │ │ └── sse2 │ │ │ │ │ └── distfiles │ │ │ ├── supersparc │ │ │ │ └── distfiles │ │ │ ├── pa7100 │ │ │ │ └── distfiles │ │ │ ├── m68k │ │ │ │ ├── mc68020 │ │ │ │ │ └── distfiles │ │ │ │ └── distfiles │ │ │ ├── sparc32v8 │ │ │ │ └── distfiles │ │ │ ├── sparc32 │ │ │ │ └── distfiles │ │ │ ├── hppa │ │ │ │ └── distfiles │ │ │ ├── power │ │ │ │ └── distfiles │ │ │ ├── amd64 │ │ │ │ ├── distfiles │ │ │ │ └── mpi-asm-defs.h │ │ │ ├── i586 │ │ │ │ └── distfiles │ │ │ ├── i386 │ │ │ │ └── distfiles │ │ │ ├── powerpc32 │ │ │ │ └── distfiles │ │ │ ├── alpha │ │ │ │ └── distfiles │ │ │ ├── mips3 │ │ │ │ ├── distfiles │ │ │ │ ├── mpi-asm-defs.h │ │ │ │ └── README │ │ │ └── generic │ │ │ │ ├── distfiles │ │ │ │ └── mpi-asm-defs.h │ │ └── src │ │ │ └── versioninfo.rc.in │ ├── posix_wrap │ │ ├── inttypes.h │ │ ├── stdint.h │ │ ├── unistd.h │ │ ├── locale.h │ │ └── localcharset.h │ ├── fake_module.c │ ├── libtasn1 │ │ └── LICENSE │ ├── zstd │ │ └── module.c │ ├── setjmp.S │ ├── emu │ │ └── halt.c │ ├── mips │ │ └── qemu_mips │ │ │ └── reboot.c │ ├── ieee1275 │ │ └── reboot.c │ ├── libtasn1_wrap │ │ ├── wrap.c │ │ └── tests │ │ │ └── CVE-2018-1000654-1_asn1_tab.h │ ├── dummy │ │ ├── halt.c │ │ └── reboot.c │ ├── uboot │ │ └── reboot.c │ └── xen │ │ ├── halt.c │ │ └── reboot.c ├── extra_deps.lst ├── fs │ ├── afs.c │ ├── exfat.c │ ├── minix2.c │ ├── minix3.c │ ├── ufs_be.c │ ├── minix_be.c │ ├── minix2_be.c │ ├── minix3_be.c │ └── ufs2.c ├── boot │ └── mips │ │ └── loongson │ │ └── fuloong2f.S ├── disk │ └── mdraid_linux_be.c ├── tests │ └── boot │ │ ├── ntldr.cfg │ │ ├── multiboot.cfg │ │ ├── kfreebsd-aout.cfg │ │ ├── multiboot2.cfg │ │ ├── pc-chainloader.cfg │ │ ├── kbsd.spec.txt │ │ ├── knetbsd.cfg │ │ ├── kopenbsd.cfg │ │ ├── linux.cfg │ │ ├── linux-ppc.cfg │ │ ├── linux16.cfg │ │ ├── kfreebsd.cfg │ │ ├── kopenbsdlabel.txt │ │ ├── qemu-shutdown-x86.S │ │ └── kernel-8086.S ├── osdep │ ├── cputime.c │ ├── emunet.c │ ├── init.c │ ├── ofpath.c │ ├── exec.c │ ├── dl.c │ ├── platform_unix.c │ ├── sleep.c │ ├── password.c │ ├── emuconsole.c │ ├── compress.c │ ├── config.c │ ├── relpath.c │ ├── blocklist.c │ ├── platform.c │ ├── random.c │ ├── windows │ │ ├── cputime.c │ │ └── sleep.c │ ├── unix │ │ ├── cputime.c │ │ └── sleep.c │ ├── basic │ │ ├── compress.c │ │ ├── platform.c │ │ └── ofpath.c │ ├── getroot.c │ └── hostdisk.c ├── commands │ ├── file32.c │ ├── file64.c │ ├── search_file.c │ ├── search_uuid.c │ └── search_label.c ├── loader │ ├── i386 │ │ ├── bsd32.c │ │ ├── bsd64.c │ │ ├── xen_file32.c │ │ └── xen_file64.c │ ├── macho32.c │ └── macho64.c ├── term │ └── i386 │ │ └── pc │ │ └── mda_text.c ├── .gitignore ├── video │ └── sm712_init.c ├── kern │ ├── emu │ │ ├── cache_s.S │ │ └── cache.c │ └── powerpc │ │ └── cache.S └── efiemu │ ├── prepare32.c │ ├── prepare64.c │ ├── loadcore32.c │ ├── loadcore64.c │ └── i386 │ ├── coredetect.c │ └── nocfgtables.c ├── docs ├── font_char_metrics.txt ├── man │ ├── grub-file.h2m │ ├── grub-mount.h2m │ ├── grub-switch-to-blscfg.h2m │ ├── grub-render-label.h2m │ ├── grub-set-bootflag.h2m │ ├── grub-mkfont.h2m │ ├── grub-pe2elf.h2m │ ├── grub-mkrescue.h2m │ ├── grub-macbless.h2m │ ├── grub-macho2img.h2m │ ├── grub-probe.h2m │ ├── grub-fstest.h2m │ ├── grub-mkconfig.h2m │ ├── grub-mknetdir.h2m │ ├── grub-ofpathname.h2m │ ├── grub-mkrelpath.h2m │ ├── grub-mkstandalone.h2m │ ├── grub-script-check.h2m │ ├── grub-set-password.h2m │ ├── grub-menulst2cfg.h2m │ ├── grub-mkpasswd-pbkdf2.h2m │ ├── grub-editenv.h2m │ ├── grub-syslinux2cfg.h2m │ ├── grub-set-default.h2m │ ├── grub-get-kernel-settings.h2m │ ├── grub-install.h2m │ ├── grub-mkimage.h2m │ ├── grub-reboot.h2m │ ├── grub-bios-setup.h2m │ ├── grub-emu.h2m │ ├── grub-sparc64-setup.h2m │ ├── grub-glue-efi.h2m │ ├── grub-kbdcomp.h2m │ └── grub-mklayout.h2m ├── .gitignore ├── font_char_metrics.png ├── grub-boot-success.service ├── Makefile.am ├── grub-boot-success.timer └── grub-boot-indeterminate.service ├── po ├── grub.d.sed ├── exclude.pot ├── .gitignore ├── swiss.sed ├── quot.sed ├── boldquot.sed ├── Rules-swiss ├── en@piglatin.header ├── Rules-windowsdir ├── remove-potcdate.sin ├── piglatin.sed ├── insert-header.sin ├── gettext-patches │ └── 0004-Use-SHELL-rather-than-bin-sh.patch └── README ├── util ├── bash-completion.d │ ├── .gitignore │ └── Makefile.am ├── setup_bios.c ├── setup_sparc.c ├── systemd │ ├── 10-grub-logind-service.conf.in │ ├── grub-systemd-integration.service.in │ └── systemd-integration.sh.in ├── grub-module-verifier32.c ├── grub-module-verifier64.c ├── grub.d │ ├── 40_custom.in │ ├── 41_custom.in │ ├── 01_users.in │ ├── 14_menu_show_once.in │ ├── README │ ├── 08_fallback_counting.in │ ├── 10_reset_boot_success.in │ ├── 25_bli.in │ └── 12_menu_auto_hide.in ├── import_gcrypth.sed ├── grub-mkimage32.c ├── grub-mkimage64.c └── i386 │ └── efi │ └── grub-dumpdevtree ├── coreboot.cfg ├── themes └── starfield │ ├── blob_w.png │ ├── slider_c.png │ ├── slider_n.png │ ├── slider_s.png │ ├── starfield.png │ ├── boot_menu_c.png │ ├── boot_menu_e.png │ ├── boot_menu_n.png │ ├── boot_menu_s.png │ ├── boot_menu_w.png │ ├── src │ ├── blob_nw.xcf │ ├── slider_c.xcf │ ├── slider_n.xcf │ ├── slider_s.xcf │ ├── bootmenu │ │ ├── center.xcf │ │ ├── corner.xcf │ │ └── side.xcf │ └── terminalbox │ │ ├── side.xcf │ │ ├── center.xcf │ │ └── corner.xcf │ ├── boot_menu_ne.png │ ├── boot_menu_nw.png │ ├── boot_menu_se.png │ ├── boot_menu_sw.png │ ├── terminal_box_c.png │ ├── terminal_box_e.png │ ├── terminal_box_n.png │ ├── terminal_box_s.png │ ├── terminal_box_w.png │ ├── terminal_box_ne.png │ ├── terminal_box_nw.png │ ├── terminal_box_se.png │ └── terminal_box_sw.png ├── asm-tests ├── i386.S ├── sparc64.S ├── powerpc.S ├── mips.S ├── arm.S └── i386-pc.S ├── TODO ├── BUGS ├── linguas.sh ├── AUTHORS └── conf └── i386-cygwin-img-ld.sc /include/grub/boottime.h: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /include/grub/ia64/linux.h: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /include/grub/mips/arc/time.h: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /include/grub/mips/linux.h: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /include/grub/powerpc/linux.h: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /include/grub/sparc64/linux.h: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /include/grub/gfxmenu_model.h: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /include/grub/i386/efi/kernel.h: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /include/grub/i386/xen/kernel.h: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /include/grub/i386/xen/memory.h: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /include/grub/x86_64/efi/boot.h: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /include/grub/x86_64/efi/kernel.h: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /include/grub/i386/coreboot/kernel.h: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /include/grub/i386/ieee1275/kernel.h: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /include/grub/mips/qemu_mips/loader.h: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /.gitattributes: -------------------------------------------------------------------------------- 1 | po/exclude.pot binary 2 | -------------------------------------------------------------------------------- /tests/file_filter/file: -------------------------------------------------------------------------------- 1 | Hello, user! 2 | -------------------------------------------------------------------------------- /grub-core/lib/.gitignore: -------------------------------------------------------------------------------- 1 | /libgcrypt-grub/ 2 | -------------------------------------------------------------------------------- /grub-core/lib/libgcrypt/mpi/powerpc64/distfiles: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/syslinux/ubuntu10.04/isolinux/adtxt.cfg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /docs/font_char_metrics.txt: -------------------------------------------------------------------------------- 1 | Please fill this in. 2 | -------------------------------------------------------------------------------- /grub-core/extra_deps.lst: -------------------------------------------------------------------------------- 1 | depends bli part_gpt 2 | -------------------------------------------------------------------------------- /include/grub/gcrypt/.gitignore: -------------------------------------------------------------------------------- 1 | g10lib.h 2 | gcrypt.h 3 | -------------------------------------------------------------------------------- /include/grub/mips/pci.h: -------------------------------------------------------------------------------- 1 | #include 2 | -------------------------------------------------------------------------------- /include/grub/x86_64/xnu.h: -------------------------------------------------------------------------------- 1 | #include 2 | -------------------------------------------------------------------------------- /po/grub.d.sed: -------------------------------------------------------------------------------- 1 | /^#: util\/grub\.d\//a\ 2 | #, c-format 3 | -------------------------------------------------------------------------------- /util/bash-completion.d/.gitignore: -------------------------------------------------------------------------------- 1 | Makefile 2 | grub 3 | -------------------------------------------------------------------------------- /grub-core/lib/posix_wrap/inttypes.h: -------------------------------------------------------------------------------- 1 | #include 2 | -------------------------------------------------------------------------------- /grub-core/lib/posix_wrap/stdint.h: -------------------------------------------------------------------------------- 1 | #include 2 | -------------------------------------------------------------------------------- /grub-core/lib/posix_wrap/unistd.h: -------------------------------------------------------------------------------- 1 | #include 2 | -------------------------------------------------------------------------------- /include/grub/mips/cmos.h: -------------------------------------------------------------------------------- 1 | #include 2 | -------------------------------------------------------------------------------- /include/grub/x86_64/macho.h: -------------------------------------------------------------------------------- 1 | #include 2 | -------------------------------------------------------------------------------- /include/grub/x86_64/memory.h: -------------------------------------------------------------------------------- 1 | #include 2 | -------------------------------------------------------------------------------- /docs/man/grub-file.h2m: -------------------------------------------------------------------------------- 1 | [NAME] 2 | grub-file \- check file type 3 | -------------------------------------------------------------------------------- /grub-core/fs/afs.c: -------------------------------------------------------------------------------- 1 | #define MODE_AFS 1 2 | #include "bfs.c" 3 | 4 | -------------------------------------------------------------------------------- /grub-core/fs/exfat.c: -------------------------------------------------------------------------------- 1 | #define MODE_EXFAT 1 2 | #include "fat.c" 3 | -------------------------------------------------------------------------------- /grub-core/lib/libgcrypt/mpi/pentium4/distfiles: -------------------------------------------------------------------------------- 1 | README 2 | 3 | 4 | -------------------------------------------------------------------------------- /include/grub/i386/coreboot/boot.h: -------------------------------------------------------------------------------- 1 | #include 2 | -------------------------------------------------------------------------------- /include/grub/i386/coreboot/time.h: -------------------------------------------------------------------------------- 1 | #include 2 | -------------------------------------------------------------------------------- /include/grub/i386/xen_pvh/boot.h: -------------------------------------------------------------------------------- 1 | #include 2 | -------------------------------------------------------------------------------- /include/grub/i386/xen_pvh/time.h: -------------------------------------------------------------------------------- 1 | #include 2 | -------------------------------------------------------------------------------- /include/grub/mips/arc/kernel.h: -------------------------------------------------------------------------------- 1 | #include 2 | 3 | -------------------------------------------------------------------------------- /include/grub/x86_64/multiboot.h: -------------------------------------------------------------------------------- 1 | #include 2 | -------------------------------------------------------------------------------- /include/grub/x86_64/relocator.h: -------------------------------------------------------------------------------- 1 | #include 2 | -------------------------------------------------------------------------------- /grub-core/fs/minix2.c: -------------------------------------------------------------------------------- 1 | #define MODE_MINIX2 1 2 | #include "minix.c" 3 | -------------------------------------------------------------------------------- /grub-core/fs/minix3.c: -------------------------------------------------------------------------------- 1 | #define MODE_MINIX3 1 2 | #include "minix.c" 3 | -------------------------------------------------------------------------------- /grub-core/fs/ufs_be.c: -------------------------------------------------------------------------------- 1 | #define MODE_BIGENDIAN 1 2 | #include "ufs.c" 3 | -------------------------------------------------------------------------------- /include/grub/i386/efi/serial.h: -------------------------------------------------------------------------------- 1 | #include 2 | -------------------------------------------------------------------------------- /include/grub/i386/qemu/time.h: -------------------------------------------------------------------------------- 1 | #include 2 | -------------------------------------------------------------------------------- /include/grub/i386/xen_pvh/console.h: -------------------------------------------------------------------------------- 1 | #include 2 | -------------------------------------------------------------------------------- /include/grub/i386/xen_pvh/int.h: -------------------------------------------------------------------------------- 1 | #include 2 | -------------------------------------------------------------------------------- /include/grub/mips/at_keyboard.h: -------------------------------------------------------------------------------- 1 | #include 2 | -------------------------------------------------------------------------------- /include/grub/x86_64/at_keyboard.h: -------------------------------------------------------------------------------- 1 | #include 2 | -------------------------------------------------------------------------------- /util/setup_bios.c: -------------------------------------------------------------------------------- 1 | #define GRUB_SETUP_BIOS 1 2 | #include "setup.c" 3 | -------------------------------------------------------------------------------- /grub-core/fs/minix_be.c: -------------------------------------------------------------------------------- 1 | #define MODE_BIGENDIAN 1 2 | #include "minix.c" 3 | -------------------------------------------------------------------------------- /grub-core/lib/libgcrypt/mpi/supersparc/distfiles: -------------------------------------------------------------------------------- 1 | Manifest 2 | udiv.S 3 | 4 | -------------------------------------------------------------------------------- /include/grub/i386/ieee1275/memory.h: -------------------------------------------------------------------------------- 1 | #include 2 | -------------------------------------------------------------------------------- /include/grub/i386/ieee1275/serial.h: -------------------------------------------------------------------------------- 1 | #include 2 | -------------------------------------------------------------------------------- /include/grub/i386/multiboot/boot.h: -------------------------------------------------------------------------------- 1 | #include 2 | -------------------------------------------------------------------------------- /include/grub/i386/multiboot/time.h: -------------------------------------------------------------------------------- 1 | #include 2 | -------------------------------------------------------------------------------- /include/grub/i386/qemu/console.h: -------------------------------------------------------------------------------- 1 | #include 2 | -------------------------------------------------------------------------------- /include/grub/i386/qemu/memory.h: -------------------------------------------------------------------------------- 1 | #include 2 | -------------------------------------------------------------------------------- /include/grub/i386/qemu/serial.h: -------------------------------------------------------------------------------- 1 | #include 2 | -------------------------------------------------------------------------------- /include/grub/i386/xen_pvh/memory.h: -------------------------------------------------------------------------------- 1 | #include 2 | -------------------------------------------------------------------------------- /include/grub/x86_64/efi/serial.h: -------------------------------------------------------------------------------- 1 | #include 2 | -------------------------------------------------------------------------------- /po/exclude.pot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/po/exclude.pot -------------------------------------------------------------------------------- /tests/example_scripted_test.in: -------------------------------------------------------------------------------- 1 | #!@BUILD_SHEBANG@ 2 | set -e 3 | 4 | true 5 | -------------------------------------------------------------------------------- /util/setup_sparc.c: -------------------------------------------------------------------------------- 1 | #define GRUB_SETUP_SPARC64 1 2 | #include "setup.c" 3 | -------------------------------------------------------------------------------- /include/grub/i386/multiboot/console.h: -------------------------------------------------------------------------------- 1 | #include 2 | -------------------------------------------------------------------------------- /include/grub/i386/multiboot/kernel.h: -------------------------------------------------------------------------------- 1 | #include 2 | -------------------------------------------------------------------------------- /include/grub/i386/multiboot/memory.h: -------------------------------------------------------------------------------- 1 | #include 2 | -------------------------------------------------------------------------------- /include/grub/i386/multiboot/serial.h: -------------------------------------------------------------------------------- 1 | #include 2 | -------------------------------------------------------------------------------- /include/grub/i386/relocator_private.h: -------------------------------------------------------------------------------- 1 | #define GRUB_RELOCATOR16_STACK_SIZE 4096 2 | -------------------------------------------------------------------------------- /docs/.gitignore: -------------------------------------------------------------------------------- 1 | /*.in 2 | /Makefile 3 | /stamp-1 4 | /stamp-vti 5 | /version*.texi 6 | -------------------------------------------------------------------------------- /docs/man/grub-mount.h2m: -------------------------------------------------------------------------------- 1 | [NAME] 2 | grub-mount \- export GRUB filesystem with FUSE 3 | -------------------------------------------------------------------------------- /grub-core/lib/libgcrypt/mpi/pentium4/mmx/distfiles: -------------------------------------------------------------------------------- 1 | mpih-lshift.S 2 | mpih-rshift.S 3 | -------------------------------------------------------------------------------- /include/grub/i386/ieee1275/ieee1275.h: -------------------------------------------------------------------------------- 1 | #include 2 | -------------------------------------------------------------------------------- /grub-core/boot/mips/loongson/fuloong2f.S: -------------------------------------------------------------------------------- 1 | #define FULOONG2F 1 2 | #include "fwstart.S" 3 | -------------------------------------------------------------------------------- /grub-core/disk/mdraid_linux_be.c: -------------------------------------------------------------------------------- 1 | #define MODE_BIGENDIAN 1 2 | #include "mdraid_linux.c" 3 | -------------------------------------------------------------------------------- /grub-core/tests/boot/ntldr.cfg: -------------------------------------------------------------------------------- 1 | ntldr /ntldr.bin 2 | boot 3 | # Shouln't happen 4 | halt 5 | -------------------------------------------------------------------------------- /tests/file_filter/keys: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/tests/file_filter/keys -------------------------------------------------------------------------------- /grub-core/lib/libgcrypt/mpi/pa7100/distfiles: -------------------------------------------------------------------------------- 1 | Manifest 2 | mpih-lshift.S 3 | mpih-rshift.S 4 | 5 | -------------------------------------------------------------------------------- /grub-core/lib/posix_wrap/locale.h: -------------------------------------------------------------------------------- 1 | #ifdef GRUB_UTIL 2 | #include_next 3 | #endif 4 | -------------------------------------------------------------------------------- /po/.gitignore: -------------------------------------------------------------------------------- 1 | /Makefile 2 | /POTFILES*.in 3 | /grub.pot 4 | /remove-potcdate.sed 5 | /stamp-po 6 | -------------------------------------------------------------------------------- /tests/file_filter/file.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/tests/file_filter/file.gz -------------------------------------------------------------------------------- /tests/file_filter/file.xz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/tests/file_filter/file.xz -------------------------------------------------------------------------------- /coreboot.cfg: -------------------------------------------------------------------------------- 1 | if test -f (cbfsdisk)/etc/grub.cfg; then 2 | source (cbfsdisk)/etc/grub.cfg 3 | fi 4 | -------------------------------------------------------------------------------- /docs/font_char_metrics.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/docs/font_char_metrics.png -------------------------------------------------------------------------------- /grub-core/fs/minix2_be.c: -------------------------------------------------------------------------------- 1 | #define MODE_MINIX2 1 2 | #define MODE_BIGENDIAN 1 3 | #include "minix.c" 4 | -------------------------------------------------------------------------------- /grub-core/fs/minix3_be.c: -------------------------------------------------------------------------------- 1 | #define MODE_MINIX3 1 2 | #define MODE_BIGENDIAN 1 3 | #include "minix.c" 4 | -------------------------------------------------------------------------------- /grub-core/fs/ufs2.c: -------------------------------------------------------------------------------- 1 | /* ufs2.c - Unix File System 2 */ 2 | #define MODE_UFS2 1 3 | #include "ufs.c" 4 | -------------------------------------------------------------------------------- /grub-core/tests/boot/multiboot.cfg: -------------------------------------------------------------------------------- 1 | multiboot /multiboot.elf 2 | boot 3 | # Shouln't happen 4 | halt 5 | -------------------------------------------------------------------------------- /tests/file_filter/file.lzop: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/tests/file_filter/file.lzop -------------------------------------------------------------------------------- /tests/file_filter/keys.pub: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/tests/file_filter/keys.pub -------------------------------------------------------------------------------- /themes/starfield/blob_w.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/themes/starfield/blob_w.png -------------------------------------------------------------------------------- /asm-tests/i386.S: -------------------------------------------------------------------------------- 1 | /* on x86 old clang doesn't support .code16 */ 2 | 3 | .code16 4 | movb %al, %bl 5 | -------------------------------------------------------------------------------- /docs/man/grub-switch-to-blscfg.h2m: -------------------------------------------------------------------------------- 1 | [NAME] 2 | grub-switch-to-blscfg \- switch to using BLS config files 3 | -------------------------------------------------------------------------------- /grub-core/tests/boot/kfreebsd-aout.cfg: -------------------------------------------------------------------------------- 1 | kfreebsd /kfreebsd.aout 2 | boot 3 | # Shouln't happen 4 | halt 5 | -------------------------------------------------------------------------------- /grub-core/tests/boot/multiboot2.cfg: -------------------------------------------------------------------------------- 1 | multiboot2 /multiboot2.elf 2 | boot 3 | # Shouln't happen 4 | halt 5 | -------------------------------------------------------------------------------- /tests/file_filter/file.gz.sig: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/tests/file_filter/file.gz.sig -------------------------------------------------------------------------------- /tests/file_filter/file.xz.sig: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/tests/file_filter/file.xz.sig -------------------------------------------------------------------------------- /tests/iso9660_ce_loop.iso.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/tests/iso9660_ce_loop.iso.gz -------------------------------------------------------------------------------- /tests/iso9660_ce_loop2.iso.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/tests/iso9660_ce_loop2.iso.gz -------------------------------------------------------------------------------- /tests/iso9660_early_ce.iso.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/tests/iso9660_early_ce.iso.gz -------------------------------------------------------------------------------- /themes/starfield/slider_c.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/themes/starfield/slider_c.png -------------------------------------------------------------------------------- /themes/starfield/slider_n.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/themes/starfield/slider_n.png -------------------------------------------------------------------------------- /themes/starfield/slider_s.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/themes/starfield/slider_s.png -------------------------------------------------------------------------------- /themes/starfield/starfield.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/themes/starfield/starfield.png -------------------------------------------------------------------------------- /docs/man/grub-render-label.h2m: -------------------------------------------------------------------------------- 1 | [NAME] 2 | grub-render-label \- generate a .disk_label for Apple Macs. 3 | 4 | -------------------------------------------------------------------------------- /docs/man/grub-set-bootflag.h2m: -------------------------------------------------------------------------------- 1 | [NAME] 2 | grub-set-bootflag \- set a bootflag in the GRUB environment block 3 | -------------------------------------------------------------------------------- /grub-core/lib/libgcrypt/mpi/m68k/mc68020/distfiles: -------------------------------------------------------------------------------- 1 | Manifest 2 | mpih-mul1.S 3 | mpih-mul2.S 4 | mpih-mul3.S 5 | -------------------------------------------------------------------------------- /grub-core/lib/libgcrypt/mpi/sparc32v8/distfiles: -------------------------------------------------------------------------------- 1 | Manifest 2 | mpih-mul1.S 3 | mpih-mul2.S 4 | mpih-mul3.S 5 | 6 | -------------------------------------------------------------------------------- /tests/example_grub_script_test.in: -------------------------------------------------------------------------------- 1 | #! @builddir@/grub-shell-tester --modules=echo 2 | 3 | echo "hello world" 4 | -------------------------------------------------------------------------------- /tests/file_filter/file.lzop.sig: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/tests/file_filter/file.lzop.sig -------------------------------------------------------------------------------- /tests/grub_script_echo_keywords.in: -------------------------------------------------------------------------------- 1 | #! @builddir@/grub-shell-tester 2 | 3 | echo if then else fi for do done 4 | -------------------------------------------------------------------------------- /tests/grub_script_leading_whitespace.in: -------------------------------------------------------------------------------- 1 | #! @builddir@/grub-shell-tester 2 | 3 | list=" 1 2 3" 4 | echo $list 5 | -------------------------------------------------------------------------------- /tests/syslinux/ubuntu10.04/isolinux/exithelp.cfg: -------------------------------------------------------------------------------- 1 | label menu 2 | kernel vesamenu.c32 3 | config isolinux.cfg 4 | -------------------------------------------------------------------------------- /themes/starfield/boot_menu_c.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/themes/starfield/boot_menu_c.png -------------------------------------------------------------------------------- /themes/starfield/boot_menu_e.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/themes/starfield/boot_menu_e.png -------------------------------------------------------------------------------- /themes/starfield/boot_menu_n.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/themes/starfield/boot_menu_n.png -------------------------------------------------------------------------------- /themes/starfield/boot_menu_s.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/themes/starfield/boot_menu_s.png -------------------------------------------------------------------------------- /themes/starfield/boot_menu_w.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/themes/starfield/boot_menu_w.png -------------------------------------------------------------------------------- /themes/starfield/src/blob_nw.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/themes/starfield/src/blob_nw.xcf -------------------------------------------------------------------------------- /util/systemd/10-grub-logind-service.conf.in: -------------------------------------------------------------------------------- 1 | [Service] 2 | Environment=SYSTEMD_REBOOT_TO_BOOT_LOADER_MENU=true 3 | -------------------------------------------------------------------------------- /docs/man/grub-mkfont.h2m: -------------------------------------------------------------------------------- 1 | [NAME] 2 | grub-mkfont \- make GRUB font files 3 | [SEE ALSO] 4 | .BR grub-mkconfig (8) 5 | -------------------------------------------------------------------------------- /docs/man/grub-pe2elf.h2m: -------------------------------------------------------------------------------- 1 | [NAME] 2 | grub-pe2elf \- convert PE image to ELF 3 | [SEE ALSO] 4 | .BR grub-mkimage (1) 5 | -------------------------------------------------------------------------------- /grub-core/tests/boot/pc-chainloader.cfg: -------------------------------------------------------------------------------- 1 | chainloader /pc-chainloader.bin 2 | boot 3 | # Shouln't happen 4 | halt 5 | -------------------------------------------------------------------------------- /tests/dfly-mbr-mbexample.mbr.img.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/tests/dfly-mbr-mbexample.mbr.img.gz -------------------------------------------------------------------------------- /themes/starfield/boot_menu_ne.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/themes/starfield/boot_menu_ne.png -------------------------------------------------------------------------------- /themes/starfield/boot_menu_nw.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/themes/starfield/boot_menu_nw.png -------------------------------------------------------------------------------- /themes/starfield/boot_menu_se.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/themes/starfield/boot_menu_se.png -------------------------------------------------------------------------------- /themes/starfield/boot_menu_sw.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/themes/starfield/boot_menu_sw.png -------------------------------------------------------------------------------- /themes/starfield/src/slider_c.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/themes/starfield/src/slider_c.xcf -------------------------------------------------------------------------------- /themes/starfield/src/slider_n.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/themes/starfield/src/slider_n.xcf -------------------------------------------------------------------------------- /themes/starfield/src/slider_s.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/themes/starfield/src/slider_s.xcf -------------------------------------------------------------------------------- /themes/starfield/terminal_box_c.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/themes/starfield/terminal_box_c.png -------------------------------------------------------------------------------- /themes/starfield/terminal_box_e.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/themes/starfield/terminal_box_e.png -------------------------------------------------------------------------------- /themes/starfield/terminal_box_n.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/themes/starfield/terminal_box_n.png -------------------------------------------------------------------------------- /themes/starfield/terminal_box_s.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/themes/starfield/terminal_box_s.png -------------------------------------------------------------------------------- /themes/starfield/terminal_box_w.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/themes/starfield/terminal_box_w.png -------------------------------------------------------------------------------- /docs/man/grub-mkrescue.h2m: -------------------------------------------------------------------------------- 1 | [NAME] 2 | grub-mkrescue \- make a GRUB rescue image 3 | [SEE ALSO] 4 | .BR grub-mkimage (1) 5 | -------------------------------------------------------------------------------- /grub-core/tests/boot/kbsd.spec.txt: -------------------------------------------------------------------------------- 1 | . type=dir 2 | dev type=dir 3 | console type=char device=0 mode=666 gid=0 uid=0 4 | -------------------------------------------------------------------------------- /tests/dfly-mbr-mbexample.dfly.img.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/tests/dfly-mbr-mbexample.dfly.img.gz -------------------------------------------------------------------------------- /themes/starfield/terminal_box_ne.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/themes/starfield/terminal_box_ne.png -------------------------------------------------------------------------------- /themes/starfield/terminal_box_nw.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/themes/starfield/terminal_box_nw.png -------------------------------------------------------------------------------- /themes/starfield/terminal_box_se.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/themes/starfield/terminal_box_se.png -------------------------------------------------------------------------------- /themes/starfield/terminal_box_sw.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/themes/starfield/terminal_box_sw.png -------------------------------------------------------------------------------- /docs/man/grub-macbless.h2m: -------------------------------------------------------------------------------- 1 | [NAME] 2 | grub-macbless \- bless a mac file/directory 3 | [SEE ALSO] 4 | .BR grub-install (1) 5 | -------------------------------------------------------------------------------- /docs/man/grub-macho2img.h2m: -------------------------------------------------------------------------------- 1 | [NAME] 2 | grub-macho2img \- convert Mach-O to raw image 3 | [SEE ALSO] 4 | .BR grub-mkimage (1) 5 | -------------------------------------------------------------------------------- /docs/man/grub-probe.h2m: -------------------------------------------------------------------------------- 1 | [NAME] 2 | grub-probe \- probe device information for GRUB 3 | [SEE ALSO] 4 | .BR grub-fstest (1) 5 | -------------------------------------------------------------------------------- /grub-core/lib/libgcrypt/mpi/sparc32/distfiles: -------------------------------------------------------------------------------- 1 | Manifest 2 | mpih-lshift.S 3 | mpih-rshift.S 4 | mpih-add1.S 5 | udiv.S 6 | 7 | -------------------------------------------------------------------------------- /themes/starfield/src/bootmenu/center.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/themes/starfield/src/bootmenu/center.xcf -------------------------------------------------------------------------------- /themes/starfield/src/bootmenu/corner.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/themes/starfield/src/bootmenu/corner.xcf -------------------------------------------------------------------------------- /themes/starfield/src/bootmenu/side.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/themes/starfield/src/bootmenu/side.xcf -------------------------------------------------------------------------------- /docs/man/grub-fstest.h2m: -------------------------------------------------------------------------------- 1 | [NAME] 2 | grub-fstest \- debug tool for GRUB filesystem drivers 3 | [SEE ALSO] 4 | .BR grub-probe (8) 5 | -------------------------------------------------------------------------------- /docs/man/grub-mkconfig.h2m: -------------------------------------------------------------------------------- 1 | [NAME] 2 | grub-mkconfig \- generate a GRUB configuration file 3 | [SEE ALSO] 4 | .BR grub-install (8) 5 | -------------------------------------------------------------------------------- /docs/man/grub-mknetdir.h2m: -------------------------------------------------------------------------------- 1 | [NAME] 2 | grub-mknetdir \- prepare a GRUB netboot directory. 3 | [SEE ALSO] 4 | .BR grub-mkimage (1) 5 | -------------------------------------------------------------------------------- /docs/man/grub-ofpathname.h2m: -------------------------------------------------------------------------------- 1 | [NAME] 2 | grub-ofpathname \- find OpenBOOT path for a device 3 | [SEE ALSO] 4 | .BR grub-probe (8) 5 | -------------------------------------------------------------------------------- /grub-core/lib/libgcrypt/mpi/pentium4/sse2/distfiles: -------------------------------------------------------------------------------- 1 | mpih-add1.S 2 | mpih-mul1.S 3 | mpih-mul2.S 4 | mpih-mul3.S 5 | mpih-sub1.S 6 | -------------------------------------------------------------------------------- /grub-core/osdep/cputime.c: -------------------------------------------------------------------------------- 1 | #ifdef __MINGW32__ 2 | #include "windows/cputime.c" 3 | #else 4 | #include "unix/cputime.c" 5 | #endif 6 | -------------------------------------------------------------------------------- /grub-core/osdep/emunet.c: -------------------------------------------------------------------------------- 1 | #if defined (__linux__) 2 | #include "linux/emunet.c" 3 | #else 4 | #include "basic/emunet.c" 5 | #endif 6 | -------------------------------------------------------------------------------- /grub-core/osdep/init.c: -------------------------------------------------------------------------------- 1 | #if defined (__MINGW32__) 2 | #include "windows/init.c" 3 | #else 4 | #include "basic/init.c" 5 | #endif 6 | -------------------------------------------------------------------------------- /grub-core/osdep/ofpath.c: -------------------------------------------------------------------------------- 1 | #if defined (__linux__) 2 | #include "linux/ofpath.c" 3 | #else 4 | #include "basic/ofpath.c" 5 | #endif 6 | -------------------------------------------------------------------------------- /grub-core/tests/boot/knetbsd.cfg: -------------------------------------------------------------------------------- 1 | knetbsd /knetbsd -h 2 | knetbsd_module_elf /miniroot.gz 3 | boot 4 | # Shouln't happen 5 | halt 6 | -------------------------------------------------------------------------------- /grub-core/tests/boot/kopenbsd.cfg: -------------------------------------------------------------------------------- 1 | kopenbsd /kopenbsd -h 2 | kopenbsd_ramdisk /ramdisk 3 | boot 4 | # Shouln't happen 5 | halt 6 | -------------------------------------------------------------------------------- /tests/grub_script_dollar.in: -------------------------------------------------------------------------------- 1 | #! @BUILD_SHEBANG@ 2 | set -e 3 | 4 | @builddir@/grub-script-check << EOF 5 | echo "\\\$" 6 | EOF 7 | -------------------------------------------------------------------------------- /themes/starfield/src/terminalbox/side.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/themes/starfield/src/terminalbox/side.xcf -------------------------------------------------------------------------------- /docs/man/grub-mkrelpath.h2m: -------------------------------------------------------------------------------- 1 | [NAME] 2 | grub-mkrelpath \- make a system path relative to its root 3 | [SEE ALSO] 4 | .BR grub-probe (8) 5 | -------------------------------------------------------------------------------- /docs/man/grub-mkstandalone.h2m: -------------------------------------------------------------------------------- 1 | [NAME] 2 | grub-mkstandalone \- make a memdisk-based GRUB image 3 | [SEE ALSO] 4 | .BR grub-mkimage (1) 5 | -------------------------------------------------------------------------------- /grub-core/lib/libgcrypt/src/versioninfo.rc.in: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/grub-core/lib/libgcrypt/src/versioninfo.rc.in -------------------------------------------------------------------------------- /grub-core/tests/boot/linux.cfg: -------------------------------------------------------------------------------- 1 | linux /linux console=ttyS0 root=/dev/ram0 2 | initrd /initrd 3 | boot 4 | # Shouln't happen 5 | halt 6 | -------------------------------------------------------------------------------- /themes/starfield/src/terminalbox/center.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/themes/starfield/src/terminalbox/center.xcf -------------------------------------------------------------------------------- /themes/starfield/src/terminalbox/corner.xcf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rhboot/grub2/HEAD/themes/starfield/src/terminalbox/corner.xcf -------------------------------------------------------------------------------- /docs/man/grub-script-check.h2m: -------------------------------------------------------------------------------- 1 | [NAME] 2 | grub-script-check \- check grub.cfg for syntax errors 3 | [SEE ALSO] 4 | .BR grub-mkconfig (8) 5 | -------------------------------------------------------------------------------- /docs/man/grub-set-password.h2m: -------------------------------------------------------------------------------- 1 | [NAME] 2 | grub-set-password \- generate the user.cfg file containing the hashed grub bootloader password 3 | -------------------------------------------------------------------------------- /grub-core/lib/libgcrypt/mpi/hppa/distfiles: -------------------------------------------------------------------------------- 1 | README 2 | udiv-qrnnd.S 3 | mpih-add1.S 4 | mpih-sub1.S 5 | mpih-lshift.S 6 | mpih-rshift.S 7 | 8 | -------------------------------------------------------------------------------- /grub-core/osdep/exec.c: -------------------------------------------------------------------------------- 1 | #if (!defined (__MINGW32__) || defined (__CYGWIN__)) && !defined (__AROS__) 2 | #include "unix/exec.c" 3 | #endif 4 | -------------------------------------------------------------------------------- /grub-core/tests/boot/linux-ppc.cfg: -------------------------------------------------------------------------------- 1 | linux /linux console=ttyPZ1 root=/dev/ram0 2 | initrd /initrd 3 | boot 4 | # Shouln't happen 5 | halt 6 | -------------------------------------------------------------------------------- /grub-core/tests/boot/linux16.cfg: -------------------------------------------------------------------------------- 1 | linux16 /linux console=ttyS0 root=/dev/ram0 2 | initrd16 /initrd 3 | boot 4 | # Shouln't happen 5 | halt 6 | -------------------------------------------------------------------------------- /po/swiss.sed: -------------------------------------------------------------------------------- 1 | s,ß,ss,g 2 | y,»«,«», 3 | s,\bRechner\b,Computer,g 4 | s,\bStrg\b,Ctrl,g 5 | s,\bEinfg\b,Insert,g 6 | s,\bEntf\b,Del,g 7 | 8 | -------------------------------------------------------------------------------- /docs/man/grub-menulst2cfg.h2m: -------------------------------------------------------------------------------- 1 | [NAME] 2 | grub-menulst2cfg \- transform legacy menu.lst into grub.cfg 3 | [SEE ALSO] 4 | .BR grub-mkconfig (8) 5 | -------------------------------------------------------------------------------- /docs/man/grub-mkpasswd-pbkdf2.h2m: -------------------------------------------------------------------------------- 1 | [NAME] 2 | grub-mkpasswd-pbkdf2 \- generate hashed password for GRUB 3 | [SEE ALSO] 4 | .BR grub-mkconfig (8) 5 | -------------------------------------------------------------------------------- /grub-core/osdep/dl.c: -------------------------------------------------------------------------------- 1 | #if defined (__MINGW32__) || defined (__CYGWIN__) 2 | #include "windows/dl.c" 3 | #else 4 | #include "unix/dl.c" 5 | #endif 6 | -------------------------------------------------------------------------------- /docs/man/grub-editenv.h2m: -------------------------------------------------------------------------------- 1 | [NAME] 2 | grub-editenv \- edit GRUB environment block 3 | [SEE ALSO] 4 | .BR grub-reboot (8), 5 | .BR grub-set-default (8) 6 | -------------------------------------------------------------------------------- /docs/man/grub-syslinux2cfg.h2m: -------------------------------------------------------------------------------- 1 | [NAME] 2 | grub-syslinux2cfg \- transform syslinux config into grub.cfg 3 | [SEE ALSO] 4 | .BR grub-menulst2cfg (8) 5 | -------------------------------------------------------------------------------- /grub-core/osdep/platform_unix.c: -------------------------------------------------------------------------------- 1 | #if !defined (__MINGW32__) && !defined (__CYGWIN__) && !defined (__AROS__) 2 | #include "unix/platform.c" 3 | #endif 4 | -------------------------------------------------------------------------------- /util/grub-module-verifier32.c: -------------------------------------------------------------------------------- 1 | #define MODULEVERIFIER_ELF32 1 2 | #ifndef GRUB_MODULE_VERIFIERXX 3 | #include "grub-module-verifierXX.c" 4 | #endif 5 | -------------------------------------------------------------------------------- /util/grub-module-verifier64.c: -------------------------------------------------------------------------------- 1 | #define MODULEVERIFIER_ELF64 1 2 | #ifndef GRUB_MODULE_VERIFIERXX 3 | #include "grub-module-verifierXX.c" 4 | #endif 5 | -------------------------------------------------------------------------------- /grub-core/osdep/sleep.c: -------------------------------------------------------------------------------- 1 | #if defined (__MINGW32__) || defined (__CYGWIN__) 2 | #include "windows/sleep.c" 3 | #else 4 | #include "unix/sleep.c" 5 | #endif 6 | -------------------------------------------------------------------------------- /tests/file_filter/test.cfg: -------------------------------------------------------------------------------- 1 | trust /keys.pub 2 | set check_signatures=enforce 3 | cat /file.gz 4 | cat /file.xz 5 | cat /file.lzop 6 | set check_signatures= 7 | -------------------------------------------------------------------------------- /tests/test_unset.in: -------------------------------------------------------------------------------- 1 | #! @builddir@/grub-shell-tester 2 | 3 | foo=one 4 | echo $foo 5 | 6 | unset foo 7 | echo $foo 8 | echo ${foo} 9 | 10 | 11 | -------------------------------------------------------------------------------- /grub-core/lib/libgcrypt/mpi/m68k/distfiles: -------------------------------------------------------------------------------- 1 | Manifest 2 | syntax.h 3 | mpih-lshift.S 4 | mpih-rshift.S 5 | mpih-add1.S 6 | mpih-sub1.S 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /grub-core/osdep/password.c: -------------------------------------------------------------------------------- 1 | #if defined (__MINGW32__) && !defined (__CYGWIN__) 2 | #include "windows/password.c" 3 | #else 4 | #include "unix/password.c" 5 | #endif 6 | -------------------------------------------------------------------------------- /po/quot.sed: -------------------------------------------------------------------------------- 1 | s/"\([^"]*\)"/“\1”/g 2 | s/`\([^`']*\)'/‘\1’/g 3 | s/ '\([^`']*\)' / ‘\1’ /g 4 | s/ '\([^`']*\)'$/ ‘\1’/g 5 | s/^'\([^`']*\)' /‘\1’ /g 6 | s/“”/""/g 7 | -------------------------------------------------------------------------------- /docs/grub-boot-success.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Mark boot as successful 3 | 4 | [Service] 5 | Type=oneshot 6 | ExecStart=/usr/sbin/grub2-set-bootflag boot_success 7 | -------------------------------------------------------------------------------- /docs/man/grub-set-default.h2m: -------------------------------------------------------------------------------- 1 | [NAME] 2 | grub-set-default \- set the saved default boot entry for GRUB 3 | [SEE ALSO] 4 | .BR grub-reboot (8), 5 | .BR grub-editenv (1) 6 | -------------------------------------------------------------------------------- /grub-core/lib/libgcrypt/mpi/power/distfiles: -------------------------------------------------------------------------------- 1 | Manifest 2 | mpih-add1.S 3 | mpih-lshift.S 4 | mpih-mul1.S 5 | mpih-mul2.S 6 | mpih-mul3.S 7 | mpih-rshift.S 8 | mpih-sub1.S 9 | -------------------------------------------------------------------------------- /grub-core/osdep/emuconsole.c: -------------------------------------------------------------------------------- 1 | #if defined (__MINGW32__) && !defined (__CYGWIN__) 2 | #include "windows/emuconsole.c" 3 | #else 4 | #include "unix/emuconsole.c" 5 | #endif 6 | -------------------------------------------------------------------------------- /docs/man/grub-get-kernel-settings.h2m: -------------------------------------------------------------------------------- 1 | [NAME] 2 | grub-get-kernel-settings \- Evaluate the system's kernel installation settings for use while making a grub configuration file 3 | -------------------------------------------------------------------------------- /docs/man/grub-install.h2m: -------------------------------------------------------------------------------- 1 | [NAME] 2 | grub-install \- install GRUB to a device 3 | [SEE ALSO] 4 | .BR grub-mkconfig (8), 5 | .BR grub-mkimage (1), 6 | .BR grub-mkrescue (1) 7 | -------------------------------------------------------------------------------- /grub-core/lib/libgcrypt/mpi/amd64/distfiles: -------------------------------------------------------------------------------- 1 | mpih-add1.S 2 | mpih-lshift.S 3 | mpih-mul1.S 4 | mpih-mul2.S 5 | mpih-mul3.S 6 | mpih-rshift.S 7 | mpih-sub1.S 8 | mpi-asm-defs.h 9 | -------------------------------------------------------------------------------- /tests/syslinux/ubuntu10.04/isolinux/isolinux.cfg: -------------------------------------------------------------------------------- 1 | # D-I config version 2.0 2 | include menu.cfg 3 | default vesamenu.c32 4 | prompt 0 5 | timeout 50 6 | ui gfxboot bootlogo 7 | -------------------------------------------------------------------------------- /docs/man/grub-mkimage.h2m: -------------------------------------------------------------------------------- 1 | [NAME] 2 | grub-mkimage \- make a bootable image of GRUB 3 | [SEE ALSO] 4 | .BR grub-install (8), 5 | .BR grub-mkrescue (1), 6 | .BR grub-mknetdir (8) 7 | -------------------------------------------------------------------------------- /docs/man/grub-reboot.h2m: -------------------------------------------------------------------------------- 1 | [NAME] 2 | grub-reboot \- set the default boot entry for GRUB, for the next boot only 3 | [SEE ALSO] 4 | .BR grub-set-default (8), 5 | .BR grub-editenv (1) 6 | -------------------------------------------------------------------------------- /include/grub/i386/pc/biosnum.h: -------------------------------------------------------------------------------- 1 | #ifndef GRUB_BIOSNUM_MACHINE_HEADER 2 | #define GRUB_BIOSNUM_MACHINE_HEADER 1 3 | 4 | extern int (*grub_get_root_biosnumber) (void); 5 | 6 | #endif 7 | -------------------------------------------------------------------------------- /docs/man/grub-bios-setup.h2m: -------------------------------------------------------------------------------- 1 | [NAME] 2 | grub-bios-setup \- set up a device to boot using GRUB 3 | [SEE ALSO] 4 | .BR grub-install (8), 5 | .BR grub-mkimage (1), 6 | .BR grub-mkrescue (1) 7 | -------------------------------------------------------------------------------- /docs/man/grub-emu.h2m: -------------------------------------------------------------------------------- 1 | [NAME] 2 | grub-emu \- GRUB emulator 3 | [SEE ALSO] 4 | If you are trying to install GRUB, then you should use 5 | .BR grub-install (8) 6 | rather than this program. 7 | -------------------------------------------------------------------------------- /grub-core/osdep/compress.c: -------------------------------------------------------------------------------- 1 | #if !defined (__MINGW32__) && !defined (__CYGWIN__) && !defined (__AROS__) 2 | #include "unix/compress.c" 3 | #else 4 | #include "basic/compress.c" 5 | #endif 6 | -------------------------------------------------------------------------------- /docs/man/grub-sparc64-setup.h2m: -------------------------------------------------------------------------------- 1 | [NAME] 2 | grub-sparc64-setup \- set up a device to boot using GRUB 3 | [SEE ALSO] 4 | .BR grub-install (8), 5 | .BR grub-mkimage (1), 6 | .BR grub-mkrescue (1) 7 | -------------------------------------------------------------------------------- /grub-core/commands/file32.c: -------------------------------------------------------------------------------- 1 | #define GRUB_TARGET_WORDSIZE 32 2 | #define XX 32 3 | #define ehdrXX ehdr32 4 | #define grub_file_check_netbsdXX grub_file_check_netbsd32 5 | #include "fileXX.c" 6 | -------------------------------------------------------------------------------- /grub-core/commands/file64.c: -------------------------------------------------------------------------------- 1 | #define GRUB_TARGET_WORDSIZE 64 2 | #define XX 64 3 | #define ehdrXX ehdr64 4 | #define grub_file_check_netbsdXX grub_file_check_netbsd64 5 | #include "fileXX.c" 6 | -------------------------------------------------------------------------------- /grub-core/lib/libgcrypt/mpi/i586/distfiles: -------------------------------------------------------------------------------- 1 | Manifest 2 | mpih-add1.S 3 | mpih-mul1.S 4 | mpih-mul2.S 5 | mpih-mul3.S 6 | mpih-lshift.S 7 | mpih-rshift.S 8 | mpih-sub1.S 9 | README 10 | 11 | -------------------------------------------------------------------------------- /tests/syslinux/ubuntu10.04/isolinux/rqtxt.cfg: -------------------------------------------------------------------------------- 1 | label rescue 2 | menu label ^Rescue mode 3 | kernel /install/vmlinuz 4 | append vga=788 initrd=/install/initrd.gz rescue/enable=true -- quiet 5 | -------------------------------------------------------------------------------- /docs/man/grub-glue-efi.h2m: -------------------------------------------------------------------------------- 1 | [NAME] 2 | grub-glue-efi \- generate a fat binary for EFI 3 | [DESCRIPTION] 4 | grub-glue-efi processes ia32 and amd64 EFI images and glues them according to Apple format. 5 | -------------------------------------------------------------------------------- /grub-core/lib/libgcrypt/mpi/i386/distfiles: -------------------------------------------------------------------------------- 1 | Manifest 2 | mpih-add1.S 3 | mpih-mul1.S 4 | mpih-mul2.S 5 | mpih-mul3.S 6 | mpih-lshift.S 7 | mpih-rshift.S 8 | mpih-sub1.S 9 | syntax.h 10 | 11 | -------------------------------------------------------------------------------- /grub-core/lib/libgcrypt/mpi/powerpc32/distfiles: -------------------------------------------------------------------------------- 1 | Manifest 2 | mpih-add1.S 3 | mpih-sub1.S 4 | mpih-mul1.S 5 | mpih-mul2.S 6 | mpih-mul3.S 7 | mpih-lshift.S 8 | mpih-rshift.S 9 | syntax.h 10 | 11 | -------------------------------------------------------------------------------- /include/grub/riscv32/efi/memory.h: -------------------------------------------------------------------------------- 1 | #ifndef GRUB_MEMORY_CPU_HEADER 2 | #include 3 | 4 | #define GRUB_EFI_MAX_USABLE_ADDRESS 0xffffffffUL 5 | 6 | #endif /* ! GRUB_MEMORY_CPU_HEADER */ 7 | -------------------------------------------------------------------------------- /grub-core/lib/libgcrypt/mpi/alpha/distfiles: -------------------------------------------------------------------------------- 1 | README 2 | mpih-add1.S 3 | mpih-sub1.S 4 | mpih-mul1.S 5 | mpih-mul2.S 6 | mpih-mul3.S 7 | mpih-lshift.S 8 | mpih-rshift.S 9 | 10 | udiv-qrnnd.S 11 | 12 | -------------------------------------------------------------------------------- /grub-core/lib/fake_module.c: -------------------------------------------------------------------------------- 1 | /* This file is intentionally empty: it's used to generate modules with no code or data. (purely dependency modules) */ 2 | #include 3 | 4 | GRUB_MOD_LICENSE ("GPLv3+"); 5 | -------------------------------------------------------------------------------- /grub-core/loader/i386/bsd32.c: -------------------------------------------------------------------------------- 1 | #define SUFFIX(x) x ## 32 2 | #define GRUB_TARGET_WORDSIZE 32 3 | #define OBJSYM 0 4 | #include 5 | typedef grub_uint32_t grub_freebsd_addr_t; 6 | #include "bsdXX.c" 7 | -------------------------------------------------------------------------------- /grub-core/loader/i386/bsd64.c: -------------------------------------------------------------------------------- 1 | #define SUFFIX(x) x ## 64 2 | #define GRUB_TARGET_WORDSIZE 64 3 | #define OBJSYM 1 4 | #include 5 | typedef grub_uint64_t grub_freebsd_addr_t; 6 | #include "bsdXX.c" 7 | -------------------------------------------------------------------------------- /grub-core/lib/libgcrypt/mpi/mips3/distfiles: -------------------------------------------------------------------------------- 1 | Manifest 2 | README 3 | mpih-add1.S 4 | mpih-sub1.S 5 | mpih-mul1.S 6 | mpih-mul2.S 7 | mpih-mul3.S 8 | mpih-lshift.S 9 | mpih-rshift.S 10 | mpi-asm-defs.h 11 | 12 | -------------------------------------------------------------------------------- /grub-core/osdep/config.c: -------------------------------------------------------------------------------- 1 | #if defined (__MINGW32__) && !defined (__CYGWIN__) 2 | #include "windows/config.c" 3 | #elif defined (__AROS__) 4 | #include "aros/config.c" 5 | #else 6 | #include "unix/config.c" 7 | #endif 8 | -------------------------------------------------------------------------------- /grub-core/osdep/relpath.c: -------------------------------------------------------------------------------- 1 | #if defined (__MINGW32__) || defined (__CYGWIN__) 2 | #include "windows/relpath.c" 3 | #elif defined (__AROS__) 4 | #include "aros/relpath.c" 5 | #else 6 | #include "unix/relpath.c" 7 | #endif 8 | -------------------------------------------------------------------------------- /grub-core/lib/libgcrypt/mpi/generic/distfiles: -------------------------------------------------------------------------------- 1 | Manifest 2 | mpih-add1.c 3 | mpih-mul1.c 4 | mpih-mul2.c 5 | mpih-mul3.c 6 | mpih-lshift.c 7 | mpih-rshift.c 8 | mpih-sub1.c 9 | udiv-w-sdiv.c 10 | mpi-asm-defs.h 11 | 12 | -------------------------------------------------------------------------------- /grub-core/osdep/blocklist.c: -------------------------------------------------------------------------------- 1 | #ifdef __linux__ 2 | #include "linux/blocklist.c" 3 | #elif defined (__MINGW32__) || defined (__CYGWIN__) 4 | #include "windows/blocklist.c" 5 | #else 6 | #include "generic/blocklist.c" 7 | #endif 8 | -------------------------------------------------------------------------------- /tests/tar_test.in: -------------------------------------------------------------------------------- 1 | #!@BUILD_SHEBANG@ 2 | 3 | set -e 4 | 5 | if ! which tar >/dev/null 2>&1; then 6 | echo "tar not installed; cannot test tar." 7 | exit 99 8 | fi 9 | 10 | "@builddir@/grub-fs-tester" tarfs 11 | -------------------------------------------------------------------------------- /grub-core/tests/boot/kfreebsd.cfg: -------------------------------------------------------------------------------- 1 | kfreebsd /kfreebsd -hv 2 | kfreebsd_loadenv /kfreebsd_env 3 | kfreebsd_module /mfsroot.gz type=mfs_root 4 | set kFreeBSD.hw.hasbrokenint12=1 5 | fakebios 6 | boot 7 | # Shouln't happen 8 | halt 9 | -------------------------------------------------------------------------------- /include/grub/osdep/hostfile.h: -------------------------------------------------------------------------------- 1 | #if defined (__AROS__) 2 | #include "hostfile_aros.h" 3 | #elif defined (__CYGWIN__) || defined (__MINGW32__) 4 | #include "hostfile_windows.h" 5 | #else 6 | #include "hostfile_unix.h" 7 | #endif 8 | -------------------------------------------------------------------------------- /include/grub/util/ofpath.h: -------------------------------------------------------------------------------- 1 | #ifndef GRUB_OFPATH_MACHINE_UTIL_HEADER 2 | #define GRUB_OFPATH_MACHINE_UTIL_HEADER 1 3 | 4 | char *grub_util_devname_to_ofpath (const char *devname); 5 | 6 | #endif /* ! GRUB_OFPATH_MACHINE_UTIL_HEADER */ 7 | -------------------------------------------------------------------------------- /asm-tests/sparc64.S: -------------------------------------------------------------------------------- 1 | .text 2 | 1: 3 | /* A small list of examples of what clang doesn't support. */ 4 | clr %o0 5 | lduw [%o4 + 4], %o4 6 | and %o6, ~0xff, %o6 7 | stw %o5, [%o3] 8 | bne,pt %icc, 1b 9 | nop 10 | -------------------------------------------------------------------------------- /grub-core/tests/boot/kopenbsdlabel.txt: -------------------------------------------------------------------------------- 1 | # size offset fstype [fsize bsize bps/cpg] 2 | a: 256 0 4.2BSD 0 0 1 3 | c: 256 0 unused 0 0 # "raw" part, don't edit 4 | -------------------------------------------------------------------------------- /po/boldquot.sed: -------------------------------------------------------------------------------- 1 | s/"\([^"]*\)"/“\1”/g 2 | s/`\([^`']*\)'/‘\1’/g 3 | s/ '\([^`']*\)' / ‘\1’ /g 4 | s/ '\([^`']*\)'$/ ‘\1’/g 5 | s/^'\([^`']*\)' /‘\1’ /g 6 | s/“”/""/g 7 | s/“/“/g 8 | s/”/”/g 9 | s/‘/‘/g 10 | s/’/’/g 11 | -------------------------------------------------------------------------------- /tests/grub_script_blanklines.in: -------------------------------------------------------------------------------- 1 | #! @BUILD_SHEBANG@ 2 | set -e 3 | 4 | @builddir@/grub-script-check </dev/null 2>&1; then 6 | echo "genromfs not installed; cannot test romfs." 7 | exit 99 8 | fi 9 | 10 | "@builddir@/grub-fs-tester" romfs 11 | -------------------------------------------------------------------------------- /tests/syslinux/ubuntu10.04/isolinux/po4a.cfg: -------------------------------------------------------------------------------- 1 | [po4a_langs] ar bn ca cs da de es eu fi fr gl hu id it ja ka ko ku lv nb nl pl pt pt_BR ru sk sv ta tr vi zh_CN zh_TW 2 | [po4a_paths] po/help.pot $lang:po/$lang.po 3 | [type:docbook] help.xml 4 | -------------------------------------------------------------------------------- /asm-tests/powerpc.S: -------------------------------------------------------------------------------- 1 | /* clang <= 3.3 doesn't handle most of ppc assembly, not even inline assembly 2 | used by gcrypt */ 3 | /* Cache invalidation loop is a fair test. */ 4 | li 5, 0 5 | 1: icbi 5, 3 6 | addi 5, 5, 32 7 | cmpw 5, 4 8 | blt 1b 9 | -------------------------------------------------------------------------------- /grub-core/lib/libgcrypt/mpi/amd64/mpi-asm-defs.h: -------------------------------------------------------------------------------- 1 | /* This file defines some basic constants for the MPI machinery. We 2 | * need to define the types on a per-CPU basis, so it is done with 3 | * this file here. */ 4 | #define BYTES_PER_MPI_LIMB 8 5 | -------------------------------------------------------------------------------- /tests/grub_script_escape_comma.in: -------------------------------------------------------------------------------- 1 | #! @builddir@/grub-shell-tester 2 | 3 | x=1\\,1 4 | echo $x 5 | y='$' 6 | echo $y 7 | z='\' 8 | echo $z 9 | t='\*' 10 | echo $t 11 | u='$' 12 | echo $u 13 | v='\?' 14 | echo $v 15 | 16 | 17 | echo \\ 18 | 19 | -------------------------------------------------------------------------------- /util/grub.d/40_custom.in: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | exec tail -n +3 $0 3 | # This file provides an easy way to add custom menu entries. Simply type the 4 | # menu entries you want to add after this comment. Be careful not to change 5 | # the 'exec tail' line above. 6 | -------------------------------------------------------------------------------- /docs/Makefile.am: -------------------------------------------------------------------------------- 1 | AUTOMAKE_OPTIONS = subdir-objects 2 | 3 | # AM_MAKEINFOFLAGS = --no-split --no-validate 4 | info_TEXINFOS = grub.texi grub-dev.texi 5 | grub_TEXINFOS = fdl.texi 6 | 7 | EXTRA_DIST = font_char_metrics.png font_char_metrics.txt 8 | 9 | 10 | -------------------------------------------------------------------------------- /asm-tests/mips.S: -------------------------------------------------------------------------------- 1 | /* on mips clang doesn't support privilegied instructions, doubleword store/load 2 | and crashes with hand-written assembly 3 | */ 4 | 5 | .set mips3 6 | sync 7 | ld $t2, 0($t1) 8 | 9 | a: 10 | addiu $t1, $s0, (b - a) 11 | b: nop 12 | -------------------------------------------------------------------------------- /include/grub/arm/efi/memory.h: -------------------------------------------------------------------------------- 1 | #ifndef GRUB_MEMORY_CPU_HEADER 2 | #include 3 | 4 | #define GRUB_EFI_MAX_USABLE_ADDRESS 0xffffffff 5 | #define GRUB_EFI_MAX_ALLOCATION_ADDRESS GRUB_EFI_MAX_USABLE_ADDRESS 6 | 7 | #endif /* ! GRUB_MEMORY_CPU_HEADER */ 8 | -------------------------------------------------------------------------------- /include/grub/i386/efi/memory.h: -------------------------------------------------------------------------------- 1 | #ifndef GRUB_MEMORY_CPU_HEADER 2 | #include 3 | 4 | #define GRUB_EFI_MAX_USABLE_ADDRESS 0xffffffff 5 | #define GRUB_EFI_MAX_ALLOCATION_ADDRESS GRUB_EFI_MAX_USABLE_ADDRESS 6 | 7 | #endif /* ! GRUB_MEMORY_CPU_HEADER */ 8 | -------------------------------------------------------------------------------- /include/grub/ia64/efi/memory.h: -------------------------------------------------------------------------------- 1 | #ifndef GRUB_MEMORY_CPU_HEADER 2 | #include 3 | 4 | #define GRUB_EFI_MAX_USABLE_ADDRESS 0xffffffff 5 | #define GRUB_EFI_MAX_ALLOCATION_ADDRESS GRUB_EFI_MAX_USABLE_ADDRESS 6 | 7 | #endif /* ! GRUB_MEMORY_CPU_HEADER */ 8 | -------------------------------------------------------------------------------- /tests/grub_script_eval.in: -------------------------------------------------------------------------------- 1 | #! @builddir@/grub-shell-tester 2 | 3 | eval echo "Hello world" 4 | valname=tst 5 | eval $valname=hi 6 | echo $tst 7 | 8 | if eval " 9 | false 10 | "; then 11 | echo should have failed 12 | else 13 | echo failed as expected 14 | fi 15 | -------------------------------------------------------------------------------- /docs/grub-boot-success.timer: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Mark boot as successful after the user session has run 2 minutes 3 | ConditionUser=!@system 4 | ConditionVirtualization=!container 5 | 6 | [Timer] 7 | OnActiveSec=2min 8 | 9 | [Install] 10 | WantedBy=timers.target 11 | -------------------------------------------------------------------------------- /include/grub/arm64/efi/memory.h: -------------------------------------------------------------------------------- 1 | #ifndef GRUB_MEMORY_CPU_HEADER 2 | #include 3 | 4 | #define GRUB_EFI_MAX_USABLE_ADDRESS 0xffffffffffffULL 5 | #define GRUB_EFI_MAX_ALLOCATION_ADDRESS GRUB_EFI_MAX_USABLE_ADDRESS 6 | 7 | #endif /* ! GRUB_MEMORY_CPU_HEADER */ 8 | -------------------------------------------------------------------------------- /include/grub/riscv64/efi/memory.h: -------------------------------------------------------------------------------- 1 | #ifndef GRUB_MEMORY_CPU_HEADER 2 | #include 3 | 4 | #define GRUB_EFI_MAX_USABLE_ADDRESS 0xffffffffffffULL 5 | #define GRUB_EFI_MAX_ALLOCATION_ADDRESS GRUB_EFI_MAX_USABLE_ADDRESS 6 | 7 | #endif /* ! GRUB_MEMORY_CPU_HEADER */ 8 | -------------------------------------------------------------------------------- /grub-core/loader/i386/xen_file32.c: -------------------------------------------------------------------------------- 1 | #define GRUB_TARGET_WORDSIZE 32 2 | #define XX 32 3 | #define grub_le_to_cpu_addr grub_le_to_cpu32 4 | #define ehdrXX ehdr32 5 | #define grub_xen_get_infoXX grub_xen_get_info32 6 | #define FOR_ELF_PHDRS FOR_ELF32_PHDRS 7 | #include "xen_fileXX.c" 8 | -------------------------------------------------------------------------------- /grub-core/loader/i386/xen_file64.c: -------------------------------------------------------------------------------- 1 | #define GRUB_TARGET_WORDSIZE 64 2 | #define XX 64 3 | #define grub_le_to_cpu_addr grub_le_to_cpu64 4 | #define ehdrXX ehdr64 5 | #define grub_xen_get_infoXX grub_xen_get_info64 6 | #define FOR_ELF_PHDRS FOR_ELF64_PHDRS 7 | #include "xen_fileXX.c" 8 | -------------------------------------------------------------------------------- /po/Rules-swiss: -------------------------------------------------------------------------------- 1 | # Special Makefile rules for transforming German typography into Swiss one. 2 | 3 | DISTFILES.common.extra2 = swiss.sed Rules-swiss 4 | 5 | de_CH.po-create: de.po swiss.sed 6 | LC_ALL=C.UTF-8 $(MSGFILTER) -i $< -o $(srcdir)/de_CH.po sed -f $(srcdir)/swiss.sed 7 | 8 | -------------------------------------------------------------------------------- /util/grub.d/41_custom.in: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | cat </dev/null 2>&1; then 6 | echo "mksquashfs not installed; cannot test squashfs." 7 | exit 99 8 | fi 9 | 10 | "@builddir@/grub-fs-tester" squash4_gzip 11 | "@builddir@/grub-fs-tester" squash4_xz 12 | "@builddir@/grub-fs-tester" squash4_lzo 13 | -------------------------------------------------------------------------------- /util/systemd/grub-systemd-integration.service.in: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Grub2 systemctl reboot --boot-loader-menu=... support 3 | Before=umount.target systemd-reboot.service 4 | DefaultDependencies=no 5 | ConditionPathExists=/run/systemd/reboot-to-boot-loader-menu 6 | 7 | [Service] 8 | ExecStart=@libexecdir@/@grubdirname@/systemd-integration.sh 9 | -------------------------------------------------------------------------------- /docs/grub-boot-indeterminate.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Mark boot as indeterminate 3 | DefaultDependencies=false 4 | Requires=sysinit.target 5 | After=sysinit.target 6 | Wants=system-update-pre.target 7 | Before=system-update-pre.target 8 | 9 | [Service] 10 | Type=oneshot 11 | ExecStart=/usr/bin/grub2-editenv - incr boot_indeterminate 12 | -------------------------------------------------------------------------------- /TODO: -------------------------------------------------------------------------------- 1 | 2 | Before working on improving GRUB, it's very important that you 3 | make contact with the core GRUB developers. Things herein might be 4 | slightly out of date or otherwise not easy to understand at first 5 | glance. So write to first. 6 | 7 | For bug tracking, refer to: 8 | 9 | http://savannah.gnu.org/bugs/?group=grub 10 | -------------------------------------------------------------------------------- /tests/jfs_test.in: -------------------------------------------------------------------------------- 1 | #!@BUILD_SHEBANG@ 2 | 3 | set -e 4 | 5 | if [ "x$EUID" = "x" ] ; then 6 | EUID=`id -u` 7 | fi 8 | 9 | if [ "$EUID" != 0 ] ; then 10 | exit 99 11 | fi 12 | 13 | if ! which mkfs.jfs >/dev/null 2>&1; then 14 | echo "mkfs.jfs not installed; cannot test JFS." 15 | exit 99 16 | fi 17 | 18 | "@builddir@/grub-fs-tester" jfs 19 | -------------------------------------------------------------------------------- /asm-tests/arm.S: -------------------------------------------------------------------------------- 1 | /* on arm clang doesn't support .arch directive */ 2 | 3 | .text 4 | .syntax unified 5 | 6 | #if !defined (__thumb2__) 7 | .arch armv7a 8 | .arm 9 | #else 10 | .arch armv7 11 | .thumb 12 | #endif 13 | mcr p15, 0, r11, c7, c14, 2 14 | 15 | /* clang restricts access to dsb/isb despite .arch */ 16 | dsb 17 | isb 18 | 19 | 20 | 21 | -------------------------------------------------------------------------------- /tests/f2fs_test.in: -------------------------------------------------------------------------------- 1 | #!@BUILD_SHEBANG@ 2 | 3 | set -e 4 | 5 | if [ "x$EUID" = "x" ] ; then 6 | EUID=`id -u` 7 | fi 8 | 9 | if [ "$EUID" != 0 ] ; then 10 | exit 99 11 | fi 12 | 13 | if ! which mkfs.f2fs >/dev/null 2>&1; then 14 | echo "mkfs.f2fs not installed; cannot test f2fs." 15 | exit 99 16 | fi 17 | 18 | 19 | "@builddir@/grub-fs-tester" f2fs 20 | -------------------------------------------------------------------------------- /tests/udf_test.in: -------------------------------------------------------------------------------- 1 | #!@BUILD_SHEBANG@ 2 | 3 | set -e 4 | 5 | if [ "x$EUID" = "x" ] ; then 6 | EUID=`id -u` 7 | fi 8 | 9 | if [ "$EUID" != 0 ] ; then 10 | exit 99 11 | fi 12 | 13 | if ! which mkudffs >/dev/null 2>&1; then 14 | echo "mkudffs not installed; cannot test UDF." 15 | exit 99 16 | fi 17 | 18 | "@builddir@/grub-fs-tester" udf 19 | 20 | -------------------------------------------------------------------------------- /tests/exfat_test.in: -------------------------------------------------------------------------------- 1 | #!@BUILD_SHEBANG@ 2 | 3 | set -e 4 | 5 | if [ "x$EUID" = "x" ] ; then 6 | EUID=`id -u` 7 | fi 8 | 9 | if [ "$EUID" != 0 ] ; then 10 | exit 99 11 | fi 12 | 13 | if ! which mkfs.exfat >/dev/null 2>&1; then 14 | echo "mkfs.exfat not installed; cannot test exFAT." 15 | exit 99 16 | fi 17 | 18 | "@builddir@/grub-fs-tester" exfat 19 | -------------------------------------------------------------------------------- /tests/nilfs2_test.in: -------------------------------------------------------------------------------- 1 | #!@BUILD_SHEBANG@ 2 | 3 | set -e 4 | 5 | if [ "x$EUID" = "x" ] ; then 6 | EUID=`id -u` 7 | fi 8 | 9 | if [ "$EUID" != 0 ] ; then 10 | exit 99 11 | fi 12 | 13 | if ! which mkfs.nilfs2 >/dev/null 2>&1; then 14 | echo "mkfs.nilfs2 not installed; cannot test nilfs2." 15 | exit 99 16 | fi 17 | 18 | "@builddir@/grub-fs-tester" nilfs2 19 | -------------------------------------------------------------------------------- /BUGS: -------------------------------------------------------------------------------- 1 | GRUB team is aware of following problems: 2 | - Currently search and assembling multidevice abstractions scans 3 | all the devices which can be slow. 4 | - Cache isn't used correctly for video which results in slowness. 5 | 6 | While these are bugs their solution has a potential of breaking more and more 7 | seriously. So it was decided for 1.99 that they aren't fixed. 8 | -------------------------------------------------------------------------------- /tests/grub_script_test.in: -------------------------------------------------------------------------------- 1 | #! @builddir@/grub-shell-tester 2 | 3 | for device in 'hd0' 'fd0'; do 4 | # But search them if their search has been inforced 5 | set fd0search="no" 6 | if [ "$device" != "fd0" -a "$device" != "cd" \ 7 | -o \ 8 | "$device" = "fd0" -a "$fd0search" = "yes" ]\ 9 | ; then 10 | echo "Yes" 11 | else 12 | echo "No" 13 | fi 14 | 15 | done -------------------------------------------------------------------------------- /tests/xfs_test.in: -------------------------------------------------------------------------------- 1 | #!@BUILD_SHEBANG@ 2 | 3 | set -e 4 | 5 | if [ "x$EUID" = "x" ] ; then 6 | EUID=`id -u` 7 | fi 8 | 9 | if [ "$EUID" != 0 ] ; then 10 | exit 99 11 | fi 12 | 13 | if ! which mkfs.xfs >/dev/null 2>&1; then 14 | echo "mkfs.xfs not installed; cannot test xfs." 15 | exit 99 16 | fi 17 | 18 | 19 | "@builddir@/grub-fs-tester" xfs_crc 20 | "@builddir@/grub-fs-tester" xfs 21 | -------------------------------------------------------------------------------- /grub-core/tests/boot/qemu-shutdown-x86.S: -------------------------------------------------------------------------------- 1 | movl $0x80000b80, %eax 2 | movw $0xcf8, %dx 3 | outl %eax, %dx 4 | movw $0xcfc, %dx 5 | inb %dx, %al 6 | orb $1, %al 7 | outb %al, %dx 8 | 9 | movl $0x80000b40, %eax 10 | movw $0xcf8, %dx 11 | outl %eax, %dx 12 | movl $0x7001, %eax 13 | movw $0xcfc, %dx 14 | outl %eax, %dx 15 | movw $0x2000, %ax 16 | movw $0x7004, %dx 17 | outw %ax, %dx 18 | -------------------------------------------------------------------------------- /grub-core/osdep/random.c: -------------------------------------------------------------------------------- 1 | #if defined (_WIN32) || defined (__CYGWIN__) 2 | #include "windows/random.c" 3 | #elif defined (__linux__) || defined (__FreeBSD__) \ 4 | || defined (__FreeBSD_kernel__) || defined (__OpenBSD__) \ 5 | || defined (__GNU__) || defined (__NetBSD__) \ 6 | || defined (__APPLE__) || defined(__sun__) || defined (__HAIKU__) 7 | #include "unix/random.c" 8 | #else 9 | #include "basic/random.c" 10 | #endif 11 | -------------------------------------------------------------------------------- /util/bash-completion.d/Makefile.am: -------------------------------------------------------------------------------- 1 | 2 | bash_completion_source = grub-completion.bash.in 3 | bash_completion_script = grub 4 | 5 | EXTRA_DIST = $(bash_completion_source) 6 | 7 | CLEANFILES = $(bash_completion_script) config.log 8 | 9 | bashcompletion_DATA = $(bash_completion_script) 10 | 11 | $(bash_completion_script): $(bash_completion_source) $(top_builddir)/config.status 12 | $(top_builddir)/config.status --file=$@:$< 13 | -------------------------------------------------------------------------------- /include/grub/arm/startup.h: -------------------------------------------------------------------------------- 1 | #ifndef GRUB_STARTUP_CPU_HEADER 2 | #define GRUB_STARTUP_CPU_HEADER 3 | 4 | struct grub_arm_startup_registers 5 | { 6 | /* registers 0-11 */ 7 | /* for U-boot r[1] is machine type */ 8 | /* for U-boot r[2] is boot data */ 9 | grub_uint32_t r[12]; 10 | grub_uint32_t sp; 11 | grub_uint32_t lr; 12 | }; 13 | 14 | extern struct grub_arm_startup_registers grub_arm_saved_registers; 15 | 16 | #endif 17 | -------------------------------------------------------------------------------- /include/grub/x86_64/efi/memory.h: -------------------------------------------------------------------------------- 1 | #ifndef GRUB_MEMORY_CPU_HEADER 2 | #include 3 | 4 | #if defined (__code_model_large__) 5 | #define GRUB_EFI_MAX_USABLE_ADDRESS __UINTPTR_MAX__ 6 | #define GRUB_EFI_MAX_ALLOCATION_ADDRESS 0x7fffffff 7 | #else 8 | #define GRUB_EFI_MAX_USABLE_ADDRESS 0x7fffffff 9 | #define GRUB_EFI_MAX_ALLOCATION_ADDRESS GRUB_EFI_MAX_USABLE_ADDRESS 10 | #endif 11 | 12 | #endif /* ! GRUB_MEMORY_CPU_HEADER */ 13 | -------------------------------------------------------------------------------- /linguas.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | rsync -Lrtvz translationproject.org::tp/latest/grub/ po 4 | 5 | autogenerated="en@quot en@hebrew de@hebrew en@cyrillic en@greek en@arabic en@piglatin de_CH" 6 | 7 | 8 | for x in $autogenerated; do 9 | rm -f "po/$x.po"; 10 | done 11 | 12 | 13 | ( 14 | ( 15 | cd po && ls *.po| cut -d. -f1 16 | for x in $autogenerated; do 17 | echo "$x"; 18 | done 19 | ) | sort | uniq | xargs 20 | ) >po/LINGUAS 21 | -------------------------------------------------------------------------------- /tests/syslinux/ubuntu10.04/isolinux/gfxboot.cfg: -------------------------------------------------------------------------------- 1 | foreground=0xFFFFFF 2 | background=0x958490 3 | screen-colour=0x270A1E 4 | hidden-timeout=2 5 | label normal=Normal 6 | append normal= 7 | label driverupdates=Use driver update disc 8 | append driverupdates=debian-installer/driver-update=true 9 | applies driverupdates=live live-install 10 | label oem=OEM install (for manufacturers) 11 | append oem=oem-config/enable=true 12 | applies oem=live live-install install 13 | -------------------------------------------------------------------------------- /tests/hfsplus_test.in: -------------------------------------------------------------------------------- 1 | #!@BUILD_SHEBANG@ 2 | 3 | set -e 4 | 5 | if [ "x$EUID" = "x" ] ; then 6 | EUID=`id -u` 7 | fi 8 | 9 | if [ "$EUID" != 0 ] ; then 10 | exit 99 11 | fi 12 | 13 | if ! which mkfs.hfsplus >/dev/null 2>&1; then 14 | echo "mkfs.hfsplus not installed; cannot test hfsplus." 15 | exit 99 16 | fi 17 | 18 | "@builddir@/grub-fs-tester" hfsplus 19 | "@builddir@/grub-fs-tester" hfsplus_casesens 20 | "@builddir@/grub-fs-tester" hfsplus_wrap 21 | -------------------------------------------------------------------------------- /po/Rules-windowsdir: -------------------------------------------------------------------------------- 1 | # generate windowsdir 2 | 3 | DISTFILES.common.extra5 = Rules-windowsdir 4 | 5 | windowsdir="$(top_builddir)/$(PACKAGE)-$(VERSION)-for-windows" 6 | windowsdir: $(GMOFILES) 7 | test -d "$(windowsdir)/locale" || mkdir "$(windowsdir)/locale" 8 | for x in $(CATALOGS); do \ 9 | test -d "$(windowsdir)/locale/$${x%.gmo}" || mkdir "$(windowsdir)/locale/$${x%.gmo}"; \ 10 | cp -fp "$(srcdir)/$$x" "$(windowsdir)/locale/$${x%.gmo}/grub.mo"; \ 11 | done 12 | -------------------------------------------------------------------------------- /tests/grub_script_no_commands.in: -------------------------------------------------------------------------------- 1 | #! @BUILD_SHEBANG@ 2 | set -e 3 | 4 | # grub-script-check refuses to pass a file with no commands; this usually 5 | # indicates a bug in the code generating that file. 6 | 7 | @builddir@/grub-script-check </dev/null 2>&1; then 6 | echo "cpio not installed; cannot test cpio." 7 | exit 99 8 | fi 9 | 10 | "@builddir@/grub-fs-tester" cpio_bin 11 | "@builddir@/grub-fs-tester" cpio_odc 12 | "@builddir@/grub-fs-tester" cpio_newc 13 | "@builddir@/grub-fs-tester" cpio_crc 14 | "@builddir@/grub-fs-tester" cpio_ustar 15 | "@builddir@/grub-fs-tester" cpio_hpbin 16 | "@builddir@/grub-fs-tester" cpio_hpodc 17 | -------------------------------------------------------------------------------- /grub-core/osdep/windows/cputime.c: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | 4 | #include 5 | #include 6 | 7 | grub_uint64_t 8 | grub_util_get_cpu_time_ms (void) 9 | { 10 | FILETIME cr, ex, ke, us; 11 | ULARGE_INTEGER us_ul; 12 | 13 | GetProcessTimes (GetCurrentProcess (), &cr, &ex, &ke, &us); 14 | us_ul.LowPart = us.dwLowDateTime; 15 | us_ul.HighPart = us.dwHighDateTime; 16 | 17 | return us_ul.QuadPart / 10000; 18 | } 19 | 20 | -------------------------------------------------------------------------------- /tests/syslinux_test.in: -------------------------------------------------------------------------------- 1 | #!@BUILD_SHEBANG@ 2 | 3 | set -e 4 | 5 | outfile="`mktemp "${TMPDIR:-/tmp}/tmp.XXXXXXXXXX"`" || exit 99 6 | 7 | "@builddir@/grub-syslinux2cfg" -r "@abs_top_srcdir@/tests/syslinux/ubuntu10.04" "@abs_top_srcdir@/tests/syslinux/ubuntu10.04/isolinux/isolinux.cfg" -o "$outfile" 8 | 9 | echo "$outfile" 10 | 11 | if ! diff -u "$outfile" "@builddir@/tests/syslinux/ubuntu10.04_grub.cfg"; then 12 | echo "Mismatch in ubuntu10.04" 13 | exit 1; 14 | fi 15 | 16 | exit 0 17 | -------------------------------------------------------------------------------- /util/grub.d/14_menu_show_once.in: -------------------------------------------------------------------------------- 1 | #! /bin/sh 2 | # Force the menu to be shown once, with a timeout of ${menu_show_once_timeout} 3 | # if requested by ${menu_show_once_timeout} being set in the env. 4 | cat << EOF 5 | if [ x\$feature_timeout_style = xy ]; then 6 | if [ "\${menu_show_once_timeout}" ]; then 7 | set timeout_style=menu 8 | set timeout="\${menu_show_once_timeout}" 9 | unset menu_show_once_timeout 10 | save_env menu_show_once_timeout 11 | fi 12 | fi 13 | EOF 14 | -------------------------------------------------------------------------------- /include/grub/mips/asm.h: -------------------------------------------------------------------------------- 1 | #ifndef GRUB_MIPS_ASM_HEADER 2 | #define GRUB_MIPS_ASM_HEADER 1 3 | 4 | #if defined(_MIPS_SIM) && defined(_ABIN32) && _MIPS_SIM == _ABIN32 5 | #define GRUB_ASM_T4 $a4 6 | #define GRUB_ASM_T5 $a5 7 | #define GRUB_ASM_SZREG 8 8 | #define GRUB_ASM_REG_S sd 9 | #define GRUB_ASM_REG_L ld 10 | #else 11 | #define GRUB_ASM_T4 $t4 12 | #define GRUB_ASM_T5 $t5 13 | #define GRUB_ASM_SZREG 4 14 | #define GRUB_ASM_REG_S sw 15 | #define GRUB_ASM_REG_L lw 16 | #endif 17 | 18 | #endif 19 | -------------------------------------------------------------------------------- /tests/luks1_test.in: -------------------------------------------------------------------------------- 1 | #!@BUILD_SHEBANG@ 2 | 3 | set -e 4 | 5 | if [ "x$EUID" = "x" ] ; then 6 | EUID=`id -u` 7 | fi 8 | 9 | if [ "$EUID" != 0 ] ; then 10 | exit 99 11 | fi 12 | 13 | if ! which mkfs.ext2 >/dev/null 2>&1; then 14 | echo "mkfs.ext2 not installed; cannot test luks." 15 | exit 99 16 | fi 17 | 18 | if ! which cryptsetup >/dev/null 2>&1; then 19 | echo "cryptsetup not installed; cannot test luks." 20 | exit 99 21 | fi 22 | 23 | "@builddir@/grub-fs-tester" luks1 24 | -------------------------------------------------------------------------------- /tests/luks2_test.in: -------------------------------------------------------------------------------- 1 | #!@BUILD_SHEBANG@ 2 | 3 | set -e 4 | 5 | if [ "x$EUID" = "x" ] ; then 6 | EUID=`id -u` 7 | fi 8 | 9 | if [ "$EUID" != 0 ] ; then 10 | exit 99 11 | fi 12 | 13 | if ! which mkfs.ext2 >/dev/null 2>&1; then 14 | echo "mkfs.ext2 not installed; cannot test luks2." 15 | exit 99 16 | fi 17 | 18 | if ! which cryptsetup >/dev/null 2>&1; then 19 | echo "cryptsetup not installed; cannot test luks2." 20 | exit 99 21 | fi 22 | 23 | "@builddir@/grub-fs-tester" luks2 24 | -------------------------------------------------------------------------------- /util/systemd/systemd-integration.sh.in: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | TIMEOUT_USEC=$(cat /run/systemd/reboot-to-boot-loader-menu) 4 | TIMEOUT=$(((TIMEOUT_USEC + 500000) / 1000000)) 5 | 6 | @grub_editenv@ - set menu_show_once_timeout=$TIMEOUT 7 | 8 | # Downstream RH / Fedora patch for compatibility with old, not (yet) 9 | # regenerated grub.cfg files which miss the menu_show_once_timeout check 10 | # this older grubenv variable leads to a fixed timeout of 60 seconds 11 | @grub_editenv@ - set menu_show_once=1 12 | -------------------------------------------------------------------------------- /tests/hfs_test.in: -------------------------------------------------------------------------------- 1 | #!@BUILD_SHEBANG@ 2 | 3 | set -e 4 | 5 | if [ "x$EUID" = "x" ] ; then 6 | EUID=`id -u` 7 | fi 8 | 9 | if [ "$EUID" != 0 ] ; then 10 | exit 99 11 | fi 12 | 13 | if ! which mkfs.hfs >/dev/null 2>&1; then 14 | echo "mkfs.hfs not installed; cannot test HFS." 15 | exit 99 16 | fi 17 | 18 | if ! grep -q mac_roman /proc/modules && ! modprobe mac_roman; then 19 | echo "no mac-roman support; cannot test HFS." 20 | exit 99 21 | fi 22 | 23 | "@builddir@/grub-fs-tester" hfs 24 | -------------------------------------------------------------------------------- /asm-tests/i386-pc.S: -------------------------------------------------------------------------------- 1 | /* on x86 old clang doesn't support .code16 2 | newer clang supports it but creates 6-byte jumps instead of 3-byte ones 3 | which makes us go over boot sector size. 4 | Starting with 3.9 clang emits 3-byte jumps but still creates 8-bytes movl 5 | instead of 5-bytes, so code overflows into data. */ 6 | 7 | .code16 8 | jmp far 9 | .org 4 10 | jmp nearer 11 | .org 6 12 | movl nearer, %ebx 13 | .org 11 14 | .space 100 15 | nearer: 16 | .space 200 17 | far: 18 | .byte 0 19 | -------------------------------------------------------------------------------- /tests/fat_test.in: -------------------------------------------------------------------------------- 1 | #!@BUILD_SHEBANG@ 2 | 3 | set -e 4 | 5 | if [ "x$EUID" = "x" ] ; then 6 | EUID=`id -u` 7 | fi 8 | 9 | if [ "$EUID" != 0 ] ; then 10 | exit 99 11 | fi 12 | 13 | if ! which mkfs.vfat >/dev/null 2>&1; then 14 | echo "mkfs.vfat not installed; cannot test FAT." 15 | exit 99 16 | fi 17 | 18 | "@builddir@/grub-fs-tester" vfat16a 19 | "@builddir@/grub-fs-tester" vfat12a 20 | "@builddir@/grub-fs-tester" vfat12 21 | "@builddir@/grub-fs-tester" vfat16 22 | "@builddir@/grub-fs-tester" vfat32 23 | -------------------------------------------------------------------------------- /tests/help_test.in: -------------------------------------------------------------------------------- 1 | #! @BUILD_SHEBANG@ 2 | set -e 3 | 4 | . "@builddir@/grub-core/modinfo.sh" 5 | 6 | template="Usage: help [PATTERN ...] 7 | Show a help message. 8 | 9 | -h, --help Display this help and exit. 10 | -u, --usage Display the usage of this command and exit. 11 | 12 | 13 | To enable less(1)-like paging, \"set pager=1\". 14 | Hello World" 15 | output="$(echo 'help help; hello' | @builddir@/grub-shell)" 16 | 17 | if [ "$template" != "$output" ]; then 18 | exit 1 19 | fi 20 | -------------------------------------------------------------------------------- /tests/reiserfs_test.in: -------------------------------------------------------------------------------- 1 | #!@BUILD_SHEBANG@ 2 | 3 | set -e 4 | 5 | if [ "x$EUID" = "x" ] ; then 6 | EUID=`id -u` 7 | fi 8 | 9 | if [ "$EUID" != 0 ] ; then 10 | exit 99 11 | fi 12 | 13 | if ! which mkfs.reiserfs >/dev/null 2>&1; then 14 | echo "mkfs.reiserfs not installed; cannot test reiserfs." 15 | exit 99 16 | fi 17 | 18 | "@builddir@/grub-fs-tester" reiserfs 19 | 20 | # Kernels since at least 4.15 can not mount ReiserFS filesystems of the old format. 21 | #"@builddir@/grub-fs-tester" reiserfs_old 22 | -------------------------------------------------------------------------------- /grub-core/osdep/unix/cputime.c: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | 4 | #include 5 | #include 6 | #include 7 | 8 | grub_uint64_t 9 | grub_util_get_cpu_time_ms (void) 10 | { 11 | struct tms tm; 12 | static long sc_clk_tck; 13 | if (!sc_clk_tck) 14 | { 15 | sc_clk_tck = sysconf(_SC_CLK_TCK); 16 | if (sc_clk_tck <= 0) 17 | sc_clk_tck = 1000; 18 | } 19 | 20 | times (&tm); 21 | return (tm.tms_utime * 1000ULL) / sc_clk_tck; 22 | } 23 | -------------------------------------------------------------------------------- /tests/grub_script_for1.in: -------------------------------------------------------------------------------- 1 | #! @builddir@/grub-shell-tester 2 | 3 | for x in one two 'three 3' "four 4" five six-6; do echo $x; done 4 | 5 | for x in one two 'three 3' "four 4" five six-6 6 | do 7 | echo $x 8 | done 9 | 10 | foo="1 2" 11 | for x in ab${foo}cd; do echo $x; done 12 | for x in "ab${foo}cd"; do echo $x; done 13 | 14 | a="one two three" 15 | y=foo 16 | echo $y 17 | for y in $a; do 18 | echo $y 19 | done 20 | echo $y 21 | 22 | 23 | b="one two three" 24 | for z in $b; do 25 | echo $z 26 | done 27 | echo $z 28 | -------------------------------------------------------------------------------- /tests/ntfs_test.in: -------------------------------------------------------------------------------- 1 | #!@BUILD_SHEBANG@ 2 | 3 | set -e 4 | 5 | if [ "x$EUID" = "x" ] ; then 6 | EUID=`id -u` 7 | fi 8 | 9 | if [ "$EUID" != 0 ] ; then 10 | exit 99 11 | fi 12 | 13 | if ! which mkfs.ntfs >/dev/null 2>&1; then 14 | echo "mkfs.ntfs not installed; cannot test ntfs." 15 | exit 99 16 | fi 17 | 18 | if ! which setfattr >/dev/null 2>&1; then 19 | echo "setfattr not installed; cannot test ntfs." 20 | exit 99 21 | fi 22 | 23 | "@builddir@/grub-fs-tester" ntfs 24 | "@builddir@/grub-fs-tester" ntfscomp 25 | -------------------------------------------------------------------------------- /po/remove-potcdate.sin: -------------------------------------------------------------------------------- 1 | # Sed script that remove the POT-Creation-Date line in the header entry 2 | # from a POT file. 3 | # 4 | # The distinction between the first and the following occurrences of the 5 | # pattern is achieved by looking at the hold space. 6 | /^"POT-Creation-Date: .*"$/{ 7 | x 8 | # Test if the hold space is empty. 9 | s/P/P/ 10 | ta 11 | # Yes it was empty. First occurrence. Remove the line. 12 | g 13 | d 14 | bb 15 | :a 16 | # The hold space was nonempty. Following occurrences. Do nothing. 17 | x 18 | :b 19 | } 20 | -------------------------------------------------------------------------------- /util/grub.d/README: -------------------------------------------------------------------------------- 1 | 2 | All executable files in this directory are processed in shell expansion order. 3 | 4 | 00_*: Reserved for 00_header. 5 | 10_*: Native boot entries. 6 | 20_*: Third party apps (e.g. memtest86+). 7 | 8 | The number namespace in-between is configurable by system installer and/or 9 | administrator. For example, you can add an entry to boot another OS as 10 | 01_otheros, 11_otheros, etc, depending on the position you want it to occupy in 11 | the menu; and then adjust the default setting via /etc/default/grub. 12 | -------------------------------------------------------------------------------- /include/grub/arm/system.h: -------------------------------------------------------------------------------- 1 | #ifndef GRUB_SYSTEM_CPU_HEADER 2 | #define GRUB_SYSTEM_CPU_HEADER 3 | 4 | #include 5 | #include 6 | 7 | enum 8 | { 9 | GRUB_ARM_MACHINE_TYPE_RASPBERRY_PI = 3138, 10 | GRUB_ARM_MACHINE_TYPE_FDT = 0xFFFFFFFF 11 | }; 12 | 13 | void EXPORT_FUNC(grub_arm_disable_caches_mmu) (void); 14 | void grub_arm_enable_caches_mmu (void); 15 | void grub_arm_enable_mmu (grub_uint32_t *mmu_tables); 16 | void grub_arm_clear_mmu_v6 (void); 17 | 18 | #endif /* ! GRUB_SYSTEM_CPU_HEADER */ 19 | 20 | -------------------------------------------------------------------------------- /include/grub/i386/pc/vesa_modes_table.h: -------------------------------------------------------------------------------- 1 | #ifndef GRUB_VESA_MODE_TABLE_HEADER 2 | #define GRUB_VESA_MODE_TABLE_HEADER 1 3 | 4 | #include 5 | 6 | #define GRUB_VESA_MODE_TABLE_START 0x300 7 | #define GRUB_VESA_MODE_TABLE_END 0x373 8 | 9 | struct grub_vesa_mode_table_entry { 10 | grub_uint16_t width; 11 | grub_uint16_t height; 12 | grub_uint8_t depth; 13 | }; 14 | 15 | extern struct grub_vesa_mode_table_entry 16 | grub_vesa_mode_table[GRUB_VESA_MODE_TABLE_END 17 | - GRUB_VESA_MODE_TABLE_START + 1]; 18 | 19 | #endif 20 | -------------------------------------------------------------------------------- /include/grub/arm/cros_ec.h: -------------------------------------------------------------------------------- 1 | #ifndef GRUB_ARM_CROS_EC_H 2 | #define GRUB_ARM_CROS_EC_H 1 3 | 4 | #include 5 | #include 6 | 7 | #define GRUB_CROS_EC_KEYSCAN_COLS 13 8 | #define GRUB_CROS_EC_KEYSCAN_ROWS 8 9 | 10 | struct grub_cros_ec_keyscan { 11 | grub_uint8_t data[GRUB_CROS_EC_KEYSCAN_COLS]; 12 | }; 13 | 14 | int 15 | grub_cros_ec_scan_keyboard (const struct grub_fdtbus_dev *dev, 16 | struct grub_cros_ec_keyscan *scan); 17 | 18 | int 19 | grub_cros_ec_validate (const struct grub_fdtbus_dev *dev); 20 | 21 | #endif 22 | -------------------------------------------------------------------------------- /tests/syslinux/ubuntu10.04/isolinux/menu.cfg: -------------------------------------------------------------------------------- 1 | menu hshift 13 2 | menu width 49 3 | menu margin 8 4 | 5 | menu title Installer boot menu 6 | include stdmenu.cfg 7 | include txt.cfg 8 | include gtk.cfg 9 | menu begin advanced 10 | menu title Advanced options 11 | include stdmenu.cfg 12 | label mainmenu 13 | menu label ^Back.. 14 | menu exit 15 | include adtxt.cfg 16 | include adgtk.cfg 17 | menu end 18 | label help 19 | menu label ^Help 20 | text help 21 | Display help screens; type 'menu' at boot prompt to return to this menu 22 | endtext 23 | config prompt.cfg 24 | -------------------------------------------------------------------------------- /tests/syslinux/ubuntu10.04/isolinux/stdmenu.cfg: -------------------------------------------------------------------------------- 1 | menu background splash.png 2 | menu color title * #FFFFFFFF * 3 | menu color border * #00000000 #00000000 none 4 | menu color sel * #ffffffff #76a1d0ff * 5 | menu color hotsel 1;7;37;40 #ffffffff #76a1d0ff * 6 | menu color tabmsg * #ffffffff #00000000 * 7 | menu color help 37;40 #ffdddd00 #00000000 none 8 | menu vshift 12 9 | menu rows 10 10 | menu helpmsgrow 15 11 | # The command line must be at least one line from the bottom. 12 | menu cmdlinerow 16 13 | menu timeoutrow 16 14 | menu tabmsgrow 18 15 | menu tabmsg Press ENTER to boot or TAB to edit a menu entry 16 | -------------------------------------------------------------------------------- /grub-core/osdep/basic/compress.c: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | #include 4 | 5 | int 6 | grub_install_compress_gzip (const char *src, const char *dest) 7 | { 8 | grub_util_error (_("no compression is available for your platform")); 9 | } 10 | 11 | int 12 | grub_install_compress_xz (const char *src, const char *dest) 13 | { 14 | grub_util_error (_("no compression is available for your platform")); 15 | } 16 | 17 | int 18 | grub_install_compress_lzop (const char *src, const char *dest) 19 | { 20 | grub_util_error (_("no compression is available for your platform")); 21 | } 22 | -------------------------------------------------------------------------------- /include/grub/linux.h: -------------------------------------------------------------------------------- 1 | #include 2 | 3 | struct grub_linux_initrd_component; 4 | 5 | struct grub_linux_initrd_context 6 | { 7 | int nfiles; 8 | struct grub_linux_initrd_component *components; 9 | grub_size_t size; 10 | }; 11 | 12 | grub_err_t 13 | grub_initrd_init (int argc, char *argv[], 14 | struct grub_linux_initrd_context *ctx); 15 | 16 | grub_size_t 17 | grub_get_initrd_size (struct grub_linux_initrd_context *ctx); 18 | 19 | void 20 | grub_initrd_close (struct grub_linux_initrd_context *initrd_ctx); 21 | 22 | grub_err_t 23 | grub_initrd_load (struct grub_linux_initrd_context *initrd_ctx, 24 | void *target); 25 | -------------------------------------------------------------------------------- /po/piglatin.sed: -------------------------------------------------------------------------------- 1 | /^Project-Id-Version:/ b 2 | /^Report-Msgid-Bugs-To:/ b 3 | /^POT-Creation-Date:/ b 4 | /^PO-Revision-Date:/ b 5 | /^Last-Translator:/ b 6 | /^Language-Team:/ b 7 | /^Language:/ b 8 | /^MIME-Version:/ b 9 | /^Content-Type:/ b 10 | /^Content-Transfer-Encoding:/ b 11 | /^Plural-Forms:/ b 12 | 13 | s/"\([^"]*\)"/“\1”/g 14 | s/`\([^`']*\)'/‘\1’/g 15 | s/ '\([^`']*\)' / ‘\1’ /g 16 | s/ '\([^`']*\)'$/ ‘\1’/g 17 | s/^'\([^`']*\)' /‘\1’ /g 18 | s/“”/""/g 19 | 20 | s,\(^\|[^a-zA-Z0-9%\\]\)\([aoeuiAOEUI]\)\([a-zA-Z]*\),\1\2\3way,g 21 | s,\(^\|[^a-zA-Z0-9%\\]\)\([bcdfghj-np-tvwxzBCDFGHJ-NP-TVWXZ][bcdfghj-np-tvwxzBCDFGHJ-NP-TVWXZ]*\)\([a-zA-Z]*\),\1\3\2ay,g 22 | -------------------------------------------------------------------------------- /tests/btrfs_test.in: -------------------------------------------------------------------------------- 1 | #!@BUILD_SHEBANG@ 2 | 3 | set -e 4 | 5 | if [ "x$EUID" = "x" ] ; then 6 | EUID=`id -u` 7 | fi 8 | 9 | if [ "$EUID" != 0 ] ; then 10 | exit 99 11 | fi 12 | 13 | if ! which mkfs.btrfs >/dev/null 2>&1; then 14 | echo "mkfs.btrfs not installed; cannot test btrfs." 15 | exit 99 16 | fi 17 | 18 | "@builddir@/grub-fs-tester" btrfs 19 | "@builddir@/grub-fs-tester" btrfs_zlib 20 | "@builddir@/grub-fs-tester" btrfs_lzo 21 | "@builddir@/grub-fs-tester" btrfs_zstd 22 | "@builddir@/grub-fs-tester" btrfs_raid0 23 | "@builddir@/grub-fs-tester" btrfs_raid1 24 | "@builddir@/grub-fs-tester" btrfs_single 25 | "@builddir@/grub-fs-tester" btrfs_raid10 26 | -------------------------------------------------------------------------------- /tests/grub_script_while1.in: -------------------------------------------------------------------------------- 1 | #! @builddir@/grub-shell-tester 2 | 3 | echo one 4 | foo="" 5 | while test "$foo" != "1111"; do foo="${foo}1"; echo "$foo"; done 6 | 7 | echo two 8 | foo="" 9 | while test "$foo" != "aaaa" 10 | do 11 | foo="${foo}a" 12 | echo $foo 13 | done 14 | 15 | foo="" 16 | until test "$foo" = "1111"; do foo="${foo}1"; echo $foo; done 17 | foo="" 18 | until test "$foo" = "aaaa" 19 | do 20 | foo="${foo}a" 21 | echo $foo 22 | done 23 | 24 | # check "$?" in condition gets its value from while body commands 25 | foo="" 26 | false 27 | while test "$?" != "0" 28 | do 29 | echo $foo 30 | foo="${foo}1" 31 | test "$foo" = "111111" 32 | done 33 | -------------------------------------------------------------------------------- /util/import_gcrypth.sed: -------------------------------------------------------------------------------- 1 | /^#@INSERT_SYS_SELECT_H@/ d 2 | /^@FALLBACK_SOCKLEN_T@/ d 3 | /^# *include / d 4 | /^# *include / d 5 | /^# *include / d 6 | /^# *include / d 7 | /^# *include / d 8 | /^# *include / d 9 | /^# *include / d 10 | /^ typedef long ssize_t;/ d 11 | /^ typedef int pid_t;/ d 12 | /^# *include / s,#include ,#include , 13 | /^typedef gpg_error_t gcry_error_t;/ d 14 | /^typedef gpg_err_code_t gcry_err_code_t;/ d 15 | /^typedef struct gcry_mpi \*gcry_mpi_t;/ d 16 | /^struct gcry_thread_cbs/ d 17 | s,_gcry_mpi_invm,gcry_mpi_invm,g 18 | p -------------------------------------------------------------------------------- /grub-core/video/sm712_init.c: -------------------------------------------------------------------------------- 1 | /* Following sequence is a capture of sm712 initialisation sequence. */ 2 | static grub_uint8_t sm712_sr_seq1[] = 3 | { 0xc8, 0x40, 0x14, 0x60, 0x0, 0xa, 0x92, 0x0, 4 | 0x51, 0x00, 0x01, 0x00, 0x0, 0x0, 0x00, 0x0, 5 | 0xc4, 0x30, 0x02, 0x00, 0x1 }; 6 | 7 | static grub_uint8_t sm712_sr_seq2[] = 8 | { 0x28, 0x03, 0x24, 0x09, 0xc0, 0x3a, 0x3a, 0x3a, 9 | 0x3a, 0x3a, 0x3a, 0x3a, 0x00, 0x00, 0x03, 0xff, 10 | 0x00, 0xfc, 0x00, 0x00, 0x20, 0x18, 0x00, 0xfc, 11 | 0x20, 0x0c, 0x44, 0x20, 0x00, 0x00, 0x00, 0x3a, 12 | 0x06, 0x68, 0xa7, 0x7f, 0x83, 0x24, 0xff, 0x03, 13 | 0x00, 0x60, 0x59, 0x3a, 0x3a, 0x00, 0x00, 0x3a, 14 | 0x01, 0x80 }; 15 | -------------------------------------------------------------------------------- /grub-core/lib/libtasn1/LICENSE: -------------------------------------------------------------------------------- 1 | LICENSING 2 | ========= 3 | 4 | The libtasn1 library is released under the GNU Lesser General Public 5 | License (LGPL) version 2.1 or later; see [COPYING.LESSER](doc/COPYING.LESSER) 6 | for the license terms. 7 | 8 | The GNU LGPL applies to the main libtasn1 library, while the 9 | included applications library are under the GNU GPL version 3. 10 | The libtasn1 library is located in the lib directory, while the applications 11 | in src/. 12 | 13 | The documentation in doc/ is under the GNU FDL license 1.3. 14 | 15 | For any copyright year range specified as YYYY-ZZZZ in this package 16 | note that the range specifies every single year in that closed interval. 17 | -------------------------------------------------------------------------------- /grub-core/kern/emu/cache_s.S: -------------------------------------------------------------------------------- 1 | #ifndef GRUB_MACHINE_EMU 2 | #error "This source is only meant for grub-emu platform" 3 | #endif 4 | 5 | /* An executable stack is not required for these functions. */ 6 | #if defined (__linux__) && defined (__ELF__) 7 | .section .note.GNU-stack,"",%progbits 8 | #endif 9 | 10 | #if defined(__i386__) || defined(__x86_64__) 11 | /* Nothing is necessary. */ 12 | #elif defined(__sparc__) 13 | #include "../sparc64/cache.S" 14 | #elif defined(__powerpc__) 15 | #include "../powerpc/cache.S" 16 | #elif defined(__ia64__) || defined(__arm__) || defined(__aarch64__) || \ 17 | defined(__mips__) || defined(__riscv) 18 | #else 19 | #error "No target cpu type is defined" 20 | #endif 21 | -------------------------------------------------------------------------------- /tests/zfs_test.in: -------------------------------------------------------------------------------- 1 | #!@BUILD_SHEBANG@ 2 | 3 | set -e 4 | 5 | if [ "x$EUID" = "x" ] ; then 6 | EUID=`id -u` 7 | fi 8 | 9 | if [ "$EUID" != 0 ] ; then 10 | exit 99 11 | fi 12 | 13 | if ! which zpool >/dev/null 2>&1; then 14 | echo "zpool not installed; cannot test zfs." 15 | exit 99 16 | fi 17 | 18 | "@builddir@/grub-fs-tester" zfs 19 | "@builddir@/grub-fs-tester" zfs_lzjb 20 | "@builddir@/grub-fs-tester" zfs_gzip 21 | "@builddir@/grub-fs-tester" zfs_zle 22 | "@builddir@/grub-fs-tester" zfs_raidz3 23 | "@builddir@/grub-fs-tester" zfs_raidz2 24 | "@builddir@/grub-fs-tester" zfs_raidz 25 | "@builddir@/grub-fs-tester" zfs_mirror 26 | "@builddir@/grub-fs-tester" zfs_stripe 27 | "@builddir@/grub-fs-tester" zfs_caseins 28 | -------------------------------------------------------------------------------- /include/grub/gcrypt/gpg-error.h: -------------------------------------------------------------------------------- 1 | #ifndef GRUB_GPG_ERROR_H 2 | #define GRUB_GPG_ERROR_H 1 3 | 4 | #include 5 | typedef enum 6 | { 7 | GPG_ERR_SOURCE_USER_1 8 | } 9 | gpg_err_source_t; 10 | #define GPG_ERR_INLINE inline 11 | static inline int 12 | gpg_err_make (gpg_err_source_t source __attribute__ ((unused)), gpg_err_code_t code) 13 | { 14 | return code; 15 | } 16 | 17 | static inline gpg_err_code_t 18 | gpg_err_code (gpg_error_t err) 19 | { 20 | return err; 21 | } 22 | 23 | static inline gpg_err_source_t 24 | gpg_err_source (gpg_error_t err __attribute__ ((unused))) 25 | { 26 | return GPG_ERR_SOURCE_USER_1; 27 | } 28 | 29 | gcry_err_code_t 30 | gpg_error_from_syserror (void); 31 | 32 | #endif 33 | -------------------------------------------------------------------------------- /tests/minixfs_test.in: -------------------------------------------------------------------------------- 1 | #!@BUILD_SHEBANG@ 2 | 3 | set -e 4 | 5 | if [ "x$EUID" = "x" ] ; then 6 | EUID=`id -u` 7 | fi 8 | 9 | if [ "$EUID" != 0 ] ; then 10 | exit 99 11 | fi 12 | 13 | if ! which mkfs.minix >/dev/null 2>&1; then 14 | echo "mkfs.minix not installed; cannot test minixfs." 15 | exit 99 16 | fi 17 | 18 | if ! mkfs.minix -h | grep -- -v > /dev/null; then 19 | echo "mkfs.minix doesn't support minix2fs; cannot test minix*fs." 20 | exit 99 21 | fi 22 | 23 | if ! mkfs.minix -h | grep -- -3 > /dev/null; then 24 | echo "mkfs.minix doesn't support minix3fs; cannot test minix*fs." 25 | exit 99 26 | fi 27 | 28 | "@builddir@/grub-fs-tester" minix 29 | "@builddir@/grub-fs-tester" minix2 30 | "@builddir@/grub-fs-tester" minix3 31 | -------------------------------------------------------------------------------- /AUTHORS: -------------------------------------------------------------------------------- 1 | The following authors assigned copyright on their work to the Free 2 | Software Foundation: 3 | 4 | Yoshinori K. Okuji designed and implemented the initial version. 5 | 6 | Jeroen Dekkers added initrd support, Multiboot support, and fixed bugs 7 | in ext2fs. 8 | 9 | Marco Gerards added ext2fs support, grub-emu, a new command-line 10 | engine, and fixed many bugs. 11 | 12 | Omniflux added terminfo and serial support. 13 | 14 | Vincent Pelletier added Sparc64 support. 15 | 16 | Hollis Blanchard implemented many parts of PowerPC support. 17 | 18 | Tomas Ebenlendr added the command chainloader into the normal mode, 19 | fixed some bugs. 20 | 21 | Guillem Jover merged architecture-independent ELF support code. 22 | 23 | Vesa Jaaskelainen added VBE support. 24 | -------------------------------------------------------------------------------- /tests/syslinux/ubuntu10.04/isolinux/txt.cfg: -------------------------------------------------------------------------------- 1 | default live 2 | label live 3 | menu label ^Try Ubuntu without installing 4 | kernel /casper/vmlinuz 5 | append file=/cdrom/preseed/ubuntu.seed boot=casper initrd=/casper/initrd.lz quiet splash -- 6 | label live-install 7 | menu label ^Install Ubuntu 8 | kernel /casper/vmlinuz 9 | append file=/cdrom/preseed/ubuntu.seed boot=casper only-ubiquity initrd=/casper/initrd.lz quiet splash -- 10 | label check 11 | menu label ^Check disc for defects 12 | kernel /casper/vmlinuz 13 | append boot=casper integrity-check initrd=/casper/initrd.lz quiet splash -- 14 | label memtest 15 | menu label Test ^memory 16 | kernel /install/mt86plus 17 | label hd 18 | menu label ^Boot from first hard disk 19 | localboot 0x80 20 | -------------------------------------------------------------------------------- /po/insert-header.sin: -------------------------------------------------------------------------------- 1 | # Sed script that inserts the file called HEADER before the header entry. 2 | # 3 | # At each occurrence of a line starting with "msgid ", we execute the following 4 | # commands. At the first occurrence, insert the file. At the following 5 | # occurrences, do nothing. The distinction between the first and the following 6 | # occurrences is achieved by looking at the hold space. 7 | /^msgid /{ 8 | x 9 | # Test if the hold space is empty. 10 | s/m/m/ 11 | ta 12 | # Yes it was empty. First occurrence. Read the file. 13 | r HEADER 14 | # Output the file's contents by reading the next line. But don't lose the 15 | # current line while doing this. 16 | g 17 | N 18 | bb 19 | :a 20 | # The hold space was nonempty. Following occurrences. Do nothing. 21 | x 22 | :b 23 | } 24 | -------------------------------------------------------------------------------- /include/grub/module_verifier.h: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | 4 | #include 5 | 6 | #define GRUB_MODULE_VERIFY_SUPPORTS_REL 1 7 | #define GRUB_MODULE_VERIFY_SUPPORTS_RELA 2 8 | 9 | struct grub_module_verifier_arch { 10 | const char *name; 11 | int voidp_sizeof; 12 | int bigendian; 13 | int machine; 14 | int flags; 15 | const int *supported_relocations; 16 | const int *short_relocations; 17 | }; 18 | 19 | void grub_module_verify64(const char * const filename, void *module_img, size_t module_size, const struct grub_module_verifier_arch *arch, const char **whitelist_empty); 20 | void grub_module_verify32(const char * const filename, void *module_img, size_t module_size, const struct grub_module_verifier_arch *arch, const char **whitelist_empty); 21 | -------------------------------------------------------------------------------- /grub-core/osdep/getroot.c: -------------------------------------------------------------------------------- 1 | #ifdef __linux__ 2 | #include "linux/getroot.c" 3 | #elif defined(__FreeBSD__) || defined(__FreeBSD_kernel__) 4 | #include "freebsd/getroot.c" 5 | #elif defined(__NetBSD__) || defined(__OpenBSD__) 6 | #include "bsd/getroot.c" 7 | #elif defined(__APPLE__) 8 | #include "apple/getroot.c" 9 | #elif defined(__sun__) 10 | #include "sun/getroot.c" 11 | #elif defined(__GNU__) 12 | #include "hurd/getroot.c" 13 | #elif defined(__CYGWIN__) || defined (__MINGW32__) 14 | #include "windows/getroot.c" 15 | #elif defined(__AROS__) 16 | #include "aros/getroot.c" 17 | #elif defined (__HAIKU__) 18 | #include "haiku/getroot.c" 19 | #else 20 | # warning "No getroot OS-specific functions is available for your system. Device detection may not work properly." 21 | #include "basic/getroot.c" 22 | #endif 23 | -------------------------------------------------------------------------------- /grub-core/osdep/hostdisk.c: -------------------------------------------------------------------------------- 1 | #ifdef __linux__ 2 | #include "linux/hostdisk.c" 3 | #elif defined(__FreeBSD__) || defined(__FreeBSD_kernel__) 4 | #include "freebsd/hostdisk.c" 5 | #elif defined(__NetBSD__) || defined(__OpenBSD__) 6 | #include "bsd/hostdisk.c" 7 | #elif defined(__APPLE__) 8 | #include "apple/hostdisk.c" 9 | #elif defined(__sun__) 10 | #include "sun/hostdisk.c" 11 | #elif defined(__GNU__) 12 | #include "hurd/hostdisk.c" 13 | #elif defined(__CYGWIN__) || defined(__MINGW32__) 14 | #include "windows/hostdisk.c" 15 | #elif defined(__AROS__) 16 | #include "aros/hostdisk.c" 17 | #elif defined (__HAIKU__) 18 | #include "haiku/hostdisk.c" 19 | #else 20 | # warning "No hostdisk OS-specific functions is available for your system. Device detection may not work properly." 21 | #include "basic/hostdisk.c" 22 | #endif 23 | -------------------------------------------------------------------------------- /grub-core/loader/macho32.c: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | 4 | #define SUFFIX(x) x ## 32 5 | typedef struct grub_macho_header32 grub_macho_header_t; 6 | typedef struct grub_macho_segment32 grub_macho_segment_t; 7 | typedef grub_uint32_t grub_macho_addr_t; 8 | typedef struct grub_macho_thread32 grub_macho_thread_t; 9 | #define offsetXX offset32 10 | #define ncmdsXX ncmds32 11 | #define cmdsizeXX cmdsize32 12 | #define cmdsXX cmds32 13 | #define endXX end32 14 | #define uncompressedXX uncompressed32 15 | #define compressedXX compressed32 16 | #define uncompressed_sizeXX uncompressed_size32 17 | #define compressed_sizeXX compressed_size32 18 | #define XX "32" 19 | #define GRUB_MACHO_MAGIC GRUB_MACHO_MAGIC32 20 | #define GRUB_MACHO_CMD_SEGMENT GRUB_MACHO_CMD_SEGMENT32 21 | #include "machoXX.c" 22 | 23 | -------------------------------------------------------------------------------- /grub-core/loader/macho64.c: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | 4 | #define SUFFIX(x) x ## 64 5 | typedef struct grub_macho_header64 grub_macho_header_t; 6 | typedef struct grub_macho_segment64 grub_macho_segment_t; 7 | typedef grub_uint64_t grub_macho_addr_t; 8 | typedef struct grub_macho_thread64 grub_macho_thread_t; 9 | #define offsetXX offset64 10 | #define ncmdsXX ncmds64 11 | #define cmdsizeXX cmdsize64 12 | #define cmdsXX cmds64 13 | #define endXX end64 14 | #define uncompressedXX uncompressed64 15 | #define compressedXX compressed64 16 | #define uncompressed_sizeXX uncompressed_size64 17 | #define compressed_sizeXX compressed_size64 18 | #define XX "64" 19 | #define GRUB_MACHO_MAGIC GRUB_MACHO_MAGIC64 20 | #define GRUB_MACHO_CMD_SEGMENT GRUB_MACHO_CMD_SEGMENT64 21 | #include "machoXX.c" 22 | 23 | -------------------------------------------------------------------------------- /tests/ext234_test.in: -------------------------------------------------------------------------------- 1 | #!@BUILD_SHEBANG@ 2 | 3 | set -e 4 | 5 | if [ "x$EUID" = "x" ] ; then 6 | EUID=`id -u` 7 | fi 8 | 9 | if [ "$EUID" != 0 ] ; then 10 | exit 99 11 | fi 12 | 13 | if ! which mkfs.ext2 >/dev/null 2>&1; then 14 | echo "mkfs.ext2 not installed; cannot test ext2." 15 | exit 99 16 | fi 17 | 18 | if ! which mkfs.ext3 >/dev/null 2>&1; then 19 | echo "mkfs.ext3 not installed; cannot test ext3." 20 | exit 99 21 | fi 22 | 23 | if ! which mkfs.ext4 >/dev/null 2>&1; then 24 | echo "mkfs.ext4 not installed; cannot test ext4." 25 | exit 99 26 | fi 27 | 28 | "@builddir@/grub-fs-tester" ext2_old 29 | "@builddir@/grub-fs-tester" ext2 30 | "@builddir@/grub-fs-tester" ext3 31 | "@builddir@/grub-fs-tester" ext4 32 | "@builddir@/grub-fs-tester" ext4_metabg 33 | "@builddir@/grub-fs-tester" ext4_encrypt 34 | -------------------------------------------------------------------------------- /util/grub-mkimage32.c: -------------------------------------------------------------------------------- 1 | #define MKIMAGE_ELF32 1 2 | 3 | # define SUFFIX(x) x ## 32 4 | # define ELFCLASSXX ELFCLASS32 5 | # define Elf_Ehdr Elf32_Ehdr 6 | # define Elf_Phdr Elf32_Phdr 7 | # define Elf_Nhdr Elf32_Nhdr 8 | # define Elf_Addr Elf32_Addr 9 | # define Elf_Sym Elf32_Sym 10 | # define Elf_Off Elf32_Off 11 | # define Elf_Shdr Elf32_Shdr 12 | # define Elf_Rela Elf32_Rela 13 | # define Elf_Rel Elf32_Rel 14 | # define Elf_Word Elf32_Word 15 | # define Elf_Half Elf32_Half 16 | # define Elf_Section Elf32_Section 17 | # define ELF_R_SYM(val) ELF32_R_SYM(val) 18 | # define ELF_R_TYPE(val) ELF32_R_TYPE(val) 19 | # define ELF_ST_TYPE(val) ELF32_ST_TYPE(val) 20 | 21 | #define XEN_NOTE_SIZE 132 22 | #define XEN_PVH_NOTE_SIZE 20 23 | 24 | #ifndef GRUB_MKIMAGEXX 25 | #include "grub-mkimagexx.c" 26 | #endif 27 | -------------------------------------------------------------------------------- /util/grub-mkimage64.c: -------------------------------------------------------------------------------- 1 | #define MKIMAGE_ELF64 1 2 | 3 | # define SUFFIX(x) x ## 64 4 | # define ELFCLASSXX ELFCLASS64 5 | # define Elf_Ehdr Elf64_Ehdr 6 | # define Elf_Phdr Elf64_Phdr 7 | # define Elf_Nhdr Elf64_Nhdr 8 | # define Elf_Addr Elf64_Addr 9 | # define Elf_Sym Elf64_Sym 10 | # define Elf_Off Elf64_Off 11 | # define Elf_Shdr Elf64_Shdr 12 | # define Elf_Rela Elf64_Rela 13 | # define Elf_Rel Elf64_Rel 14 | # define Elf_Word Elf64_Word 15 | # define Elf_Half Elf64_Half 16 | # define Elf_Section Elf64_Section 17 | # define ELF_R_SYM(val) ELF64_R_SYM(val) 18 | # define ELF_R_TYPE(val) ELF64_R_TYPE(val) 19 | # define ELF_ST_TYPE(val) ELF64_ST_TYPE(val) 20 | 21 | #define XEN_NOTE_SIZE 120 22 | #define XEN_PVH_NOTE_SIZE 24 23 | 24 | #ifndef GRUB_MKIMAGEXX 25 | #include "grub-mkimagexx.c" 26 | #endif 27 | -------------------------------------------------------------------------------- /grub-core/kern/emu/cache.c: -------------------------------------------------------------------------------- 1 | #ifndef GRUB_MACHINE_EMU 2 | #error "This source is only meant for grub-emu platform" 3 | #endif 4 | 5 | #include 6 | 7 | #if defined(__ia64__) 8 | #include "../ia64/cache.c" 9 | #elif defined (__arm__) || defined (__aarch64__) 10 | 11 | void __clear_cache (void *beg, void *end); 12 | 13 | void 14 | grub_arch_sync_caches (void *address, grub_size_t len) 15 | { 16 | __clear_cache (address, (char *) address + len); 17 | } 18 | 19 | #elif defined (__mips__) 20 | void _flush_cache (void *address, grub_size_t len, int type); 21 | 22 | void 23 | grub_arch_sync_caches (void *address, grub_size_t len) 24 | { 25 | return _flush_cache (address, len, 0); 26 | } 27 | 28 | #elif defined(__riscv) 29 | void 30 | grub_arch_sync_caches (void *address, grub_size_t len) 31 | { 32 | } 33 | 34 | #endif 35 | 36 | -------------------------------------------------------------------------------- /include/grub/x86_64/io.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2009 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #include 20 | -------------------------------------------------------------------------------- /po/gettext-patches/0004-Use-SHELL-rather-than-bin-sh.patch: -------------------------------------------------------------------------------- 1 | From f36f12e77798223ee7ee882c0d09e0e63db11454 Mon Sep 17 00:00:00 2001 2 | From: Colin Watson 3 | Date: Sun, 1 Mar 2020 12:14:07 +0000 4 | Subject: [PATCH 4/4] Use @SHELL rather than /bin/sh 5 | 6 | /bin/sh might not exist. 7 | --- 8 | gettext-runtime/po/Makefile.in.in | 2 +- 9 | 1 file changed, 1 insertion(+), 1 deletion(-) 10 | 11 | diff --git a/gettext-runtime/po/Makefile.in.in b/gettext-runtime/po/Makefile.in.in 12 | index f3ef54c39..285a55a9d 100644 13 | --- a/gettext-runtime/po/Makefile.in.in 14 | +++ b/gettext-runtime/po/Makefile.in.in 15 | @@ -16,7 +16,7 @@ VERSION = @VERSION@ 16 | PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ 17 | 18 | SED = @SED@ 19 | -SHELL = /bin/sh 20 | +SHELL = @SHELL@ 21 | @SET_MAKE@ 22 | 23 | srcdir = @srcdir@ 24 | -- 25 | 2.17.1 26 | 27 | -------------------------------------------------------------------------------- /grub-core/tests/boot/kernel-8086.S: -------------------------------------------------------------------------------- 1 | 2 | .text 3 | .globl _start 4 | _start: 5 | base: 6 | .code16 7 | jmp cont 8 | 9 | serialmsg: 10 | 1: 11 | movb 0(%si), %bl 12 | testb %bl, %bl 13 | jz 1f 14 | movw $0x3fd, %dx 15 | 2: 16 | inb %dx, %al 17 | testb $0x20, %al 18 | jz 2b 19 | 20 | movw $0x3f8, %dx 21 | movb %bl, %al 22 | outb %al, %dx 23 | incw %si 24 | jmp 1b 25 | 1: 26 | ret 27 | 28 | cont: 29 | #ifdef TARGET_NTLDR 30 | movw $0x2000, %ax 31 | #elif defined (TARGET_CHAINLOADER) 32 | xorw %ax, %ax 33 | #else 34 | #error unsupported target 35 | #endif 36 | movw %ax, %ds 37 | lea message, %si 38 | call serialmsg 39 | #include "qemu-shutdown-x86.S" 40 | 41 | 1: 42 | hlt 43 | jmp 1b 44 | 45 | message: 46 | .ascii "Boot Test Passed Successfully\n" SUCCESSFUL_BOOT_STRING "\n" 47 | .byte 0 48 | 49 | .org 510 50 | .short 0xaa55 51 | -------------------------------------------------------------------------------- /include/grub/x86_64/pci.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2008 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #include 20 | -------------------------------------------------------------------------------- /include/grub/x86_64/linux.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2008 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #include 20 | -------------------------------------------------------------------------------- /tests/grub_func_test.in: -------------------------------------------------------------------------------- 1 | #! @BUILD_SHEBANG@ 2 | set -e 3 | 4 | . "@builddir@/grub-core/modinfo.sh" 5 | 6 | if [ ! -e "@builddir@/"unicode.pf2 ]; then 7 | echo "Functional test requires grub-mkfont support" 8 | exit 99 9 | fi 10 | 11 | case "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" in 12 | # PLATFORM: Max RAM is 256M 13 | mips-qemu_mips | mipsel-qemu_mips) 14 | mem=256M;; 15 | loongarch64-efi) 16 | mem=3G;; 17 | *) 18 | mem=512M;; 19 | esac 20 | 21 | # Increase memory as some of tests are high-resolution and need a lot of memory. 22 | out=`echo all_functional_test | @builddir@/grub-shell --timeout=3600 --files="/boot/grub/fonts/unicode.pf2"="@builddir@/"unicode.pf2 --qemu-opts="-m $mem"` 23 | 24 | if [ "$(echo "$out" | tail -n 1)" != "ALL TESTS PASSED" ]; then 25 | echo "Functional test failure: $out" 26 | exit 1 27 | fi 28 | 29 | -------------------------------------------------------------------------------- /grub-core/lib/libgcrypt/mpi/mips3/README: -------------------------------------------------------------------------------- 1 | This directory contains mpn functions optimized for MIPS3. Example of 2 | processors that implement MIPS3 are R4000, R4400, R4600, R4700, and R8000. 3 | 4 | RELEVANT OPTIMIZATION ISSUES 5 | 6 | 1. On the R4000 and R4400, branches, both the plain and the "likely" ones, 7 | take 3 cycles to execute. (The fastest possible loop will take 4 cycles, 8 | because of the delay insn.) 9 | 10 | On the R4600, branches takes a single cycle 11 | 12 | On the R8000, branches often take no noticable cycles, as they are 13 | executed in a separate function unit.. 14 | 15 | 2. The R4000 and R4400 have a load latency of 4 cycles. 16 | 17 | 3. On the R4000 and R4400, multiplies take a data-dependent number of 18 | cycles, contrary to the SGI documentation. There seem to be 3 or 4 19 | possible latencies. 20 | 21 | STATUS 22 | 23 | Good... 24 | -------------------------------------------------------------------------------- /grub-core/lib/zstd/module.c: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2018 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #include 20 | 21 | GRUB_MOD_LICENSE ("GPLv3"); 22 | -------------------------------------------------------------------------------- /tests/grub_cmd_sleep.in: -------------------------------------------------------------------------------- 1 | #! @BUILD_SHEBANG@ 2 | set -e 3 | 4 | . "@builddir@/grub-core/modinfo.sh" 5 | 6 | # FIXME: OpenBIOS on sparc64 doesn't implement RTC 7 | if [ "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" = sparc64-ieee1275 ]; then 8 | exit 77 9 | fi 10 | 11 | # Compare RTC with interval timer. 12 | # Not 100% proper but should check that timer is running ok 13 | dt=`echo 'date; sleep 10; date' | @builddir@/grub-shell` 14 | dt1="$(date -u -d "$(echo "$dt" | head -n 1 | sed 's, [A-Z][a-z]*$,,')" +%s)" 15 | dt2="$(date -u -d "$(echo "$dt" | tail -n 1 | sed 's, [A-Z][a-z]*$,,')" +%s)" 16 | 17 | # Ignore QEMU bug 18 | if [ "${grub_modinfo_target_cpu}" = arm ] && [ $((dt2 - dt1)) -ge 15 ] && [ $((dt2 - dt1)) -le 17 ]; then 19 | exit 0; 20 | fi 21 | 22 | if [ $((dt2 - dt1)) -gt 11 ] || [ $((dt2 - dt1)) -lt 9 ]; then 23 | echo "Interval not in range $dt2-$dt1 != 10" 24 | exit 1 25 | fi 26 | -------------------------------------------------------------------------------- /tests/grub_cmd_date.in: -------------------------------------------------------------------------------- 1 | #! @BUILD_SHEBANG@ 2 | set -e 3 | 4 | . "@builddir@/grub-core/modinfo.sh" 5 | 6 | # FIXME: OpenBIOS on sparc64 doesn't implement RTC 7 | if [ "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" = sparc64-ieee1275 ]; then 8 | exit 77 9 | fi 10 | 11 | pdt="$(date -u +%s)" 12 | dt="$(echo date | @builddir@/grub-shell)" 13 | dt="$(echo "$dt" | sed 's, [A-Z][a-z]*$,,')" 14 | dtg="$(date -u -d "$dt" +%s)" 15 | ndt="$(date -u +%s)" 16 | 17 | if [ $pdt -gt $dtg ] || [ $dtg -gt $ndt ]; then 18 | echo "Date not in range: $pdt <= $dtg <= $ndt" 19 | exit 1 20 | fi 21 | 22 | pdt="$(date -u +%s)" 23 | dt=`echo 'insmod datehook; echo $YEAR-$MONTH-$DAY $HOUR:$MINUTE:$SECOND' | @builddir@/grub-shell` 24 | dtg="$(date -u -d "$dt" +%s)" 25 | ndt="$(date -u +%s)" 26 | 27 | if [ $pdt -gt $dtg ] || [ $dtg -gt $ndt ]; then 28 | echo "Date not in range: $pdt <= $dtg <= $ndt" 29 | exit 1 30 | fi 31 | -------------------------------------------------------------------------------- /tests/grub_script_comments.in: -------------------------------------------------------------------------------- 1 | #! @builddir@/grub-shell-tester 2 | # 3 | # Copyright (C) 2010 Free Software Foundation, Inc. 4 | # 5 | # GRUB is free software: you can redistribute it and/or modify 6 | # it under the terms of the GNU General Public License as published by 7 | # the Free Software Foundation, either version 3 of the License, or 8 | # (at your option) any later version. 9 | # 10 | # GRUB is distributed in the hope that it will be useful, 11 | # but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | # GNU General Public License for more details. 14 | # 15 | # You should have received a copy of the GNU General Public License 16 | # along with GRUB. If not, see . 17 | 18 | echo a###b 19 | echo a# #b 20 | 21 | echo # 22 | echo \# 23 | 24 | echo '#' 25 | echo "#" 26 | 27 | echo '\#' 28 | echo "\#" 29 | -------------------------------------------------------------------------------- /grub-core/lib/setjmp.S: -------------------------------------------------------------------------------- 1 | /* An executable stack is not required for these functions. */ 2 | #if defined (__linux__) && defined (__ELF__) 3 | .section .note.GNU-stack,"",%progbits 4 | #endif 5 | #if defined(__i386__) 6 | #include "./i386/setjmp.S" 7 | #elif defined(__x86_64__) 8 | #include "./x86_64/setjmp.S" 9 | #elif defined(__sparc__) 10 | #include "./sparc64/setjmp.S" 11 | #elif defined(__mips__) 12 | #include "./mips/setjmp.S" 13 | #elif defined(__powerpc__) || defined(__PPC__) 14 | #include "./powerpc/setjmp.S" 15 | #elif defined(__ia64__) 16 | #include "./ia64/setjmp.S" 17 | #include "./ia64/longjmp.S" 18 | #elif defined(__arm__) 19 | #include "./arm/setjmp.S" 20 | #elif defined(__aarch64__) 21 | #include "./arm64/setjmp.S" 22 | #elif defined(__loongarch_lp64) 23 | #include "./loongarch64/setjmp.S" 24 | #elif defined(__riscv) 25 | #include "./riscv/setjmp.S" 26 | #else 27 | #error "Unknown target cpu type" 28 | #endif 29 | -------------------------------------------------------------------------------- /include/grub/powerpc/kernel.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2005,2006,2007,2008 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef GRUB_KERNEL_CPU_HEADER 20 | #define GRUB_KERNEL_CPU_HEADER 1 21 | 22 | #endif 23 | -------------------------------------------------------------------------------- /tests/grub_cmd_set_date.in: -------------------------------------------------------------------------------- 1 | #! @BUILD_SHEBANG@ 2 | set -e 3 | 4 | . "@builddir@/grub-core/modinfo.sh" 5 | 6 | case "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" in 7 | # FIXME: OpenBIOS on sparc64 doesn't implement RTC 8 | sparc64-ieee1275) 9 | exit 77;; 10 | # PLATFORM: ARC doesn't provide any way to set time 11 | *-arc) 12 | exit 77;; 13 | # PLATFORM: EMU doesn't provide any way to set time 14 | # Even if it did we'd need some kind of sandbox to avoid 15 | # modifying real system time. 16 | *-emu) 17 | exit 77;; 18 | esac 19 | 20 | out=$(cat <. 17 | 18 | if [ "x$1" = "x" ]; then 19 | echo "Filename required". 20 | fi 21 | 22 | ioreg -lw0 -p IODeviceTree -n efi -r -x |grep device-properties | sed 's/.*.*//;' | xxd -r -p > $1 23 | -------------------------------------------------------------------------------- /tests/grub_script_strcmp.in: -------------------------------------------------------------------------------- 1 | #! @builddir@/grub-shell-tester 2 | # 3 | # Copyright (C) 2012 Free Software Foundation, Inc. 4 | # 5 | # GRUB is free software: you can redistribute it and/or modify 6 | # it under the terms of the GNU General Public License as published by 7 | # the Free Software Foundation, either version 3 of the License, or 8 | # (at your option) any later version. 9 | # 10 | # GRUB is distributed in the hope that it will be useful, 11 | # but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | # GNU General Public License for more details. 14 | # 15 | # You should have received a copy of the GNU General Public License 16 | # along with GRUB. If not, see . 17 | 18 | LC_ALL=C 19 | export LC_ALL 20 | 21 | if [ "z" "<" "â" ]; then echo unsigned; else echo signed; fi 22 | if [ "z" ">" "â" ]; then echo signed; else echo unsigned; fi 23 | -------------------------------------------------------------------------------- /util/grub.d/08_fallback_counting.in: -------------------------------------------------------------------------------- 1 | #! /bin/sh -e 2 | # Fallback Countdown 3 | # 4 | # This snippet depends on 10_reset_boot_success and needs to be kept in sync. 5 | # 6 | # The boot_counter env var can be used to count down boot attempts after an 7 | # OSTree upgrade and choose the rollback deployment when 0 is reached. 8 | # Both boot_counter=X and boot_success=1 need to be set from userspace. 9 | cat << EOF 10 | insmod increment 11 | # Check if boot_counter exists and boot_success=0 to activate this behaviour. 12 | if [ -n "\${boot_counter}" -a "\${boot_success}" = "0" ]; then 13 | # if countdown has ended, choose to boot rollback deployment, 14 | # i.e. default=1 on OSTree-based systems. 15 | if [ "\${boot_counter}" = "0" -o "\${boot_counter}" = "-1" ]; then 16 | set default=1 17 | set boot_counter=-1 18 | # otherwise decrement boot_counter 19 | else 20 | decrement boot_counter 21 | fi 22 | save_env boot_counter 23 | fi 24 | EOF 25 | -------------------------------------------------------------------------------- /grub-core/lib/emu/halt.c: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2003,2004,2005,2006,2007,2008,2009,2010 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #include 20 | 21 | void 22 | grub_halt (void) 23 | { 24 | grub_reboot (); 25 | } 26 | -------------------------------------------------------------------------------- /util/grub.d/10_reset_boot_success.in: -------------------------------------------------------------------------------- 1 | #! /bin/sh -e 2 | # Reset Boot Success 3 | # 4 | # The 08_fallback_counting and 12_menu_auto_hide snippets rely on this one 5 | # and need to be kept in sync. 6 | # 7 | # The boot_success var needs to be set to 1 from userspace to mark a boot successful. 8 | cat << EOF 9 | # Hiding the menu is ok if last boot was ok or if this is a first boot attempt to boot the entry 10 | if [ "\${boot_success}" = "1" -o "\${boot_indeterminate}" = "1" ]; then 11 | set menu_hide_ok=1 12 | else 13 | set menu_hide_ok=0 14 | fi 15 | # Reset boot_indeterminate after a successful boot 16 | if [ "\${boot_success}" = "1" ] ; then 17 | set boot_indeterminate=0 18 | # Avoid boot_indeterminate causing the menu to be hidden more than once 19 | elif [ "\${boot_indeterminate}" = "1" ]; then 20 | set boot_indeterminate=2 21 | fi 22 | # Reset boot_success for current boot 23 | set boot_success=0 24 | save_env boot_success boot_indeterminate 25 | EOF 26 | -------------------------------------------------------------------------------- /grub-core/efiemu/prepare32.c: -------------------------------------------------------------------------------- 1 | /* This file contains definitions so that prepare.c compiles for 32-bit */ 2 | /* 3 | * GRUB -- GRand Unified Bootloader 4 | * Copyright (C) 2009 Free Software Foundation, Inc. 5 | * 6 | * GRUB is free software: you can redistribute it and/or modify 7 | * it under the terms of the GNU General Public License as published by 8 | * the Free Software Foundation, either version 3 of the License, or 9 | * (at your option) any later version. 10 | * 11 | * GRUB is distributed in the hope that it will be useful, 12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | * GNU General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU General Public License 17 | * along with GRUB. If not, see . 18 | */ 19 | 20 | #define SUFFIX(x) x ## 32 21 | 22 | #include "prepare.c" 23 | -------------------------------------------------------------------------------- /grub-core/efiemu/prepare64.c: -------------------------------------------------------------------------------- 1 | /* This file contains definitions so that prepare.c compiles for 64-bit */ 2 | /* 3 | * GRUB -- GRand Unified Bootloader 4 | * Copyright (C) 2009 Free Software Foundation, Inc. 5 | * 6 | * GRUB is free software: you can redistribute it and/or modify 7 | * it under the terms of the GNU General Public License as published by 8 | * the Free Software Foundation, either version 3 of the License, or 9 | * (at your option) any later version. 10 | * 11 | * GRUB is distributed in the hope that it will be useful, 12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | * GNU General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU General Public License 17 | * along with GRUB. If not, see . 18 | */ 19 | 20 | #define SUFFIX(x) x ## 64 21 | 22 | #include "prepare.c" 23 | -------------------------------------------------------------------------------- /include/grub/ia64/efi/time.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2008 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | #ifndef GRUB_MACHINE_TIME_HEADER 19 | #define GRUB_MACHINE_TIME_HEADER 1 20 | 21 | #include 22 | 23 | #endif /* ! GRUB_MACHINE_TIME_HEADER */ 24 | -------------------------------------------------------------------------------- /util/grub.d/25_bli.in: -------------------------------------------------------------------------------- 1 | #! /bin/sh 2 | set -e 3 | 4 | # grub-mkconfig helper script. 5 | # Copyright (C) 2023 Free Software Foundation, Inc. 6 | # 7 | # GRUB is free software: you can redistribute it and/or modify 8 | # it under the terms of the GNU General Public License as published by 9 | # the Free Software Foundation, either version 3 of the License, or 10 | # (at your option) any later version. 11 | # 12 | # GRUB is distributed in the hope that it will be useful, 13 | # but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 | # GNU General Public License for more details. 16 | # 17 | # You should have received a copy of the GNU General Public License 18 | # along with GRUB. If not, see . 19 | 20 | cat << EOF 21 | if [ "\$grub_platform" = "efi" ]; then 22 | if [ ! insmod bli ]; then 23 | echo "bli module not available" 24 | fi 25 | fi 26 | EOF 27 | -------------------------------------------------------------------------------- /include/grub/mips/qemu_mips/serial.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2009 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef GRUB_MACHINE_SERIAL_HEADER 20 | #define GRUB_MACHINE_SERIAL_HEADER 1 21 | 22 | #define GRUB_MACHINE_SERIAL_PORTS { 0xb40003f8 } 23 | 24 | #endif 25 | -------------------------------------------------------------------------------- /grub-core/efiemu/loadcore32.c: -------------------------------------------------------------------------------- 1 | /* This file contains definitions so that loadcore.c compiles for 32-bit */ 2 | /* 3 | * GRUB -- GRand Unified Bootloader 4 | * Copyright (C) 2009 Free Software Foundation, Inc. 5 | * 6 | * GRUB is free software: you can redistribute it and/or modify 7 | * it under the terms of the GNU General Public License as published by 8 | * the Free Software Foundation, either version 3 of the License, or 9 | * (at your option) any later version. 10 | * 11 | * GRUB is distributed in the hope that it will be useful, 12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | * GNU General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU General Public License 17 | * along with GRUB. If not, see . 18 | */ 19 | 20 | #define SUFFIX(x) x ## 32 21 | #define GRUB_TARGET_WORDSIZE 32 22 | #include "loadcore.c" 23 | -------------------------------------------------------------------------------- /grub-core/efiemu/loadcore64.c: -------------------------------------------------------------------------------- 1 | /* This file contains definitions so that loadcore.c compiles for 64-bit */ 2 | /* 3 | * GRUB -- GRand Unified Bootloader 4 | * Copyright (C) 2009 Free Software Foundation, Inc. 5 | * 6 | * GRUB is free software: you can redistribute it and/or modify 7 | * it under the terms of the GNU General Public License as published by 8 | * the Free Software Foundation, either version 3 of the License, or 9 | * (at your option) any later version. 10 | * 11 | * GRUB is distributed in the hope that it will be useful, 12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | * GNU General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU General Public License 17 | * along with GRUB. If not, see . 18 | */ 19 | 20 | #define SUFFIX(x) x ## 64 21 | #define GRUB_TARGET_WORDSIZE 64 22 | #include "loadcore.c" 23 | -------------------------------------------------------------------------------- /grub-core/lib/mips/qemu_mips/reboot.c: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2011 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #include 20 | #include 21 | 22 | void 23 | grub_reboot (void) 24 | { 25 | grub_outl (42, 0xbfbf0000); 26 | while (1); 27 | } 28 | -------------------------------------------------------------------------------- /include/grub/arm/efi/console.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2002,2005,2006,2007 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef GRUB_ARM_EFI_CONSOLE_H 20 | #define GRUB_ARM_EFI_CONSOLE_H 21 | 22 | #include 23 | 24 | #endif /* ! GRUB_ARM_EFI_CONSOLE_H */ 25 | -------------------------------------------------------------------------------- /include/grub/ieee1275/obdisk.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2019 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef GRUB_OBDISK_HEADER 20 | #define GRUB_OBDISK_HEADER 1 21 | 22 | extern void grub_obdisk_init (void); 23 | extern void grub_obdisk_fini (void); 24 | 25 | #endif 26 | -------------------------------------------------------------------------------- /include/grub/arm64/efi/console.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2002,2005,2006,2007 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef GRUB_ARM64_EFI_CONSOLE_H 20 | #define GRUB_ARM64_EFI_CONSOLE_H 21 | 22 | #include 23 | 24 | #endif /* ! GRUB_ARM64_EFI_CONSOLE_H */ 25 | -------------------------------------------------------------------------------- /include/grub/i386/efi/console.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2002,2005,2006,2007 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef GRUB_I386_EFI_CONSOLE_H 20 | #define GRUB_I386_EFI_CONSOLE_H 21 | 22 | #include 23 | 24 | #endif /* ! GRUB_I386_EFI_CONSOLE_H */ 25 | -------------------------------------------------------------------------------- /include/grub/mips/kernel.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2005,2006,2007,2008,2009 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef GRUB_KERNEL_CPU_HEADER 20 | #define GRUB_KERNEL_CPU_HEADER 1 21 | 22 | #include 23 | 24 | #endif /* ! GRUB_KERNEL_MACHINE_HEADER */ 25 | -------------------------------------------------------------------------------- /include/grub/i386/coreboot/serial.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2009 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef GRUB_MACHINE_SERIAL_HEADER 20 | #define GRUB_MACHINE_SERIAL_HEADER 1 21 | 22 | #define GRUB_MACHINE_SERIAL_PORTS { 0x3f8, 0x2f8, 0x3e8, 0x2e8 } 23 | 24 | #endif 25 | -------------------------------------------------------------------------------- /include/grub/i386/pc/time.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2003,2004,2005,2007 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef KERNEL_MACHINE_TIME_HEADER 20 | #define KERNEL_MACHINE_TIME_HEADER 1 21 | 22 | #include 23 | 24 | #endif /* ! KERNEL_MACHINE_TIME_HEADER */ 25 | -------------------------------------------------------------------------------- /include/grub/x86_64/efi/console.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2002,2005,2006,2007 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef GRUB_X86_64_EFI_CONSOLE_H 20 | #define GRUB_X86_64_EFI_CONSOLE_H 21 | 22 | #include 23 | 24 | #endif /* ! GRUB_X86_64_EFI_CONSOLE_H */ 25 | -------------------------------------------------------------------------------- /include/grub/i386/reboot.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2011 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef GRUB_REBOOT_H 20 | #define GRUB_REBOOT_H 1 21 | 22 | #ifndef ASM_FILE 23 | 24 | extern grub_uint8_t grub_reboot_end[], grub_reboot_start[]; 25 | 26 | #endif 27 | 28 | #endif 29 | -------------------------------------------------------------------------------- /include/grub/ia64/kernel.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2010 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef GRUB_CPU_KERNEL_HEADER 20 | #define GRUB_CPU_KERNEL_HEADER 1 21 | 22 | #define GRUB_MOD_ALIGN 0x1 23 | #define GRUB_MOD_GAP 0x0 24 | 25 | #endif /* ! GRUB_CPU_KERNEL_HEADER */ 26 | -------------------------------------------------------------------------------- /include/grub/loongarch64/efi/memory.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2023 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef GRUB_MEMORY_CPU_HEADER 20 | #include 21 | 22 | #define GRUB_EFI_MAX_USABLE_ADDRESS 0xfffffffffffULL 23 | 24 | #endif /* ! GRUB_MEMORY_CPU_HEADER */ 25 | -------------------------------------------------------------------------------- /grub-core/lib/ieee1275/reboot.c: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2011 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #include 20 | #include 21 | 22 | void 23 | grub_reboot (void) 24 | { 25 | grub_ieee1275_interpret ("reset-all", 0); 26 | for (;;) ; 27 | } 28 | -------------------------------------------------------------------------------- /include/grub/i386/at_keyboard.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2007,2008,2009 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef GRUB_CPU_AT_KEYBOARD_HEADER 20 | #define GRUB_CPU_AT_KEYBOARD_HEADER 1 21 | 22 | #define KEYBOARD_REG_DATA 0x60 23 | #define KEYBOARD_REG_STATUS 0x64 24 | 25 | #endif 26 | -------------------------------------------------------------------------------- /include/grub/loongarch64/time.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2023 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef KERNEL_CPU_TIME_HEADER 20 | #define KERNEL_CPU_TIME_HEADER 1 21 | 22 | static inline void 23 | grub_cpu_idle(void) 24 | { 25 | asm volatile ("idle 0"); 26 | } 27 | 28 | #endif 29 | -------------------------------------------------------------------------------- /tests/test_sha512sum.in: -------------------------------------------------------------------------------- 1 | #! @BUILD_SHEBANG@ 2 | set -e 3 | 4 | # create a randome file 5 | file="`mktemp "${TMPDIR:-/tmp}/tmp.XXXXXXXXXX"`" || exit 99 6 | cat >$file <$outfile1 <$outfile2 26 | 27 | SHA1=`cat $outfile1 | tr -d '\n' | cut -f1 -d\ ` 28 | SHA2=`cat $outfile2 | cut -f1 -d\ ` 29 | 30 | if test "$SHA1" = "$SHA2"; then 31 | rm -f ${outfile1} ${outfile2} 32 | exit 0 33 | else 34 | echo "GRUB sha512sum output did not match sha512sum output." 35 | echo "See diff -u ${outfile1} ${outfile2}" 36 | exit 1 37 | fi 38 | -------------------------------------------------------------------------------- /include/grub/lib/crc.h: -------------------------------------------------------------------------------- 1 | /* crc.h - prototypes for crc */ 2 | /* 3 | * GRUB -- GRand Unified Bootloader 4 | * Copyright (C) 2008 Free Software Foundation, Inc. 5 | * 6 | * GRUB is free software: you can redistribute it and/or modify 7 | * it under the terms of the GNU General Public License as published by 8 | * the Free Software Foundation, either version 3 of the License, or 9 | * (at your option) any later version. 10 | * 11 | * GRUB is distributed in the hope that it will be useful, 12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | * GNU General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU General Public License 17 | * along with GRUB. If not, see . 18 | */ 19 | 20 | #ifndef GRUB_CRC_H 21 | #define GRUB_CRC_H 1 22 | 23 | grub_uint32_t grub_getcrc32c (grub_uint32_t crc, const void *buf, int size); 24 | 25 | #endif /* ! GRUB_CRC_H */ 26 | -------------------------------------------------------------------------------- /include/grub/lib/hexdump.h: -------------------------------------------------------------------------------- 1 | /* hexdump.h - prototypes for dump */ 2 | /* 3 | * GRUB -- GRand Unified Bootloader 4 | * Copyright (C) 2007 Free Software Foundation, Inc. 5 | * 6 | * GRUB is free software: you can redistribute it and/or modify 7 | * it under the terms of the GNU General Public License as published by 8 | * the Free Software Foundation, either version 3 of the License, or 9 | * (at your option) any later version. 10 | * 11 | * GRUB is distributed in the hope that it will be useful, 12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | * GNU General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU General Public License 17 | * along with GRUB. If not, see . 18 | */ 19 | 20 | #ifndef GRUB_HEXDUMP_H 21 | #define GRUB_HEXDUMP_H 1 22 | 23 | void hexdump (unsigned long bse,char* buf,int len); 24 | 25 | #endif /* ! GRUB_HEXDUMP_H */ 26 | -------------------------------------------------------------------------------- /include/grub/riscv32/time.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2018 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef KERNEL_CPU_TIME_HEADER 20 | #define KERNEL_CPU_TIME_HEADER 1 21 | 22 | static __inline void 23 | grub_cpu_idle (void) 24 | { 25 | /* TODO */ 26 | } 27 | 28 | #endif /* ! KERNEL_CPU_TIME_HEADER */ 29 | -------------------------------------------------------------------------------- /include/grub/riscv64/time.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2018 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef KERNEL_CPU_TIME_HEADER 20 | #define KERNEL_CPU_TIME_HEADER 1 21 | 22 | static __inline void 23 | grub_cpu_idle (void) 24 | { 25 | /* TODO */ 26 | } 27 | 28 | #endif /* ! KERNEL_CPU_TIME_HEADER */ 29 | -------------------------------------------------------------------------------- /tests/grub_script_vars1.in: -------------------------------------------------------------------------------- 1 | #! @builddir@/grub-shell-tester 2 | 3 | # Run GRUB script in a Qemu instance 4 | # Copyright (C) 2010 Free Software Foundation, Inc. 5 | # 6 | # GRUB is free software: you can redistribute it and/or modify 7 | # it under the terms of the GNU General Public License as published by 8 | # the Free Software Foundation, either version 3 of the License, or 9 | # (at your option) any later version. 10 | # 11 | # GRUB is distributed in the hope that it will be useful, 12 | # but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | # GNU General Public License for more details. 15 | # 16 | # You should have received a copy of the GNU General Public License 17 | # along with GRUB. If not, see . 18 | 19 | var=foo 20 | echo $var 21 | echo "$var" 22 | echo ${var} 23 | echo "${var}" 24 | 25 | echo $1 $2 $? 26 | 27 | foo=foo 28 | echo "" $foo 29 | 30 | echo $bar $foo 31 | 32 | bar="" 33 | echo $bar $foo 34 | 35 | -------------------------------------------------------------------------------- /grub-core/lib/posix_wrap/localcharset.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2009, 2010 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef GRUB_POSIX_LOCALCHARSET_H 20 | #define GRUB_POSIX_LOCALCHARSET_H 1 21 | 22 | static inline const char * 23 | locale_charset (void) 24 | { 25 | return "UTF-8"; 26 | } 27 | 28 | #endif 29 | -------------------------------------------------------------------------------- /include/grub/i386/qemu/boot.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2009 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef GRUB_BOOT_MACHINE_HEADER 20 | #define GRUB_BOOT_MACHINE_HEADER 1 21 | 22 | /* The size of boot.img. */ 23 | #define GRUB_BOOT_MACHINE_SIZE (0x100000 - GRUB_BOOT_MACHINE_LINK_ADDR) 24 | 25 | #endif 26 | -------------------------------------------------------------------------------- /grub-core/kern/powerpc/cache.S: -------------------------------------------------------------------------------- 1 | /* cache.S - Flush the processor cache for a specific region. */ 2 | /* 3 | * GRUB -- GRand Unified Bootloader 4 | * Copyright (C) 2004,2007,2010 Free Software Foundation, Inc. 5 | * 6 | * GRUB is free software: you can redistribute it and/or modify 7 | * it under the terms of the GNU General Public License as published by 8 | * the Free Software Foundation, either version 3 of the License, or 9 | * (at your option) any later version. 10 | * 11 | * GRUB is distributed in the hope that it will be useful, 12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | * GNU General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU General Public License 17 | * along with GRUB. If not, see . 18 | */ 19 | 20 | .text 21 | 22 | .align 2 23 | .globl grub_arch_sync_caches 24 | grub_arch_sync_caches: 25 | #include "cache_flush.S" 26 | blr 27 | -------------------------------------------------------------------------------- /include/grub/mips/qemu_mips/at_keyboard.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2007,2008,2009 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef GRUB_MACHINE_AT_KEYBOARD_HEADER 20 | #define GRUB_MACHINE_AT_KEYBOARD_HEADER 1 21 | 22 | #define KEYBOARD_REG_DATA 0xb4000060 23 | #define KEYBOARD_REG_STATUS 0xb4000064 24 | 25 | #endif 26 | -------------------------------------------------------------------------------- /include/grub/mips/qemu_mips/console.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2009 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef GRUB_MACHINE_CONSOLE_HEADER 20 | #define GRUB_MACHINE_CONSOLE_HEADER 1 21 | 22 | void grub_vga_text_init (void); 23 | void grub_vga_text_fini (void); 24 | 25 | #endif /* ! GRUB_MACHINE_CONSOLE_HEADER */ 26 | -------------------------------------------------------------------------------- /include/grub/mips/qemu_mips/time.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2003,2004,2005,2007 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef KERNEL_MACHINE_TIME_HEADER 20 | #define KERNEL_MACHINE_TIME_HEADER 1 21 | 22 | #include 23 | #include 24 | 25 | #endif /* ! KERNEL_MACHINE_TIME_HEADER */ 26 | -------------------------------------------------------------------------------- /include/grub/powerpc/time.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2007 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef KERNEL_CPU_TIME_HEADER 20 | #define KERNEL_CPU_TIME_HEADER 1 21 | 22 | static __inline void 23 | grub_cpu_idle (void) 24 | { 25 | /* FIXME: not implemented */ 26 | } 27 | 28 | #endif /* ! KERNEL_CPU_TIME_HEADER */ 29 | -------------------------------------------------------------------------------- /include/grub/sparc64/time.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2007 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef KERNEL_CPU_TIME_HEADER 20 | #define KERNEL_CPU_TIME_HEADER 1 21 | 22 | static __inline void 23 | grub_cpu_idle (void) 24 | { 25 | /* FIXME: not implemented */ 26 | } 27 | 28 | #endif /* ! KERNEL_CPU_TIME_HEADER */ 29 | -------------------------------------------------------------------------------- /include/grub/x86_64/efi/loader.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2002,2003,2004,2006,2007 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef GRUB_LOADER_MACHINE_HEADER 20 | #define GRUB_LOADER_MACHINE_HEADER 1 21 | 22 | #include 23 | #include 24 | 25 | 26 | #endif /* ! GRUB_LOADER_MACHINE_HEADER */ 27 | -------------------------------------------------------------------------------- /include/grub/fileid.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2013 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef GRUB_FILEID_HEADER 20 | #define GRUB_FILEID_HEADER 1 21 | 22 | #include 23 | 24 | int 25 | grub_file_check_netbsd32 (grub_elf_t elf); 26 | int 27 | grub_file_check_netbsd64 (grub_elf_t elf); 28 | 29 | #endif 30 | -------------------------------------------------------------------------------- /include/grub/ia64/time.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2007, 2008 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef KERNEL_CPU_TIME_HEADER 20 | #define KERNEL_CPU_TIME_HEADER 1 21 | 22 | static __inline void 23 | grub_cpu_idle (void) 24 | { 25 | /* FIXME: not implemented */ 26 | } 27 | 28 | #endif /* ! KERNEL_CPU_TIME_HEADER */ 29 | -------------------------------------------------------------------------------- /util/grub.d/12_menu_auto_hide.in: -------------------------------------------------------------------------------- 1 | #! /bin/sh 2 | # Menu Auto Hide 3 | # 4 | # This snippet depends on 10_reset_boot_success and needs to be kept in sync. 5 | # 6 | # Disable / skip generating menu-auto-hide config parts on serial terminals 7 | for x in ${GRUB_TERMINAL_INPUT} ${GRUB_TERMINAL_OUTPUT}; do 8 | case "$x" in 9 | serial*) 10 | exit 0 11 | ;; 12 | esac 13 | done 14 | 15 | cat << EOF 16 | if [ x\$feature_timeout_style = xy ] ; then 17 | if [ "\${menu_show_once}" ]; then 18 | unset menu_show_once 19 | save_env menu_show_once 20 | set timeout_style=menu 21 | set timeout=60 22 | elif [ "\${menu_auto_hide}" -a "\${menu_hide_ok}" = "1" ]; then 23 | set orig_timeout_style=\${timeout_style} 24 | set orig_timeout=\${timeout} 25 | if [ "\${fastboot}" = "1" ]; then 26 | # timeout_style=menu + timeout=0 avoids the countdown code keypress check 27 | set timeout_style=menu 28 | set timeout=0 29 | else 30 | set timeout_style=hidden 31 | set timeout=1 32 | fi 33 | fi 34 | fi 35 | EOF 36 | -------------------------------------------------------------------------------- /grub-core/lib/libtasn1_wrap/wrap.c: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2020 IBM Corporation 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #include 20 | 21 | /* 22 | * libtasn1 is provided under LGPL2.1+, which is compatible 23 | * with GPL3+. As Grub as a whole is under GPL3+, this module 24 | * is therefore under GPL3+ also. 25 | */ 26 | GRUB_MOD_LICENSE ("GPLv3+"); 27 | -------------------------------------------------------------------------------- /grub-core/lib/libtasn1_wrap/tests/CVE-2018-1000654-1_asn1_tab.h: -------------------------------------------------------------------------------- 1 | #if HAVE_CONFIG_H 2 | # include "config.h" 3 | #endif 4 | 5 | #include 6 | 7 | const asn1_static_node CVE_2018_1000654_1_asn1_tab[] = { 8 | { "TEST_TREE", 536875024, NULL }, 9 | { NULL, 1610612748, NULL }, 10 | { "iso", 1073741825, "1"}, 11 | { "identified-organization", 1073741825, "3"}, 12 | { "dod", 1073741825, "6"}, 13 | { "internet", 1073741825, "1"}, 14 | { "security", 1073741825, "5"}, 15 | { "mechanisms", 1073741825, "5"}, 16 | { "pkix", 1073741825, "7"}, 17 | { "id-mod", 1073741825, "0"}, 18 | { "id-pkix1-implicit-88", 1, "2"}, 19 | { "id-xnyTest", 1879048204, NULL }, 20 | { NULL, 1073741825, "id-ix"}, 21 | { NULL, 1073741825, "29"}, 22 | { NULL, 1, "1"}, 23 | { "id-ix", 1880096780, "OBJECR"}, 24 | { NULL, 1073741825, "id-ix"}, 25 | { NULL, 1073741825, "29"}, 26 | { NULL, 1, "2"}, 27 | { "id-xnyTest", 805306380, NULL }, 28 | { NULL, 1073741825, "id-ix"}, 29 | { NULL, 1073741825, "29"}, 30 | { NULL, 1, "1"}, 31 | { NULL, 0, NULL } 32 | }; 33 | -------------------------------------------------------------------------------- /grub-core/efiemu/i386/coredetect.c: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2009 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #include 20 | #include 21 | #include 22 | 23 | const char * 24 | grub_efiemu_get_default_core_name (void) 25 | { 26 | return grub_cpuid_has_longmode ? "efiemu64.o" : "efiemu32.o"; 27 | } 28 | -------------------------------------------------------------------------------- /include/grub/tparm.h: -------------------------------------------------------------------------------- 1 | /* tparm.h - parameter formatting of terminfo */ 2 | /* 3 | * GRUB -- GRand Unified Bootloader 4 | * Copyright (C) 2002,2005,2007 Free Software Foundation, Inc. 5 | * 6 | * GRUB is free software: you can redistribute it and/or modify 7 | * it under the terms of the GNU General Public License as published by 8 | * the Free Software Foundation, either version 3 of the License, or 9 | * (at your option) any later version. 10 | * 11 | * GRUB is distributed in the hope that it will be useful, 12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | * GNU General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU General Public License 17 | * along with GRUB. If not, see . 18 | */ 19 | 20 | #ifndef GRUB_TPARM_HEADER 21 | #define GRUB_TPARM_HEADER 1 22 | 23 | /* Function prototypes. */ 24 | const char *grub_terminfo_tparm (const char *string, ...); 25 | 26 | #endif /* ! GRUB_TPARM_HEADER */ 27 | -------------------------------------------------------------------------------- /include/grub/udf.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2013 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef GRUB_UDF_H 20 | #define GRUB_UDF_H 1 21 | 22 | #include 23 | 24 | #ifdef GRUB_UTIL 25 | #include 26 | 27 | grub_disk_addr_t 28 | grub_udf_get_cluster_sector (grub_disk_t disk, grub_uint64_t *sec_per_lcn); 29 | #endif 30 | #endif 31 | -------------------------------------------------------------------------------- /grub-core/lib/dummy/halt.c: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2013 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #include 20 | #include 21 | #include 22 | #include 23 | 24 | void 25 | grub_halt (void) 26 | { 27 | grub_machine_fini (GRUB_LOADER_FLAG_NORETURN); 28 | 29 | /* Just stop here */ 30 | 31 | while (1); 32 | } 33 | -------------------------------------------------------------------------------- /grub-core/osdep/basic/platform.c: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2013 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #include 20 | 21 | const char * 22 | grub_install_get_default_arm_platform (void) 23 | { 24 | return "arm-uboot"; 25 | } 26 | 27 | const char * 28 | grub_install_get_default_x86_platform (void) 29 | { 30 | return "i386-pc"; 31 | } 32 | 33 | -------------------------------------------------------------------------------- /grub-core/lib/dummy/reboot.c: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2013 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #include 20 | #include 21 | #include 22 | #include 23 | 24 | void 25 | grub_reboot (void) 26 | { 27 | grub_machine_fini (GRUB_LOADER_FLAG_NORETURN); 28 | 29 | /* Just stop here */ 30 | 31 | while (1); 32 | } 33 | -------------------------------------------------------------------------------- /grub-core/lib/uboot/reboot.c: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2013 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #include 20 | #include 21 | #include 22 | #include 23 | 24 | void 25 | grub_reboot (void) 26 | { 27 | grub_machine_fini (GRUB_LOADER_FLAG_NORETURN); 28 | 29 | grub_uboot_reset (); 30 | while (1); 31 | } 32 | -------------------------------------------------------------------------------- /include/grub/i386/pc/chainloader.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2004,2007 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef GRUB_CHAINLOADER_MACHINE_HEADER 20 | #define GRUB_CHAINLOADER_MACHINE_HEADER 1 21 | 22 | #include 23 | 24 | void 25 | grub_chainloader_patch_bpb (void *bs, grub_device_t dev, grub_uint8_t dl); 26 | 27 | #endif /* GRUB_CHAINLOADER_MACHINE_HEADER */ 28 | -------------------------------------------------------------------------------- /grub-core/osdep/windows/sleep.c: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2002,2003,2005,2006,2007,2008,2009,2010,2011,2012,2013 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #include 20 | #include 21 | 22 | #include 23 | #include 24 | #include 25 | 26 | void 27 | grub_millisleep (grub_uint32_t ms) 28 | { 29 | Sleep (ms); 30 | } 31 | 32 | -------------------------------------------------------------------------------- /include/grub/arm/time.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2013 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef KERNEL_CPU_TIME_HEADER 20 | #define KERNEL_CPU_TIME_HEADER 1 21 | 22 | static __inline void 23 | grub_cpu_idle (void) 24 | { 25 | /* FIXME: this can't work until we handle interrupts. */ 26 | /* asm volatile ("wfi"); */ 27 | } 28 | 29 | #endif /* ! KERNEL_CPU_TIME_HEADER */ 30 | -------------------------------------------------------------------------------- /include/grub/arm64/time.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2013 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef KERNEL_CPU_TIME_HEADER 20 | #define KERNEL_CPU_TIME_HEADER 1 21 | 22 | static __inline void 23 | grub_cpu_idle (void) 24 | { 25 | /* FIXME: this can't work until we handle interrupts. */ 26 | /* asm volatile ("wfi"); */ 27 | } 28 | 29 | #endif /* ! KERNEL_CPU_TIME_HEADER */ 30 | -------------------------------------------------------------------------------- /include/grub/i386/time.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2007 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef KERNEL_CPU_TIME_HEADER 20 | #define KERNEL_CPU_TIME_HEADER 1 21 | 22 | static __inline void 23 | grub_cpu_idle (void) 24 | { 25 | /* FIXME: this can't work until we handle interrupts. */ 26 | /* asm volatile ("hlt"); */ 27 | } 28 | 29 | #endif /* ! KERNEL_CPU_TIME_HEADER */ 30 | -------------------------------------------------------------------------------- /include/grub/mips/qemu_mips/kernel.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2005,2006,2007,2008,2009 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef GRUB_KERNEL_MACHINE_HEADER 20 | #define GRUB_KERNEL_MACHINE_HEADER 1 21 | 22 | #include 23 | 24 | #ifndef ASM_FILE 25 | 26 | void grub_qemu_init_cirrus (void); 27 | 28 | #endif 29 | 30 | #endif /* ! GRUB_KERNEL_MACHINE_HEADER */ 31 | -------------------------------------------------------------------------------- /include/grub/x86_64/time.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2007 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef KERNEL_CPU_TIME_HEADER 20 | #define KERNEL_CPU_TIME_HEADER 1 21 | 22 | static __inline void 23 | grub_cpu_idle (void) 24 | { 25 | /* FIXME: this can't work until we handle interrupts. */ 26 | /* asm volatile ("hlt"); */ 27 | } 28 | 29 | #endif /* ! KERNEL_CPU_TIME_HEADER */ 30 | -------------------------------------------------------------------------------- /include/grub/emu/console.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2009 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef GRUB_CONSOLE_UTIL_HEADER 20 | #define GRUB_CONSOLE_UTIL_HEADER 1 21 | 22 | /* Initialize the console system. */ 23 | void grub_console_init (void); 24 | 25 | /* Finish the console system. */ 26 | void grub_console_fini (void); 27 | 28 | #endif /* ! GRUB_CONSOLE_UTIL_HEADER */ 29 | -------------------------------------------------------------------------------- /include/grub/loopback.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2019 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef GRUB_LOOPBACK_HEADER 20 | #define GRUB_LOOPBACK_HEADER 1 21 | 22 | struct grub_loopback 23 | { 24 | char *devname; 25 | grub_file_t file; 26 | struct grub_loopback *next; 27 | unsigned long id; 28 | grub_uint64_t refcnt; 29 | }; 30 | 31 | #endif /* ! GRUB_LOOPBACK_HEADER */ 32 | -------------------------------------------------------------------------------- /po/README: -------------------------------------------------------------------------------- 1 | 2 | If you checked out this source tree directly from GRUB Git, you might be 3 | wondering where are the POT and PO files. Here are some instructions 4 | that will hopefully clarify the situation. 5 | 6 | - If you're a user or a distributor, simply fill the po directory by 7 | importing translations from the Translation Project: 8 | 9 | ./linguas.sh 10 | 11 | GRUB's build system will automatically detect those and include them 12 | in your install. 13 | 14 | - If you're a translator and want to add a new translation or improve an 15 | existing one, get in touch with the Translation Project 16 | (http://translationproject.org/). The GRUB project doesn't interact 17 | with translators directly (but we dearly appreciate your work!). 18 | 19 | - If you're a developer adding/removing/modifying translatable strings, 20 | you can check that these turn into a sane POT file by using the 21 | `po/grub.pot' make rule. 22 | 23 | - If you're the maintainer of GNU GRUB preparing a new release, don't 24 | forget to include the latest PO files in your source tarball! 25 | -------------------------------------------------------------------------------- /tests/grub_cmd_echo.in: -------------------------------------------------------------------------------- 1 | #! @builddir@/grub-shell-tester 2 | # 3 | # Copyright (C) 2010 Free Software Foundation, Inc. 4 | # 5 | # GRUB is free software: you can redistribute it and/or modify 6 | # it under the terms of the GNU General Public License as published by 7 | # the Free Software Foundation, either version 3 of the License, or 8 | # (at your option) any later version. 9 | # 10 | # GRUB is distributed in the hope that it will be useful, 11 | # but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | # GNU General Public License for more details. 14 | # 15 | # You should have received a copy of the GNU General Public License 16 | # along with GRUB. If not, see . 17 | 18 | echo 19 | echo -n 20 | 21 | echo foo 22 | echo foo bar 23 | 24 | echo -n foo 25 | 26 | echo -e "foo\nbar" 27 | 28 | echo -n -e "foo\nbar" 29 | 30 | echo foo -n 31 | echo foo -n -e 32 | 33 | echo ------- 34 | 35 | if test -n "$grubshell"; then insmod regexp; fi 36 | 37 | echo '*' 38 | echo "*" 39 | 40 | foo="*" 41 | echo "$foo" 42 | -------------------------------------------------------------------------------- /tests/xzcompress_test.in: -------------------------------------------------------------------------------- 1 | #! @BUILD_SHEBANG@ 2 | # Copyright (C) 2013 Free Software Foundation, Inc. 3 | # 4 | # GRUB is free software: you can redistribute it and/or modify 5 | # it under the terms of the GNU General Public License as published by 6 | # the Free Software Foundation, either version 3 of the License, or 7 | # (at your option) any later version. 8 | # 9 | # GRUB is distributed in the hope that it will be useful, 10 | # but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | # GNU General Public License for more details. 13 | # 14 | # You should have received a copy of the GNU General Public License 15 | # along with GRUB. If not, see . 16 | 17 | set -e 18 | grubshell=@builddir@/grub-shell 19 | 20 | . "@builddir@/grub-core/modinfo.sh" 21 | 22 | if ! which xz >/dev/null 2>&1; then 23 | echo "xz not installed; cannot test xz compression." 24 | exit 99 25 | fi 26 | 27 | v=$(echo hello | "${grubshell}" --mkrescue-arg=--compress=xz) 28 | if [ "$v" != "Hello World" ]; then 29 | exit 1 30 | fi 31 | -------------------------------------------------------------------------------- /conf/i386-cygwin-img-ld.sc: -------------------------------------------------------------------------------- 1 | /* Linker script to create grub .img files on Cygwin. */ 2 | 3 | SECTIONS 4 | { 5 | .text : 6 | { 7 | start = . ; 8 | _start = . ; 9 | __start = . ; 10 | *(.text) 11 | etext = . ; 12 | } 13 | .data : 14 | { 15 | __data_start__ = . ; 16 | *(.data) 17 | /* Do not discard this section. */ 18 | . = . ; 19 | __data_end__ = . ; 20 | __rdata_start__ = . ; 21 | *(.rdata) 22 | __rdata_end__ = . ; 23 | *(.pdata) 24 | edata = . ; 25 | _edata = . ; 26 | __edata = . ; 27 | } 28 | .bss : 29 | { 30 | __bss_start__ = . ; 31 | *(.bss) 32 | __common_start__ = . ; 33 | *(COMMON) 34 | __bss_end__ = . ; 35 | } 36 | .edata : 37 | { 38 | *(.edata) 39 | /* Do not discard this section. */ 40 | . = . ; 41 | end = . ; 42 | _end = . ; 43 | __end = . ; 44 | } 45 | .stab : 46 | { 47 | *(.stab) 48 | } 49 | .stabstr : 50 | { 51 | *(.stabstr) 52 | } 53 | } 54 | 55 | ASSERT("__rdata_end__"=="edata", ".pdata not empty") 56 | ASSERT("__bss_end__" =="end" , ".edata not empty") 57 | 58 | -------------------------------------------------------------------------------- /grub-core/efiemu/i386/nocfgtables.c: -------------------------------------------------------------------------------- 1 | /* Register SMBIOS and ACPI tables. */ 2 | /* 3 | * GRUB -- GRand Unified Bootloader 4 | * Copyright (C) 2009 Free Software Foundation, Inc. 5 | * 6 | * GRUB is free software: you can redistribute it and/or modify 7 | * it under the terms of the GNU General Public License as published by 8 | * the Free Software Foundation, either version 3 of the License, or 9 | * (at your option) any later version. 10 | * 11 | * GRUB is distributed in the hope that it will be useful, 12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | * GNU General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU General Public License 17 | * along with GRUB. If not, see . 18 | */ 19 | 20 | #include 21 | #include 22 | #include 23 | #include 24 | #include 25 | 26 | grub_err_t 27 | grub_machine_efiemu_init_tables (void) 28 | { 29 | return GRUB_ERR_NONE; 30 | } 31 | -------------------------------------------------------------------------------- /grub-core/lib/xen/halt.c: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2011 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #include 20 | #include 21 | #include 22 | #include 23 | 24 | void 25 | grub_halt (void) 26 | { 27 | struct sched_shutdown arg; 28 | 29 | arg.reason = SHUTDOWN_poweroff; 30 | grub_xen_sched_op (SCHEDOP_shutdown, &arg); 31 | for (;;); 32 | } 33 | -------------------------------------------------------------------------------- /grub-core/osdep/basic/ofpath.c: -------------------------------------------------------------------------------- 1 | /* ofpath.c - calculate OpenFirmware path names given an OS device */ 2 | /* 3 | * GRUB -- GRand Unified Bootloader 4 | * Copyright (C) 2009, 2011,2012, 2013 Free Software Foundation, Inc. 5 | * 6 | * GRUB is free software: you can redistribute it and/or modify 7 | * it under the terms of the GNU General Public License as published by 8 | * the Free Software Foundation, either version 3 of the License, or 9 | * (at your option) any later version. 10 | * 11 | * GRUB is distributed in the hope that it will be useful, 12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | * GNU General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU General Public License 17 | * along with GRUB. If not, see . 18 | */ 19 | 20 | #include 21 | #include 22 | 23 | char * 24 | grub_util_devname_to_ofpath (const char *sys_devname __attribute__ ((unused))) 25 | { 26 | return NULL; 27 | } 28 | 29 | 30 | -------------------------------------------------------------------------------- /grub-core/osdep/unix/sleep.c: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2002,2003,2005,2006,2007,2008,2009,2010,2011,2012,2013 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #include 20 | #include 21 | 22 | void 23 | grub_millisleep (grub_uint32_t ms) 24 | { 25 | struct timespec ts; 26 | 27 | ts.tv_sec = ms / 1000; 28 | ts.tv_nsec = (ms % 1000) * 1000000; 29 | nanosleep (&ts, NULL); 30 | } 31 | -------------------------------------------------------------------------------- /include/grub/mips/loongson/at_keyboard.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2007,2008,2009 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef GRUB_MACHINE_AT_KEYBOARD_HEADER 20 | #define GRUB_MACHINE_AT_KEYBOARD_HEADER 1 21 | 22 | #include 23 | 24 | #define KEYBOARD_REG_DATA (GRUB_MACHINE_PCI_IO_BASE | 0x60) 25 | #define KEYBOARD_REG_STATUS (GRUB_MACHINE_PCI_IO_BASE | 0x64) 26 | 27 | #endif 28 | -------------------------------------------------------------------------------- /include/grub/mips/mips.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2010 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef GRUB_REGISTERS_CPU_HEADER 20 | #define GRUB_REGISTERS_CPU_HEADER 1 21 | 22 | #ifdef ASM_FILE 23 | #define GRUB_CPU_REGISTER_WRAP(x) x 24 | #else 25 | #define GRUB_CPU_REGISTER_WRAP(x) #x 26 | #endif 27 | 28 | #define GRUB_CPU_MIPS_COP0_TIMER_COUNT GRUB_CPU_REGISTER_WRAP($9) 29 | 30 | #endif 31 | -------------------------------------------------------------------------------- /tests/grub_script_if.in: -------------------------------------------------------------------------------- 1 | #! @builddir@/grub-shell-tester 2 | 3 | #basic if, execute 4 | if true; then echo yes; fi 5 | 6 | #basic if, no execution 7 | if false; then echo no; fi 8 | 9 | #if else, execute if path 10 | if true; then echo yes; else echo no; fi 11 | 12 | #if else, execute else path 13 | if false; then echo no; else echo yes; fi 14 | 15 | #if elif, execute elif 16 | if false; then echo no; elif true; then echo yes; fi 17 | 18 | #if elif else, execute else 19 | if false; then echo no; elif false; then echo no; else echo yes; fi 20 | 21 | #if elif(1) elif(2), execute elif(2) 22 | if false; then echo no; elif false; then echo no; elif true; then echo yes; fi 23 | 24 | #if elif(1) elif(2) else, execute else 25 | if false; then echo no; elif false; then echo no; elif false; then echo no; else echo yes; fi 26 | 27 | #if {if elif else}, execute elif 28 | if true; then if false; then echo no; elif true; then echo yes; else echo no; fi; fi 29 | 30 | #if {if elif} else, execute elif. ofcourse no dangling-else problem due to "fi" 31 | if true; then if false; then echo no; elif true; then echo yes; fi; else echo no; fi 32 | -------------------------------------------------------------------------------- /tests/gzcompress_test.in: -------------------------------------------------------------------------------- 1 | #! @BUILD_SHEBANG@ 2 | # Copyright (C) 2013 Free Software Foundation, Inc. 3 | # 4 | # GRUB is free software: you can redistribute it and/or modify 5 | # it under the terms of the GNU General Public License as published by 6 | # the Free Software Foundation, either version 3 of the License, or 7 | # (at your option) any later version. 8 | # 9 | # GRUB is distributed in the hope that it will be useful, 10 | # but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | # GNU General Public License for more details. 13 | # 14 | # You should have received a copy of the GNU General Public License 15 | # along with GRUB. If not, see . 16 | 17 | set -e 18 | grubshell=@builddir@/grub-shell 19 | 20 | . "@builddir@/grub-core/modinfo.sh" 21 | 22 | if ! which gzip >/dev/null 2>&1; then 23 | echo "gzip not installed; cannot test gzip compression." 24 | exit 99 25 | fi 26 | 27 | v=$(echo hello | "${grubshell}" --mkrescue-arg=--compress=gz) 28 | if [ "$v" != "Hello World" ]; then 29 | exit 1 30 | fi 31 | -------------------------------------------------------------------------------- /tests/lzocompress_test.in: -------------------------------------------------------------------------------- 1 | #! @BUILD_SHEBANG@ 2 | # Copyright (C) 2013 Free Software Foundation, Inc. 3 | # 4 | # GRUB is free software: you can redistribute it and/or modify 5 | # it under the terms of the GNU General Public License as published by 6 | # the Free Software Foundation, either version 3 of the License, or 7 | # (at your option) any later version. 8 | # 9 | # GRUB is distributed in the hope that it will be useful, 10 | # but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | # GNU General Public License for more details. 13 | # 14 | # You should have received a copy of the GNU General Public License 15 | # along with GRUB. If not, see . 16 | 17 | set -e 18 | grubshell=@builddir@/grub-shell 19 | 20 | . "@builddir@/grub-core/modinfo.sh" 21 | 22 | if ! which lzop >/dev/null 2>&1; then 23 | echo "lzop not installed; cannot test lzo compression." 24 | exit 99 25 | fi 26 | 27 | v=$(echo hello | "${grubshell}" --mkrescue-arg=--compress=lzo) 28 | if [ "$v" != "Hello World" ]; then 29 | exit 1 30 | fi 31 | -------------------------------------------------------------------------------- /grub-core/lib/xen/reboot.c: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2011 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #include 20 | #include 21 | #include 22 | #include 23 | 24 | void 25 | grub_reboot (void) 26 | { 27 | struct sched_shutdown arg; 28 | 29 | arg.reason = SHUTDOWN_reboot; 30 | grub_xen_sched_op (SCHEDOP_shutdown, &arg); 31 | for (;;); 32 | } 33 | -------------------------------------------------------------------------------- /include/grub/efi/fdtload.h: -------------------------------------------------------------------------------- 1 | /* 2 | * GRUB -- GRand Unified Bootloader 3 | * Copyright (C) 2013-2015 Free Software Foundation, Inc. 4 | * 5 | * GRUB is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * GRUB is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with GRUB. If not, see . 17 | */ 18 | 19 | #ifndef GRUB_FDTLOAD_CPU_HEADER 20 | #define GRUB_FDTLOAD_CPU_HEADER 1 21 | 22 | #include 23 | #include 24 | 25 | void * 26 | grub_fdt_load (grub_size_t additional_size); 27 | void 28 | grub_fdt_unload (void); 29 | grub_err_t 30 | grub_fdt_install (void); 31 | 32 | #endif 33 | --------------------------------------------------------------------------------