summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFlorian Schmaus <flow@gentoo.org>2022-07-16 13:02:11 +0200
committerFlorian Schmaus <flow@gentoo.org>2022-07-16 13:02:11 +0200
commit628cef9486ddab3f691bbeac9a99af03cf64242c (patch)
tree70f591b8d29c82e6c21d5a63809685fdc5dcfe1d
parentcommit-and-tag: only commit if there is something to commit (diff)
downloadxen-gentoo-patches-4.16.1-gentoo-patchset-2.tar.gz
xen-gentoo-patches-4.16.1-gentoo-patchset-2.tar.bz2
xen-gentoo-patches-4.16.1-gentoo-patchset-2.zip
Gentoo specific patches for Xen 4.16.1 (or later)4.16.1-gentoo-patchset-24.16
Signed-off-by: Florian Schmaus <flow@gentoo.org>
-rw-r--r--no-boot-symlinks/xen-4.16-no-symlinks.patch17
-rw-r--r--ovmf/xen-tools-4.15.1-brotli-gcc11.patch33
-rw-r--r--xen-4.16-efi.patch12
3 files changed, 62 insertions, 0 deletions
diff --git a/no-boot-symlinks/xen-4.16-no-symlinks.patch b/no-boot-symlinks/xen-4.16-no-symlinks.patch
new file mode 100644
index 0000000..8aed75b
--- /dev/null
+++ b/no-boot-symlinks/xen-4.16-no-symlinks.patch
@@ -0,0 +1,17 @@
+diff --git a/xen/Makefile b/xen/Makefile
+index dfb0efcc..1816eb66 100644
+--- a/xen/Makefile
++++ b/xen/Makefile
+@@ -311,9 +311,9 @@ _install: Z=$(CONFIG_XEN_INSTALL_SUFFIX)
+ _install: $(TARGET)$(CONFIG_XEN_INSTALL_SUFFIX)
+ [ -d $(D)$(BOOT_DIR) ] || $(INSTALL_DIR) $(D)$(BOOT_DIR)
+ $(INSTALL_DATA) $(TARGET)$(Z) $(D)$(BOOT_DIR)/$(T)-$(XEN_FULLVERSION)$(Z)
+- ln -f -s $(T)-$(XEN_FULLVERSION)$(Z) $(D)$(BOOT_DIR)/$(T)-$(XEN_VERSION).$(XEN_SUBVERSION)$(Z)
+- ln -f -s $(T)-$(XEN_FULLVERSION)$(Z) $(D)$(BOOT_DIR)/$(T)-$(XEN_VERSION)$(Z)
+- ln -f -s $(T)-$(XEN_FULLVERSION)$(Z) $(D)$(BOOT_DIR)/$(T)$(Z)
++ $(INSTALL_DATA) $(TARGET)$(Z) $(D)$(BOOT_DIR)/$(T)-$(XEN_VERSION).$(XEN_SUBVERSION)$(Z)
++ $(INSTALL_DATA) $(TARGET)$(Z) $(D)$(BOOT_DIR)/$(T)-$(XEN_VERSION)$(Z)
++ $(INSTALL_DATA) $(TARGET)$(Z) $(D)$(BOOT_DIR)/$(T)$(Z)
+ [ -d "$(D)$(DEBUG_DIR)" ] || $(INSTALL_DIR) $(D)$(DEBUG_DIR)
+ $(INSTALL_DATA) $(TARGET)-syms $(D)$(DEBUG_DIR)/$(T)-syms-$(XEN_FULLVERSION)
+ $(INSTALL_DATA) $(TARGET)-syms.map $(D)$(DEBUG_DIR)/$(T)-syms-$(XEN_FULLVERSION).map
diff --git a/ovmf/xen-tools-4.15.1-brotli-gcc11.patch b/ovmf/xen-tools-4.15.1-brotli-gcc11.patch
new file mode 100644
index 0000000..c30cb32
--- /dev/null
+++ b/ovmf/xen-tools-4.15.1-brotli-gcc11.patch
@@ -0,0 +1,33 @@
+diff --git a/c/dec/decode.c b/c/dec/decode.c
+index ae5a3d3f..7eee9688 100644
+--- a/c/dec/decode.c
++++ b/c/dec/decode.c
+@@ -2033,8 +2033,10 @@ static BROTLI_NOINLINE BrotliDecoderErrorCode SafeProcessCommands(
+ }
+
+ BrotliDecoderResult BrotliDecoderDecompress(
+- size_t encoded_size, const uint8_t* encoded_buffer, size_t* decoded_size,
+- uint8_t* decoded_buffer) {
++ size_t encoded_size,
++ const uint8_t encoded_buffer[BROTLI_ARRAY_PARAM(encoded_size)],
++ size_t* decoded_size,
++ uint8_t decoded_buffer[BROTLI_ARRAY_PARAM(*decoded_size)]) {
+ BrotliDecoderState s;
+ BrotliDecoderResult result;
+ size_t total_out = 0;
+diff --git a/c/enc/encode.c b/c/enc/encode.c
+index 8d90937b..0c49c641 100644
+--- a/c/enc/encode.c
++++ b/c/enc/encode.c
+@@ -1470,8 +1470,9 @@ static size_t MakeUncompressedStream(
+
+ BROTLI_BOOL BrotliEncoderCompress(
+ int quality, int lgwin, BrotliEncoderMode mode, size_t input_size,
+- const uint8_t* input_buffer, size_t* encoded_size,
+- uint8_t* encoded_buffer) {
++ const uint8_t input_buffer[BROTLI_ARRAY_PARAM(input_size)],
++ size_t* encoded_size,
++ uint8_t encoded_buffer[BROTLI_ARRAY_PARAM(*encoded_size)]) {
+ BrotliEncoderState* s;
+ size_t out_size = *encoded_size;
+ const uint8_t* input_start = input_buffer;
diff --git a/xen-4.16-efi.patch b/xen-4.16-efi.patch
new file mode 100644
index 0000000..0de5575
--- /dev/null
+++ b/xen-4.16-efi.patch
@@ -0,0 +1,12 @@
+diff -urN a/xen/arch/x86/Makefile b/xen/arch/x86/Makefile
+--- a/xen/arch/x86/Makefile 2021-11-30 06:42:42.000000000 -0500
++++ b/xen/arch/x86/Makefile 2022-02-17 07:43:06.597244620 -0500
+@@ -127,7 +127,7 @@
+ CFLAGS-$(XEN_BUILD_EFI) += -DXEN_BUILD_EFI
+
+ # Check if the linker supports PE.
+-EFI_LDFLAGS = $(patsubst -m%,-mi386pep,$(XEN_LDFLAGS)) --subsystem=10
++EFI_LDFLAGS = -mi386pep $(patsubst -m%,-mi386pep,$(XEN_LDFLAGS)) --subsystem=10
+ XEN_BUILD_PE := $(if $(XEN_BUILD_EFI),$(call ld-option,$(EFI_LDFLAGS) --image-base=0x100000000 -o efi/check.efi efi/check.o))
+ # If the above failed, it may be merely because of the linker not dealing well
+ # with debug info. Try again with stripping it.