diff options
Diffstat (limited to 'gcc-11.patch')
-rw-r--r-- | gcc-11.patch | 69 |
1 files changed, 69 insertions, 0 deletions
diff --git a/gcc-11.patch b/gcc-11.patch new file mode 100644 index 000000000000..7aa60600c192 --- /dev/null +++ b/gcc-11.patch @@ -0,0 +1,69 @@ +diff --git a/tools/libs/foreignmemory/linux.c b/tools/libs/foreignmemory/linux.c +index c1f35e2db7..71ba3beb57 100644 +--- a/tools/libs/foreignmemory/linux.c ++++ b/tools/libs/foreignmemory/linux.c +@@ -161,7 +161,7 @@ out: + void *osdep_xenforeignmemory_map(xenforeignmemory_handle *fmem, + uint32_t dom, void *addr, + int prot, int flags, size_t num, +- const xen_pfn_t arr[/*num*/], int err[/*num*/]) ++ const xen_pfn_t arr[num], int err[num]) + { + int fd = fmem->fd; + privcmd_mmapbatch_v2_t ioctlx; +diff --git a/tools/libs/foreignmemory/minios.c b/tools/libs/foreignmemory/minios.c +index 43341ca301..c3ddbc8872 100644 +--- a/tools/libs/foreignmemory/minios.c ++++ b/tools/libs/foreignmemory/minios.c +@@ -42,7 +42,7 @@ int osdep_xenforeignmemory_close(xenforeignmemory_handle *fmem) + void *osdep_xenforeignmemory_map(xenforeignmemory_handle *fmem, + uint32_t dom, void *addr, + int prot, int flags, size_t num, +- const xen_pfn_t arr[/*num*/], int err[/*num*/]) ++ const xen_pfn_t arr[num], int err[num]) + { + unsigned long pt_prot = 0; + if (prot & PROT_READ) +diff --git a/xen/arch/x86/tboot.c b/xen/arch/x86/tboot.c +index aadcce591f..774c123883 100644 +--- a/xen/arch/x86/tboot.c ++++ b/xen/arch/x86/tboot.c +@@ -92,7 +92,7 @@ static void __init tboot_copy_memory(unsigned char *va, uint32_t size, + + void __init tboot_probe(void) + { +- tboot_shared_t *tboot_shared; ++ tboot_shared_t * volatile tboot_shared; + + /* Look for valid page-aligned address for shared page. */ + if ( !opt_tboot_pa || (opt_tboot_pa & ~PAGE_MASK) ) +diff --git a/xen/arch/x86/x86_emulate/x86_emulate.c b/xen/arch/x86/x86_emulate/x86_emulate.c +index c25d88d0d8..ba104602be 100644 +--- a/xen/arch/x86/x86_emulate/x86_emulate.c ++++ b/xen/arch/x86/x86_emulate/x86_emulate.c +@@ -726,9 +726,9 @@ union vex { + #define copy_VEX(ptr, vex) ({ \ + if ( !mode_64bit() ) \ + (vex).reg |= 8; \ +- (ptr)[0 - PFX_BYTES] = ext < ext_8f08 ? 0xc4 : 0x8f; \ +- (ptr)[1 - PFX_BYTES] = (vex).raw[0]; \ +- (ptr)[2 - PFX_BYTES] = (vex).raw[1]; \ ++ ((volatile uint8_t *)ptr)[0 - PFX_BYTES] = ext < ext_8f08 ? 0xc4 : 0x8f; \ ++ ((volatile uint8_t *)ptr)[1 - PFX_BYTES] = (vex).raw[0]; \ ++ ((volatile uint8_t *)ptr)[2 - PFX_BYTES] = (vex).raw[1]; \ + container_of((ptr) + 1 - PFX_BYTES, typeof(vex), raw[0]); \ + }) + +diff --git a/xen/include/crypto/vmac.h b/xen/include/crypto/vmac.h +index 457f3f5dd6..ce61e7fb35 100644 +--- a/xen/include/crypto/vmac.h ++++ b/xen/include/crypto/vmac.h +@@ -142,7 +142,7 @@ extern "C" { + + #define vmac_update vhash_update + +-void vhash_update(unsigned char m[], ++void vhash_update(uint8_t *m, + unsigned int mbytes, + vmac_ctx_t *ctx); + |