All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/2] stubdom: disable building of pv-grub per default
@ 2021-09-09  8:27 Juergen Gross
  2021-09-09  8:27 ` [PATCH 1/2] stubdom: fix build with disabled pv-grub Juergen Gross
                   ` (2 more replies)
  0 siblings, 3 replies; 7+ messages in thread
From: Juergen Gross @ 2021-09-09  8:27 UTC (permalink / raw)
  To: xen-devel
  Cc: Juergen Gross, Andrew Cooper, George Dunlap, Ian Jackson,
	Jan Beulich, Julien Grall, Stefano Stabellini, Wei Liu,
	Samuel Thibault

This is a first step of deprecating pv-grub. Switch the default to not
building it.

NOTE: This should be mentioned in the release notes!

Juergen Gross (2):
  stubdom: fix build with disabled pv-grub
  stubdom: disable building pv-grub

 Makefile             |  4 ++--
 stubdom/Makefile     | 13 +++++++++++++
 stubdom/configure    |  8 ++------
 stubdom/configure.ac |  2 +-
 4 files changed, 18 insertions(+), 9 deletions(-)

-- 
2.26.2



^ permalink raw reply	[flat|nested] 7+ messages in thread

* [PATCH 1/2] stubdom: fix build with disabled pv-grub
  2021-09-09  8:27 [PATCH 0/2] stubdom: disable building of pv-grub per default Juergen Gross
@ 2021-09-09  8:27 ` Juergen Gross
  2021-09-09  9:03   ` Samuel Thibault
  2021-09-09  8:27 ` [PATCH 2/2] stubdom: disable building pv-grub Juergen Gross
  2021-09-09  8:44 ` [PATCH 0/2] stubdom: disable building of pv-grub per default Jan Beulich
  2 siblings, 1 reply; 7+ messages in thread
From: Juergen Gross @ 2021-09-09  8:27 UTC (permalink / raw)
  To: xen-devel
  Cc: Juergen Gross, Andrew Cooper, George Dunlap, Ian Jackson,
	Jan Beulich, Julien Grall, Stefano Stabellini, Wei Liu,
	Samuel Thibault

Today the build will fail if --disable-pv-grub as a parameter of
configure, as the main Makefile will unconditionally try to build a
32-bit pv-grub stubdom.

Fix that by introducing a pv-grub32 target in stubdom/Makefile taking
care of this situation.

Signed-off-by: Juergen Gross <jgross@suse.com>
---
 Makefile         |  4 ++--
 stubdom/Makefile | 13 +++++++++++++
 2 files changed, 15 insertions(+), 2 deletions(-)

diff --git a/Makefile b/Makefile
index 96d32cfd50..5b5cef3e49 100644
--- a/Makefile
+++ b/Makefile
@@ -72,7 +72,7 @@ build-tools-oxenstored: build-tools-public-headers
 build-stubdom: mini-os-dir build-tools-public-headers
 	$(MAKE) -C stubdom build
 ifeq (x86_64,$(XEN_TARGET_ARCH))
-	XEN_TARGET_ARCH=x86_32 $(MAKE) -C stubdom pv-grub
+	XEN_TARGET_ARCH=x86_32 $(MAKE) -C stubdom pv-grub32
 endif
 
 .PHONY: build-docs
@@ -143,7 +143,7 @@ install-tools: install-tools-public-headers
 install-stubdom: mini-os-dir install-tools
 	$(MAKE) -C stubdom install
 ifeq (x86_64,$(XEN_TARGET_ARCH))
-	XEN_TARGET_ARCH=x86_32 $(MAKE) -C stubdom install-grub
+	XEN_TARGET_ARCH=x86_32 $(MAKE) -C stubdom install-grub32
 endif
 
 .PHONY: tools/firmware/seabios-dir-force-update
diff --git a/stubdom/Makefile b/stubdom/Makefile
index 06aa69d8bc..b339ae701c 100644
--- a/stubdom/Makefile
+++ b/stubdom/Makefile
@@ -531,6 +531,13 @@ vtpmmgr-stubdom: mini-os-$(XEN_TARGET_ARCH)-vtpmmgr vtpmmgr
 pv-grub: mini-os-$(XEN_TARGET_ARCH)-grub libxenguest grub
 	DEF_CPPFLAGS="$(TARGET_CPPFLAGS)" DEF_CFLAGS="$(TARGET_CFLAGS)" DEF_LDFLAGS="$(TARGET_LDFLAGS)" MINIOS_CONFIG="$(CURDIR)/grub/minios.cfg" $(MAKE) DESTDIR= -C $(MINI_OS) OBJ_DIR=$(CURDIR)/$< APP_OBJS=$(CURDIR)/grub-$(XEN_TARGET_ARCH)/main.a
 
+.PHONY: pv-grub32
+ifneq ($(filter grub,$(STUBDOM_TARGETS)),)
+pv-grub32: pv-grub
+else
+pv-grub32:
+endif
+
 .PHONY: xenstore-stubdom
 xenstore-stubdom: mini-os-$(XEN_TARGET_ARCH)-xenstore libxenguest xenstore
 	DEF_CPPFLAGS="$(TARGET_CPPFLAGS)" DEF_CFLAGS="$(TARGET_CFLAGS)" DEF_LDFLAGS="$(TARGET_LDFLAGS)" MINIOS_CONFIG="$(CURDIR)/xenstore-minios.cfg" $(MAKE) DESTDIR= -C $(MINI_OS) OBJ_DIR=$(CURDIR)/$< APP_OBJS=$(CURDIR)/xenstore/xenstored.a
@@ -560,6 +567,12 @@ install-grub: pv-grub
 	$(INSTALL_DIR) "$(DESTDIR)$(XENFIRMWAREDIR)"
 	$(INSTALL_DATA) mini-os-$(XEN_TARGET_ARCH)-grub/mini-os.gz "$(DESTDIR)$(XENFIRMWAREDIR)/pv-grub-$(XEN_TARGET_ARCH).gz"
 
+ifneq ($(filter grub,$(STUBDOM_TARGETS)),)
+install-grub32: install-grub
+else
+install-grub32:
+endif
+
 install-c: c-stubdom
 
 install-caml: caml-stubdom
-- 
2.26.2



^ permalink raw reply related	[flat|nested] 7+ messages in thread

* [PATCH 2/2] stubdom: disable building pv-grub
  2021-09-09  8:27 [PATCH 0/2] stubdom: disable building of pv-grub per default Juergen Gross
  2021-09-09  8:27 ` [PATCH 1/2] stubdom: fix build with disabled pv-grub Juergen Gross
@ 2021-09-09  8:27 ` Juergen Gross
  2021-09-09  9:04   ` Samuel Thibault
  2021-09-09  8:44 ` [PATCH 0/2] stubdom: disable building of pv-grub per default Jan Beulich
  2 siblings, 1 reply; 7+ messages in thread
From: Juergen Gross @ 2021-09-09  8:27 UTC (permalink / raw)
  To: xen-devel; +Cc: Juergen Gross, Samuel Thibault, Ian Jackson, Wei Liu

The stubdom based pv-grub is using a very outdated version of grub
(0.97) and should not be used any longer. Mainline grub has support for
PV guests for a long time now, so that should be used as a boot loader
of a PV domain.

So disable building pv-grub per default. In case someone really wants
to continue using it he/she can still use a pv-grub binary from an older
Xen version or manually enable building it via:

  configure --enable-pv-grub

Signed-off-by: Juergen Gross <jgross@suse.com>
---
 stubdom/configure    | 8 ++------
 stubdom/configure.ac | 2 +-
 2 files changed, 3 insertions(+), 7 deletions(-)

diff --git a/stubdom/configure b/stubdom/configure
index aa48df986d..df31532abb 100755
--- a/stubdom/configure
+++ b/stubdom/configure
@@ -1342,7 +1342,7 @@ Optional Features:
   --enable-ioemu-stubdom  Build and install ioemu-stubdom
   --enable-c-stubdom      Build and install c-stubdom (default is DISABLED)
   --enable-caml-stubdom   Build and install caml-stubdom (default is DISABLED)
-  --disable-pv-grub       Build and install pv-grub (default is ENABLED)
+  --enable-pv-grub        Build and install pv-grub (default is DISABLED)
   --disable-xenstore-stubdom
                           Build and install xenstore-stubdom (default is
                           ENABLED)
@@ -2129,11 +2129,7 @@ fi
 else
 
 
-grub=y
-STUBDOM_TARGETS="$STUBDOM_TARGETS grub"
-STUBDOM_BUILD="$STUBDOM_BUILD pv-grub"
-STUBDOM_INSTALL="$STUBDOM_INSTALL install-grub"
-STUBDOM_UNINSTALL="$STUBDOM_UNINSTALL install-grub"
+grub=n
 
 
 fi
diff --git a/stubdom/configure.ac b/stubdom/configure.ac
index bd6f765929..a07a1edae5 100644
--- a/stubdom/configure.ac
+++ b/stubdom/configure.ac
@@ -21,7 +21,7 @@ m4_include([../m4/fetcher.m4])
 AX_STUBDOM_CONDITIONAL([ioemu-stubdom], [ioemu])
 AX_STUBDOM_DEFAULT_DISABLE([c-stubdom], [c])
 AX_STUBDOM_DEFAULT_DISABLE([caml-stubdom], [caml])
-AX_STUBDOM_DEFAULT_ENABLE([pv-grub], [grub])
+AX_STUBDOM_DEFAULT_DISABLE([pv-grub], [grub])
 AX_STUBDOM_DEFAULT_ENABLE([xenstore-stubdom], [xenstore])
 AX_STUBDOM_DEFAULT_ENABLE([xenstorepvh-stubdom], [xenstorepvh])
 AX_STUBDOM_CONDITIONAL([vtpm-stubdom], [vtpm])
-- 
2.26.2



^ permalink raw reply related	[flat|nested] 7+ messages in thread

* Re: [PATCH 0/2] stubdom: disable building of pv-grub per default
  2021-09-09  8:27 [PATCH 0/2] stubdom: disable building of pv-grub per default Juergen Gross
  2021-09-09  8:27 ` [PATCH 1/2] stubdom: fix build with disabled pv-grub Juergen Gross
  2021-09-09  8:27 ` [PATCH 2/2] stubdom: disable building pv-grub Juergen Gross
@ 2021-09-09  8:44 ` Jan Beulich
  2021-09-09  8:52   ` Juergen Gross
  2 siblings, 1 reply; 7+ messages in thread
From: Jan Beulich @ 2021-09-09  8:44 UTC (permalink / raw)
  To: Juergen Gross
  Cc: Andrew Cooper, George Dunlap, Ian Jackson, Julien Grall,
	Stefano Stabellini, Wei Liu, Samuel Thibault, xen-devel

On 09.09.2021 10:27, Juergen Gross wrote:
> This is a first step of deprecating pv-grub. Switch the default to not
> building it.
> 
> NOTE: This should be mentioned in the release notes!

And/or perhaps in ./CHANGELOG.md?

Jan



^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH 0/2] stubdom: disable building of pv-grub per default
  2021-09-09  8:44 ` [PATCH 0/2] stubdom: disable building of pv-grub per default Jan Beulich
@ 2021-09-09  8:52   ` Juergen Gross
  0 siblings, 0 replies; 7+ messages in thread
From: Juergen Gross @ 2021-09-09  8:52 UTC (permalink / raw)
  To: Jan Beulich
  Cc: Andrew Cooper, George Dunlap, Ian Jackson, Julien Grall,
	Stefano Stabellini, Wei Liu, Samuel Thibault, xen-devel


[-- Attachment #1.1.1: Type: text/plain, Size: 342 bytes --]

On 09.09.21 10:44, Jan Beulich wrote:
> On 09.09.2021 10:27, Juergen Gross wrote:
>> This is a first step of deprecating pv-grub. Switch the default to not
>> building it.
>>
>> NOTE: This should be mentioned in the release notes!
> 
> And/or perhaps in ./CHANGELOG.md?

Oh yes, of course!

I'll add this to patch 2.


Juergen

[-- Attachment #1.1.2: OpenPGP public key --]
[-- Type: application/pgp-keys, Size: 3135 bytes --]

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 495 bytes --]

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH 1/2] stubdom: fix build with disabled pv-grub
  2021-09-09  8:27 ` [PATCH 1/2] stubdom: fix build with disabled pv-grub Juergen Gross
@ 2021-09-09  9:03   ` Samuel Thibault
  0 siblings, 0 replies; 7+ messages in thread
From: Samuel Thibault @ 2021-09-09  9:03 UTC (permalink / raw)
  To: Juergen Gross
  Cc: xen-devel, Andrew Cooper, George Dunlap, Ian Jackson,
	Jan Beulich, Julien Grall, Stefano Stabellini, Wei Liu

Juergen Gross, le jeu. 09 sept. 2021 10:27:04 +0200, a ecrit:
> Today the build will fail if --disable-pv-grub as a parameter of
> configure, as the main Makefile will unconditionally try to build a
> 32-bit pv-grub stubdom.
> 
> Fix that by introducing a pv-grub32 target in stubdom/Makefile taking
> care of this situation.
> 
> Signed-off-by: Juergen Gross <jgross@suse.com>

Reviewed-by: Samuel Thibault <samuel.thibault@ens-lyon.org>

> ---
>  Makefile         |  4 ++--
>  stubdom/Makefile | 13 +++++++++++++
>  2 files changed, 15 insertions(+), 2 deletions(-)
> 
> diff --git a/Makefile b/Makefile
> index 96d32cfd50..5b5cef3e49 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -72,7 +72,7 @@ build-tools-oxenstored: build-tools-public-headers
>  build-stubdom: mini-os-dir build-tools-public-headers
>  	$(MAKE) -C stubdom build
>  ifeq (x86_64,$(XEN_TARGET_ARCH))
> -	XEN_TARGET_ARCH=x86_32 $(MAKE) -C stubdom pv-grub
> +	XEN_TARGET_ARCH=x86_32 $(MAKE) -C stubdom pv-grub32
>  endif
>  
>  .PHONY: build-docs
> @@ -143,7 +143,7 @@ install-tools: install-tools-public-headers
>  install-stubdom: mini-os-dir install-tools
>  	$(MAKE) -C stubdom install
>  ifeq (x86_64,$(XEN_TARGET_ARCH))
> -	XEN_TARGET_ARCH=x86_32 $(MAKE) -C stubdom install-grub
> +	XEN_TARGET_ARCH=x86_32 $(MAKE) -C stubdom install-grub32
>  endif
>  
>  .PHONY: tools/firmware/seabios-dir-force-update
> diff --git a/stubdom/Makefile b/stubdom/Makefile
> index 06aa69d8bc..b339ae701c 100644
> --- a/stubdom/Makefile
> +++ b/stubdom/Makefile
> @@ -531,6 +531,13 @@ vtpmmgr-stubdom: mini-os-$(XEN_TARGET_ARCH)-vtpmmgr vtpmmgr
>  pv-grub: mini-os-$(XEN_TARGET_ARCH)-grub libxenguest grub
>  	DEF_CPPFLAGS="$(TARGET_CPPFLAGS)" DEF_CFLAGS="$(TARGET_CFLAGS)" DEF_LDFLAGS="$(TARGET_LDFLAGS)" MINIOS_CONFIG="$(CURDIR)/grub/minios.cfg" $(MAKE) DESTDIR= -C $(MINI_OS) OBJ_DIR=$(CURDIR)/$< APP_OBJS=$(CURDIR)/grub-$(XEN_TARGET_ARCH)/main.a
>  
> +.PHONY: pv-grub32
> +ifneq ($(filter grub,$(STUBDOM_TARGETS)),)
> +pv-grub32: pv-grub
> +else
> +pv-grub32:
> +endif
> +
>  .PHONY: xenstore-stubdom
>  xenstore-stubdom: mini-os-$(XEN_TARGET_ARCH)-xenstore libxenguest xenstore
>  	DEF_CPPFLAGS="$(TARGET_CPPFLAGS)" DEF_CFLAGS="$(TARGET_CFLAGS)" DEF_LDFLAGS="$(TARGET_LDFLAGS)" MINIOS_CONFIG="$(CURDIR)/xenstore-minios.cfg" $(MAKE) DESTDIR= -C $(MINI_OS) OBJ_DIR=$(CURDIR)/$< APP_OBJS=$(CURDIR)/xenstore/xenstored.a
> @@ -560,6 +567,12 @@ install-grub: pv-grub
>  	$(INSTALL_DIR) "$(DESTDIR)$(XENFIRMWAREDIR)"
>  	$(INSTALL_DATA) mini-os-$(XEN_TARGET_ARCH)-grub/mini-os.gz "$(DESTDIR)$(XENFIRMWAREDIR)/pv-grub-$(XEN_TARGET_ARCH).gz"
>  
> +ifneq ($(filter grub,$(STUBDOM_TARGETS)),)
> +install-grub32: install-grub
> +else
> +install-grub32:
> +endif
> +
>  install-c: c-stubdom
>  
>  install-caml: caml-stubdom
> -- 
> 2.26.2
> 

-- 
Samuel
The nice thing about Windows is - It does not just crash, it displays a
dialog box and lets you press 'OK' first.
(Arno Schaefer's .sig)


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH 2/2] stubdom: disable building pv-grub
  2021-09-09  8:27 ` [PATCH 2/2] stubdom: disable building pv-grub Juergen Gross
@ 2021-09-09  9:04   ` Samuel Thibault
  0 siblings, 0 replies; 7+ messages in thread
From: Samuel Thibault @ 2021-09-09  9:04 UTC (permalink / raw)
  To: Juergen Gross; +Cc: xen-devel, Ian Jackson, Wei Liu

Juergen Gross, le jeu. 09 sept. 2021 10:27:05 +0200, a ecrit:
> The stubdom based pv-grub is using a very outdated version of grub
> (0.97) and should not be used any longer. Mainline grub has support for
> PV guests for a long time now, so that should be used as a boot loader
> of a PV domain.
> 
> So disable building pv-grub per default. In case someone really wants
> to continue using it he/she can still use a pv-grub binary from an older
> Xen version or manually enable building it via:
> 
>   configure --enable-pv-grub
> 
> Signed-off-by: Juergen Gross <jgross@suse.com>

Reviewed-by: Samuel Thibault <samuel.thibault@ens-lyon.org>

> ---
>  stubdom/configure    | 8 ++------
>  stubdom/configure.ac | 2 +-
>  2 files changed, 3 insertions(+), 7 deletions(-)
> 
> diff --git a/stubdom/configure b/stubdom/configure
> index aa48df986d..df31532abb 100755
> --- a/stubdom/configure
> +++ b/stubdom/configure
> @@ -1342,7 +1342,7 @@ Optional Features:
>    --enable-ioemu-stubdom  Build and install ioemu-stubdom
>    --enable-c-stubdom      Build and install c-stubdom (default is DISABLED)
>    --enable-caml-stubdom   Build and install caml-stubdom (default is DISABLED)
> -  --disable-pv-grub       Build and install pv-grub (default is ENABLED)
> +  --enable-pv-grub        Build and install pv-grub (default is DISABLED)
>    --disable-xenstore-stubdom
>                            Build and install xenstore-stubdom (default is
>                            ENABLED)
> @@ -2129,11 +2129,7 @@ fi
>  else
>  
>  
> -grub=y
> -STUBDOM_TARGETS="$STUBDOM_TARGETS grub"
> -STUBDOM_BUILD="$STUBDOM_BUILD pv-grub"
> -STUBDOM_INSTALL="$STUBDOM_INSTALL install-grub"
> -STUBDOM_UNINSTALL="$STUBDOM_UNINSTALL install-grub"
> +grub=n
>  
>  
>  fi
> diff --git a/stubdom/configure.ac b/stubdom/configure.ac
> index bd6f765929..a07a1edae5 100644
> --- a/stubdom/configure.ac
> +++ b/stubdom/configure.ac
> @@ -21,7 +21,7 @@ m4_include([../m4/fetcher.m4])
>  AX_STUBDOM_CONDITIONAL([ioemu-stubdom], [ioemu])
>  AX_STUBDOM_DEFAULT_DISABLE([c-stubdom], [c])
>  AX_STUBDOM_DEFAULT_DISABLE([caml-stubdom], [caml])
> -AX_STUBDOM_DEFAULT_ENABLE([pv-grub], [grub])
> +AX_STUBDOM_DEFAULT_DISABLE([pv-grub], [grub])
>  AX_STUBDOM_DEFAULT_ENABLE([xenstore-stubdom], [xenstore])
>  AX_STUBDOM_DEFAULT_ENABLE([xenstorepvh-stubdom], [xenstorepvh])
>  AX_STUBDOM_CONDITIONAL([vtpm-stubdom], [vtpm])
> -- 
> 2.26.2
> 

-- 
Samuel
<Raize> can you guys see what I type?
<vecna> no, raize
<Raize> How do I set it up so you can see it?


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2021-09-09  9:04 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-09-09  8:27 [PATCH 0/2] stubdom: disable building of pv-grub per default Juergen Gross
2021-09-09  8:27 ` [PATCH 1/2] stubdom: fix build with disabled pv-grub Juergen Gross
2021-09-09  9:03   ` Samuel Thibault
2021-09-09  8:27 ` [PATCH 2/2] stubdom: disable building pv-grub Juergen Gross
2021-09-09  9:04   ` Samuel Thibault
2021-09-09  8:44 ` [PATCH 0/2] stubdom: disable building of pv-grub per default Jan Beulich
2021-09-09  8:52   ` Juergen Gross

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.