grub-install: Install PV Xen binaries into the upstream specified path
PATCH 1/1 grub-install: Install PV Xen binaries into the upstream specified path
Upstream have defined a specification for where guests ought to place their xenpv grub binaries in order to facilitate chainloading from a stage 1 grub loaded from dom0.
http://xenbits.xen.org/docs/unstable-staging/misc/x86-xenpv-bootloader.html
The spec calls for installation into /boot/xen/pvboot-i386.elf or /boot/xen/pvboot-x86_64.elf.
--- util/grub-install.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-)
util/grub-install.c +8 -2
@@ -1979,6 +1979,14 @@ main (int argc, char *argv[]) }break ; +case GRUB_INSTALL_PLATFORM_I386_XEN : +grub_install_copy_file (imgfile,"/boot/xen/pvboot-i386.elf" ,1 ); +break ; + +case GRUB_INSTALL_PLATFORM_X86_64_XEN : +grub_install_copy_file (imgfile,"/boot/xen/pvboot-x86_64.elf" ,1 ); +break ; +case GRUB_INSTALL_PLATFORM_MIPSEL_LOONGSON :case GRUB_INSTALL_PLATFORM_MIPSEL_QEMU_MIPS :case GRUB_INSTALL_PLATFORM_MIPS_QEMU_MIPS :
@@ -1987,8 +1995,6 @@ main (int argc, char *argv[])case GRUB_INSTALL_PLATFORM_MIPSEL_ARC :case GRUB_INSTALL_PLATFORM_ARM_UBOOT :case GRUB_INSTALL_PLATFORM_I386_QEMU : -case GRUB_INSTALL_PLATFORM_I386_XEN : -case GRUB_INSTALL_PLATFORM_X86_64_XEN :grub_util_warn ("%s" ,_ ("WARNING: no platform-specific install was performed" ));break ;
Signature · 1 line
2.1.0
Quoted 20 lines · Ian Campbell
Upstream have defined a specification for where guests ought to place their xenpv grub binaries in order to facilitate chainloading from a stage 1 grub loaded from dom0.
http://xenbits.xen.org/docs/unstable-staging/misc/x86-xenpv-bootloader.html
The spec calls for installation into
/boot/xen/pvboot-i386.elfor/boot/xen/pvboot-x86_64.elf.Signed-off-by Ian Campbell <[email protected]>--- util/grub-install.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-)util/grub-install.c +0
-0@@ -1979,6 +1979,14 @@ main (int argc, char *argv[]) }
util/grub-install.c main (int argc, char *argv[]) · line 1989
Quoted 10 lines
util/grub-install.c +8
-0break ; +case GRUB_INSTALL_PLATFORM_I386_XEN : +grub_install_copy_file (imgfile,"/boot/xen/pvboot-i386.elf" ,1 ); +break ; + +case GRUB_INSTALL_PLATFORM_X86_64_XEN : +grub_install_copy_file (imgfile,"/boot/xen/pvboot-x86_64.elf" ,1 ); +break ; +
What ensures that /boot/xen exists? Should grub-install create it?
Quoted 20 lines
util/grub-install.c +0
-3case GRUB_INSTALL_PLATFORM_MIPSEL_LOONGSON :case GRUB_INSTALL_PLATFORM_MIPSEL_QEMU_MIPS :case GRUB_INSTALL_PLATFORM_MIPS_QEMU_MIPS :@@ -1987,8 +1995,6 @@ main (int argc, char *argv[])case GRUB_INSTALL_PLATFORM_MIPSEL_ARC :case GRUB_INSTALL_PLATFORM_ARM_UBOOT :case GRUB_INSTALL_PLATFORM_I386_QEMU : -case GRUB_INSTALL_PLATFORM_I386_XEN : -case GRUB_INSTALL_PLATFORM_X86_64_XEN :grub_util_warn ("%s" ,_ ("WARNING: no platform-specific install was performed" ));break ; --2.1.0
_______________________________________________
Grub-devel mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/grub-devel
Quoted 20 lines · Ian Campbell
Upstream have defined a specification for where guests ought to place their xenpv grub binaries in order to facilitate chainloading from a stage 1 grub loaded from dom0.
http://xenbits.xen.org/docs/unstable-staging/misc/x86-xenpv-bootloader.html
The spec calls for installation into
/boot/xen/pvboot-i386.elfor/boot/xen/pvboot-x86_64.elf.Signed-off-by Ian Campbell <[email protected]>--- util/grub-install.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-)util/grub-install.c +0
-0@@ -1979,6 +1979,14 @@ main (int argc, char *argv[]) }
util/grub-install.c main (int argc, char *argv[]) · line 1989
Quoted 10 lines
util/grub-install.c +8
-0break ; +case GRUB_INSTALL_PLATFORM_I386_XEN : +grub_install_copy_file (imgfile,"/boot/xen/pvboot-i386.elf" ,1 ); +break ; + +case GRUB_INSTALL_PLATFORM_X86_64_XEN : +grub_install_copy_file (imgfile,"/boot/xen/pvboot-x86_64.elf" ,1 ); +break ; +
What ensures that /boot/xen exists? Should grub-install create it?
Quoted 20 lines
util/grub-install.c +0
-3case GRUB_INSTALL_PLATFORM_MIPSEL_LOONGSON :case GRUB_INSTALL_PLATFORM_MIPSEL_QEMU_MIPS :case GRUB_INSTALL_PLATFORM_MIPS_QEMU_MIPS :@@ -1987,8 +1995,6 @@ main (int argc, char *argv[])case GRUB_INSTALL_PLATFORM_MIPSEL_ARC :case GRUB_INSTALL_PLATFORM_ARM_UBOOT :case GRUB_INSTALL_PLATFORM_I386_QEMU : -case GRUB_INSTALL_PLATFORM_I386_XEN : -case GRUB_INSTALL_PLATFORM_X86_64_XEN :grub_util_warn ("%s" ,_ ("WARNING: no platform-specific install was performed" ));break ; --2.1.0
_______________________________________________
Grub-devel mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/grub-devel
Quoted 23 lines · Andrei Borzenkov
Quoted 22 lines · Ian Campbell
Upstream have defined a specification for where guests ought to place their xenpv grub binaries in order to facilitate chainloading from a stage 1 grub loaded from dom0.
http://xenbits.xen.org/docs/unstable-staging/misc/x86-xenpv-bootloader.html
The spec calls for installation into
/boot/xen/pvboot-i386.elfor/boot/xen/pvboot-x86_64.elf.Signed-off-by Ian Campbell <[email protected]>--- util/grub-install.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-)util/grub-install.c +0
-0@@ -1979,6 +1979,14 @@ main (int argc, char *argv[]) }break ;
Quoted 10 lines
util/grub-install.c main (int argc, char *argv[]) · line 1989
Quoted 8 lines
util/grub-install.c +8
-0+case GRUB_INSTALL_PLATFORM_I386_XEN : +grub_install_copy_file (imgfile,"/boot/xen/pvboot-i386.elf" ,1 ); +break ; + +case GRUB_INSTALL_PLATFORM_X86_64_XEN : +grub_install_copy_file (imgfile,"/boot/xen/pvboot-x86_64.elf" ,1 ); +break ; +What ensures that
/boot/xenexists? Should grub-install create it?
I expected it would just happen, but looking again only grub_install_copy_files has this behaviour, not grub_install_copy_file.
Should I add grub_install_mkdir_p in the hunks above, or should I be thinking of patching grub_install_copy_file?
I've been testing this via the Debian packaging, which contains the mkdir before it invokes grub-mkimage.
Ian.
Quoted 25 lines
Quoted 16 lines
util/grub-install.c +0
-3case GRUB_INSTALL_PLATFORM_MIPSEL_LOONGSON :case GRUB_INSTALL_PLATFORM_MIPSEL_QEMU_MIPS :case GRUB_INSTALL_PLATFORM_MIPS_QEMU_MIPS :@@ -1987,8 +1995,6 @@ main (int argc, char *argv[])case GRUB_INSTALL_PLATFORM_MIPSEL_ARC :case GRUB_INSTALL_PLATFORM_ARM_UBOOT :case GRUB_INSTALL_PLATFORM_I386_QEMU : -case GRUB_INSTALL_PLATFORM_I386_XEN : -case GRUB_INSTALL_PLATFORM_X86_64_XEN :grub_util_warn ("%s" ,_ ("WARNING: no platform-specific install was performed" ));break ; --2.1.0
Quoted 4 lines
_______________________________________________
Grub-devel mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/grub-devel_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel
Quoted 23 lines · Andrei Borzenkov
Quoted 22 lines · Ian Campbell
Upstream have defined a specification for where guests ought to place their xenpv grub binaries in order to facilitate chainloading from a stage 1 grub loaded from dom0.
http://xenbits.xen.org/docs/unstable-staging/misc/x86-xenpv-bootloader.html
The spec calls for installation into
/boot/xen/pvboot-i386.elfor/boot/xen/pvboot-x86_64.elf.Signed-off-by Ian Campbell <[email protected]>--- util/grub-install.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-)util/grub-install.c +0
-0@@ -1979,6 +1979,14 @@ main (int argc, char *argv[]) }break ;
Quoted 10 lines
util/grub-install.c main (int argc, char *argv[]) · line 1989
Quoted 8 lines
util/grub-install.c +8
-0+case GRUB_INSTALL_PLATFORM_I386_XEN : +grub_install_copy_file (imgfile,"/boot/xen/pvboot-i386.elf" ,1 ); +break ; + +case GRUB_INSTALL_PLATFORM_X86_64_XEN : +grub_install_copy_file (imgfile,"/boot/xen/pvboot-x86_64.elf" ,1 ); +break ; +What ensures that
/boot/xenexists? Should grub-install create it?
I expected it would just happen, but looking again only grub_install_copy_files has this behaviour, not grub_install_copy_file.
Should I add grub_install_mkdir_p in the hunks above, or should I be thinking of patching grub_install_copy_file?
I've been testing this via the Debian packaging, which contains the mkdir before it invokes grub-mkimage.
Ian.
Quoted 25 lines
Quoted 16 lines
util/grub-install.c +0
-3case GRUB_INSTALL_PLATFORM_MIPSEL_LOONGSON :case GRUB_INSTALL_PLATFORM_MIPSEL_QEMU_MIPS :case GRUB_INSTALL_PLATFORM_MIPS_QEMU_MIPS :@@ -1987,8 +1995,6 @@ main (int argc, char *argv[])case GRUB_INSTALL_PLATFORM_MIPSEL_ARC :case GRUB_INSTALL_PLATFORM_ARM_UBOOT :case GRUB_INSTALL_PLATFORM_I386_QEMU : -case GRUB_INSTALL_PLATFORM_I386_XEN : -case GRUB_INSTALL_PLATFORM_X86_64_XEN :grub_util_warn ("%s" ,_ ("WARNING: no platform-specific install was performed" ));break ; --2.1.0
Quoted 4 lines
_______________________________________________
Grub-devel mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/grub-devel_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel
В Wed, 22 Oct 2014 14:37:56 +0100
Ian Campbell <[email protected]> пишет:
Quoted 35 lines · Andrei Borzenkov
Quoted 23 lines · Ian Campbell
Quoted 22 lines
Upstream have defined a specification for where guests ought to place their xenpv grub binaries in order to facilitate chainloading from a stage 1 grub loaded from dom0.
http://xenbits.xen.org/docs/unstable-staging/misc/x86-xenpv-bootloader.html
The spec calls for installation into
/boot/xen/pvboot-i386.elfor/boot/xen/pvboot-x86_64.elf.Signed-off-by Ian Campbell <[email protected]>--- util/grub-install.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-)util/grub-install.c +0
-0@@ -1979,6 +1979,14 @@ main (int argc, char *argv[]) }break ;Quoted 10 lines
util/grub-install.c main (int argc, char *argv[]) · line 1989
Quoted 8 lines
util/grub-install.c +8
-0+case GRUB_INSTALL_PLATFORM_I386_XEN : +grub_install_copy_file (imgfile,"/boot/xen/pvboot-i386.elf" ,1 ); +break ; + +case GRUB_INSTALL_PLATFORM_X86_64_XEN : +grub_install_copy_file (imgfile,"/boot/xen/pvboot-x86_64.elf" ,1 ); +break ; +What ensures that
/boot/xenexists? Should grub-install create it?
Quoted 3 lines
I expected it would just happen, but looking again only
grub_install_copy_fileshas this behaviour, notgrub_install_copy_file.
grub_install_copy_files is pretty misleading, it should really be named grub_install_platform_files as this is the only thing it does.
Quoted 3 lines
Should I add
grub_install_mkdir_pin the hunks above, or should I be thinking of patchinggrub_install_copy_file?
All other usages of grub_install_copy_file assume existing directory, so I guess explicitly creating directory is fine.
Please do not use hardcoded absolute path names. It should respect bootdir to facilitate offroot installation.
Quoted 32 lines
I've been testing this via the Debian packaging, which contains the mkdir before it invokes grub-mkimage.
Ian.
Quoted 25 lines
Quoted 16 lines
util/grub-install.c +0
-3case GRUB_INSTALL_PLATFORM_MIPSEL_LOONGSON :case GRUB_INSTALL_PLATFORM_MIPSEL_QEMU_MIPS :case GRUB_INSTALL_PLATFORM_MIPS_QEMU_MIPS :@@ -1987,8 +1995,6 @@ main (int argc, char *argv[])case GRUB_INSTALL_PLATFORM_MIPSEL_ARC :case GRUB_INSTALL_PLATFORM_ARM_UBOOT :case GRUB_INSTALL_PLATFORM_I386_QEMU : -case GRUB_INSTALL_PLATFORM_I386_XEN : -case GRUB_INSTALL_PLATFORM_X86_64_XEN :grub_util_warn ("%s" ,_ ("WARNING: no platform-specific install was performed" ));break ; --2.1.0
Quoted 4 lines
_______________________________________________
Grub-devel mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/grub-devel_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel
_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel
В Wed, 22 Oct 2014 14:37:56 +0100
Ian Campbell <[email protected]> пишет:
Quoted 35 lines · Andrei Borzenkov
Quoted 23 lines · Ian Campbell
Quoted 22 lines
Upstream have defined a specification for where guests ought to place their xenpv grub binaries in order to facilitate chainloading from a stage 1 grub loaded from dom0.
http://xenbits.xen.org/docs/unstable-staging/misc/x86-xenpv-bootloader.html
The spec calls for installation into
/boot/xen/pvboot-i386.elfor/boot/xen/pvboot-x86_64.elf.Signed-off-by Ian Campbell <[email protected]>--- util/grub-install.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-)util/grub-install.c +0
-0@@ -1979,6 +1979,14 @@ main (int argc, char *argv[]) }break ;Quoted 10 lines
util/grub-install.c main (int argc, char *argv[]) · line 1989
Quoted 8 lines
util/grub-install.c +8
-0+case GRUB_INSTALL_PLATFORM_I386_XEN : +grub_install_copy_file (imgfile,"/boot/xen/pvboot-i386.elf" ,1 ); +break ; + +case GRUB_INSTALL_PLATFORM_X86_64_XEN : +grub_install_copy_file (imgfile,"/boot/xen/pvboot-x86_64.elf" ,1 ); +break ; +What ensures that
/boot/xenexists? Should grub-install create it?
Quoted 3 lines
I expected it would just happen, but looking again only
grub_install_copy_fileshas this behaviour, notgrub_install_copy_file.
grub_install_copy_files is pretty misleading, it should really be named grub_install_platform_files as this is the only thing it does.
Quoted 3 lines
Should I add
grub_install_mkdir_pin the hunks above, or should I be thinking of patchinggrub_install_copy_file?
All other usages of grub_install_copy_file assume existing directory, so I guess explicitly creating directory is fine.
Please do not use hardcoded absolute path names. It should respect bootdir to facilitate offroot installation.
Quoted 32 lines
I've been testing this via the Debian packaging, which contains the mkdir before it invokes grub-mkimage.
Ian.
Quoted 25 lines
Quoted 16 lines
util/grub-install.c +0
-3case GRUB_INSTALL_PLATFORM_MIPSEL_LOONGSON :case GRUB_INSTALL_PLATFORM_MIPSEL_QEMU_MIPS :case GRUB_INSTALL_PLATFORM_MIPS_QEMU_MIPS :@@ -1987,8 +1995,6 @@ main (int argc, char *argv[])case GRUB_INSTALL_PLATFORM_MIPSEL_ARC :case GRUB_INSTALL_PLATFORM_ARM_UBOOT :case GRUB_INSTALL_PLATFORM_I386_QEMU : -case GRUB_INSTALL_PLATFORM_I386_XEN : -case GRUB_INSTALL_PLATFORM_X86_64_XEN :grub_util_warn ("%s" ,_ ("WARNING: no platform-specific install was performed" ));break ; --2.1.0
Quoted 4 lines
_______________________________________________
Grub-devel mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/grub-devel_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel