Accepting request 734658 from Virtualization
Update to v4.1.0 qemu. Also change to use multibuild. (Do I need to do anything special to handle the existing linked qemu-linux-user and qemu-testsuite packages which are done the old way?) Also switch from numbered patches to unnumbered. Add scripting changes to handle our git-based patches a different (better?) way. Disable a few block tests which randomly fail in context of build service for unknown reasons. Specify that shell for build is bash. OBS-URL: https://build.opensuse.org/request/show/734658 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/qemu?expand=0&rev=160
This commit is contained in:
commit
4004f9cda4
@ -1,42 +0,0 @@
|
||||
From: Bruce Rogers <brogers@suse.com>
|
||||
Date: Fri, 13 Apr 2018 11:46:47 -0600
|
||||
Subject: tests: test-thread-pool is racy - add some barriers
|
||||
|
||||
I imagine there is more to be done to fix the memory consistency
|
||||
races here, but these added barriers at least let it pass on ppc64le,
|
||||
whereas before it would fail regularly there.
|
||||
|
||||
[BR: minor edits to pass qemu's checkpatch script]
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
tests/test-thread-pool.c | 3 +++
|
||||
1 file changed, 3 insertions(+)
|
||||
|
||||
diff --git a/tests/test-thread-pool.c b/tests/test-thread-pool.c
|
||||
index 9cdccb3a47..2cbabaadd3 100644
|
||||
--- a/tests/test-thread-pool.c
|
||||
+++ b/tests/test-thread-pool.c
|
||||
@@ -171,6 +171,7 @@ static void do_test_cancel(bool sync)
|
||||
/* Cancel the jobs that haven't been started yet. */
|
||||
num_canceled = 0;
|
||||
for (i = 0; i < 100; i++) {
|
||||
+ smp_mb(); /* test is currently racy */
|
||||
if (atomic_cmpxchg(&data[i].n, 0, 3) == 0) {
|
||||
data[i].ret = -ECANCELED;
|
||||
if (sync) {
|
||||
@@ -185,6 +186,7 @@ static void do_test_cancel(bool sync)
|
||||
g_assert_cmpint(num_canceled, <, 100);
|
||||
|
||||
for (i = 0; i < 100; i++) {
|
||||
+ smp_mb(); /* test is currently racy */
|
||||
if (data[i].aiocb && data[i].n != 3) {
|
||||
if (sync) {
|
||||
/* Canceling the others will be a blocking operation. */
|
||||
@@ -201,6 +203,7 @@ static void do_test_cancel(bool sync)
|
||||
}
|
||||
g_assert_cmpint(active, ==, 0);
|
||||
for (i = 0; i < 100; i++) {
|
||||
+ smp_mb(); /* test is currently racy */
|
||||
if (data[i].n == 3) {
|
||||
g_assert_cmpint(data[i].ret, ==, -ECANCELED);
|
||||
g_assert(data[i].aiocb == NULL);
|
@ -1,25 +0,0 @@
|
||||
From: Bruce Rogers <brogers@suse.com>
|
||||
Date: Fri, 11 Jan 2019 16:26:21 -0700
|
||||
Subject: tests: Fix Makefile handling of check-report.tap
|
||||
|
||||
I assume this will get fixed upstream soon, but for now, fix
|
||||
what I understand to be the intended functionality.
|
||||
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
tests/Makefile.include | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/tests/Makefile.include b/tests/Makefile.include
|
||||
index 36fc73fef5..befc02ac7a 100644
|
||||
--- a/tests/Makefile.include
|
||||
+++ b/tests/Makefile.include
|
||||
@@ -923,7 +923,7 @@ check-report-unit.tap: $(check-unit-y)
|
||||
# Reports and overall runs
|
||||
|
||||
check-report.tap: $(patsubst %,check-report-qtest-%.tap, $(QTEST_TARGETS)) check-report-unit.tap
|
||||
- $(call quiet-command,./scripts/tap-merge.py $^ > $@,"GEN","$@")
|
||||
+ $(call quiet-command,./scripts/tap-merge.pl < $^ > $@,"GEN","$@")
|
||||
|
||||
# FPU Emulation tests (aka softfloat)
|
||||
#
|
@ -1,65 +0,0 @@
|
||||
From: Bruce Rogers <brogers@suse.com>
|
||||
Date: Fri, 15 Feb 2019 15:12:04 -0700
|
||||
Subject: Revert "target/i386: kvm: add VMX migration blocker"
|
||||
|
||||
This reverts commit d98f26073bebddcd3da0ba1b86c3a34e840c0fb8.
|
||||
Here is some text explaining the revert:
|
||||
I've thought about this some more, and with upstream
|
||||
discussions about it having stagnated, at this point I think
|
||||
the best solution is to revert the patch which considers it
|
||||
a migration blocker to have the vmx feature enabled. It's
|
||||
worth noting that not only are migrations blocked, but
|
||||
saving of the vm state via save/restore and snapshots.
|
||||
|
||||
Given that it is still widely known that Nested Virtualization
|
||||
is not supported by SUSE and other vendors, but is still used
|
||||
by quite a few people who understand that there are caveats
|
||||
with it's usage, I believe this migration blocker is more
|
||||
hurtful than helpful.
|
||||
|
||||
The fact that as of the v4.20 kernel, nested virtualization is
|
||||
enabled by default (for vmx), was partly why the patch was
|
||||
added in the first place. But my perspective is that perhaps
|
||||
enabling nested was still a bit premature.
|
||||
|
||||
I will make sure our qemu changelog explains that despite
|
||||
removing that migration blocker, the user is warned that
|
||||
nested virtualization is still a "use at your own risk
|
||||
feature".
|
||||
|
||||
[BR: BSC#1121604]
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
target/i386/kvm.c | 12 ------------
|
||||
1 file changed, 12 deletions(-)
|
||||
|
||||
diff --git a/target/i386/kvm.c b/target/i386/kvm.c
|
||||
index 3b29ce5c0d..6ad450d9f1 100644
|
||||
--- a/target/i386/kvm.c
|
||||
+++ b/target/i386/kvm.c
|
||||
@@ -906,7 +906,6 @@ static int hyperv_init_vcpu(X86CPU *cpu)
|
||||
}
|
||||
|
||||
static Error *invtsc_mig_blocker;
|
||||
-static Error *vmx_mig_blocker;
|
||||
|
||||
#define KVM_MAX_CPUID_ENTRIES 100
|
||||
|
||||
@@ -1270,17 +1269,6 @@ int kvm_arch_init_vcpu(CPUState *cs)
|
||||
!!(c->ecx & CPUID_EXT_SMX);
|
||||
}
|
||||
|
||||
- if ((env->features[FEAT_1_ECX] & CPUID_EXT_VMX) && !vmx_mig_blocker) {
|
||||
- error_setg(&vmx_mig_blocker,
|
||||
- "Nested VMX virtualization does not support live migration yet");
|
||||
- r = migrate_add_blocker(vmx_mig_blocker, &local_err);
|
||||
- if (local_err) {
|
||||
- error_report_err(local_err);
|
||||
- error_free(vmx_mig_blocker);
|
||||
- return r;
|
||||
- }
|
||||
- }
|
||||
-
|
||||
if (env->mcg_cap & MCG_LMCE_P) {
|
||||
has_msr_mcg_ext_ctl = has_msr_feature_control = true;
|
||||
}
|
@ -1,95 +0,0 @@
|
||||
From: =?UTF-8?q?Daniel=20P=2E=20Berrang=C3=A9?= <berrange@redhat.com>
|
||||
Date: Wed, 1 May 2019 15:50:52 +0100
|
||||
Subject: sockets: avoid string truncation warnings when copying UNIX path
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
In file included from /usr/include/string.h:494,
|
||||
from include/qemu/osdep.h:101,
|
||||
from util/qemu-sockets.c:18:
|
||||
In function ‘strncpy’,
|
||||
inlined from ‘unix_connect_saddr.isra.0’ at util/qemu-sockets.c:925:5:
|
||||
/usr/include/bits/string_fortified.h:106:10: warning: ‘__builtin_strncpy’ specified bound 108 equals destination size [-Wstringop-truncation]
|
||||
106 | return __builtin___strncpy_chk (__dest, __src, __len, __bos (__dest));
|
||||
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
In function ‘strncpy’,
|
||||
inlined from ‘unix_listen_saddr.isra.0’ at util/qemu-sockets.c:880:5:
|
||||
/usr/include/bits/string_fortified.h:106:10: warning: ‘__builtin_strncpy’ specified bound 108 equals destination size [-Wstringop-truncation]
|
||||
106 | return __builtin___strncpy_chk (__dest, __src, __len, __bos (__dest));
|
||||
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
We are already validating the UNIX socket path length earlier in
|
||||
the functions. If we save this string length when we first check
|
||||
it, then we can simply use memcpy instead of strcpy later, avoiding
|
||||
the gcc truncation warnings.
|
||||
|
||||
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
|
||||
Reviewed-by: Eric Blake <eblake@redhat.com>
|
||||
Reviewed-by: Stefano Garzarella <sgarzare@redhat.com>
|
||||
Message-Id: <20190501145052.12579-1-berrange@redhat.com>
|
||||
Signed-off-by: Laurent Vivier <laurent@vivier.eu>
|
||||
(cherry picked from commit 2d2023c3b99edb33ad4bb9791f70456ea1a1c049)
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
util/qemu-sockets.c | 12 ++++++++----
|
||||
1 file changed, 8 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/util/qemu-sockets.c b/util/qemu-sockets.c
|
||||
index 9705051690..ba6335e71a 100644
|
||||
--- a/util/qemu-sockets.c
|
||||
+++ b/util/qemu-sockets.c
|
||||
@@ -830,6 +830,7 @@ static int unix_listen_saddr(UnixSocketAddress *saddr,
|
||||
int sock, fd;
|
||||
char *pathbuf = NULL;
|
||||
const char *path;
|
||||
+ size_t pathlen;
|
||||
|
||||
sock = qemu_socket(PF_UNIX, SOCK_STREAM, 0);
|
||||
if (sock < 0) {
|
||||
@@ -845,7 +846,8 @@ static int unix_listen_saddr(UnixSocketAddress *saddr,
|
||||
path = pathbuf = g_strdup_printf("%s/qemu-socket-XXXXXX", tmpdir);
|
||||
}
|
||||
|
||||
- if (strlen(path) > sizeof(un.sun_path)) {
|
||||
+ pathlen = strlen(path);
|
||||
+ if (pathlen > sizeof(un.sun_path)) {
|
||||
error_setg(errp, "UNIX socket path '%s' is too long", path);
|
||||
error_append_hint(errp, "Path must be less than %zu bytes\n",
|
||||
sizeof(un.sun_path));
|
||||
@@ -877,7 +879,7 @@ static int unix_listen_saddr(UnixSocketAddress *saddr,
|
||||
|
||||
memset(&un, 0, sizeof(un));
|
||||
un.sun_family = AF_UNIX;
|
||||
- strncpy(un.sun_path, path, sizeof(un.sun_path));
|
||||
+ memcpy(un.sun_path, path, pathlen);
|
||||
|
||||
if (bind(sock, (struct sockaddr*) &un, sizeof(un)) < 0) {
|
||||
error_setg_errno(errp, errno, "Failed to bind socket to %s", path);
|
||||
@@ -901,6 +903,7 @@ static int unix_connect_saddr(UnixSocketAddress *saddr, Error **errp)
|
||||
{
|
||||
struct sockaddr_un un;
|
||||
int sock, rc;
|
||||
+ size_t pathlen;
|
||||
|
||||
if (saddr->path == NULL) {
|
||||
error_setg(errp, "unix connect: no path specified");
|
||||
@@ -913,7 +916,8 @@ static int unix_connect_saddr(UnixSocketAddress *saddr, Error **errp)
|
||||
return -1;
|
||||
}
|
||||
|
||||
- if (strlen(saddr->path) > sizeof(un.sun_path)) {
|
||||
+ pathlen = strlen(saddr->path);
|
||||
+ if (pathlen > sizeof(un.sun_path)) {
|
||||
error_setg(errp, "UNIX socket path '%s' is too long", saddr->path);
|
||||
error_append_hint(errp, "Path must be less than %zu bytes\n",
|
||||
sizeof(un.sun_path));
|
||||
@@ -922,7 +926,7 @@ static int unix_connect_saddr(UnixSocketAddress *saddr, Error **errp)
|
||||
|
||||
memset(&un, 0, sizeof(un));
|
||||
un.sun_family = AF_UNIX;
|
||||
- strncpy(un.sun_path, saddr->path, sizeof(un.sun_path));
|
||||
+ memcpy(un.sun_path, saddr->path, pathlen);
|
||||
|
||||
/* connect to peer */
|
||||
do {
|
@ -1,47 +0,0 @@
|
||||
From: =?UTF-8?q?Daniel=20P=2E=20Berrang=C3=A9?= <berrange@redhat.com>
|
||||
Date: Wed, 1 May 2019 15:46:46 +0100
|
||||
Subject: linux-user: avoid string truncation warnings in uname field copying
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
In file included from /usr/include/string.h:494,
|
||||
from include/qemu/osdep.h:101,
|
||||
from linux-user/uname.c:20:
|
||||
In function ‘strncpy’,
|
||||
inlined from ‘sys_uname’ at linux-user/uname.c:94:3:
|
||||
/usr/include/bits/string_fortified.h:106:10: warning: ‘__builtin_strncpy’ output may be truncated copying 64 bytes from a string of length 64 [-Wstringop-truncation]
|
||||
106 | return __builtin___strncpy_chk (__dest, __src, __len, __bos (__dest));
|
||||
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
We don't care where the NUL terminator in the original uname
|
||||
field was. It suffices to copy the entire original field and
|
||||
simply force a NUL terminator at the end of the new field.
|
||||
|
||||
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
|
||||
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
|
||||
Message-Id: <20190501144646.4851-1-berrange@redhat.com>
|
||||
Signed-off-by: Laurent Vivier <laurent@vivier.eu>
|
||||
[BR: Played with indent to avoid error from checkpatch.pl]
|
||||
(cherry picked from commit b2acfb55962bc8caeaa50a5158da2f701f2c1f7c)
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
linux-user/uname.c | 5 ++---
|
||||
1 file changed, 2 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/linux-user/uname.c b/linux-user/uname.c
|
||||
index 313b79dbad..0c6ddf2ad9 100644
|
||||
--- a/linux-user/uname.c
|
||||
+++ b/linux-user/uname.c
|
||||
@@ -72,9 +72,8 @@ const char *cpu_to_uname_machine(void *cpu_env)
|
||||
|
||||
#define COPY_UTSNAME_FIELD(dest, src) \
|
||||
do { \
|
||||
- /* __NEW_UTS_LEN doesn't include terminating null */ \
|
||||
- (void) strncpy((dest), (src), __NEW_UTS_LEN); \
|
||||
- (dest)[__NEW_UTS_LEN] = '\0'; \
|
||||
+ memcpy((dest), (src), MIN(sizeof(src), sizeof(dest))); \
|
||||
+ (dest)[sizeof(dest) - 1] = '\0'; \
|
||||
} while (0)
|
||||
|
||||
int sys_uname(struct new_utsname *buf)
|
@ -1,40 +0,0 @@
|
||||
From: Alistair Francis <Alistair.Francis@wdc.com>
|
||||
Date: Tue, 30 Apr 2019 23:29:01 +0000
|
||||
Subject: linux-user/elfload: Fix GCC 9 build warnings
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
Fix this warning when building with GCC9 on Fedora 30:
|
||||
In function ‘strncpy’,
|
||||
inlined from ‘fill_psinfo’ at /home/alistair/qemu/linux-user/elfload.c:3208:12,
|
||||
inlined from ‘fill_note_info’ at /home/alistair/qemu/linux-user/elfload.c:3390:5,
|
||||
inlined from ‘elf_core_dump’ at /home/alistair/qemu/linux-user/elfload.c:3539:9:
|
||||
/usr/include/bits/string_fortified.h:106:10: error: ‘__builtin_strncpy’ specified bound 16 equals destination size [-Werror=stringop-truncation]
|
||||
106 | return __builtin___strncpy_chk (__dest, __src, __len, __bos (__dest));
|
||||
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
|
||||
Reviewed-by: Laurent Vivier <laurent@vivier.eu>
|
||||
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
|
||||
Message-Id: <c4d2b1de9efadcf1c900b91361af9302823a72a9.1556666645.git.alistair.francis@wdc.com>
|
||||
Signed-off-by: Laurent Vivier <laurent@vivier.eu>
|
||||
(cherry picked from commit d7eb2b928a855a2e8038e8e75f7edf1a12226bd3)
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
linux-user/elfload.c | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/linux-user/elfload.c b/linux-user/elfload.c
|
||||
index c1a26021f8..d08fe23466 100644
|
||||
--- a/linux-user/elfload.c
|
||||
+++ b/linux-user/elfload.c
|
||||
@@ -2872,7 +2872,7 @@ struct target_elf_prpsinfo {
|
||||
target_gid_t pr_gid;
|
||||
target_pid_t pr_pid, pr_ppid, pr_pgrp, pr_sid;
|
||||
/* Lots missing */
|
||||
- char pr_fname[16]; /* filename of executable */
|
||||
+ char pr_fname[16] QEMU_NONSTRING; /* filename of executable */
|
||||
char pr_psargs[ELF_PRARGSZ]; /* initial part of arg list */
|
||||
};
|
||||
|
@ -1,144 +0,0 @@
|
||||
From: =?UTF-8?q?Daniel=20P=2E=20Berrang=C3=A9?= <berrange@redhat.com>
|
||||
Date: Fri, 12 Apr 2019 13:16:26 +0100
|
||||
Subject: qxl: avoid unaligned pointer reads/writes
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
The SPICE_RING_PROD_ITEM() macro is initializing a local
|
||||
'uint64_t *' variable to point to the 'el' field inside
|
||||
the QXLReleaseRing struct. This uint64_t field is not
|
||||
guaranteed aligned as the struct is packed.
|
||||
|
||||
Code should not take the address of fields within a
|
||||
packed struct. Changing the SPICE_RING_PROD_ITEM()
|
||||
macro to avoid taking the address of the field is
|
||||
impractical. It is clearer to just remove the macro
|
||||
and inline its functionality in the three call sites
|
||||
that need it.
|
||||
|
||||
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
|
||||
Message-Id: <20190412121626.19829-6-berrange@redhat.com>
|
||||
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
|
||||
(cherry picked from commit 94932c95c10400acd286fd768a6b411e7ebbec8f)
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
hw/display/qxl.c | 55 +++++++++++++++++++++---------------------------
|
||||
1 file changed, 24 insertions(+), 31 deletions(-)
|
||||
|
||||
diff --git a/hw/display/qxl.c b/hw/display/qxl.c
|
||||
index c8ce5781e0..5c38e6e906 100644
|
||||
--- a/hw/display/qxl.c
|
||||
+++ b/hw/display/qxl.c
|
||||
@@ -33,24 +33,6 @@
|
||||
|
||||
#include "qxl.h"
|
||||
|
||||
-/*
|
||||
- * NOTE: SPICE_RING_PROD_ITEM accesses memory on the pci bar and as
|
||||
- * such can be changed by the guest, so to avoid a guest trigerrable
|
||||
- * abort we just qxl_set_guest_bug and set the return to NULL. Still
|
||||
- * it may happen as a result of emulator bug as well.
|
||||
- */
|
||||
-#undef SPICE_RING_PROD_ITEM
|
||||
-#define SPICE_RING_PROD_ITEM(qxl, r, ret) { \
|
||||
- uint32_t prod = (r)->prod & SPICE_RING_INDEX_MASK(r); \
|
||||
- if (prod >= ARRAY_SIZE((r)->items)) { \
|
||||
- qxl_set_guest_bug(qxl, "SPICE_RING_PROD_ITEM indices mismatch " \
|
||||
- "%u >= %zu", prod, ARRAY_SIZE((r)->items)); \
|
||||
- ret = NULL; \
|
||||
- } else { \
|
||||
- ret = &(r)->items[prod].el; \
|
||||
- } \
|
||||
- }
|
||||
-
|
||||
#undef SPICE_RING_CONS_ITEM
|
||||
#define SPICE_RING_CONS_ITEM(qxl, r, ret) { \
|
||||
uint32_t cons = (r)->cons & SPICE_RING_INDEX_MASK(r); \
|
||||
@@ -414,7 +396,8 @@ static void init_qxl_rom(PCIQXLDevice *d)
|
||||
static void init_qxl_ram(PCIQXLDevice *d)
|
||||
{
|
||||
uint8_t *buf;
|
||||
- uint64_t *item;
|
||||
+ uint32_t prod;
|
||||
+ QXLReleaseRing *ring;
|
||||
|
||||
buf = d->vga.vram_ptr;
|
||||
d->ram = (QXLRam *)(buf + le32_to_cpu(d->shadow_rom.ram_header_offset));
|
||||
@@ -426,9 +409,12 @@ static void init_qxl_ram(PCIQXLDevice *d)
|
||||
SPICE_RING_INIT(&d->ram->cmd_ring);
|
||||
SPICE_RING_INIT(&d->ram->cursor_ring);
|
||||
SPICE_RING_INIT(&d->ram->release_ring);
|
||||
- SPICE_RING_PROD_ITEM(d, &d->ram->release_ring, item);
|
||||
- assert(item);
|
||||
- *item = 0;
|
||||
+
|
||||
+ ring = &d->ram->release_ring;
|
||||
+ prod = ring->prod & SPICE_RING_INDEX_MASK(ring);
|
||||
+ assert(prod < ARRAY_SIZE(ring->items));
|
||||
+ ring->items[prod].el = 0;
|
||||
+
|
||||
qxl_ring_set_dirty(d);
|
||||
}
|
||||
|
||||
@@ -732,7 +718,7 @@ static int interface_req_cmd_notification(QXLInstance *sin)
|
||||
static inline void qxl_push_free_res(PCIQXLDevice *d, int flush)
|
||||
{
|
||||
QXLReleaseRing *ring = &d->ram->release_ring;
|
||||
- uint64_t *item;
|
||||
+ uint32_t prod;
|
||||
int notify;
|
||||
|
||||
#define QXL_FREE_BUNCH_SIZE 32
|
||||
@@ -759,11 +745,15 @@ static inline void qxl_push_free_res(PCIQXLDevice *d, int flush)
|
||||
if (notify) {
|
||||
qxl_send_events(d, QXL_INTERRUPT_DISPLAY);
|
||||
}
|
||||
- SPICE_RING_PROD_ITEM(d, ring, item);
|
||||
- if (!item) {
|
||||
+
|
||||
+ ring = &d->ram->release_ring;
|
||||
+ prod = ring->prod & SPICE_RING_INDEX_MASK(ring);
|
||||
+ if (prod >= ARRAY_SIZE(ring->items)) {
|
||||
+ qxl_set_guest_bug(d, "SPICE_RING_PROD_ITEM indices mismatch "
|
||||
+ "%u >= %zu", prod, ARRAY_SIZE(ring->items));
|
||||
return;
|
||||
}
|
||||
- *item = 0;
|
||||
+ ring->items[prod].el = 0;
|
||||
d->num_free_res = 0;
|
||||
d->last_release = NULL;
|
||||
qxl_ring_set_dirty(d);
|
||||
@@ -775,7 +765,8 @@ static void interface_release_resource(QXLInstance *sin,
|
||||
{
|
||||
PCIQXLDevice *qxl = container_of(sin, PCIQXLDevice, ssd.qxl);
|
||||
QXLReleaseRing *ring;
|
||||
- uint64_t *item, id;
|
||||
+ uint32_t prod;
|
||||
+ uint64_t id;
|
||||
|
||||
if (ext.group_id == MEMSLOT_GROUP_HOST) {
|
||||
/* host group -> vga mode update request */
|
||||
@@ -792,16 +783,18 @@ static void interface_release_resource(QXLInstance *sin,
|
||||
* pci bar 0, $command.release_info
|
||||
*/
|
||||
ring = &qxl->ram->release_ring;
|
||||
- SPICE_RING_PROD_ITEM(qxl, ring, item);
|
||||
- if (!item) {
|
||||
+ prod = ring->prod & SPICE_RING_INDEX_MASK(ring);
|
||||
+ if (prod >= ARRAY_SIZE(ring->items)) {
|
||||
+ qxl_set_guest_bug(qxl, "SPICE_RING_PROD_ITEM indices mismatch "
|
||||
+ "%u >= %zu", prod, ARRAY_SIZE(ring->items));
|
||||
return;
|
||||
}
|
||||
- if (*item == 0) {
|
||||
+ if (ring->items[prod].el == 0) {
|
||||
/* stick head into the ring */
|
||||
id = ext.info->id;
|
||||
ext.info->next = 0;
|
||||
qxl_ram_set_dirty(qxl, &ext.info->next);
|
||||
- *item = id;
|
||||
+ ring->items[prod].el = id;
|
||||
qxl_ring_set_dirty(qxl);
|
||||
} else {
|
||||
/* append item to the list */
|
@ -1,60 +0,0 @@
|
||||
From: =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= <marcandre.lureau@redhat.com>
|
||||
Date: Fri, 3 May 2019 15:00:29 +0200
|
||||
Subject: libvhost-user: fix -Waddress-of-packed-member
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
/home/elmarco/src/qemu/contrib/libvhost-user/libvhost-user.c: In function ‘vu_set_mem_table_exec_postcopy’:
|
||||
/home/elmarco/src/qemu/contrib/libvhost-user/libvhost-user.c:546:31: warning: taking address of packed member of ‘struct VhostUserMsg’ may result in an unaligned pointer value [-Waddress-of-packed-member]
|
||||
546 | VhostUserMemory *memory = &vmsg->payload.memory;
|
||||
| ^~~~~~~~~~~~~~~~~~~~~
|
||||
/home/elmarco/src/qemu/contrib/libvhost-user/libvhost-user.c: In function ‘vu_set_mem_table_exec’:
|
||||
/home/elmarco/src/qemu/contrib/libvhost-user/libvhost-user.c:688:31: warning: taking address of packed member of ‘struct VhostUserMsg’ may result in an unaligned pointer value [-Waddress-of-packed-member]
|
||||
688 | VhostUserMemory *memory = &vmsg->payload.memory;
|
||||
| ^~~~~~~~~~~~~~~~~~~~~
|
||||
/home/elmarco/src/qemu/contrib/libvhost-user/libvhost-user.c: In function ‘vu_set_vring_addr_exec’:
|
||||
/home/elmarco/src/qemu/contrib/libvhost-user/libvhost-user.c:817:36: warning: taking address of packed member of ‘struct VhostUserMsg’ may result in an unaligned pointer value [-Waddress-of-packed-member]
|
||||
817 | struct vhost_vring_addr *vra = &vmsg->payload.addr;
|
||||
| ^~~~~~~~~~~~~~~~~~~
|
||||
|
||||
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
|
||||
Message-id: 20190503130034.24916-2-marcandre.lureau@redhat.com
|
||||
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
|
||||
(cherry picked from commit d288eef3a0a8ac46cc45808b50d73606476148b0)
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
contrib/libvhost-user/libvhost-user.c | 6 +++---
|
||||
1 file changed, 3 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/contrib/libvhost-user/libvhost-user.c b/contrib/libvhost-user/libvhost-user.c
|
||||
index e08d6c7b97..dcf4a969f2 100644
|
||||
--- a/contrib/libvhost-user/libvhost-user.c
|
||||
+++ b/contrib/libvhost-user/libvhost-user.c
|
||||
@@ -542,7 +542,7 @@ static bool
|
||||
vu_set_mem_table_exec_postcopy(VuDev *dev, VhostUserMsg *vmsg)
|
||||
{
|
||||
int i;
|
||||
- VhostUserMemory *memory = &vmsg->payload.memory;
|
||||
+ VhostUserMemory m = vmsg->payload.memory, *memory = &m;
|
||||
dev->nregions = memory->nregions;
|
||||
|
||||
DPRINT("Nregions: %d\n", memory->nregions);
|
||||
@@ -684,7 +684,7 @@ static bool
|
||||
vu_set_mem_table_exec(VuDev *dev, VhostUserMsg *vmsg)
|
||||
{
|
||||
int i;
|
||||
- VhostUserMemory *memory = &vmsg->payload.memory;
|
||||
+ VhostUserMemory m = vmsg->payload.memory, *memory = &m;
|
||||
|
||||
for (i = 0; i < dev->nregions; i++) {
|
||||
VuDevRegion *r = &dev->regions[i];
|
||||
@@ -813,7 +813,7 @@ vu_set_vring_num_exec(VuDev *dev, VhostUserMsg *vmsg)
|
||||
static bool
|
||||
vu_set_vring_addr_exec(VuDev *dev, VhostUserMsg *vmsg)
|
||||
{
|
||||
- struct vhost_vring_addr *vra = &vmsg->payload.addr;
|
||||
+ struct vhost_vring_addr addr = vmsg->payload.addr, *vra = &addr;
|
||||
unsigned int index = vra->index;
|
||||
VuVirtq *vq = &dev->vq[index];
|
||||
|
@ -1,32 +0,0 @@
|
||||
From: Paolo Bonzini <pbonzini@redhat.com>
|
||||
Date: Wed, 15 May 2019 15:10:10 +0100
|
||||
Subject: target/i386: define md-clear bit
|
||||
|
||||
md-clear is a new CPUID bit which is set when microcode provides the
|
||||
mechanism to invoke a flush of various exploitable CPU buffers by invoking
|
||||
the VERW instruction.
|
||||
|
||||
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
|
||||
Message-Id: <20190515141011.5315-2-berrange@redhat.com>
|
||||
Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
|
||||
(cherry picked from commit b2ae52101fca7f9547ac2f388085dbc58f8fe1c0)
|
||||
[BR: BSC#1111331 CVE-2018-12126 CVE-2018-12127 CVE-2018-12130
|
||||
CVE-2019-11091]
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
target/i386/cpu.c | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/target/i386/cpu.c b/target/i386/cpu.c
|
||||
index d6bb57d210..4ea78a4939 100644
|
||||
--- a/target/i386/cpu.c
|
||||
+++ b/target/i386/cpu.c
|
||||
@@ -1076,7 +1076,7 @@ static FeatureWordInfo feature_word_info[FEATURE_WORDS] = {
|
||||
.feat_names = {
|
||||
NULL, NULL, "avx512-4vnniw", "avx512-4fmaps",
|
||||
NULL, NULL, NULL, NULL,
|
||||
- NULL, NULL, NULL, NULL,
|
||||
+ NULL, NULL, "md-clear", NULL,
|
||||
NULL, NULL, NULL, NULL,
|
||||
NULL, NULL, NULL, NULL,
|
||||
NULL, NULL, NULL, NULL,
|
@ -1,36 +0,0 @@
|
||||
From: Gerd Hoffmann <kraxel@redhat.com>
|
||||
Date: Tue, 14 May 2019 06:24:43 +0200
|
||||
Subject: kbd-state: fix autorepeat handling
|
||||
|
||||
When allowing multiple down-events in a row (key autorepeat) we can't
|
||||
use change_bit() any more to update the state, because autorepeat events
|
||||
don't change the key state. We have to explicitly use set_bit() and
|
||||
clear_bit() instead.
|
||||
|
||||
Cc: qemu-stable@nongnu.org
|
||||
Fixes: 35921860156e kbd-state: don't block auto-repeat events
|
||||
Buglink: https://bugs.launchpad.net/qemu/+bug/1828272
|
||||
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
|
||||
Message-id: 20190514042443.10735-1-kraxel@redhat.com
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
ui/kbd-state.c | 6 +++++-
|
||||
1 file changed, 5 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/ui/kbd-state.c b/ui/kbd-state.c
|
||||
index f3ab2d7a66..1668d17dda 100644
|
||||
--- a/ui/kbd-state.c
|
||||
+++ b/ui/kbd-state.c
|
||||
@@ -59,7 +59,11 @@ void qkbd_state_key_event(QKbdState *kbd, QKeyCode qcode, bool down)
|
||||
}
|
||||
|
||||
/* update key and modifier state */
|
||||
- change_bit(qcode, kbd->keys);
|
||||
+ if (down) {
|
||||
+ set_bit(qcode, kbd->keys);
|
||||
+ } else {
|
||||
+ clear_bit(qcode, kbd->keys);
|
||||
+ }
|
||||
switch (qcode) {
|
||||
case Q_KEY_CODE_SHIFT:
|
||||
case Q_KEY_CODE_SHIFT_R:
|
@ -1,24 +0,0 @@
|
||||
From: Bruce Rogers <brogers@suse.com>
|
||||
Date: Tue, 28 May 2019 13:35:39 -0600
|
||||
Subject: target/ppc: ensure we get null terminated rtas token name
|
||||
|
||||
Leave room for null termination of the string when doing strncpy.
|
||||
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
target/ppc/kvm.c | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/target/ppc/kvm.c b/target/ppc/kvm.c
|
||||
index 2427c8ee13..7885de2d7c 100644
|
||||
--- a/target/ppc/kvm.c
|
||||
+++ b/target/ppc/kvm.c
|
||||
@@ -2605,7 +2605,7 @@ int kvmppc_define_rtas_kernel_token(uint32_t token, const char *function)
|
||||
return -ENOENT;
|
||||
}
|
||||
|
||||
- strncpy(args.name, function, sizeof(args.name));
|
||||
+ strncpy(args.name, function, sizeof(args.name) - 1);
|
||||
|
||||
return kvm_vm_ioctl(kvm_state, KVM_PPC_RTAS_DEFINE_TOKEN, &args);
|
||||
}
|
@ -1,33 +0,0 @@
|
||||
From: Prasad J Pandit <pjp@fedoraproject.org>
|
||||
Date: Thu, 25 Apr 2019 12:05:34 +0530
|
||||
Subject: qxl: check release info object
|
||||
|
||||
When releasing spice resources in release_resource() routine,
|
||||
if release info object 'ext.info' is null, it leads to null
|
||||
pointer dereference. Add check to avoid it.
|
||||
|
||||
Reported-by: Bugs SysSec <bugs-syssec@rub.de>
|
||||
Signed-off-by: Prasad J Pandit <pjp@fedoraproject.org>
|
||||
Message-id: 20190425063534.32747-1-ppandit@redhat.com
|
||||
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
|
||||
(cherry picked from commit d52680fc932efb8a2f334cc6993e705ed1e31e99)
|
||||
[LY: BSC#1135902 CVE-2019-12155]
|
||||
Signed-off-by: Liang Yan <lyan@suse.com>
|
||||
---
|
||||
hw/display/qxl.c | 3 +++
|
||||
1 file changed, 3 insertions(+)
|
||||
|
||||
diff --git a/hw/display/qxl.c b/hw/display/qxl.c
|
||||
index 5c38e6e906..3880a7410b 100644
|
||||
--- a/hw/display/qxl.c
|
||||
+++ b/hw/display/qxl.c
|
||||
@@ -768,6 +768,9 @@ static void interface_release_resource(QXLInstance *sin,
|
||||
uint32_t prod;
|
||||
uint64_t id;
|
||||
|
||||
+ if (!ext.info) {
|
||||
+ return;
|
||||
+ }
|
||||
if (ext.group_id == MEMSLOT_GROUP_HOST) {
|
||||
/* host group -> vga mode update request */
|
||||
QXLCommandExt *cmdext = (void *)(intptr_t)(ext.info->id);
|
@ -1,48 +0,0 @@
|
||||
From: Liang Yan <lyan@suse.com>
|
||||
Date: Thu, 25 Jul 2019 13:28:26 -0400
|
||||
Subject: qemu-bridge-helper: restrict interface name
|
||||
|
||||
The interface names in qemu-bridge-helper are defined to be
|
||||
of size IFNAMSIZ(=16), including the terminating null('\0') byte.
|
||||
The same is applied to interface names read from 'bridge.conf'
|
||||
file to form ACLs rules. If user supplied '--br=bridge' name
|
||||
is not restricted to the same length, it could lead to ACL bypass
|
||||
issue. Restrict bridge name to IFNAMSIZ, including null byte.
|
||||
|
||||
Reported-by: Riccardo Schirone <rschiron@redhat.com>
|
||||
Signed-off-by: Prasad J Pandit <pjp@fedoraproject.org>
|
||||
[LY: BSC#1140402 CVE-2019-13164]
|
||||
Signed-off-by: Liang Yan <lyan@suse.com>
|
||||
---
|
||||
qemu-bridge-helper.c | 11 +++++++++++
|
||||
1 file changed, 11 insertions(+)
|
||||
|
||||
diff --git a/qemu-bridge-helper.c b/qemu-bridge-helper.c
|
||||
index cafe2bf27b..8ae6104ec4 100644
|
||||
--- a/qemu-bridge-helper.c
|
||||
+++ b/qemu-bridge-helper.c
|
||||
@@ -109,6 +109,13 @@ static int parse_acl_file(const char *filename, ACLList *acl_list)
|
||||
}
|
||||
*argend = 0;
|
||||
|
||||
+ if (!g_str_equal(cmd, "include") && strlen(arg) >= IFNAMSIZ) {
|
||||
+ fprintf(stderr, "name `%s' too long: %zu\n", arg, strlen(arg));
|
||||
+ fclose(f);
|
||||
+ errno = EINVAL;
|
||||
+ return -1;
|
||||
+ }
|
||||
+
|
||||
if (strcmp(cmd, "deny") == 0) {
|
||||
acl_rule = calloc(1, sizeof(*acl_rule));
|
||||
if (!acl_rule) {
|
||||
@@ -264,6 +271,10 @@ int main(int argc, char **argv)
|
||||
return EXIT_FAILURE;
|
||||
}
|
||||
}
|
||||
+ if (strlen(bridge) >= IFNAMSIZ) {
|
||||
+ fprintf(stderr, "name `%s' too long: %zu\n", bridge, strlen(bridge));
|
||||
+ return EXIT_FAILURE;
|
||||
+ }
|
||||
|
||||
if (bridge == NULL || unixfd == -1) {
|
||||
usage();
|
@ -1,334 +0,0 @@
|
||||
From: =?UTF-8?q?Daniel=20P=2E=20Berrang=C3=A9?= <berrange@redhat.com>
|
||||
Date: Thu, 18 Jul 2019 15:06:41 +0200
|
||||
Subject: linux-user: fix to handle variably sized SIOCGSTAMP with new kernels
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
The SIOCGSTAMP symbol was previously defined in the
|
||||
asm-generic/sockios.h header file. QEMU sees that header
|
||||
indirectly via sys/socket.h
|
||||
|
||||
In linux kernel commit 0768e17073dc527ccd18ed5f96ce85f9985e9115
|
||||
the asm-generic/sockios.h header no longer defines SIOCGSTAMP.
|
||||
Instead it provides only SIOCGSTAMP_OLD, which only uses a
|
||||
32-bit time_t on 32-bit architectures.
|
||||
|
||||
The linux/sockios.h header then defines SIOCGSTAMP using
|
||||
either SIOCGSTAMP_OLD or SIOCGSTAMP_NEW as appropriate. If
|
||||
SIOCGSTAMP_NEW is used, then the tv_sec field is 64-bit even
|
||||
on 32-bit architectures
|
||||
|
||||
To cope with this we must now convert the old and new type from
|
||||
the target to the host one.
|
||||
|
||||
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
|
||||
Signed-off-by: Laurent Vivier <laurent@vivier.eu>
|
||||
Reviewed-by: Arnd Bergmann <arnd@arndb.de>
|
||||
Message-Id: <20190718130641.15294-1-laurent@vivier.eu>
|
||||
Signed-off-by: Laurent Vivier <laurent@vivier.eu>
|
||||
(cherry picked from commit 6d5d5dde9adb5acb32e6b8e3dfbf47fff0f308d2)
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
linux-user/ioctls.h | 21 +++++-
|
||||
linux-user/syscall.c | 140 +++++++++++++++++++++++++++++--------
|
||||
linux-user/syscall_defs.h | 31 +++++++-
|
||||
linux-user/syscall_types.h | 6 --
|
||||
4 files changed, 160 insertions(+), 38 deletions(-)
|
||||
|
||||
diff --git a/linux-user/ioctls.h b/linux-user/ioctls.h
|
||||
index ae8951625f..e6a27ad9d6 100644
|
||||
--- a/linux-user/ioctls.h
|
||||
+++ b/linux-user/ioctls.h
|
||||
@@ -219,8 +219,25 @@
|
||||
IOCTL(SIOCGRARP, IOC_R, MK_PTR(MK_STRUCT(STRUCT_arpreq)))
|
||||
IOCTL(SIOCGIWNAME, IOC_W | IOC_R, MK_PTR(MK_STRUCT(STRUCT_char_ifreq)))
|
||||
IOCTL(SIOCGPGRP, IOC_R, MK_PTR(TYPE_INT)) /* pid_t */
|
||||
- IOCTL(SIOCGSTAMP, IOC_R, MK_PTR(MK_STRUCT(STRUCT_timeval)))
|
||||
- IOCTL(SIOCGSTAMPNS, IOC_R, MK_PTR(MK_STRUCT(STRUCT_timespec)))
|
||||
+
|
||||
+ /*
|
||||
+ * We can't use IOCTL_SPECIAL() because it will set
|
||||
+ * host_cmd to XXX_OLD and XXX_NEW and these macros
|
||||
+ * are not defined with kernel prior to 5.2.
|
||||
+ * We must set host_cmd to the same value as in target_cmd
|
||||
+ * otherwise the consistency check in syscall_init()
|
||||
+ * will trigger an error.
|
||||
+ * host_cmd is ignored by the do_ioctl_XXX() helpers.
|
||||
+ * FIXME: create a macro to define this kind of entry
|
||||
+ */
|
||||
+ { TARGET_SIOCGSTAMP_OLD, TARGET_SIOCGSTAMP_OLD,
|
||||
+ "SIOCGSTAMP_OLD", IOC_R, do_ioctl_SIOCGSTAMP },
|
||||
+ { TARGET_SIOCGSTAMPNS_OLD, TARGET_SIOCGSTAMPNS_OLD,
|
||||
+ "SIOCGSTAMPNS_OLD", IOC_R, do_ioctl_SIOCGSTAMPNS },
|
||||
+ { TARGET_SIOCGSTAMP_NEW, TARGET_SIOCGSTAMP_NEW,
|
||||
+ "SIOCGSTAMP_NEW", IOC_R, do_ioctl_SIOCGSTAMP },
|
||||
+ { TARGET_SIOCGSTAMPNS_NEW, TARGET_SIOCGSTAMPNS_NEW,
|
||||
+ "SIOCGSTAMPNS_NEW", IOC_R, do_ioctl_SIOCGSTAMPNS },
|
||||
|
||||
IOCTL(RNDGETENTCNT, IOC_R, MK_PTR(TYPE_INT))
|
||||
IOCTL(RNDADDTOENTCNT, IOC_W, MK_PTR(TYPE_INT))
|
||||
diff --git a/linux-user/syscall.c b/linux-user/syscall.c
|
||||
index ed1c76e304..4e94bf6ecf 100644
|
||||
--- a/linux-user/syscall.c
|
||||
+++ b/linux-user/syscall.c
|
||||
@@ -37,6 +37,7 @@
|
||||
#include <sched.h>
|
||||
#include <sys/timex.h>
|
||||
#include <sys/socket.h>
|
||||
+#include <linux/sockios.h>
|
||||
#include <sys/un.h>
|
||||
#include <sys/uio.h>
|
||||
#include <poll.h>
|
||||
@@ -1139,8 +1140,9 @@ static inline abi_long copy_from_user_timeval(struct timeval *tv,
|
||||
{
|
||||
struct target_timeval *target_tv;
|
||||
|
||||
- if (!lock_user_struct(VERIFY_READ, target_tv, target_tv_addr, 1))
|
||||
+ if (!lock_user_struct(VERIFY_READ, target_tv, target_tv_addr, 1)) {
|
||||
return -TARGET_EFAULT;
|
||||
+ }
|
||||
|
||||
__get_user(tv->tv_sec, &target_tv->tv_sec);
|
||||
__get_user(tv->tv_usec, &target_tv->tv_usec);
|
||||
@@ -1155,8 +1157,26 @@ static inline abi_long copy_to_user_timeval(abi_ulong target_tv_addr,
|
||||
{
|
||||
struct target_timeval *target_tv;
|
||||
|
||||
- if (!lock_user_struct(VERIFY_WRITE, target_tv, target_tv_addr, 0))
|
||||
+ if (!lock_user_struct(VERIFY_WRITE, target_tv, target_tv_addr, 0)) {
|
||||
+ return -TARGET_EFAULT;
|
||||
+ }
|
||||
+
|
||||
+ __put_user(tv->tv_sec, &target_tv->tv_sec);
|
||||
+ __put_user(tv->tv_usec, &target_tv->tv_usec);
|
||||
+
|
||||
+ unlock_user_struct(target_tv, target_tv_addr, 1);
|
||||
+
|
||||
+ return 0;
|
||||
+}
|
||||
+
|
||||
+static inline abi_long copy_to_user_timeval64(abi_ulong target_tv_addr,
|
||||
+ const struct timeval *tv)
|
||||
+{
|
||||
+ struct target__kernel_sock_timeval *target_tv;
|
||||
+
|
||||
+ if (!lock_user_struct(VERIFY_WRITE, target_tv, target_tv_addr, 0)) {
|
||||
return -TARGET_EFAULT;
|
||||
+ }
|
||||
|
||||
__put_user(tv->tv_sec, &target_tv->tv_sec);
|
||||
__put_user(tv->tv_usec, &target_tv->tv_usec);
|
||||
@@ -1166,6 +1186,48 @@ static inline abi_long copy_to_user_timeval(abi_ulong target_tv_addr,
|
||||
return 0;
|
||||
}
|
||||
|
||||
+static inline abi_long target_to_host_timespec(struct timespec *host_ts,
|
||||
+ abi_ulong target_addr)
|
||||
+{
|
||||
+ struct target_timespec *target_ts;
|
||||
+
|
||||
+ if (!lock_user_struct(VERIFY_READ, target_ts, target_addr, 1)) {
|
||||
+ return -TARGET_EFAULT;
|
||||
+ }
|
||||
+ __get_user(host_ts->tv_sec, &target_ts->tv_sec);
|
||||
+ __get_user(host_ts->tv_nsec, &target_ts->tv_nsec);
|
||||
+ unlock_user_struct(target_ts, target_addr, 0);
|
||||
+ return 0;
|
||||
+}
|
||||
+
|
||||
+static inline abi_long host_to_target_timespec(abi_ulong target_addr,
|
||||
+ struct timespec *host_ts)
|
||||
+{
|
||||
+ struct target_timespec *target_ts;
|
||||
+
|
||||
+ if (!lock_user_struct(VERIFY_WRITE, target_ts, target_addr, 0)) {
|
||||
+ return -TARGET_EFAULT;
|
||||
+ }
|
||||
+ __put_user(host_ts->tv_sec, &target_ts->tv_sec);
|
||||
+ __put_user(host_ts->tv_nsec, &target_ts->tv_nsec);
|
||||
+ unlock_user_struct(target_ts, target_addr, 1);
|
||||
+ return 0;
|
||||
+}
|
||||
+
|
||||
+static inline abi_long host_to_target_timespec64(abi_ulong target_addr,
|
||||
+ struct timespec *host_ts)
|
||||
+{
|
||||
+ struct target__kernel_timespec *target_ts;
|
||||
+
|
||||
+ if (!lock_user_struct(VERIFY_WRITE, target_ts, target_addr, 0)) {
|
||||
+ return -TARGET_EFAULT;
|
||||
+ }
|
||||
+ __put_user(host_ts->tv_sec, &target_ts->tv_sec);
|
||||
+ __put_user(host_ts->tv_nsec, &target_ts->tv_nsec);
|
||||
+ unlock_user_struct(target_ts, target_addr, 1);
|
||||
+ return 0;
|
||||
+}
|
||||
+
|
||||
static inline abi_long copy_from_user_timezone(struct timezone *tz,
|
||||
abi_ulong target_tz_addr)
|
||||
{
|
||||
@@ -4790,6 +4852,54 @@ static abi_long do_ioctl_kdsigaccept(const IOCTLEntry *ie, uint8_t *buf_temp,
|
||||
return get_errno(safe_ioctl(fd, ie->host_cmd, sig));
|
||||
}
|
||||
|
||||
+static abi_long do_ioctl_SIOCGSTAMP(const IOCTLEntry *ie, uint8_t *buf_temp,
|
||||
+ int fd, int cmd, abi_long arg)
|
||||
+{
|
||||
+ struct timeval tv;
|
||||
+ abi_long ret;
|
||||
+
|
||||
+ ret = get_errno(safe_ioctl(fd, SIOCGSTAMP, &tv));
|
||||
+ if (is_error(ret)) {
|
||||
+ return ret;
|
||||
+ }
|
||||
+
|
||||
+ if (cmd == (int)TARGET_SIOCGSTAMP_OLD) {
|
||||
+ if (copy_to_user_timeval(arg, &tv)) {
|
||||
+ return -TARGET_EFAULT;
|
||||
+ }
|
||||
+ } else {
|
||||
+ if (copy_to_user_timeval64(arg, &tv)) {
|
||||
+ return -TARGET_EFAULT;
|
||||
+ }
|
||||
+ }
|
||||
+
|
||||
+ return ret;
|
||||
+}
|
||||
+
|
||||
+static abi_long do_ioctl_SIOCGSTAMPNS(const IOCTLEntry *ie, uint8_t *buf_temp,
|
||||
+ int fd, int cmd, abi_long arg)
|
||||
+{
|
||||
+ struct timespec ts;
|
||||
+ abi_long ret;
|
||||
+
|
||||
+ ret = get_errno(safe_ioctl(fd, SIOCGSTAMPNS, &ts));
|
||||
+ if (is_error(ret)) {
|
||||
+ return ret;
|
||||
+ }
|
||||
+
|
||||
+ if (cmd == (int)TARGET_SIOCGSTAMPNS_OLD) {
|
||||
+ if (host_to_target_timespec(arg, &ts)) {
|
||||
+ return -TARGET_EFAULT;
|
||||
+ }
|
||||
+ } else{
|
||||
+ if (host_to_target_timespec64(arg, &ts)) {
|
||||
+ return -TARGET_EFAULT;
|
||||
+ }
|
||||
+ }
|
||||
+
|
||||
+ return ret;
|
||||
+}
|
||||
+
|
||||
#ifdef TIOCGPTPEER
|
||||
static abi_long do_ioctl_tiocgptpeer(const IOCTLEntry *ie, uint8_t *buf_temp,
|
||||
int fd, int cmd, abi_long arg)
|
||||
@@ -6180,32 +6290,6 @@ static inline abi_long target_ftruncate64(void *cpu_env, abi_long arg1,
|
||||
}
|
||||
#endif
|
||||
|
||||
-static inline abi_long target_to_host_timespec(struct timespec *host_ts,
|
||||
- abi_ulong target_addr)
|
||||
-{
|
||||
- struct target_timespec *target_ts;
|
||||
-
|
||||
- if (!lock_user_struct(VERIFY_READ, target_ts, target_addr, 1))
|
||||
- return -TARGET_EFAULT;
|
||||
- __get_user(host_ts->tv_sec, &target_ts->tv_sec);
|
||||
- __get_user(host_ts->tv_nsec, &target_ts->tv_nsec);
|
||||
- unlock_user_struct(target_ts, target_addr, 0);
|
||||
- return 0;
|
||||
-}
|
||||
-
|
||||
-static inline abi_long host_to_target_timespec(abi_ulong target_addr,
|
||||
- struct timespec *host_ts)
|
||||
-{
|
||||
- struct target_timespec *target_ts;
|
||||
-
|
||||
- if (!lock_user_struct(VERIFY_WRITE, target_ts, target_addr, 0))
|
||||
- return -TARGET_EFAULT;
|
||||
- __put_user(host_ts->tv_sec, &target_ts->tv_sec);
|
||||
- __put_user(host_ts->tv_nsec, &target_ts->tv_nsec);
|
||||
- unlock_user_struct(target_ts, target_addr, 1);
|
||||
- return 0;
|
||||
-}
|
||||
-
|
||||
static inline abi_long target_to_host_itimerspec(struct itimerspec *host_itspec,
|
||||
abi_ulong target_addr)
|
||||
{
|
||||
diff --git a/linux-user/syscall_defs.h b/linux-user/syscall_defs.h
|
||||
index 12c8407144..cfb3eeec07 100644
|
||||
--- a/linux-user/syscall_defs.h
|
||||
+++ b/linux-user/syscall_defs.h
|
||||
@@ -208,16 +208,34 @@ struct target_linger {
|
||||
abi_int l_linger; /* How long to linger for */
|
||||
};
|
||||
|
||||
+#if defined(TARGET_SPARC64) && !defined(TARGET_ABI32)
|
||||
+struct target_timeval {
|
||||
+ abi_long tv_sec;
|
||||
+ abi_int tv_usec;
|
||||
+};
|
||||
+#define target__kernel_sock_timeval target_timeval
|
||||
+#else
|
||||
struct target_timeval {
|
||||
abi_long tv_sec;
|
||||
abi_long tv_usec;
|
||||
};
|
||||
|
||||
+struct target__kernel_sock_timeval {
|
||||
+ abi_llong tv_sec;
|
||||
+ abi_llong tv_usec;
|
||||
+};
|
||||
+#endif
|
||||
+
|
||||
struct target_timespec {
|
||||
abi_long tv_sec;
|
||||
abi_long tv_nsec;
|
||||
};
|
||||
|
||||
+struct target__kernel_timespec {
|
||||
+ abi_llong tv_sec;
|
||||
+ abi_llong tv_nsec;
|
||||
+};
|
||||
+
|
||||
struct target_timezone {
|
||||
abi_int tz_minuteswest;
|
||||
abi_int tz_dsttime;
|
||||
@@ -743,8 +761,17 @@ struct target_pollfd {
|
||||
#define TARGET_SIOCATMARK 0x8905
|
||||
#define TARGET_SIOCGPGRP 0x8904
|
||||
#endif
|
||||
-#define TARGET_SIOCGSTAMP 0x8906 /* Get stamp (timeval) */
|
||||
-#define TARGET_SIOCGSTAMPNS 0x8907 /* Get stamp (timespec) */
|
||||
+
|
||||
+#if defined(TARGET_SH4)
|
||||
+#define TARGET_SIOCGSTAMP_OLD TARGET_IOR('s', 100, struct target_timeval)
|
||||
+#define TARGET_SIOCGSTAMPNS_OLD TARGET_IOR('s', 101, struct target_timespec)
|
||||
+#else
|
||||
+#define TARGET_SIOCGSTAMP_OLD 0x8906
|
||||
+#define TARGET_SIOCGSTAMPNS_OLD 0x8907
|
||||
+#endif
|
||||
+
|
||||
+#define TARGET_SIOCGSTAMP_NEW TARGET_IOR(0x89, 0x06, abi_llong[2])
|
||||
+#define TARGET_SIOCGSTAMPNS_NEW TARGET_IOR(0x89, 0x07, abi_llong[2])
|
||||
|
||||
/* Networking ioctls */
|
||||
#define TARGET_SIOCADDRT 0x890B /* add routing table entry */
|
||||
diff --git a/linux-user/syscall_types.h b/linux-user/syscall_types.h
|
||||
index b98a23b0f1..4e36983826 100644
|
||||
--- a/linux-user/syscall_types.h
|
||||
+++ b/linux-user/syscall_types.h
|
||||
@@ -14,12 +14,6 @@ STRUCT(serial_icounter_struct,
|
||||
STRUCT(sockaddr,
|
||||
TYPE_SHORT, MK_ARRAY(TYPE_CHAR, 14))
|
||||
|
||||
-STRUCT(timeval,
|
||||
- MK_ARRAY(TYPE_LONG, 2))
|
||||
-
|
||||
-STRUCT(timespec,
|
||||
- MK_ARRAY(TYPE_LONG, 2))
|
||||
-
|
||||
STRUCT(rtentry,
|
||||
TYPE_ULONG, MK_STRUCT(STRUCT_sockaddr), MK_STRUCT(STRUCT_sockaddr), MK_STRUCT(STRUCT_sockaddr),
|
||||
TYPE_SHORT, TYPE_SHORT, TYPE_ULONG, TYPE_PTRVOID, TYPE_SHORT, TYPE_PTRVOID,
|
@ -20,10 +20,10 @@ Signed-off-by: Alexander Graf <agraf@suse.de>
|
||||
1 file changed, 6 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/util/thread-pool.c b/util/thread-pool.c
|
||||
index 610646d131..2e34e9846d 100644
|
||||
index 4ed9b89ab2d9c4e6d805ea47c2b2..697c989885ca8aa4dd1185b780df 100644
|
||||
--- a/util/thread-pool.c
|
||||
+++ b/util/thread-pool.c
|
||||
@@ -308,7 +308,12 @@ static void thread_pool_init_one(ThreadPool *pool, AioContext *ctx)
|
||||
@@ -307,7 +307,12 @@ static void thread_pool_init_one(ThreadPool *pool, AioContext *ctx)
|
||||
qemu_mutex_init(&pool->lock);
|
||||
qemu_cond_init(&pool->worker_stopped);
|
||||
qemu_sem_init(&pool->sem, 0);
|
@ -8,21 +8,21 @@ Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
1 file changed, 2 insertions(+)
|
||||
|
||||
diff --git a/Makefile b/Makefile
|
||||
index f9d6e92510..583bfc5d93 100644
|
||||
index 00ed716275743a161ea05e7d2a1e..ab4d8683ad8f86aa680b343310e1 100644
|
||||
--- a/Makefile
|
||||
+++ b/Makefile
|
||||
@@ -809,6 +809,7 @@ ifneq ($(BLOBS),)
|
||||
$(INSTALL_DATA) $(SRC_PATH)/pc-bios/$$x "$(DESTDIR)$(qemu_datadir)"; \
|
||||
@@ -887,6 +887,7 @@ ifneq ($(DESCS),)
|
||||
"$(DESTDIR)$(qemu_datadir)/firmware/$$x"; \
|
||||
done
|
||||
endif
|
||||
+ifneq ($(or $(CONFIG_GTK),$(CONFIG_SDL)),)
|
||||
for s in $(ICON_SIZES); do \
|
||||
mkdir -p "$(DESTDIR)/$(qemu_icondir)/hicolor/$${s}/apps"; \
|
||||
mkdir -p "$(DESTDIR)$(qemu_icondir)/hicolor/$${s}/apps"; \
|
||||
$(INSTALL_DATA) $(SRC_PATH)/ui/icons/qemu_$${s}.png \
|
||||
@@ -823,6 +824,7 @@ endif
|
||||
mkdir -p "$(DESTDIR)/$(qemu_desktopdir)"
|
||||
@@ -901,6 +902,7 @@ endif
|
||||
mkdir -p "$(DESTDIR)$(qemu_desktopdir)"
|
||||
$(INSTALL_DATA) $(SRC_PATH)/ui/qemu.desktop \
|
||||
"$(DESTDIR)/$(qemu_desktopdir)/qemu.desktop"
|
||||
"$(DESTDIR)$(qemu_desktopdir)/qemu.desktop"
|
||||
+endif
|
||||
ifdef CONFIG_GTK
|
||||
$(MAKE) -C po $@
|
29
Disable-Waddress-of-packed-member-for-GC.patch
Normal file
29
Disable-Waddress-of-packed-member-for-GC.patch
Normal file
@ -0,0 +1,29 @@
|
||||
From: Stewart Smith <stewart@linux.ibm.com>
|
||||
Date: Tue, 18 Jun 2019 16:09:44 +1000
|
||||
Subject: Disable -Waddress-of-packed-member for GCC9
|
||||
|
||||
Git-commit: b904cb733750de1bb0e04e5012c391a9c3094d11
|
||||
|
||||
We throw a bunch of errors in errorlog code otherwise, which we should
|
||||
fix, but we don't *have* to yet.
|
||||
|
||||
Signed-off-by: Stewart Smith <stewart@linux.ibm.com>
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
Makefile.main | 3 ++-
|
||||
1 file changed, 2 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/roms/skiboot/Makefile.main b/roms/skiboot/Makefile.main
|
||||
index a8e34d16c4729921901871b3f9e3..91dc73e06903e8f10c6ad09c1db9 100644
|
||||
--- a/roms/skiboot/Makefile.main
|
||||
+++ b/roms/skiboot/Makefile.main
|
||||
@@ -120,7 +120,8 @@ endif
|
||||
CFLAGS += $(call try-cflag,$(CC),-Wjump-misses-init) \
|
||||
$(call try-cflag,$(CC),-Wsuggest-attribute=const) \
|
||||
$(call try-cflag,$(CC),-Wsuggest-attribute=noreturn) \
|
||||
- $(call try-cflag,$(CC),-Wstack-usage=1024)
|
||||
+ $(call try-cflag,$(CC),-Wstack-usage=1024) \
|
||||
+ $(call try-cflag,$(CC),-Wno-error=address-of-packed-member)
|
||||
|
||||
CFLAGS += $(CWARNS) $(OPTS) $(DBG)
|
||||
|
67
Do-not-apply-WORKAROUND_CFLAGS-for-host-.patch
Normal file
67
Do-not-apply-WORKAROUND_CFLAGS-for-host-.patch
Normal file
@ -0,0 +1,67 @@
|
||||
From: Michael Brown <mcb30@ipxe.org>
|
||||
Date: Mon, 22 Jul 2019 14:51:28 +0100
|
||||
Subject: Do not apply WORKAROUND_CFLAGS for host compiler
|
||||
|
||||
Git-commit: a4f8c6e31f6c62522cfc633bbbffa81b22f9d6f3
|
||||
Include-If: %ifarch aarch64
|
||||
|
||||
The WORKAROUND_CFLAGS list is constructed based on running tests on
|
||||
the target compiler, and the results may not be valid for the host
|
||||
compiler.
|
||||
|
||||
The only relevant workaround required for the host compiler is
|
||||
-Wno-stringop-truncation, which is needed to avoid a spurious compiler
|
||||
warning for a totally correct usage of strncpy() in util/elf2efi.c.
|
||||
|
||||
Duplicating the workaround tests for the host compiler is messy, as is
|
||||
conditionally applying __attribute__((nonstring)). Fix instead by
|
||||
disapplying WORKAROUND_CFLAGS for the host compiler, and using
|
||||
memcpy() with an explicitly calculated length instead of strncpy() in
|
||||
util/elf2efi.c.
|
||||
|
||||
Reported-by: Ignat Korchagin <ignat@cloudflare.com>
|
||||
Reported-by: Christopher Clark <christopher.w.clark@gmail.com>
|
||||
Signed-off-by: Michael Brown <mcb30@ipxe.org>
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
src/Makefile.housekeeping | 2 +-
|
||||
src/util/elf2efi.c | 6 +++++-
|
||||
2 files changed, 6 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/roms/ipxe/src/Makefile.housekeeping b/roms/ipxe/src/Makefile.housekeeping
|
||||
index e5f6927de889167d286ccfcdda92..1ddbddd247d9929d63b1654d7206 100644
|
||||
--- a/roms/ipxe/src/Makefile.housekeeping
|
||||
+++ b/roms/ipxe/src/Makefile.housekeeping
|
||||
@@ -454,7 +454,7 @@ endif
|
||||
CFLAGS += $(WORKAROUND_CFLAGS) $(EXTRA_CFLAGS)
|
||||
ASFLAGS += $(WORKAROUND_ASFLAGS) $(EXTRA_ASFLAGS)
|
||||
LDFLAGS += $(WORKAROUND_LDFLAGS) $(EXTRA_LDFLAGS)
|
||||
-HOST_CFLAGS += $(WORKAROUND_CFLAGS) -O2 -g
|
||||
+HOST_CFLAGS += -O2 -g
|
||||
|
||||
# Inhibit -Werror if NO_WERROR is specified on make command line
|
||||
#
|
||||
diff --git a/roms/ipxe/src/util/elf2efi.c b/roms/ipxe/src/util/elf2efi.c
|
||||
index 2c5b9df8aae853bfce4d5d3bae89..bcd53c9afda7880d42ec80c07f17 100644
|
||||
--- a/roms/ipxe/src/util/elf2efi.c
|
||||
+++ b/roms/ipxe/src/util/elf2efi.c
|
||||
@@ -458,6 +458,7 @@ static struct pe_section * process_section ( struct elf_file *elf,
|
||||
struct pe_header *pe_header ) {
|
||||
struct pe_section *new;
|
||||
const char *name;
|
||||
+ size_t name_len;
|
||||
size_t section_memsz;
|
||||
size_t section_filesz;
|
||||
unsigned long code_start;
|
||||
@@ -494,7 +495,10 @@ static struct pe_section * process_section ( struct elf_file *elf,
|
||||
memset ( new, 0, sizeof ( *new ) + section_filesz );
|
||||
|
||||
/* Fill in section header details */
|
||||
- strncpy ( ( char * ) new->hdr.Name, name, sizeof ( new->hdr.Name ) );
|
||||
+ name_len = strlen ( name );
|
||||
+ if ( name_len > sizeof ( new->hdr.Name ) )
|
||||
+ name_len = sizeof ( new->hdr.Name );
|
||||
+ memcpy ( new->hdr.Name, name, name_len );
|
||||
new->hdr.Misc.VirtualSize = section_memsz;
|
||||
new->hdr.VirtualAddress = shdr->sh_addr;
|
||||
new->hdr.SizeOfRawData = section_filesz;
|
35
Fix-s-directive-argument-is-null-error.patch
Normal file
35
Fix-s-directive-argument-is-null-error.patch
Normal file
@ -0,0 +1,35 @@
|
||||
From: Valentine Barshak <gvaxon@gmail.com>
|
||||
Date: Sun, 9 Jun 2019 13:30:11 +0300
|
||||
Subject: Fix "'%s' directive argument is null" error
|
||||
|
||||
Git-commit: 412acd7854de10e7194f362a6b1a3257a17974f7
|
||||
References: bsc#1121464
|
||||
|
||||
Use '%p' directive, and print handle's address if the address is null
|
||||
and the handle doesn't have a name. This fixes the following
|
||||
compilation error:
|
||||
|
||||
interface/efi/efi_debug.c:334:3: error: '%s' directive
|
||||
argument is null [-Werror=format-overflow=]
|
||||
|
||||
Signed-off-by: Valentine Barshak <gvaxon@gmail.com>
|
||||
Signed-off-by: Michael Brown <mcb30@ipxe.org>
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
src/interface/efi/efi_debug.c | 3 +--
|
||||
1 file changed, 1 insertion(+), 2 deletions(-)
|
||||
|
||||
diff --git a/roms/ipxe/src/interface/efi/efi_debug.c b/roms/ipxe/src/interface/efi/efi_debug.c
|
||||
index 8ea0a822d044caca088c64ca2407..de9b1af5579cfddba1b55788b7b6 100644
|
||||
--- a/roms/ipxe/src/interface/efi/efi_debug.c
|
||||
+++ b/roms/ipxe/src/interface/efi/efi_debug.c
|
||||
@@ -331,8 +331,7 @@ void dbg_efi_protocols ( EFI_HANDLE handle ) {
|
||||
|
||||
/* Sanity check */
|
||||
if ( ! handle ) {
|
||||
- printf ( "HANDLE %s could not retrieve protocols\n",
|
||||
- efi_handle_name ( handle ) );
|
||||
+ printf ( "HANDLE %p could not retrieve protocols\n", handle );
|
||||
return;
|
||||
}
|
||||
|
@ -29,7 +29,7 @@ Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
5 files changed, 22 insertions(+)
|
||||
|
||||
diff --git a/chardev/char-fe.c b/chardev/char-fe.c
|
||||
index f3530a90e6..f8aa0daf31 100644
|
||||
index f3530a90e6364d813097105b6113..f8aa0daf31692810efc7d5ca32eb 100644
|
||||
--- a/chardev/char-fe.c
|
||||
+++ b/chardev/char-fe.c
|
||||
@@ -21,6 +21,7 @@
|
||||
@ -41,7 +41,7 @@ index f3530a90e6..f8aa0daf31 100644
|
||||
#include "qemu/error-report.h"
|
||||
#include "qapi/error.h"
|
||||
diff --git a/chardev/char-mux.c b/chardev/char-mux.c
|
||||
index 23aa82125d..83252fd399 100644
|
||||
index 200c62a0d08bd779de8efdc95aad..10acb4fce1d3bda0d9f818eeb5ee 100644
|
||||
--- a/chardev/char-mux.c
|
||||
+++ b/chardev/char-mux.c
|
||||
@@ -22,6 +22,7 @@
|
||||
@ -51,8 +51,8 @@ index 23aa82125d..83252fd399 100644
|
||||
+#define HW_POISON_H /* avoid poison since we patch against rules it "enforces" */
|
||||
#include "qemu/osdep.h"
|
||||
#include "qapi/error.h"
|
||||
#include "qemu/option.h"
|
||||
@@ -190,6 +191,17 @@ static void mux_chr_accept_input(Chardev *chr)
|
||||
#include "qemu/module.h"
|
||||
@@ -191,6 +192,17 @@ static void mux_chr_accept_input(Chardev *chr)
|
||||
be->chr_read(be->opaque,
|
||||
&d->buffer[m][d->cons[m]++ & MUX_BUFFER_MASK], 1);
|
||||
}
|
||||
@ -70,7 +70,7 @@ index 23aa82125d..83252fd399 100644
|
||||
}
|
||||
|
||||
static int mux_chr_can_read(void *opaque)
|
||||
@@ -324,6 +336,10 @@ static void qemu_chr_open_mux(Chardev *chr,
|
||||
@@ -325,6 +337,10 @@ static void qemu_chr_open_mux(Chardev *chr,
|
||||
}
|
||||
|
||||
d->focus = -1;
|
||||
@ -82,7 +82,7 @@ index 23aa82125d..83252fd399 100644
|
||||
* set of muxes
|
||||
*/
|
||||
diff --git a/chardev/char.c b/chardev/char.c
|
||||
index 514cd6b0c3..9bd3848366 100644
|
||||
index 7b6b2cb12300042c6adf257e188c..d2134d72f60e58f35ee9e7869db4 100644
|
||||
--- a/chardev/char.c
|
||||
+++ b/chardev/char.c
|
||||
@@ -22,6 +22,7 @@
|
||||
@ -94,7 +94,7 @@ index 514cd6b0c3..9bd3848366 100644
|
||||
#include "qemu/cutils.h"
|
||||
#include "monitor/monitor.h"
|
||||
diff --git a/include/chardev/char-mux.h b/include/chardev/char-mux.h
|
||||
index 572cefd517..6e80785bd9 100644
|
||||
index 572cefd517c8fa9d605cbd10fc21..6e80785bd9c12b85e747fa9f924e 100644
|
||||
--- a/include/chardev/char-mux.h
|
||||
+++ b/include/chardev/char-mux.h
|
||||
@@ -34,6 +34,9 @@ typedef struct MuxChardev {
|
||||
@ -108,7 +108,7 @@ index 572cefd517..6e80785bd9 100644
|
||||
int mux_cnt;
|
||||
int term_got_escape;
|
||||
diff --git a/tests/test-char.c b/tests/test-char.c
|
||||
index 95ccfd3cdb..87fb0c1a4c 100644
|
||||
index f9440cdcfdb51f98b2f6542e6f21..d1f99632de1acb95ba8e1b4a8584 100644
|
||||
--- a/tests/test-char.c
|
||||
+++ b/tests/test-char.c
|
||||
@@ -1,3 +1,4 @@
|
@ -2,9 +2,10 @@ From: Bruce Rogers <brogers@suse.com>
|
||||
Date: Thu, 25 Jan 2018 14:16:10 -0700
|
||||
Subject: Make installed scripts explicitly python3
|
||||
|
||||
References: bsc#1077564
|
||||
|
||||
We want to explicitly reference python3 in the scripts we install.
|
||||
|
||||
[BR: BSC#1077564]
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
scripts/analyze-migration.py | 2 +-
|
||||
@ -12,7 +13,7 @@ Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
2 files changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/scripts/analyze-migration.py b/scripts/analyze-migration.py
|
||||
index e527eb168e..fd376eac71 100755
|
||||
index e527eb168e9ce7c3944094ec6701..fd376eac71f73e6366a9e17a1c51 100755
|
||||
--- a/scripts/analyze-migration.py
|
||||
+++ b/scripts/analyze-migration.py
|
||||
@@ -1,4 +1,4 @@
|
||||
@ -22,7 +23,7 @@ index e527eb168e..fd376eac71 100755
|
||||
# Migration Stream Analyzer
|
||||
#
|
||||
diff --git a/scripts/vmstate-static-checker.py b/scripts/vmstate-static-checker.py
|
||||
index d3467288dc..2046b1fedd 100755
|
||||
index d3467288dcc5dd2f7274576262f7..2046b1feddb4c225c8f3bee080ac 100755
|
||||
--- a/scripts/vmstate-static-checker.py
|
||||
+++ b/scripts/vmstate-static-checker.py
|
||||
@@ -1,4 +1,4 @@
|
@ -1,6 +1,18 @@
|
||||
--- a/tools/keymap-gen 2019-08-05 21:56:01.731846467 +0200
|
||||
+++ b/tools/keymap-gen 2019-08-05 22:00:14.563720016 +0200
|
||||
@@ -20,6 +20,7 @@
|
||||
From: =?UTF-8?q?Stefan=20Br=C3=BCns?= <stefan.bruens@rwth-aachen.de>
|
||||
Date: Mon, 5 Aug 2019 20:03:11 +0000
|
||||
Subject: Make keycode-gen output reproducible (use SOURCE_DATE_EPOCH
|
||||
timestamp)
|
||||
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com
|
||||
---
|
||||
tools/keymap-gen | 7 ++++++-
|
||||
1 file changed, 6 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/ui/keycodemapdb/tools/keymap-gen b/ui/keycodemapdb/tools/keymap-gen
|
||||
index f0269e3cabf57881bb41e2333143..a374eb255fb3c55b65b475e86461 100755
|
||||
--- a/ui/keycodemapdb/tools/keymap-gen
|
||||
+++ b/ui/keycodemapdb/tools/keymap-gen
|
||||
@@ -20,6 +20,7 @@ except:
|
||||
sys.path.append(os.path.join(os.path.dirname(__file__), "../thirdparty"))
|
||||
import argparse
|
||||
import hashlib
|
||||
@ -8,7 +20,7 @@
|
||||
import time
|
||||
import sys
|
||||
|
||||
@@ -317,7 +318,11 @@
|
||||
@@ -317,7 +318,11 @@ class LanguageGenerator(object):
|
||||
raise NotImplementedError()
|
||||
|
||||
def generate_header(self, database, args):
|
@ -14,10 +14,10 @@ Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
1 file changed, 2 insertions(+)
|
||||
|
||||
diff --git a/exec.c b/exec.c
|
||||
index 6ab62f4eee..55f3bed025 100644
|
||||
index 3e78de3b8f8bb1914811a7965377..d2183f58816f53f15ef64e844291 100644
|
||||
--- a/exec.c
|
||||
+++ b/exec.c
|
||||
@@ -2281,11 +2281,13 @@ RAMBlock *qemu_ram_alloc_from_fd(ram_addr_t size, MemoryRegion *mr,
|
||||
@@ -2339,11 +2339,13 @@ RAMBlock *qemu_ram_alloc_from_fd(ram_addr_t size, MemoryRegion *mr,
|
||||
return NULL;
|
||||
}
|
||||
|
73
README.PACKAGING
Normal file
73
README.PACKAGING
Normal file
@ -0,0 +1,73 @@
|
||||
The qemu package, and derived packages have a special maintenance workflow in
|
||||
order to support git based patching. Please use it in order to have changes
|
||||
you make be acceptable to the package maintainers.
|
||||
|
||||
The qemu.spec file is generated from a qemu.spec.in template, so to make changes
|
||||
to the spec file (besides patch name or order changes), you'll need to edit the
|
||||
template. The patches included are inserted into the spec file by scripts
|
||||
described below.
|
||||
|
||||
If you are not modifying any patches or their order, but just need to update the
|
||||
spec file from a changed template, run 'bash ./update_git.sh refresh'.
|
||||
|
||||
If the set of patches is being modified, including their order, you will want to
|
||||
first run 'bash ./update_git.sh pkg2git', in order to get the current patch
|
||||
queue made available in a local git branch named frombundle. (qemu packaging now
|
||||
includes a "bundle of git bundles" stored as a package source file, which
|
||||
contains the "git version" of the package patches.) You will create an altered
|
||||
patch queue in the $GIT_BRANCH branch (see config.sh for actual name), and use
|
||||
the frombundle branch as a starting point (eg perhaps start by doing git reset
|
||||
--hard frombundle, then cherry-pick upstream patches from there). Once you have
|
||||
the patch queue ready to go run 'bash ./update_git.sh git2pkg' to update the
|
||||
bundle of bundles (bundles.tsr.xz file) as well as the spec and patch files.
|
||||
|
||||
Additional Notes:
|
||||
|
||||
** SPECIAL NOTE ABOUT CURRENT STATUS ***
|
||||
The current status as of 12 Sep 2019 is that for this incarnation of qemu
|
||||
packaging, the old update_git.sh workflow is no longer supported, being
|
||||
suplanted with the workflow described above. THIS IS STILL A WORK IN PROGRESS.
|
||||
If it isn't working right, please contact Bruce Rogers <brogers@suse.com>.
|
||||
It isn't foolproof by a long shot!
|
||||
|
||||
Also note that qemu now takes advantage of the MultiBuild feature of the Build
|
||||
Service. No longer do the qemu-linux-user and qemu-testsuite packages have build
|
||||
service links to the qemu package, but instead are generated straight from the
|
||||
main qemu spec file via the use of a _multibuild file which identifies those
|
||||
package variants.
|
||||
- Bruce Rogers
|
||||
*** END SPECIAL NOTE ***
|
||||
|
||||
Patches which are from an upstream git repo should have the commit id recorded
|
||||
just below the Subject line (after a blank line) as follows:
|
||||
|
||||
Git-commit: <40-char-sha-id>
|
||||
|
||||
If a patch is anticipated to be shortly included in upstream repo, mark that
|
||||
fact by doing the above with 40 0's, which will flag it as needing to be updated
|
||||
in the near future.
|
||||
|
||||
Bug or feature tracking identifiers should also be added to the patch similarly,
|
||||
using the abbreviations identified here:
|
||||
http://en.opensuse.org/openSUSE:Packaging_Patches_guidelines#Current_set_of_abbreviations
|
||||
using the "Reference:" tag, with multiple entries comma separated.
|
||||
|
||||
The ability to provide a conditional inclusion of a patch (eg based on
|
||||
architecture, is provided by using the "Include-If:" tag similarly, as follows:
|
||||
|
||||
Include-If: %ifarch aarch64
|
||||
|
||||
This will cause the patch application in the spec file to be done as follows:
|
||||
%ifarch aarch64
|
||||
%patch0013 -p1
|
||||
%endif
|
||||
|
||||
A trick worth noting is, if a given git tracked patch is to be applied in a way
|
||||
that can't be done in the normal patching section of the spec file, you can still
|
||||
include the patch, and use it by name with the patch program elsewhere in the
|
||||
spec file by doing something such as:
|
||||
Include-If: %if 0%{?patch-possibly-applied-elsewhere}
|
||||
(this variable will remain undefined in the spec file) And then elsewhere in spec
|
||||
file, the actual patch (eg specially-handled-change.patch) is referenced as, eg:
|
||||
|
||||
patch -p1 < %_sourcedir/specially-handled-change.patch
|
@ -16,26 +16,26 @@ Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
1 file changed, 12 insertions(+)
|
||||
|
||||
diff --git a/vl.c b/vl.c
|
||||
index c696ad2a13..de43d2adf2 100644
|
||||
index b426b3213461210565bd1db15a0c..2b864f7dbe8b60ace40fa3258a37 100644
|
||||
--- a/vl.c
|
||||
+++ b/vl.c
|
||||
@@ -29,6 +29,7 @@
|
||||
@@ -30,6 +30,7 @@
|
||||
#include "qemu/cutils.h"
|
||||
#include "qemu/help_option.h"
|
||||
#include "qemu/uuid.h"
|
||||
+#include <sys/resource.h>
|
||||
#include "sysemu/seccomp.h"
|
||||
#include "sysemu/tcg.h"
|
||||
|
||||
#ifdef CONFIG_SDL
|
||||
@@ -3021,6 +3022,7 @@ int main(int argc, char **argv, char **envp)
|
||||
@@ -2889,6 +2890,7 @@ int main(int argc, char **argv, char **envp)
|
||||
bool list_data_dirs = false;
|
||||
char *dir, **dirs;
|
||||
BlockdevOptionsQueue bdo_queue = QSIMPLEQ_HEAD_INITIALIZER(bdo_queue);
|
||||
+ struct rlimit rlimit_as;
|
||||
|
||||
module_call_init(MODULE_INIT_TRACE);
|
||||
os_set_line_buffering();
|
||||
|
||||
@@ -3029,6 +3031,16 @@ int main(int argc, char **argv, char **envp)
|
||||
@@ -2900,6 +2902,16 @@ int main(int argc, char **argv, char **envp)
|
||||
|
||||
qemu_mutex_lock_iothread();
|
||||
|
||||
@ -50,5 +50,5 @@ index c696ad2a13..de43d2adf2 100644
|
||||
+ }
|
||||
+
|
||||
atexit(qemu_run_exit_notifiers);
|
||||
error_set_progname(argv[0]);
|
||||
qemu_init_exec_dir(argv[0]);
|
||||
|
@ -9,10 +9,10 @@ Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
2 files changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/Makefile b/Makefile
|
||||
index 04a0d45050..f9d6e92510 100644
|
||||
index 85862fb81a1d276c41133a31b2d9..00ed716275743a161ea05e7d2a1e 100644
|
||||
--- a/Makefile
|
||||
+++ b/Makefile
|
||||
@@ -521,7 +521,7 @@ fsdev/virtfs-proxy-helper$(EXESUF): LIBS += -lcap
|
||||
@@ -556,7 +556,7 @@ fsdev/virtfs-proxy-helper$(EXESUF): LIBS += -lcap
|
||||
|
||||
scsi/qemu-pr-helper$(EXESUF): scsi/qemu-pr-helper.o scsi/utils.o $(authz-obj-y) $(crypto-obj-y) $(io-obj-y) $(qom-obj-y) $(COMMON_LDADDS)
|
||||
ifdef CONFIG_MPATH
|
||||
@ -22,10 +22,10 @@ index 04a0d45050..f9d6e92510 100644
|
||||
|
||||
qemu-img-cmds.h: $(SRC_PATH)/qemu-img-cmds.hx $(SRC_PATH)/scripts/hxtool
|
||||
diff --git a/configure b/configure
|
||||
index 1c563a7027..5df1b9a285 100755
|
||||
index 714e7fb6a1fbd72ccdcd92b506ce..578d208b374261803d84c22c2479 100755
|
||||
--- a/configure
|
||||
+++ b/configure
|
||||
@@ -3755,7 +3755,7 @@ int main(void) {
|
||||
@@ -3781,7 +3781,7 @@ int main(void) {
|
||||
return 0;
|
||||
}
|
||||
EOF
|
53
Workaround-compilation-error-with-gcc-9..patch
Normal file
53
Workaround-compilation-error-with-gcc-9..patch
Normal file
@ -0,0 +1,53 @@
|
||||
From: Valentine Barshak <gvaxon@gmail.com>
|
||||
Date: Mon, 22 Jul 2019 10:47:50 +0100
|
||||
Subject: Workaround compilation error with gcc 9.1
|
||||
|
||||
References: bsc#1121464
|
||||
|
||||
Compiling with gcc 9.1 generates lots of "taking address of packed
|
||||
member of ... may result in an unaligned pointer value" warnings.
|
||||
|
||||
Some of these warnings are genuine, and indicate correctly that parts
|
||||
of iPXE currently require the CPU (or runtime environment) to support
|
||||
unaligned accesses. For example: the TCP/IP receive data path will
|
||||
attempt to access 32-bit fields that may not be aligned to a 32-bit
|
||||
boundary.
|
||||
|
||||
Other warnings are either spurious (such as when the pointer is to a
|
||||
variable-length byte array, which can have no alignment requirement
|
||||
anyway) or unhelpful (such as when the pointer is used solely to
|
||||
provide a debug colour value for the DBGC() macro).
|
||||
|
||||
There appears to be no easy way to silence the spurious warnings.
|
||||
Since the ability to perform unaligned accesses is already a
|
||||
requirement for iPXE, work around the problem by silencing this class
|
||||
of warnings.
|
||||
|
||||
Signed-off-by: Valentine Barshak <gvaxon@gmail.com>
|
||||
Modified-by: Michael Brown <mcb30@ipxe.org>
|
||||
Signed-off-by: Michael Brown <mcb30@ipxe.org>
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
src/Makefile.housekeeping | 9 +++++++++
|
||||
1 file changed, 9 insertions(+)
|
||||
|
||||
diff --git a/roms/ipxe/src/Makefile.housekeeping b/roms/ipxe/src/Makefile.housekeeping
|
||||
index 97fa325bb52314e05192d0414436..e5f6927de889167d286ccfcdda92 100644
|
||||
--- a/roms/ipxe/src/Makefile.housekeeping
|
||||
+++ b/roms/ipxe/src/Makefile.housekeeping
|
||||
@@ -185,6 +185,15 @@ WNST_TEST = $(CC) -Wstringop-truncation -x c -c /dev/null -o /dev/null \
|
||||
>/dev/null 2>&1
|
||||
WNST_FLAGS := $(shell $(WNST_TEST) && $(ECHO) '-Wno-stringop-truncation')
|
||||
WORKAROUND_CFLAGS += $(WNST_FLAGS)
|
||||
+
|
||||
+# gcc 9.1 generates warnings for taking address of packed member which
|
||||
+# may result in an unaligned pointer value. Inhibit the warnings.
|
||||
+#
|
||||
+WNAPM_TEST = $(CC) -Wno-address-of-packed-member -x c -c /dev/null \
|
||||
+ -o /dev/null >/dev/null 2>&1
|
||||
+WNAPM_FLAGS := $(shell $(WNAPM_TEST) && \
|
||||
+ $(ECHO) '-Wno-address-of-packed-member')
|
||||
+WORKAROUND_CFLAGS += $(WNAPM_FLAGS)
|
||||
endif
|
||||
|
||||
# Some versions of gas choke on division operators, treating them as
|
@ -8,10 +8,10 @@ Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
1 file changed, 6 insertions(+)
|
||||
|
||||
diff --git a/linux-user/signal.c b/linux-user/signal.c
|
||||
index e2c0b37173..8588c97507 100644
|
||||
index 5ca6d62b15d3e4d3faee3f554fff..1d6382ce881795b057ab229e4129 100644
|
||||
--- a/linux-user/signal.c
|
||||
+++ b/linux-user/signal.c
|
||||
@@ -575,6 +575,10 @@ static void QEMU_NORETURN dump_core_and_abort(int target_sig)
|
||||
@@ -581,6 +581,10 @@ static void QEMU_NORETURN dump_core_and_abort(int target_sig)
|
||||
trace_user_force_sig(env, target_sig, host_sig);
|
||||
gdb_signalled(env, target_sig);
|
||||
|
||||
@ -22,7 +22,7 @@ index e2c0b37173..8588c97507 100644
|
||||
/* dump core if supported by target binary format */
|
||||
if (core_dump_signal(target_sig) && (ts->bprm->core_dump != NULL)) {
|
||||
stop_all_tasks();
|
||||
@@ -592,6 +596,8 @@ static void QEMU_NORETURN dump_core_and_abort(int target_sig)
|
||||
@@ -598,6 +602,8 @@ static void QEMU_NORETURN dump_core_and_abort(int target_sig)
|
||||
target_sig, strsignal(host_sig), "core dumped" );
|
||||
}
|
||||
|
11
_constraints
11
_constraints
@ -50,4 +50,15 @@
|
||||
</memory>
|
||||
</hardware>
|
||||
</overwrite>
|
||||
<!-- To build qemu in a reasonable amount of time, aarch64 and x86_64 needs as much parallelism as we can get -->
|
||||
<overwrite>
|
||||
<conditions>
|
||||
<arch>aarch64</arch>
|
||||
<arch>x86_64</arch>
|
||||
<package>qemu</package>
|
||||
</conditions>
|
||||
<hardware>
|
||||
<processors>8</processors>
|
||||
</hardware>
|
||||
</overwrite>
|
||||
</constraints>
|
||||
|
4
_multibuild
Normal file
4
_multibuild
Normal file
@ -0,0 +1,4 @@
|
||||
<multibuild>
|
||||
<package>linux-user</package>
|
||||
<package>testsuite</package>
|
||||
</multibuild>
|
@ -5,21 +5,21 @@ MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
References: bnc#812836
|
||||
|
||||
qemu-kvm 0.15 uses the same GPE format as qemu 1.4, but as version 2
|
||||
rather than 3.
|
||||
|
||||
Addresses part of BNC#812836.
|
||||
|
||||
Signed-off-by: Andreas Färber <afaerber@suse.de>
|
||||
---
|
||||
hw/acpi/piix4.c | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/hw/acpi/piix4.c b/hw/acpi/piix4.c
|
||||
index 9c079d6834..ebcc240196 100644
|
||||
index ec4e186cec7ccff739b7bad8dcc4..be5529867ab426b38b26dab5498a 100644
|
||||
--- a/hw/acpi/piix4.c
|
||||
+++ b/hw/acpi/piix4.c
|
||||
@@ -315,7 +315,7 @@ static bool piix4_vmstate_need_smbus(void *opaque, int version_id)
|
||||
@@ -306,7 +306,7 @@ static bool piix4_vmstate_need_smbus(void *opaque, int version_id)
|
||||
static const VMStateDescription vmstate_acpi = {
|
||||
.name = "piix4_pm",
|
||||
.version_id = 3,
|
159
ati-add-edid-support.patch
Normal file
159
ati-add-edid-support.patch
Normal file
@ -0,0 +1,159 @@
|
||||
From: Gerd Hoffmann <kraxel@redhat.com>
|
||||
Date: Mon, 18 Mar 2019 15:43:53 +0100
|
||||
Subject: ati: add edid support.
|
||||
|
||||
Git-commit: 588eb12163b51c4d402383369456ce1cd1ec86ab
|
||||
|
||||
Read EDID blob via i2c, store in VBE_edid.
|
||||
|
||||
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
vgasrc/atiext.c | 114 ++++++++++++++++++++++++++++++++++++++++++++++++
|
||||
1 file changed, 114 insertions(+)
|
||||
|
||||
diff --git a/roms/seabios/vgasrc/atiext.c b/roms/seabios/vgasrc/atiext.c
|
||||
index 0586279ce214fac7d2a7e6c87a94..8c9e6966db47f083646193d7faf6 100644
|
||||
--- a/roms/seabios/vgasrc/atiext.c
|
||||
+++ b/roms/seabios/vgasrc/atiext.c
|
||||
@@ -19,6 +19,8 @@
|
||||
#define MM_DATA 0x0004
|
||||
#define CRTC_GEN_CNTL 0x0050
|
||||
#define CRTC_EXT_CNTL 0x0054
|
||||
+#define GPIO_VGA_DDC 0x0060
|
||||
+#define GPIO_DVI_DDC 0x0064
|
||||
#define CRTC_H_TOTAL_DISP 0x0200
|
||||
#define CRTC_V_TOTAL_DISP 0x0208
|
||||
#define CRTC_OFFSET 0x0224
|
||||
@@ -106,6 +108,20 @@ static inline void ati_write(u32 reg, u32 val)
|
||||
}
|
||||
}
|
||||
|
||||
+static inline u32 ati_read(u32 reg)
|
||||
+{
|
||||
+ u32 io_addr = GET_GLOBAL(ati_io_addr);
|
||||
+ u32 val;
|
||||
+
|
||||
+ if (reg < 0x100) {
|
||||
+ val = inl(io_addr + reg);
|
||||
+ } else {
|
||||
+ outl(reg, io_addr + MM_INDEX);
|
||||
+ reg = inl(io_addr + MM_DATA);
|
||||
+ }
|
||||
+ return val;
|
||||
+}
|
||||
+
|
||||
static void ati_clear(u32 offset, u32 size)
|
||||
{
|
||||
u8 data[64];
|
||||
@@ -180,6 +196,97 @@ ati_set_mode(struct vgamode_s *vmode_g, int flags)
|
||||
return stdvga_set_mode(vmode_g, flags);
|
||||
}
|
||||
|
||||
+/****************************************************************
|
||||
+ * edid
|
||||
+ ****************************************************************/
|
||||
+
|
||||
+static void
|
||||
+ati_i2c_set_scl_sda(int scl, int sda)
|
||||
+{
|
||||
+ u32 data = 0;
|
||||
+
|
||||
+ if (!scl)
|
||||
+ data |= (1 << 17);
|
||||
+ if (!sda)
|
||||
+ data |= (1 << 16);
|
||||
+ ati_write(GPIO_DVI_DDC, data);
|
||||
+}
|
||||
+
|
||||
+static int
|
||||
+ati_i2c_get_sda(void)
|
||||
+{
|
||||
+ u32 data = ati_read(GPIO_DVI_DDC);
|
||||
+
|
||||
+ return data & (1 << 8) ? 1 : 0;
|
||||
+}
|
||||
+
|
||||
+static void ati_i2c_start(void)
|
||||
+{
|
||||
+ ati_i2c_set_scl_sda(1, 1);
|
||||
+ ati_i2c_set_scl_sda(1, 0);
|
||||
+ ati_i2c_set_scl_sda(0, 0);
|
||||
+}
|
||||
+
|
||||
+static void ati_i2c_ack(void)
|
||||
+{
|
||||
+ ati_i2c_set_scl_sda(0, 0);
|
||||
+ ati_i2c_set_scl_sda(1, 0);
|
||||
+ ati_i2c_set_scl_sda(0, 0);
|
||||
+}
|
||||
+
|
||||
+static void ati_i2c_stop(void)
|
||||
+{
|
||||
+ ati_i2c_set_scl_sda(0, 0);
|
||||
+ ati_i2c_set_scl_sda(1, 0);
|
||||
+ ati_i2c_set_scl_sda(1, 1);
|
||||
+}
|
||||
+
|
||||
+static void ati_i2c_send_byte(u8 byte)
|
||||
+{
|
||||
+ int i, bit;
|
||||
+
|
||||
+ for (i = 0; i < 8; i++) {
|
||||
+ bit = (1 << (7-i)) & byte ? 1 : 0;
|
||||
+ ati_i2c_set_scl_sda(0, bit);
|
||||
+ ati_i2c_set_scl_sda(1, bit);
|
||||
+ ati_i2c_set_scl_sda(0, bit);
|
||||
+ }
|
||||
+}
|
||||
+
|
||||
+static u8 ati_i2c_recv_byte(void)
|
||||
+{
|
||||
+ u8 byte = 0;
|
||||
+ int i, bit;
|
||||
+
|
||||
+ for (i = 0; i < 8; i++) {
|
||||
+ ati_i2c_set_scl_sda(0, 1);
|
||||
+ ati_i2c_set_scl_sda(1, 1);
|
||||
+ bit = ati_i2c_get_sda();
|
||||
+ ati_i2c_set_scl_sda(0, 1);
|
||||
+ if (bit)
|
||||
+ byte |= (1 << (7-i));
|
||||
+ }
|
||||
+
|
||||
+ return byte;
|
||||
+}
|
||||
+
|
||||
+static void ati_i2c_edid(void)
|
||||
+{
|
||||
+ u8 byte;
|
||||
+ int i;
|
||||
+
|
||||
+ dprintf(1, "ati: reading edid blob\n");
|
||||
+ ati_i2c_start();
|
||||
+ ati_i2c_send_byte(0x50 << 1 | 1);
|
||||
+ ati_i2c_ack();
|
||||
+ for (i = 0; i < 128; i++) {
|
||||
+ byte = ati_i2c_recv_byte();
|
||||
+ ati_i2c_ack();
|
||||
+ SET_VGA(VBE_edid[i], byte);
|
||||
+ }
|
||||
+ ati_i2c_stop();
|
||||
+}
|
||||
+
|
||||
/****************************************************************
|
||||
* init
|
||||
****************************************************************/
|
||||
@@ -241,5 +348,12 @@ ati_setup(void)
|
||||
}
|
||||
}
|
||||
|
||||
+ u16 device = pci_config_readw(bdf, PCI_DEVICE_ID);
|
||||
+ switch (device) {
|
||||
+ case 0x5159:
|
||||
+ ati_i2c_edid();
|
||||
+ break;
|
||||
+ }
|
||||
+
|
||||
return 0;
|
||||
}
|
78
ati-vga-add-rage128-edid-support.patch
Normal file
78
ati-vga-add-rage128-edid-support.patch
Normal file
@ -0,0 +1,78 @@
|
||||
From: Gerd Hoffmann <kraxel@redhat.com>
|
||||
Date: Mon, 24 Jun 2019 13:35:46 +0200
|
||||
Subject: ati-vga: add rage128 edid support
|
||||
|
||||
Git-commit: 020bc4fc5ce93107c8e1bc731b9802cee56a123e
|
||||
|
||||
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
vgasrc/atiext.c | 25 +++++++++++++++++++++++++
|
||||
1 file changed, 25 insertions(+)
|
||||
|
||||
diff --git a/roms/seabios/vgasrc/atiext.c b/roms/seabios/vgasrc/atiext.c
|
||||
index 71dfa859a22dc569ed2fd1312c6b..69dfd46e550a8865734def85c62d 100644
|
||||
--- a/roms/seabios/vgasrc/atiext.c
|
||||
+++ b/roms/seabios/vgasrc/atiext.c
|
||||
@@ -21,6 +21,7 @@
|
||||
#define CRTC_EXT_CNTL 0x0054
|
||||
#define GPIO_VGA_DDC 0x0060
|
||||
#define GPIO_DVI_DDC 0x0064
|
||||
+#define GPIO_MONID 0x0068
|
||||
#define CRTC_H_TOTAL_DISP 0x0200
|
||||
#define CRTC_V_TOTAL_DISP 0x0208
|
||||
#define CRTC_OFFSET 0x0224
|
||||
@@ -47,6 +48,7 @@ static u32 ati_i2c_reg VAR16;
|
||||
static u32 ati_i2c_bit_scl_out VAR16;
|
||||
static u32 ati_i2c_bit_sda_out VAR16;
|
||||
static u32 ati_i2c_bit_sda_in VAR16;
|
||||
+static u32 ati_i2c_bit_enable VAR16 = -1;
|
||||
|
||||
|
||||
int
|
||||
@@ -208,8 +210,11 @@ ati_set_mode(struct vgamode_s *vmode_g, int flags)
|
||||
static void
|
||||
ati_i2c_set_scl_sda(int scl, int sda)
|
||||
{
|
||||
+ u32 enable = GET_GLOBAL(ati_i2c_bit_enable);
|
||||
u32 data = 0;
|
||||
|
||||
+ if (enable != -1)
|
||||
+ data |= (1 << enable);
|
||||
if (!scl)
|
||||
data |= (1 << GET_GLOBAL(ati_i2c_bit_scl_out));
|
||||
if (!sda)
|
||||
@@ -316,6 +321,23 @@ static void ati_i2c_edid_radeon(void)
|
||||
dprintf(1, "ati: ... %s\n", valid ? "good" : "invalid");
|
||||
}
|
||||
|
||||
+static void ati_i2c_edid_rage128(void)
|
||||
+{
|
||||
+ int valid;
|
||||
+
|
||||
+ SET_VGA(ati_i2c_bit_enable, 25);
|
||||
+ SET_VGA(ati_i2c_bit_scl_out, 18);
|
||||
+ SET_VGA(ati_i2c_bit_sda_out, 17);
|
||||
+ SET_VGA(ati_i2c_bit_sda_in, 9);
|
||||
+ SET_VGA(ati_i2c_reg, GPIO_MONID);
|
||||
+
|
||||
+ dprintf(1, "ati: reading edid blob (rage128) ... \n");
|
||||
+ ati_i2c_edid();
|
||||
+ valid = (GET_GLOBAL(VBE_edid[0]) == 0x00 &&
|
||||
+ GET_GLOBAL(VBE_edid[1]) == 0xff);
|
||||
+ dprintf(1, "ati: ... %s\n", valid ? "good" : "invalid");
|
||||
+}
|
||||
+
|
||||
/****************************************************************
|
||||
* init
|
||||
****************************************************************/
|
||||
@@ -379,6 +401,9 @@ ati_setup(void)
|
||||
|
||||
u16 device = pci_config_readw(bdf, PCI_DEVICE_ID);
|
||||
switch (device) {
|
||||
+ case 0x5046:
|
||||
+ ati_i2c_edid_rage128();
|
||||
+ break;
|
||||
case 0x5159:
|
||||
ati_i2c_edid_radeon();
|
||||
break;
|
28
ati-vga-fix-ati_read.patch
Normal file
28
ati-vga-fix-ati_read.patch
Normal file
@ -0,0 +1,28 @@
|
||||
From: Gerd Hoffmann <kraxel@redhat.com>
|
||||
Date: Mon, 24 Jun 2019 12:09:31 +0200
|
||||
Subject: ati-vga: fix ati_read()
|
||||
|
||||
Git-commit: 136e2612bd48ef06562625f15259fbacf7bcf66f
|
||||
|
||||
Cut & paste bug probably. Had no bad effect so far because the code
|
||||
doesn't read registers larger than 0x100.
|
||||
|
||||
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
vgasrc/atiext.c | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/roms/seabios/vgasrc/atiext.c b/roms/seabios/vgasrc/atiext.c
|
||||
index b3975226c47852c80ec4278b9a95..a24b980638a9562daaa37fe236b4 100644
|
||||
--- a/roms/seabios/vgasrc/atiext.c
|
||||
+++ b/roms/seabios/vgasrc/atiext.c
|
||||
@@ -117,7 +117,7 @@ static inline u32 ati_read(u32 reg)
|
||||
val = inl(io_addr + reg);
|
||||
} else {
|
||||
outl(reg, io_addr + MM_INDEX);
|
||||
- reg = inl(io_addr + MM_DATA);
|
||||
+ val = inl(io_addr + MM_DATA);
|
||||
}
|
||||
return val;
|
||||
}
|
95
ati-vga-make-i2c-register-and-bits-confi.patch
Normal file
95
ati-vga-make-i2c-register-and-bits-confi.patch
Normal file
@ -0,0 +1,95 @@
|
||||
From: Gerd Hoffmann <kraxel@redhat.com>
|
||||
Date: Mon, 24 Jun 2019 12:08:32 +0200
|
||||
Subject: ati-vga: make i2c register and bits configurable
|
||||
|
||||
Git-commit: ae9a9796ec395e66ff0ed6d4484ea40ce85c0300
|
||||
|
||||
Prepare to support other ati cards. Also log access mode and whenever
|
||||
we got a valid edid block.
|
||||
|
||||
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
vgasrc/atiext.c | 34 +++++++++++++++++++++++++++-------
|
||||
1 file changed, 27 insertions(+), 7 deletions(-)
|
||||
|
||||
diff --git a/roms/seabios/vgasrc/atiext.c b/roms/seabios/vgasrc/atiext.c
|
||||
index a24b980638a9562daaa37fe236b4..901e82d013837f54f4db292628d1 100644
|
||||
--- a/roms/seabios/vgasrc/atiext.c
|
||||
+++ b/roms/seabios/vgasrc/atiext.c
|
||||
@@ -43,6 +43,11 @@
|
||||
#define CRT_CRTC_ON 0x00008000
|
||||
|
||||
static u32 ati_io_addr VAR16 = 0;
|
||||
+static u32 ati_i2c_reg VAR16;
|
||||
+static u32 ati_i2c_bit_scl_out VAR16;
|
||||
+static u32 ati_i2c_bit_sda_out VAR16;
|
||||
+static u32 ati_i2c_bit_sda_in VAR16;
|
||||
+
|
||||
|
||||
int
|
||||
is_ati_mode(struct vgamode_s *vmode_g)
|
||||
@@ -206,18 +211,18 @@ ati_i2c_set_scl_sda(int scl, int sda)
|
||||
u32 data = 0;
|
||||
|
||||
if (!scl)
|
||||
- data |= (1 << 17);
|
||||
+ data |= (1 << GET_GLOBAL(ati_i2c_bit_scl_out));
|
||||
if (!sda)
|
||||
- data |= (1 << 16);
|
||||
- ati_write(GPIO_DVI_DDC, data);
|
||||
+ data |= (1 << GET_GLOBAL(ati_i2c_bit_sda_out));
|
||||
+ ati_write(GET_GLOBAL(ati_i2c_reg), data);
|
||||
}
|
||||
|
||||
static int
|
||||
ati_i2c_get_sda(void)
|
||||
{
|
||||
- u32 data = ati_read(GPIO_DVI_DDC);
|
||||
+ u32 data = ati_read(GET_GLOBAL(ati_i2c_reg));
|
||||
|
||||
- return data & (1 << 8) ? 1 : 0;
|
||||
+ return data & (1 << GET_GLOBAL(ati_i2c_bit_sda_in)) ? 1 : 0;
|
||||
}
|
||||
|
||||
static void ati_i2c_start(void)
|
||||
@@ -275,7 +280,6 @@ static void ati_i2c_edid(void)
|
||||
u8 byte;
|
||||
int i;
|
||||
|
||||
- dprintf(1, "ati: reading edid blob\n");
|
||||
ati_i2c_start();
|
||||
ati_i2c_send_byte(0x50 << 1 | 1);
|
||||
ati_i2c_ack();
|
||||
@@ -287,6 +291,22 @@ static void ati_i2c_edid(void)
|
||||
ati_i2c_stop();
|
||||
}
|
||||
|
||||
+static void ati_i2c_edid_radeon(void)
|
||||
+{
|
||||
+ int valid;
|
||||
+
|
||||
+ SET_VGA(ati_i2c_bit_scl_out, 17);
|
||||
+ SET_VGA(ati_i2c_bit_sda_out, 16);
|
||||
+ SET_VGA(ati_i2c_bit_sda_in, 8);
|
||||
+
|
||||
+ dprintf(1, "ati: reading edid blob (radeon dvi) ... \n");
|
||||
+ SET_VGA(ati_i2c_reg, GPIO_DVI_DDC);
|
||||
+ ati_i2c_edid();
|
||||
+ valid = (GET_GLOBAL(VBE_edid[0]) == 0x00 &&
|
||||
+ GET_GLOBAL(VBE_edid[1]) == 0xff);
|
||||
+ dprintf(1, "ati: ... %s\n", valid ? "good" : "invalid");
|
||||
+}
|
||||
+
|
||||
/****************************************************************
|
||||
* init
|
||||
****************************************************************/
|
||||
@@ -351,7 +371,7 @@ ati_setup(void)
|
||||
u16 device = pci_config_readw(bdf, PCI_DEVICE_ID);
|
||||
switch (device) {
|
||||
case 0x5159:
|
||||
- ati_i2c_edid();
|
||||
+ ati_i2c_edid_radeon();
|
||||
break;
|
||||
}
|
||||
|
27
ati-vga-make-less-verbose.patch
Normal file
27
ati-vga-make-less-verbose.patch
Normal file
@ -0,0 +1,27 @@
|
||||
From: Gerd Hoffmann <kraxel@redhat.com>
|
||||
Date: Mon, 24 Jun 2019 12:09:52 +0200
|
||||
Subject: ati-vga: make less verbose
|
||||
|
||||
Git-commit: ce52a31f612e33df66ac3553d9633732e34a277b
|
||||
|
||||
Reduce loglevel for mode line removals from 1 to 3.
|
||||
|
||||
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
vgasrc/atiext.c | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/roms/seabios/vgasrc/atiext.c b/roms/seabios/vgasrc/atiext.c
|
||||
index 8c9e6966db47f083646193d7faf6..b3975226c47852c80ec4278b9a95 100644
|
||||
--- a/roms/seabios/vgasrc/atiext.c
|
||||
+++ b/roms/seabios/vgasrc/atiext.c
|
||||
@@ -343,7 +343,7 @@ ati_setup(void)
|
||||
height > 0xfff ||
|
||||
mem > totalmem ||
|
||||
memmodel != MM_DIRECT) {
|
||||
- dprintf(1, "ati: removing mode 0x%x\n", GET_GLOBAL(m->mode));
|
||||
+ dprintf(3, "ati: removing mode 0x%x\n", GET_GLOBAL(m->mode));
|
||||
SET_VGA(m->mode, 0xffff);
|
||||
}
|
||||
}
|
35
ati-vga-try-vga-ddc-first.patch
Normal file
35
ati-vga-try-vga-ddc-first.patch
Normal file
@ -0,0 +1,35 @@
|
||||
From: Gerd Hoffmann <kraxel@redhat.com>
|
||||
Date: Mon, 24 Jun 2019 12:17:28 +0200
|
||||
Subject: ati-vga: try vga ddc first
|
||||
|
||||
Git-commit: af573dceef7b9a45d13192ec5abf29b73c78540e
|
||||
|
||||
Try vga ddc bus before dvi ddc bus.
|
||||
Return early in case we got valid data.
|
||||
|
||||
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
vgasrc/atiext.c | 9 +++++++++
|
||||
1 file changed, 9 insertions(+)
|
||||
|
||||
diff --git a/roms/seabios/vgasrc/atiext.c b/roms/seabios/vgasrc/atiext.c
|
||||
index 901e82d013837f54f4db292628d1..71dfa859a22dc569ed2fd1312c6b 100644
|
||||
--- a/roms/seabios/vgasrc/atiext.c
|
||||
+++ b/roms/seabios/vgasrc/atiext.c
|
||||
@@ -299,6 +299,15 @@ static void ati_i2c_edid_radeon(void)
|
||||
SET_VGA(ati_i2c_bit_sda_out, 16);
|
||||
SET_VGA(ati_i2c_bit_sda_in, 8);
|
||||
|
||||
+ dprintf(1, "ati: reading edid blob (radeon vga) ... \n");
|
||||
+ SET_VGA(ati_i2c_reg, GPIO_VGA_DDC);
|
||||
+ ati_i2c_edid();
|
||||
+ valid = (GET_GLOBAL(VBE_edid[0]) == 0x00 &&
|
||||
+ GET_GLOBAL(VBE_edid[1]) == 0xff);
|
||||
+ dprintf(1, "ati: ... %s\n", valid ? "good" : "invalid");
|
||||
+ if (valid)
|
||||
+ return;
|
||||
+
|
||||
dprintf(1, "ati: reading edid blob (radeon dvi) ... \n");
|
||||
SET_VGA(ati_i2c_reg, GPIO_DVI_DDC);
|
||||
ati_i2c_edid();
|
93
block-create-Do-not-abort-if-a-block-dri.patch
Normal file
93
block-create-Do-not-abort-if-a-block-dri.patch
Normal file
@ -0,0 +1,93 @@
|
||||
From: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= <philmd@redhat.com>
|
||||
Date: Thu, 12 Sep 2019 00:08:49 +0200
|
||||
Subject: block/create: Do not abort if a block driver is not available
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
Git-commit: d90d5cae2b10efc0e8d0b3cc91ff16201853d3ba
|
||||
|
||||
The 'blockdev-create' QMP command was introduced as experimental
|
||||
feature in commit b0292b851b8, using the assert() debug call.
|
||||
It got promoted to 'stable' command in 3fb588a0f2c, but the
|
||||
assert call was not removed.
|
||||
|
||||
Some block drivers are optional, and bdrv_find_format() might
|
||||
return a NULL value, triggering the assertion.
|
||||
|
||||
Stable code is not expected to abort, so return an error instead.
|
||||
|
||||
This is easily reproducible when libnfs is not installed:
|
||||
|
||||
./configure
|
||||
[...]
|
||||
module support no
|
||||
Block whitelist (rw)
|
||||
Block whitelist (ro)
|
||||
libiscsi support yes
|
||||
libnfs support no
|
||||
[...]
|
||||
|
||||
Start QEMU:
|
||||
|
||||
$ qemu-system-x86_64 -S -qmp unix:/tmp/qemu.qmp,server,nowait
|
||||
|
||||
Send the 'blockdev-create' with the 'nfs' driver:
|
||||
|
||||
$ ( cat << 'EOF'
|
||||
{'execute': 'qmp_capabilities'}
|
||||
{'execute': 'blockdev-create', 'arguments': {'job-id': 'x', 'options': {'size': 0, 'driver': 'nfs', 'location': {'path': '/', 'server': {'host': '::1', 'type': 'inet'}}}}, 'id': 'x'}
|
||||
EOF
|
||||
) | socat STDIO UNIX:/tmp/qemu.qmp
|
||||
{"QMP": {"version": {"qemu": {"micro": 50, "minor": 1, "major": 4}, "package": "v4.1.0-733-g89ea03a7dc"}, "capabilities": ["oob"]}}
|
||||
{"return": {}}
|
||||
|
||||
QEMU crashes:
|
||||
|
||||
$ gdb qemu-system-x86_64 core
|
||||
Program received signal SIGSEGV, Segmentation fault.
|
||||
(gdb) bt
|
||||
#0 0x00007ffff510957f in raise () at /lib64/libc.so.6
|
||||
#1 0x00007ffff50f3895 in abort () at /lib64/libc.so.6
|
||||
#2 0x00007ffff50f3769 in _nl_load_domain.cold.0 () at /lib64/libc.so.6
|
||||
#3 0x00007ffff5101a26 in .annobin_assert.c_end () at /lib64/libc.so.6
|
||||
#4 0x0000555555d7e1f1 in qmp_blockdev_create (job_id=0x555556baee40 "x", options=0x555557666610, errp=0x7fffffffc770) at block/create.c:69
|
||||
#5 0x0000555555c96b52 in qmp_marshal_blockdev_create (args=0x7fffdc003830, ret=0x7fffffffc7f8, errp=0x7fffffffc7f0) at qapi/qapi-commands-block-core.c:1314
|
||||
#6 0x0000555555deb0a0 in do_qmp_dispatch (cmds=0x55555645de70 <qmp_commands>, request=0x7fffdc005c70, allow_oob=false, errp=0x7fffffffc898) at qapi/qmp-dispatch.c:131
|
||||
#7 0x0000555555deb2a1 in qmp_dispatch (cmds=0x55555645de70 <qmp_commands>, request=0x7fffdc005c70, allow_oob=false) at qapi/qmp-dispatch.c:174
|
||||
|
||||
With this patch applied, QEMU returns a QMP error:
|
||||
|
||||
{'execute': 'blockdev-create', 'arguments': {'job-id': 'x', 'options': {'size': 0, 'driver': 'nfs', 'location': {'path': '/', 'server': {'host': '::1', 'type': 'inet'}}}}, 'id': 'x'}
|
||||
{"id": "x", "error": {"class": "GenericError", "desc": "Block driver 'nfs' not found or not supported"}}
|
||||
|
||||
Cc: qemu-stable@nongnu.org
|
||||
Reported-by: Xu Tian <xutian@redhat.com>
|
||||
Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
|
||||
Reviewed-by: Eric Blake <eblake@redhat.com>
|
||||
Reviewed-by: John Snow <jsnow@redhat.com>
|
||||
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
block/create.c | 6 +++++-
|
||||
1 file changed, 5 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/block/create.c b/block/create.c
|
||||
index 95341219efcd670a5151d0d3f4f5..de5e97bb186ffdf039fb39980874 100644
|
||||
--- a/block/create.c
|
||||
+++ b/block/create.c
|
||||
@@ -63,9 +63,13 @@ void qmp_blockdev_create(const char *job_id, BlockdevCreateOptions *options,
|
||||
const char *fmt = BlockdevDriver_str(options->driver);
|
||||
BlockDriver *drv = bdrv_find_format(fmt);
|
||||
|
||||
+ if (!drv) {
|
||||
+ error_setg(errp, "Block driver '%s' not found or not supported", fmt);
|
||||
+ return;
|
||||
+ }
|
||||
+
|
||||
/* If the driver is in the schema, we know that it exists. But it may not
|
||||
* be whitelisted. */
|
||||
- assert(drv);
|
||||
if (bdrv_uses_whitelist() && !bdrv_is_whitelisted(drv, false)) {
|
||||
error_setg(errp, "Driver is not whitelisted");
|
||||
return;
|
163
block-file-posix-Reduce-xfsctl-use.patch
Normal file
163
block-file-posix-Reduce-xfsctl-use.patch
Normal file
@ -0,0 +1,163 @@
|
||||
From: Max Reitz <mreitz@redhat.com>
|
||||
Date: Fri, 23 Aug 2019 15:03:40 +0200
|
||||
Subject: block/file-posix: Reduce xfsctl() use
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
Git-commit: b2c6f23f4a9f6d8f1b648705cd46d3713b78d6a2
|
||||
|
||||
This patch removes xfs_write_zeroes() and xfs_discard(). Both functions
|
||||
have been added just before the same feature was present through
|
||||
fallocate():
|
||||
|
||||
- fallocate() has supported PUNCH_HOLE for XFS since Linux 2.6.38 (March
|
||||
2011); xfs_discard() was added in December 2010.
|
||||
|
||||
- fallocate() has supported ZERO_RANGE for XFS since Linux 3.15 (June
|
||||
2014); xfs_write_zeroes() was added in November 2013.
|
||||
|
||||
Nowadays, all systems that qemu runs on should support both fallocate()
|
||||
features (RHEL 7's kernel does).
|
||||
|
||||
xfsctl() is still useful for getting the request alignment for O_DIRECT,
|
||||
so this patch does not remove our dependency on it completely.
|
||||
|
||||
Note that xfs_write_zeroes() had a bug: It calls ftruncate() when the
|
||||
file is shorter than the specified range (because ZERO_RANGE does not
|
||||
increase the file length). ftruncate() may yield and then discard data
|
||||
that parallel write requests have written past the EOF in the meantime.
|
||||
Dropping the function altogether fixes the bug.
|
||||
|
||||
Suggested-by: Paolo Bonzini <pbonzini@redhat.com>
|
||||
Fixes: 50ba5b2d994853b38fed10e0841b119da0f8b8e5
|
||||
Reported-by: Lukáš Doktor <ldoktor@redhat.com>
|
||||
Cc: qemu-stable@nongnu.org
|
||||
Signed-off-by: Max Reitz <mreitz@redhat.com>
|
||||
Reviewed-by: Stefano Garzarella <sgarzare@redhat.com>
|
||||
Reviewed-by: John Snow <jsnow@redhat.com>
|
||||
Tested-by: Stefano Garzarella <sgarzare@redhat.com>
|
||||
Tested-by: John Snow <jsnow@redhat.com>
|
||||
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
block/file-posix.c | 77 +---------------------------------------------
|
||||
1 file changed, 1 insertion(+), 76 deletions(-)
|
||||
|
||||
diff --git a/block/file-posix.c b/block/file-posix.c
|
||||
index 4479cc7ab467f217cff8b3efbd1f..992eb4a798b99fe02e93103028c6 100644
|
||||
--- a/block/file-posix.c
|
||||
+++ b/block/file-posix.c
|
||||
@@ -1445,59 +1445,6 @@ out:
|
||||
}
|
||||
}
|
||||
|
||||
-#ifdef CONFIG_XFS
|
||||
-static int xfs_write_zeroes(BDRVRawState *s, int64_t offset, uint64_t bytes)
|
||||
-{
|
||||
- int64_t len;
|
||||
- struct xfs_flock64 fl;
|
||||
- int err;
|
||||
-
|
||||
- len = lseek(s->fd, 0, SEEK_END);
|
||||
- if (len < 0) {
|
||||
- return -errno;
|
||||
- }
|
||||
-
|
||||
- if (offset + bytes > len) {
|
||||
- /* XFS_IOC_ZERO_RANGE does not increase the file length */
|
||||
- if (ftruncate(s->fd, offset + bytes) < 0) {
|
||||
- return -errno;
|
||||
- }
|
||||
- }
|
||||
-
|
||||
- memset(&fl, 0, sizeof(fl));
|
||||
- fl.l_whence = SEEK_SET;
|
||||
- fl.l_start = offset;
|
||||
- fl.l_len = bytes;
|
||||
-
|
||||
- if (xfsctl(NULL, s->fd, XFS_IOC_ZERO_RANGE, &fl) < 0) {
|
||||
- err = errno;
|
||||
- trace_file_xfs_write_zeroes(strerror(errno));
|
||||
- return -err;
|
||||
- }
|
||||
-
|
||||
- return 0;
|
||||
-}
|
||||
-
|
||||
-static int xfs_discard(BDRVRawState *s, int64_t offset, uint64_t bytes)
|
||||
-{
|
||||
- struct xfs_flock64 fl;
|
||||
- int err;
|
||||
-
|
||||
- memset(&fl, 0, sizeof(fl));
|
||||
- fl.l_whence = SEEK_SET;
|
||||
- fl.l_start = offset;
|
||||
- fl.l_len = bytes;
|
||||
-
|
||||
- if (xfsctl(NULL, s->fd, XFS_IOC_UNRESVSP64, &fl) < 0) {
|
||||
- err = errno;
|
||||
- trace_file_xfs_discard(strerror(errno));
|
||||
- return -err;
|
||||
- }
|
||||
-
|
||||
- return 0;
|
||||
-}
|
||||
-#endif
|
||||
-
|
||||
static int translate_err(int err)
|
||||
{
|
||||
if (err == -ENODEV || err == -ENOSYS || err == -EOPNOTSUPP ||
|
||||
@@ -1553,10 +1500,8 @@ static ssize_t handle_aiocb_write_zeroes_block(RawPosixAIOData *aiocb)
|
||||
static int handle_aiocb_write_zeroes(void *opaque)
|
||||
{
|
||||
RawPosixAIOData *aiocb = opaque;
|
||||
-#if defined(CONFIG_FALLOCATE) || defined(CONFIG_XFS)
|
||||
- BDRVRawState *s = aiocb->bs->opaque;
|
||||
-#endif
|
||||
#ifdef CONFIG_FALLOCATE
|
||||
+ BDRVRawState *s = aiocb->bs->opaque;
|
||||
int64_t len;
|
||||
#endif
|
||||
|
||||
@@ -1564,12 +1509,6 @@ static int handle_aiocb_write_zeroes(void *opaque)
|
||||
return handle_aiocb_write_zeroes_block(aiocb);
|
||||
}
|
||||
|
||||
-#ifdef CONFIG_XFS
|
||||
- if (s->is_xfs) {
|
||||
- return xfs_write_zeroes(s, aiocb->aio_offset, aiocb->aio_nbytes);
|
||||
- }
|
||||
-#endif
|
||||
-
|
||||
#ifdef CONFIG_FALLOCATE_ZERO_RANGE
|
||||
if (s->has_write_zeroes) {
|
||||
int ret = do_fallocate(s->fd, FALLOC_FL_ZERO_RANGE,
|
||||
@@ -1632,14 +1571,6 @@ static int handle_aiocb_write_zeroes_unmap(void *opaque)
|
||||
}
|
||||
#endif
|
||||
|
||||
-#ifdef CONFIG_XFS
|
||||
- if (s->is_xfs) {
|
||||
- /* xfs_discard() guarantees that the discarded area reads as all-zero
|
||||
- * afterwards, so we can use it here. */
|
||||
- return xfs_discard(s, aiocb->aio_offset, aiocb->aio_nbytes);
|
||||
- }
|
||||
-#endif
|
||||
-
|
||||
/* If we couldn't manage to unmap while guaranteed that the area reads as
|
||||
* all-zero afterwards, just write zeroes without unmapping */
|
||||
ret = handle_aiocb_write_zeroes(aiocb);
|
||||
@@ -1716,12 +1647,6 @@ static int handle_aiocb_discard(void *opaque)
|
||||
ret = -errno;
|
||||
#endif
|
||||
} else {
|
||||
-#ifdef CONFIG_XFS
|
||||
- if (s->is_xfs) {
|
||||
- return xfs_discard(s, aiocb->aio_offset, aiocb->aio_nbytes);
|
||||
- }
|
||||
-#endif
|
||||
-
|
||||
#ifdef CONFIG_FALLOCATE_PUNCH_HOLE
|
||||
ret = do_fallocate(s->fd, FALLOC_FL_PUNCH_HOLE | FALLOC_FL_KEEP_SIZE,
|
||||
aiocb->aio_offset, aiocb->aio_nbytes);
|
39
block-nfs-tear-down-aio-before-nfs_close.patch
Normal file
39
block-nfs-tear-down-aio-before-nfs_close.patch
Normal file
@ -0,0 +1,39 @@
|
||||
From: Peter Lieven <pl@kamp.de>
|
||||
Date: Tue, 10 Sep 2019 17:41:09 +0200
|
||||
Subject: block/nfs: tear down aio before nfs_close
|
||||
|
||||
Git-commit: 601dc6559725f7a614b6f893611e17ff0908e914
|
||||
|
||||
nfs_close is a sync call from libnfs and has its own event
|
||||
handler polling on the nfs FD. Avoid that both QEMU and libnfs
|
||||
are intefering here.
|
||||
|
||||
CC: qemu-stable@nongnu.org
|
||||
Signed-off-by: Peter Lieven <pl@kamp.de>
|
||||
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
block/nfs.c | 6 ++++--
|
||||
1 file changed, 4 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/block/nfs.c b/block/nfs.c
|
||||
index d93241b3bb84cf0a662f0ddec582..2b7a0782419af82aea80dd76e474 100644
|
||||
--- a/block/nfs.c
|
||||
+++ b/block/nfs.c
|
||||
@@ -390,12 +390,14 @@ static void nfs_attach_aio_context(BlockDriverState *bs,
|
||||
static void nfs_client_close(NFSClient *client)
|
||||
{
|
||||
if (client->context) {
|
||||
+ qemu_mutex_lock(&client->mutex);
|
||||
+ aio_set_fd_handler(client->aio_context, nfs_get_fd(client->context),
|
||||
+ false, NULL, NULL, NULL, NULL);
|
||||
+ qemu_mutex_unlock(&client->mutex);
|
||||
if (client->fh) {
|
||||
nfs_close(client->context, client->fh);
|
||||
client->fh = NULL;
|
||||
}
|
||||
- aio_set_fd_handler(client->aio_context, nfs_get_fd(client->context),
|
||||
- false, NULL, NULL, NULL, NULL);
|
||||
nfs_destroy_context(client->context);
|
||||
client->context = NULL;
|
||||
}
|
59
blockjob-update-nodes-head-while-removin.patch
Normal file
59
blockjob-update-nodes-head-while-removin.patch
Normal file
@ -0,0 +1,59 @@
|
||||
From: Sergio Lopez <slp@redhat.com>
|
||||
Date: Wed, 11 Sep 2019 12:03:16 +0200
|
||||
Subject: blockjob: update nodes head while removing all bdrv
|
||||
|
||||
Git-commit: d876bf676f5e7c6aa9ac64555e48cba8734ecb2f
|
||||
|
||||
block_job_remove_all_bdrv() iterates through job->nodes, calling
|
||||
bdrv_root_unref_child() for each entry. The call to the latter may
|
||||
reach child_job_[can_]set_aio_ctx(), which will also attempt to
|
||||
traverse job->nodes, potentially finding entries that where freed
|
||||
on previous iterations.
|
||||
|
||||
To avoid this situation, update job->nodes head on each iteration to
|
||||
ensure that already freed entries are no longer linked to the list.
|
||||
|
||||
RHBZ: https://bugzilla.redhat.com/show_bug.cgi?id=1746631
|
||||
Signed-off-by: Sergio Lopez <slp@redhat.com>
|
||||
Cc: qemu-stable@nongnu.org
|
||||
Signed-off-by: Max Reitz <mreitz@redhat.com>
|
||||
Message-id: 20190911100316.32282-1-mreitz@redhat.com
|
||||
Reviewed-by: Sergio Lopez <slp@redhat.com>
|
||||
Signed-off-by: Max Reitz <mreitz@redhat.com>
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
blockjob.c | 17 +++++++++++++----
|
||||
1 file changed, 13 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/blockjob.c b/blockjob.c
|
||||
index 20b7f557da3e491927b99b113b73..74abb97bfdf27b5a9f4f82cd55b4 100644
|
||||
--- a/blockjob.c
|
||||
+++ b/blockjob.c
|
||||
@@ -186,14 +186,23 @@ static const BdrvChildRole child_job = {
|
||||
|
||||
void block_job_remove_all_bdrv(BlockJob *job)
|
||||
{
|
||||
- GSList *l;
|
||||
- for (l = job->nodes; l; l = l->next) {
|
||||
+ /*
|
||||
+ * bdrv_root_unref_child() may reach child_job_[can_]set_aio_ctx(),
|
||||
+ * which will also traverse job->nodes, so consume the list one by
|
||||
+ * one to make sure that such a concurrent access does not attempt
|
||||
+ * to process an already freed BdrvChild.
|
||||
+ */
|
||||
+ while (job->nodes) {
|
||||
+ GSList *l = job->nodes;
|
||||
BdrvChild *c = l->data;
|
||||
+
|
||||
+ job->nodes = l->next;
|
||||
+
|
||||
bdrv_op_unblock_all(c->bs, job->blocker);
|
||||
bdrv_root_unref_child(c);
|
||||
+
|
||||
+ g_slist_free_1(l);
|
||||
}
|
||||
- g_slist_free(job->nodes);
|
||||
- job->nodes = NULL;
|
||||
}
|
||||
|
||||
bool block_job_has_bdrv(BlockJob *job, BlockDriverState *bs)
|
3
bundles.tar.xz
Normal file
3
bundles.tar.xz
Normal file
@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:a7b737c94e0a6b8e4f922d2947f19bdef88c8ea1e1124e7d47c74298e5cf2fbe
|
||||
size 53016
|
103
config.sh
Normal file
103
config.sh
Normal file
@ -0,0 +1,103 @@
|
||||
#!/bin/bash
|
||||
|
||||
# config.sh:
|
||||
|
||||
# The next few VARIABLES may be edited (or uncommented) as required:
|
||||
|
||||
# The commit upon which our patchqueue gets rebased. The special value LATEST
|
||||
# may be used to "automatically" track the upstream development tree in the
|
||||
# master branch
|
||||
GIT_UPSTREAM_COMMIT_ISH=v4.1.0
|
||||
if [ "$GIT_UPSTREAM_COMMIT_ISH" = "LATEST" ]; then
|
||||
echo "Using LATEST upstream commit as base for tarball and patch queue"
|
||||
GIT_BRANCH=master
|
||||
fi
|
||||
# otherwise we specify the branch to use, eg:
|
||||
# WARNING: If transitioning from using LATEST to not, MANUALLY re-set the
|
||||
# tarball present
|
||||
GIT_BRANCH=opensuse-4.1
|
||||
# This is used for the automated development branch tracking
|
||||
NEXT_RELEASE_IS_MAJOR=0
|
||||
|
||||
# The shared openSUSE specific git repo, on which $GIT_LOCAL_TREE is based
|
||||
GIT_TREE=git://github.com/openSUSE/qemu.git
|
||||
|
||||
# Temporary directories used by this script
|
||||
GIT_DIR=/dev/shm/qemu-factory-git-dir
|
||||
CMP_DIR=/dev/shm/qemu-factory-cmp-dir
|
||||
BUNDLE_DIR=/dev/shm/qemu-factory-bundle-dir
|
||||
|
||||
# For the following, use 1 or 0 as needed
|
||||
NUMBERED_PATCHES=0
|
||||
|
||||
PATCH_RANGE=1000
|
||||
REPO_COUNT=26
|
||||
|
||||
# Perhaps we need to instead use the terminal local dirname as the index
|
||||
# and store the ~/git/ as a separate VARIABLE
|
||||
# This way, we only have one big array instead of two
|
||||
# BUT STILL WE NEED TO START WITH THE DATA STORED SOMEWHERE!!!!!!
|
||||
LOCAL_REPO_MAP=(
|
||||
~/git/qemu-opensuse
|
||||
~/git/qemu-seabios
|
||||
~/git/qemu-ipxe
|
||||
~/git/qemu-sgabios
|
||||
~/git/qemu-edk2
|
||||
~/git/qemu-skiboot
|
||||
~/git/qemu-SLOF
|
||||
~/git/qemu-openbios
|
||||
~/git/qemu-keycodemapdb
|
||||
~/git/qemu-slirp
|
||||
~/git/qemu-u-boot
|
||||
~/git/qemu-openhackware
|
||||
~/git/qemu-dtc
|
||||
~/git/qemu-opensbi
|
||||
~/git/qemu-edk2-openssl
|
||||
~/git/qemu-capstone
|
||||
~/git/qemu-qemu-palcode
|
||||
~/git/qemu-seabios-hppa
|
||||
~/git/qemu-u-boot-sam460ex
|
||||
~/git/qemu-QemuMacDrivers
|
||||
~/git/qemu-tests-berkeley-softfloat-3
|
||||
~/git/qemu-tests-berkeley-testfloat-3
|
||||
~/git/qemu-edk2-berkeley-softfloat-3
|
||||
~/git/qemu-edk2-openssl-boringssl
|
||||
~/git/qemu-edk2-openssl-krb5
|
||||
~/git/qemu-edk2-openssl-pyca-cryptography
|
||||
)
|
||||
|
||||
PATCH_PATH_MAP=(
|
||||
""
|
||||
"roms/seabios/"
|
||||
"roms/ipxe/"
|
||||
"roms/sgabios/"
|
||||
"roms/edk2/"
|
||||
"roms/skiboot/"
|
||||
"roms/SLOF/"
|
||||
"roms/openbios/"
|
||||
"ui/keycodemapdb/"
|
||||
"slirp/"
|
||||
"roms/u-boot/"
|
||||
"roms/openhackware/"
|
||||
"dtc/"
|
||||
"roms/opensbi/"
|
||||
"roms/edk2/CryptoPkg/Library/OpensslLib/openssl/"
|
||||
"capstone/"
|
||||
"roms/qemu-palcode/"
|
||||
"roms/seabios-hppa/"
|
||||
"roms/u-boot-sam460ex/"
|
||||
"roms/QemuMacDrivers/"
|
||||
"tests/fp/berkeley-softfloat-3/"
|
||||
"tests/fp/berkeley-testfloat-3/"
|
||||
"roms/edk2/ArmPkg/Library/ArmSoftFloatLib/berkeley-softfloat-3/"
|
||||
"roms/edk2/CryptoPkg/Library/OpensslLib/openssl/boringssl/"
|
||||
"roms/edk2/CryptoPkg/Library/OpensslLib/openssl/krb5/"
|
||||
"roms/edk2/CryptoPkg/Library/OpensslLib/openssl/pyca-cryptography/"
|
||||
)
|
||||
|
||||
# Zero based numbering, so we subtract 1 here:
|
||||
if (( (REPO_COUNT * PATCH_RANGE) - 1 > 9999 )); then
|
||||
FIVE_DIGIT_POTENTIAL=1
|
||||
else
|
||||
FIVE_DIGIT_POTENTIAL=0
|
||||
fi
|
@ -12,15 +12,15 @@ Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
1 file changed, 3 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/configure b/configure
|
||||
index 5df1b9a285..cf261e9cc5 100755
|
||||
index 578d208b374261803d84c22c2479..6cfe739061d2d8fef6d89147fcd5 100755
|
||||
--- a/configure
|
||||
+++ b/configure
|
||||
@@ -6166,12 +6166,13 @@ if { test "$cpu" = "i386" || test "$cpu" = "x86_64"; } && \
|
||||
@@ -6211,12 +6211,13 @@ if { test "$cpu" = "i386" || test "$cpu" = "x86_64"; } && \
|
||||
fi
|
||||
done
|
||||
fi
|
||||
-if test "$cpu" = "ppc64" && test "$targetos" != "Darwin" ; then
|
||||
+if test "$cpu" = "ppc64" && test "$targetos" != "Darwin" && \
|
||||
-if test "$ARCH" = "ppc64" && test "$targetos" != "Darwin" ; then
|
||||
+if test "$ARCH" = "ppc64" && test "$targetos" != "Darwin" && \
|
||||
+ test "$softmmu" = yes ; then
|
||||
roms="$roms spapr-rtas"
|
||||
fi
|
71
curl-Check-completion-in-curl_multi_do.patch
Normal file
71
curl-Check-completion-in-curl_multi_do.patch
Normal file
@ -0,0 +1,71 @@
|
||||
From: Max Reitz <mreitz@redhat.com>
|
||||
Date: Tue, 10 Sep 2019 14:41:32 +0200
|
||||
Subject: curl: Check completion in curl_multi_do()
|
||||
|
||||
Git-commit: 948403bcb1c7e71dcbe8ab8479cf3934a0efcbb5
|
||||
|
||||
While it is more likely that transfers complete after some file
|
||||
descriptor has data ready to read, we probably should not rely on it.
|
||||
Better be safe than sorry and call curl_multi_check_completion() in
|
||||
curl_multi_do(), too, just like it is done in curl_multi_read().
|
||||
|
||||
With this change, curl_multi_do() and curl_multi_read() are actually the
|
||||
same, so drop curl_multi_read() and use curl_multi_do() as the sole FD
|
||||
handler.
|
||||
|
||||
Signed-off-by: Max Reitz <mreitz@redhat.com>
|
||||
Message-id: 20190910124136.10565-4-mreitz@redhat.com
|
||||
Reviewed-by: Maxim Levitsky <mlevitsk@redhat.com>
|
||||
Reviewed-by: John Snow <jsnow@redhat.com>
|
||||
Signed-off-by: Max Reitz <mreitz@redhat.com>
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
block/curl.c | 14 ++------------
|
||||
1 file changed, 2 insertions(+), 12 deletions(-)
|
||||
|
||||
diff --git a/block/curl.c b/block/curl.c
|
||||
index 95d7b77dc0b1cf25443effdb9eb3..5838afef99e070d8e7b704fa55e7 100644
|
||||
--- a/block/curl.c
|
||||
+++ b/block/curl.c
|
||||
@@ -139,7 +139,6 @@ typedef struct BDRVCURLState {
|
||||
|
||||
static void curl_clean_state(CURLState *s);
|
||||
static void curl_multi_do(void *arg);
|
||||
-static void curl_multi_read(void *arg);
|
||||
|
||||
#ifdef NEED_CURL_TIMER_CALLBACK
|
||||
/* Called from curl_multi_do_locked, with s->mutex held. */
|
||||
@@ -186,7 +185,7 @@ static int curl_sock_cb(CURL *curl, curl_socket_t fd, int action,
|
||||
switch (action) {
|
||||
case CURL_POLL_IN:
|
||||
aio_set_fd_handler(s->aio_context, fd, false,
|
||||
- curl_multi_read, NULL, NULL, state);
|
||||
+ curl_multi_do, NULL, NULL, state);
|
||||
break;
|
||||
case CURL_POLL_OUT:
|
||||
aio_set_fd_handler(s->aio_context, fd, false,
|
||||
@@ -194,7 +193,7 @@ static int curl_sock_cb(CURL *curl, curl_socket_t fd, int action,
|
||||
break;
|
||||
case CURL_POLL_INOUT:
|
||||
aio_set_fd_handler(s->aio_context, fd, false,
|
||||
- curl_multi_read, curl_multi_do, NULL, state);
|
||||
+ curl_multi_do, curl_multi_do, NULL, state);
|
||||
break;
|
||||
case CURL_POLL_REMOVE:
|
||||
aio_set_fd_handler(s->aio_context, fd, false,
|
||||
@@ -416,15 +415,6 @@ static void curl_multi_do(void *arg)
|
||||
{
|
||||
CURLState *s = (CURLState *)arg;
|
||||
|
||||
- qemu_mutex_lock(&s->s->mutex);
|
||||
- curl_multi_do_locked(s);
|
||||
- qemu_mutex_unlock(&s->s->mutex);
|
||||
-}
|
||||
-
|
||||
-static void curl_multi_read(void *arg)
|
||||
-{
|
||||
- CURLState *s = (CURLState *)arg;
|
||||
-
|
||||
qemu_mutex_lock(&s->s->mutex);
|
||||
curl_multi_do_locked(s);
|
||||
curl_multi_check_completion(s->s);
|
146
curl-Handle-success-in-multi_check_compl.patch
Normal file
146
curl-Handle-success-in-multi_check_compl.patch
Normal file
@ -0,0 +1,146 @@
|
||||
From: Max Reitz <mreitz@redhat.com>
|
||||
Date: Tue, 10 Sep 2019 14:41:35 +0200
|
||||
Subject: curl: Handle success in multi_check_completion
|
||||
|
||||
Git-commit: bfb23b480a49114315877aacf700b49453e0f9d9
|
||||
|
||||
Background: As of cURL 7.59.0, it verifies that several functions are
|
||||
not called from within a callback. Among these functions is
|
||||
curl_multi_add_handle().
|
||||
|
||||
curl_read_cb() is a callback from cURL and not a coroutine. Waking up
|
||||
acb->co will lead to entering it then and there, which means the current
|
||||
request will settle and the caller (if it runs in the same coroutine)
|
||||
may then issue the next request. In such a case, we will enter
|
||||
curl_setup_preadv() effectively from within curl_read_cb().
|
||||
|
||||
Calling curl_multi_add_handle() will then fail and the new request will
|
||||
not be processed.
|
||||
|
||||
Fix this by not letting curl_read_cb() wake up acb->co. Instead, leave
|
||||
the whole business of settling the AIOCB objects to
|
||||
curl_multi_check_completion() (which is called from our timer callback
|
||||
and our FD handler, so not from any cURL callbacks).
|
||||
|
||||
Reported-by: Natalie Gavrielov <ngavrilo@redhat.com>
|
||||
Buglink: https://bugzilla.redhat.com/show_bug.cgi?id=1740193
|
||||
Cc: qemu-stable@nongnu.org
|
||||
Signed-off-by: Max Reitz <mreitz@redhat.com>
|
||||
Message-id: 20190910124136.10565-7-mreitz@redhat.com
|
||||
Reviewed-by: John Snow <jsnow@redhat.com>
|
||||
Reviewed-by: Maxim Levitsky <mlevitsk@redhat.com>
|
||||
Signed-off-by: Max Reitz <mreitz@redhat.com>
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
block/curl.c | 69 ++++++++++++++++++++++------------------------------
|
||||
1 file changed, 29 insertions(+), 40 deletions(-)
|
||||
|
||||
diff --git a/block/curl.c b/block/curl.c
|
||||
index fd70f1ebc458f22f6d1a4bc01e1e..c343c7ed3ddad205051d7e3b0196 100644
|
||||
--- a/block/curl.c
|
||||
+++ b/block/curl.c
|
||||
@@ -229,7 +229,6 @@ static size_t curl_read_cb(void *ptr, size_t size, size_t nmemb, void *opaque)
|
||||
{
|
||||
CURLState *s = ((CURLState*)opaque);
|
||||
size_t realsize = size * nmemb;
|
||||
- int i;
|
||||
|
||||
trace_curl_read_cb(realsize);
|
||||
|
||||
@@ -245,32 +244,6 @@ static size_t curl_read_cb(void *ptr, size_t size, size_t nmemb, void *opaque)
|
||||
memcpy(s->orig_buf + s->buf_off, ptr, realsize);
|
||||
s->buf_off += realsize;
|
||||
|
||||
- for(i=0; i<CURL_NUM_ACB; i++) {
|
||||
- CURLAIOCB *acb = s->acb[i];
|
||||
-
|
||||
- if (!acb)
|
||||
- continue;
|
||||
-
|
||||
- if ((s->buf_off >= acb->end)) {
|
||||
- size_t request_length = acb->bytes;
|
||||
-
|
||||
- qemu_iovec_from_buf(acb->qiov, 0, s->orig_buf + acb->start,
|
||||
- acb->end - acb->start);
|
||||
-
|
||||
- if (acb->end - acb->start < request_length) {
|
||||
- size_t offset = acb->end - acb->start;
|
||||
- qemu_iovec_memset(acb->qiov, offset, 0,
|
||||
- request_length - offset);
|
||||
- }
|
||||
-
|
||||
- acb->ret = 0;
|
||||
- s->acb[i] = NULL;
|
||||
- qemu_mutex_unlock(&s->s->mutex);
|
||||
- aio_co_wake(acb->co);
|
||||
- qemu_mutex_lock(&s->s->mutex);
|
||||
- }
|
||||
- }
|
||||
-
|
||||
read_end:
|
||||
/* curl will error out if we do not return this value */
|
||||
return size * nmemb;
|
||||
@@ -351,13 +324,14 @@ static void curl_multi_check_completion(BDRVCURLState *s)
|
||||
break;
|
||||
|
||||
if (msg->msg == CURLMSG_DONE) {
|
||||
+ int i;
|
||||
CURLState *state = NULL;
|
||||
+ bool error = msg->data.result != CURLE_OK;
|
||||
+
|
||||
curl_easy_getinfo(msg->easy_handle, CURLINFO_PRIVATE,
|
||||
(char **)&state);
|
||||
|
||||
- /* ACBs for successful messages get completed in curl_read_cb */
|
||||
- if (msg->data.result != CURLE_OK) {
|
||||
- int i;
|
||||
+ if (error) {
|
||||
static int errcount = 100;
|
||||
|
||||
/* Don't lose the original error message from curl, since
|
||||
@@ -369,20 +343,35 @@ static void curl_multi_check_completion(BDRVCURLState *s)
|
||||
error_report("curl: further errors suppressed");
|
||||
}
|
||||
}
|
||||
+ }
|
||||
|
||||
- for (i = 0; i < CURL_NUM_ACB; i++) {
|
||||
- CURLAIOCB *acb = state->acb[i];
|
||||
+ for (i = 0; i < CURL_NUM_ACB; i++) {
|
||||
+ CURLAIOCB *acb = state->acb[i];
|
||||
|
||||
- if (acb == NULL) {
|
||||
- continue;
|
||||
- }
|
||||
+ if (acb == NULL) {
|
||||
+ continue;
|
||||
+ }
|
||||
+
|
||||
+ if (!error) {
|
||||
+ /* Assert that we have read all data */
|
||||
+ assert(state->buf_off >= acb->end);
|
||||
+
|
||||
+ qemu_iovec_from_buf(acb->qiov, 0,
|
||||
+ state->orig_buf + acb->start,
|
||||
+ acb->end - acb->start);
|
||||
|
||||
- acb->ret = -EIO;
|
||||
- state->acb[i] = NULL;
|
||||
- qemu_mutex_unlock(&s->mutex);
|
||||
- aio_co_wake(acb->co);
|
||||
- qemu_mutex_lock(&s->mutex);
|
||||
+ if (acb->end - acb->start < acb->bytes) {
|
||||
+ size_t offset = acb->end - acb->start;
|
||||
+ qemu_iovec_memset(acb->qiov, offset, 0,
|
||||
+ acb->bytes - offset);
|
||||
+ }
|
||||
}
|
||||
+
|
||||
+ acb->ret = error ? -EIO : 0;
|
||||
+ state->acb[i] = NULL;
|
||||
+ qemu_mutex_unlock(&s->mutex);
|
||||
+ aio_co_wake(acb->co);
|
||||
+ qemu_mutex_lock(&s->mutex);
|
||||
}
|
||||
|
||||
curl_clean_state(state);
|
49
curl-Keep-pointer-to-the-CURLState-in-CU.patch
Normal file
49
curl-Keep-pointer-to-the-CURLState-in-CU.patch
Normal file
@ -0,0 +1,49 @@
|
||||
From: Max Reitz <mreitz@redhat.com>
|
||||
Date: Tue, 10 Sep 2019 14:41:30 +0200
|
||||
Subject: curl: Keep pointer to the CURLState in CURLSocket
|
||||
|
||||
Git-commit: 0487861685294660b23bc146e1ebd5304aa8bbe0
|
||||
|
||||
A follow-up patch will make curl_multi_do() and curl_multi_read() take a
|
||||
CURLSocket instead of the CURLState. They still need the latter,
|
||||
though, so add a pointer to it to the former.
|
||||
|
||||
Cc: qemu-stable@nongnu.org
|
||||
Signed-off-by: Max Reitz <mreitz@redhat.com>
|
||||
Reviewed-by: John Snow <jsnow@redhat.com>
|
||||
Message-id: 20190910124136.10565-2-mreitz@redhat.com
|
||||
Reviewed-by: Maxim Levitsky <mlevitsk@redhat.com>
|
||||
Signed-off-by: Max Reitz <mreitz@redhat.com>
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
block/curl.c | 3 +++
|
||||
1 file changed, 3 insertions(+)
|
||||
|
||||
diff --git a/block/curl.c b/block/curl.c
|
||||
index d4c8e94f3e0fe26ee221e763356e..92dc2f630e20f4a6b138c9c82b8b 100644
|
||||
--- a/block/curl.c
|
||||
+++ b/block/curl.c
|
||||
@@ -80,6 +80,7 @@ static CURLMcode __curl_multi_socket_action(CURLM *multi_handle,
|
||||
#define CURL_BLOCK_OPT_TIMEOUT_DEFAULT 5
|
||||
|
||||
struct BDRVCURLState;
|
||||
+struct CURLState;
|
||||
|
||||
static bool libcurl_initialized;
|
||||
|
||||
@@ -97,6 +98,7 @@ typedef struct CURLAIOCB {
|
||||
|
||||
typedef struct CURLSocket {
|
||||
int fd;
|
||||
+ struct CURLState *state;
|
||||
QLIST_ENTRY(CURLSocket) next;
|
||||
} CURLSocket;
|
||||
|
||||
@@ -180,6 +182,7 @@ static int curl_sock_cb(CURL *curl, curl_socket_t fd, int action,
|
||||
if (!socket) {
|
||||
socket = g_new0(CURLSocket, 1);
|
||||
socket->fd = fd;
|
||||
+ socket->state = state;
|
||||
QLIST_INSERT_HEAD(&state->sockets, socket, next);
|
||||
}
|
||||
socket = NULL;
|
56
curl-Keep-socket-until-the-end-of-curl_s.patch
Normal file
56
curl-Keep-socket-until-the-end-of-curl_s.patch
Normal file
@ -0,0 +1,56 @@
|
||||
From: Max Reitz <mreitz@redhat.com>
|
||||
Date: Tue, 10 Sep 2019 14:41:31 +0200
|
||||
Subject: curl: Keep *socket until the end of curl_sock_cb()
|
||||
|
||||
Git-commit: 007f339b1099af46a008dac438ca0943e31dba72
|
||||
|
||||
This does not really change anything, but it makes the code a bit easier
|
||||
to follow once we use @socket as the opaque pointer for
|
||||
aio_set_fd_handler().
|
||||
|
||||
Cc: qemu-stable@nongnu.org
|
||||
Signed-off-by: Max Reitz <mreitz@redhat.com>
|
||||
Message-id: 20190910124136.10565-3-mreitz@redhat.com
|
||||
Reviewed-by: Maxim Levitsky <mlevitsk@redhat.com>
|
||||
Reviewed-by: John Snow <jsnow@redhat.com>
|
||||
Signed-off-by: Max Reitz <mreitz@redhat.com>
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
block/curl.c | 10 +++++-----
|
||||
1 file changed, 5 insertions(+), 5 deletions(-)
|
||||
|
||||
diff --git a/block/curl.c b/block/curl.c
|
||||
index 92dc2f630e20f4a6b138c9c82b8b..95d7b77dc0b1cf25443effdb9eb3 100644
|
||||
--- a/block/curl.c
|
||||
+++ b/block/curl.c
|
||||
@@ -172,10 +172,6 @@ static int curl_sock_cb(CURL *curl, curl_socket_t fd, int action,
|
||||
|
||||
QLIST_FOREACH(socket, &state->sockets, next) {
|
||||
if (socket->fd == fd) {
|
||||
- if (action == CURL_POLL_REMOVE) {
|
||||
- QLIST_REMOVE(socket, next);
|
||||
- g_free(socket);
|
||||
- }
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -185,7 +181,6 @@ static int curl_sock_cb(CURL *curl, curl_socket_t fd, int action,
|
||||
socket->state = state;
|
||||
QLIST_INSERT_HEAD(&state->sockets, socket, next);
|
||||
}
|
||||
- socket = NULL;
|
||||
|
||||
trace_curl_sock_cb(action, (int)fd);
|
||||
switch (action) {
|
||||
@@ -207,6 +202,11 @@ static int curl_sock_cb(CURL *curl, curl_socket_t fd, int action,
|
||||
break;
|
||||
}
|
||||
|
||||
+ if (action == CURL_POLL_REMOVE) {
|
||||
+ QLIST_REMOVE(socket, next);
|
||||
+ g_free(socket);
|
||||
+ }
|
||||
+
|
||||
return 0;
|
||||
}
|
||||
|
77
curl-Pass-CURLSocket-to-curl_multi_do.patch
Normal file
77
curl-Pass-CURLSocket-to-curl_multi_do.patch
Normal file
@ -0,0 +1,77 @@
|
||||
From: Max Reitz <mreitz@redhat.com>
|
||||
Date: Tue, 10 Sep 2019 14:41:33 +0200
|
||||
Subject: curl: Pass CURLSocket to curl_multi_do()
|
||||
|
||||
Git-commit: 9dbad87d25587ff640ef878f7b6159fc368ff541
|
||||
|
||||
curl_multi_do_locked() currently marks all sockets as ready. That is
|
||||
not only inefficient, but in fact unsafe (the loop is). A follow-up
|
||||
patch will change that, but to do so, curl_multi_do_locked() needs to
|
||||
know exactly which socket is ready; and that is accomplished by this
|
||||
patch here.
|
||||
|
||||
Cc: qemu-stable@nongnu.org
|
||||
Signed-off-by: Max Reitz <mreitz@redhat.com>
|
||||
Message-id: 20190910124136.10565-5-mreitz@redhat.com
|
||||
Reviewed-by: Maxim Levitsky <mlevitsk@redhat.com>
|
||||
Reviewed-by: John Snow <jsnow@redhat.com>
|
||||
Signed-off-by: Max Reitz <mreitz@redhat.com>
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
block/curl.c | 20 +++++++++++---------
|
||||
1 file changed, 11 insertions(+), 9 deletions(-)
|
||||
|
||||
diff --git a/block/curl.c b/block/curl.c
|
||||
index 5838afef99e070d8e7b704fa55e7..cf2686218dcf4bc7d2db1a7026f9 100644
|
||||
--- a/block/curl.c
|
||||
+++ b/block/curl.c
|
||||
@@ -185,15 +185,15 @@ static int curl_sock_cb(CURL *curl, curl_socket_t fd, int action,
|
||||
switch (action) {
|
||||
case CURL_POLL_IN:
|
||||
aio_set_fd_handler(s->aio_context, fd, false,
|
||||
- curl_multi_do, NULL, NULL, state);
|
||||
+ curl_multi_do, NULL, NULL, socket);
|
||||
break;
|
||||
case CURL_POLL_OUT:
|
||||
aio_set_fd_handler(s->aio_context, fd, false,
|
||||
- NULL, curl_multi_do, NULL, state);
|
||||
+ NULL, curl_multi_do, NULL, socket);
|
||||
break;
|
||||
case CURL_POLL_INOUT:
|
||||
aio_set_fd_handler(s->aio_context, fd, false,
|
||||
- curl_multi_do, curl_multi_do, NULL, state);
|
||||
+ curl_multi_do, curl_multi_do, NULL, socket);
|
||||
break;
|
||||
case CURL_POLL_REMOVE:
|
||||
aio_set_fd_handler(s->aio_context, fd, false,
|
||||
@@ -392,9 +392,10 @@ static void curl_multi_check_completion(BDRVCURLState *s)
|
||||
}
|
||||
|
||||
/* Called with s->mutex held. */
|
||||
-static void curl_multi_do_locked(CURLState *s)
|
||||
+static void curl_multi_do_locked(CURLSocket *ready_socket)
|
||||
{
|
||||
CURLSocket *socket, *next_socket;
|
||||
+ CURLState *s = ready_socket->state;
|
||||
int running;
|
||||
int r;
|
||||
|
||||
@@ -413,12 +414,13 @@ static void curl_multi_do_locked(CURLState *s)
|
||||
|
||||
static void curl_multi_do(void *arg)
|
||||
{
|
||||
- CURLState *s = (CURLState *)arg;
|
||||
+ CURLSocket *socket = arg;
|
||||
+ BDRVCURLState *s = socket->state->s;
|
||||
|
||||
- qemu_mutex_lock(&s->s->mutex);
|
||||
- curl_multi_do_locked(s);
|
||||
- curl_multi_check_completion(s->s);
|
||||
- qemu_mutex_unlock(&s->s->mutex);
|
||||
+ qemu_mutex_lock(&s->mutex);
|
||||
+ curl_multi_do_locked(socket);
|
||||
+ curl_multi_check_completion(s);
|
||||
+ qemu_mutex_unlock(&s->mutex);
|
||||
}
|
||||
|
||||
static void curl_multi_timeout_do(void *arg)
|
61
curl-Report-only-ready-sockets.patch
Normal file
61
curl-Report-only-ready-sockets.patch
Normal file
@ -0,0 +1,61 @@
|
||||
From: Max Reitz <mreitz@redhat.com>
|
||||
Date: Tue, 10 Sep 2019 14:41:34 +0200
|
||||
Subject: curl: Report only ready sockets
|
||||
|
||||
Git-commit: 9abaf9fc474c3dd53e8e119326abc774c977c331
|
||||
|
||||
Instead of reporting all sockets to cURL, only report the one that has
|
||||
caused curl_multi_do_locked() to be called. This lets us get rid of the
|
||||
QLIST_FOREACH_SAFE() list, which was actually wrong: SAFE foreaches are
|
||||
only safe when the current element is removed in each iteration. If it
|
||||
possible for the list to be concurrently modified, we cannot guarantee
|
||||
that only the current element will be removed. Therefore, we must not
|
||||
use QLIST_FOREACH_SAFE() here.
|
||||
|
||||
Fixes: ff5ca1664af85b24a4180d595ea6873fd3deac57
|
||||
Cc: qemu-stable@nongnu.org
|
||||
Signed-off-by: Max Reitz <mreitz@redhat.com>
|
||||
Message-id: 20190910124136.10565-6-mreitz@redhat.com
|
||||
Reviewed-by: Maxim Levitsky <mlevitsk@redhat.com>
|
||||
Reviewed-by: John Snow <jsnow@redhat.com>
|
||||
Signed-off-by: Max Reitz <mreitz@redhat.com>
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
block/curl.c | 17 ++++++-----------
|
||||
1 file changed, 6 insertions(+), 11 deletions(-)
|
||||
|
||||
diff --git a/block/curl.c b/block/curl.c
|
||||
index cf2686218dcf4bc7d2db1a7026f9..fd70f1ebc458f22f6d1a4bc01e1e 100644
|
||||
--- a/block/curl.c
|
||||
+++ b/block/curl.c
|
||||
@@ -392,24 +392,19 @@ static void curl_multi_check_completion(BDRVCURLState *s)
|
||||
}
|
||||
|
||||
/* Called with s->mutex held. */
|
||||
-static void curl_multi_do_locked(CURLSocket *ready_socket)
|
||||
+static void curl_multi_do_locked(CURLSocket *socket)
|
||||
{
|
||||
- CURLSocket *socket, *next_socket;
|
||||
- CURLState *s = ready_socket->state;
|
||||
+ BDRVCURLState *s = socket->state->s;
|
||||
int running;
|
||||
int r;
|
||||
|
||||
- if (!s->s->multi) {
|
||||
+ if (!s->multi) {
|
||||
return;
|
||||
}
|
||||
|
||||
- /* Need to use _SAFE because curl_multi_socket_action() may trigger
|
||||
- * curl_sock_cb() which might modify this list */
|
||||
- QLIST_FOREACH_SAFE(socket, &s->sockets, next, next_socket) {
|
||||
- do {
|
||||
- r = curl_multi_socket_action(s->s->multi, socket->fd, 0, &running);
|
||||
- } while (r == CURLM_CALL_MULTI_PERFORM);
|
||||
- }
|
||||
+ do {
|
||||
+ r = curl_multi_socket_action(s->multi, socket->fd, 0, &running);
|
||||
+ } while (r == CURLM_CALL_MULTI_PERFORM);
|
||||
}
|
||||
|
||||
static void curl_multi_do(void *arg)
|
22
enable-cross-compilation-on-ARM.patch
Normal file
22
enable-cross-compilation-on-ARM.patch
Normal file
@ -0,0 +1,22 @@
|
||||
From: Bruce Rogers <brogers@suse.com>
|
||||
Date: Mon, 26 Aug 2019 13:28:57 -0600
|
||||
Subject: enable cross compilation on ARM
|
||||
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
Makefile | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/roms/seabios/Makefile b/roms/seabios/Makefile
|
||||
index bd34cfc2394a9103fec2e951bb67..7b8a5cd6b17254685df89798ed10 100644
|
||||
--- a/roms/seabios/Makefile
|
||||
+++ b/roms/seabios/Makefile
|
||||
@@ -13,7 +13,7 @@ export CONFIG_SHELL := sh
|
||||
export KCONFIG_AUTOHEADER := autoconf.h
|
||||
export KCONFIG_CONFIG := $(CURDIR)/.config
|
||||
export LC_ALL := C
|
||||
-CROSS_PREFIX=
|
||||
+CROSS_PREFIX=$(CROSS_COMPILE)
|
||||
ifneq ($(CROSS_PREFIX),)
|
||||
CC=$(CROSS_PREFIX)gcc
|
||||
endif
|
64
hdata-vpd-fix-printing-char-0x00.patch
Normal file
64
hdata-vpd-fix-printing-char-0x00.patch
Normal file
@ -0,0 +1,64 @@
|
||||
From: Stewart Smith <stewart@linux.ibm.com>
|
||||
Date: Tue, 18 Jun 2019 16:06:44 +1000
|
||||
Subject: hdata/vpd: fix printing (char*)0x00
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
Git-commit: ba977f2e4406f9de318afcdf5d666e77585ef269
|
||||
|
||||
GCC9 now catches this bug:
|
||||
|
||||
In file included from hdata/vpd.c:17:
|
||||
In function ‘vpd_vini_parse’,
|
||||
inlined from ‘vpd_data_parse’ at hdata/vpd.c:416:3:
|
||||
/home/stewart/skiboot/include/skiboot.h:93:31: error: ‘%s’ directive argument is null [-Werror=format-overflow=]
|
||||
93 | #define prlog(l, f, ...) do { _prlog(l, pr_fmt(f), ##__VA_ARGS__); } while(0)
|
||||
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
hdata/vpd.c:390:5: note: in expansion of macro ‘prlog’
|
||||
390 | prlog(PR_WARNING,
|
||||
| ^~~~~
|
||||
hdata/vpd.c: In function ‘vpd_data_parse’:
|
||||
hdata/vpd.c:391:46: note: format string is defined here
|
||||
391 | "VPD: CCIN desc not available for: %s\n",
|
||||
| ^~
|
||||
cc1: all warnings being treated as errors
|
||||
|
||||
Signed-off-by: Stewart Smith <stewart@linux.ibm.com>
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
hdata/vpd.c | 9 +++++----
|
||||
1 file changed, 5 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/roms/skiboot/hdata/vpd.c b/roms/skiboot/hdata/vpd.c
|
||||
index 129b5062356a48d900c6aa5a140d..5a01bcc9f6fa2faef2a118eca938 100644
|
||||
--- a/roms/skiboot/hdata/vpd.c
|
||||
+++ b/roms/skiboot/hdata/vpd.c
|
||||
@@ -328,6 +328,7 @@ static void vpd_vini_parse(struct dt_node *node,
|
||||
const void *fruvpd, unsigned int fruvpd_sz)
|
||||
{
|
||||
const void *kw;
|
||||
+ const char *desc;
|
||||
uint8_t sz;
|
||||
const struct card_info *cinfo;
|
||||
|
||||
@@ -381,15 +382,15 @@ static void vpd_vini_parse(struct dt_node *node,
|
||||
dt_add_property_string(node,
|
||||
"description", cinfo->description);
|
||||
} else {
|
||||
- kw = vpd_find(fruvpd, fruvpd_sz, "VINI", "DR", &sz);
|
||||
- if (kw) {
|
||||
+ desc = vpd_find(fruvpd, fruvpd_sz, "VINI", "DR", &sz);
|
||||
+ if (desc) {
|
||||
dt_add_prop_sanitize_val(node,
|
||||
- "description", kw, sz);
|
||||
+ "description", desc, sz);
|
||||
} else {
|
||||
dt_add_property_string(node, "description", "Unknown");
|
||||
prlog(PR_WARNING,
|
||||
"VPD: CCIN desc not available for: %s\n",
|
||||
- (char *)kw);
|
||||
+ (char*)kw);
|
||||
}
|
||||
}
|
||||
}
|
45
hw-arm-boot.c-Set-NSACR.-CP11-CP10-for-N.patch
Normal file
45
hw-arm-boot.c-Set-NSACR.-CP11-CP10-for-N.patch
Normal file
@ -0,0 +1,45 @@
|
||||
From: Peter Maydell <peter.maydell@linaro.org>
|
||||
Date: Fri, 20 Sep 2019 18:40:39 +0100
|
||||
Subject: hw/arm/boot.c: Set NSACR.{CP11,CP10} for NS kernel boots
|
||||
|
||||
Git-commit: ece628fcf69cbbd4b3efb6fbd203af07609467a2
|
||||
|
||||
If we're booting a Linux kernel directly into Non-Secure
|
||||
state on a CPU which has Secure state, then make sure we
|
||||
set the NSACR CP11 and CP10 bits, so that Non-Secure is allowed
|
||||
to access the FPU. Otherwise an AArch32 kernel will UNDEF as
|
||||
soon as it tries to use the FPU.
|
||||
|
||||
It used to not matter that we didn't do this until commit
|
||||
fc1120a7f5f2d4b6, where we implemented actually honouring
|
||||
these NSACR bits.
|
||||
|
||||
The problem only exists for CPUs where EL3 is AArch32; the
|
||||
equivalent AArch64 trap bits are in CPTR_EL3 and are "0 to
|
||||
not trap, 1 to trap", so the reset value of the register
|
||||
permits NS access, unlike NSACR.
|
||||
|
||||
Fixes: fc1120a7f5
|
||||
Fixes: https://bugs.launchpad.net/qemu/+bug/1844597
|
||||
Cc: qemu-stable@nongnu.org
|
||||
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
|
||||
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
|
||||
Message-id: 20190920174039.3916-1-peter.maydell@linaro.org
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
hw/arm/boot.c | 2 ++
|
||||
1 file changed, 2 insertions(+)
|
||||
|
||||
diff --git a/hw/arm/boot.c b/hw/arm/boot.c
|
||||
index c2b89b3bb9b6b92b0293d859712e..fc4e021a38a6bc1e5e2aa5b5876c 100644
|
||||
--- a/hw/arm/boot.c
|
||||
+++ b/hw/arm/boot.c
|
||||
@@ -754,6 +754,8 @@ static void do_cpu_reset(void *opaque)
|
||||
(cs != first_cpu || !info->secure_board_setup)) {
|
||||
/* Linux expects non-secure state */
|
||||
env->cp15.scr_el3 |= SCR_NS;
|
||||
+ /* Set NSACR.{CP11,CP10} so NS can access the FPU */
|
||||
+ env->cp15.nsacr |= 3 << 10;
|
||||
}
|
||||
}
|
||||
|
43
hw-core-loader-Fix-possible-crash-in-rom.patch
Normal file
43
hw-core-loader-Fix-possible-crash-in-rom.patch
Normal file
@ -0,0 +1,43 @@
|
||||
From: Thomas Huth <thuth@redhat.com>
|
||||
Date: Wed, 25 Sep 2019 14:16:43 +0200
|
||||
Subject: hw/core/loader: Fix possible crash in rom_copy()
|
||||
|
||||
Git-commit: e423455c4f23a1a828901c78fe6d03b7dde79319
|
||||
|
||||
Both, "rom->addr" and "addr" are derived from the binary image
|
||||
that can be loaded with the "-kernel" paramer. The code in
|
||||
rom_copy() then calculates:
|
||||
|
||||
d = dest + (rom->addr - addr);
|
||||
|
||||
and uses "d" as destination in a memcpy() some lines later. Now with
|
||||
bad kernel images, it is possible that rom->addr is smaller than addr,
|
||||
thus "rom->addr - addr" gets negative and the memcpy() then tries to
|
||||
copy contents from the image to a bad memory location. This could
|
||||
maybe be used to inject code from a kernel image into the QEMU binary,
|
||||
so we better fix it with an additional sanity check here.
|
||||
|
||||
Cc: qemu-stable@nongnu.org
|
||||
Reported-by: Guangming Liu
|
||||
Buglink: https://bugs.launchpad.net/qemu/+bug/1844635
|
||||
Message-Id: <20190925130331.27825-1-thuth@redhat.com>
|
||||
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
|
||||
Signed-off-by: Thomas Huth <thuth@redhat.com>
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
hw/core/loader.c | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/hw/core/loader.c b/hw/core/loader.c
|
||||
index 425bf69a9968765b4604a442eb0a..838a34174ac2039d55f557fa427a 100644
|
||||
--- a/hw/core/loader.c
|
||||
+++ b/hw/core/loader.c
|
||||
@@ -1242,7 +1242,7 @@ int rom_copy(uint8_t *dest, hwaddr addr, size_t size)
|
||||
if (rom->addr + rom->romsize < addr) {
|
||||
continue;
|
||||
}
|
||||
- if (rom->addr > end) {
|
||||
+ if (rom->addr > end || rom->addr < addr) {
|
||||
break;
|
||||
}
|
||||
|
@ -41,7 +41,7 @@ Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/hw/intc/exynos4210_gic.c b/hw/intc/exynos4210_gic.c
|
||||
index 69f9c18d73..4770950c94 100644
|
||||
index e37d457fcf3ae8f37ae3c4047161..640f146a50af42ccd03aa18786f2 100644
|
||||
--- a/hw/intc/exynos4210_gic.c
|
||||
+++ b/hw/intc/exynos4210_gic.c
|
||||
@@ -288,8 +288,8 @@ static void exynos4210_gic_realize(DeviceState *dev, Error **errp)
|
@ -2,23 +2,24 @@ From: Bruce Rogers <brogers@suse.com>
|
||||
Date: Fri, 5 Apr 2019 21:10:30 -0600
|
||||
Subject: hw/smbios: handle both file formats regardless of machine type
|
||||
|
||||
References: bsc#994082, bsc#1084316, boo#1131894
|
||||
|
||||
It's easy enough to handle either per-spec or legacy smbios structures
|
||||
in the smbios file input without regard to the machine type used, by
|
||||
simply applying the basic smbios formatting rules. then depending on
|
||||
what is detected. terminal numm bytes are added or removed for machine
|
||||
type specific processing.
|
||||
|
||||
[BR: BSC#994082 BSC#1084316 BOO#1131894]
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
hw/smbios/smbios.c | 43 +++++++++++++++++++++++++++++++++++++++----
|
||||
1 file changed, 39 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/hw/smbios/smbios.c b/hw/smbios/smbios.c
|
||||
index 47be9071fa..d4b95ebc84 100644
|
||||
index 7bcd67b098e91a0e724b77b224c1..44e62c2a627195d71ac569e9de49 100644
|
||||
--- a/hw/smbios/smbios.c
|
||||
+++ b/hw/smbios/smbios.c
|
||||
@@ -960,6 +960,7 @@ void smbios_entry_add(QemuOpts *opts, Error **errp)
|
||||
@@ -965,6 +965,7 @@ void smbios_entry_add(QemuOpts *opts, Error **errp)
|
||||
struct smbios_structure_header *header;
|
||||
int size;
|
||||
struct smbios_table *table; /* legacy mode only */
|
||||
@ -26,7 +27,7 @@ index 47be9071fa..d4b95ebc84 100644
|
||||
|
||||
qemu_opts_validate(opts, qemu_smbios_file_opts, &err);
|
||||
if (err) {
|
||||
@@ -974,11 +975,21 @@ void smbios_entry_add(QemuOpts *opts, Error **errp)
|
||||
@@ -979,11 +980,21 @@ void smbios_entry_add(QemuOpts *opts, Error **errp)
|
||||
}
|
||||
|
||||
/*
|
||||
@ -52,7 +53,7 @@ index 47be9071fa..d4b95ebc84 100644
|
||||
header = (struct smbios_structure_header *)(smbios_tables +
|
||||
smbios_tables_len);
|
||||
|
||||
@@ -993,6 +1004,19 @@ void smbios_entry_add(QemuOpts *opts, Error **errp)
|
||||
@@ -998,6 +1009,19 @@ void smbios_entry_add(QemuOpts *opts, Error **errp)
|
||||
header->type);
|
||||
return;
|
||||
}
|
||||
@ -72,7 +73,7 @@ index 47be9071fa..d4b95ebc84 100644
|
||||
set_bit(header->type, have_binfile_bitmap);
|
||||
|
||||
if (header->type == 4) {
|
||||
@@ -1013,6 +1037,17 @@ void smbios_entry_add(QemuOpts *opts, Error **errp)
|
||||
@@ -1018,6 +1042,17 @@ void smbios_entry_add(QemuOpts *opts, Error **errp)
|
||||
* delete the one we don't need from smbios_set_defaults(),
|
||||
* once we know which machine version has been requested.
|
||||
*/
|
@ -1,9 +1,12 @@
|
||||
From: Alistair Francis <Alistair.Francis@wdc.com>
|
||||
Date: Sat, 4 May 2019 07:58:55 -0600
|
||||
Subject: hw/usb/dev-mtp: Fix GCC 9 build warning
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
Fix this warning with GCC 9 on Fedora 30:
|
||||
hw/usb/dev-mtp.c:1715:36: error: taking address of packed member of 'struct <anonymous>' may result in an unaligned pointer value [-Werror=address-of-packed-member]
|
||||
hw/usb/dev-mtp.c:1715:36: error: taking address of packed member of struct <anonymous> may result in an unaligned pointer value [-Werror=address-of-packed-member]
|
||||
1715 | dataset->filename);
|
||||
| ~~~~~~~^~~~~~~~~~
|
||||
|
||||
@ -14,10 +17,10 @@ Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
1 file changed, 13 insertions(+)
|
||||
|
||||
diff --git a/hw/usb/dev-mtp.c b/hw/usb/dev-mtp.c
|
||||
index 99548b012d..8233beacab 100644
|
||||
index fd1b3394a5b4b4827deece722e0c..8de503cc4d55423ae0bd070867c0 100644
|
||||
--- a/hw/usb/dev-mtp.c
|
||||
+++ b/hw/usb/dev-mtp.c
|
||||
@@ -1711,9 +1711,22 @@ static void usb_mtp_write_metadata(MTPState *s, uint64_t dlen)
|
||||
@@ -1720,9 +1720,22 @@ static void usb_mtp_write_metadata(MTPState *s, uint64_t dlen)
|
||||
assert(!s->write_pending);
|
||||
assert(p != NULL);
|
||||
|
@ -1,9 +1,12 @@
|
||||
From: Alistair Francis <Alistair.Francis@wdc.com>
|
||||
Date: Sat, 4 May 2019 07:58:35 -0600
|
||||
Subject: hw/usb/hcd-xhci: Fix GCC 9 build warning
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
Fix this build warning with GCC 9 on Fedora 30:
|
||||
hw/usb/hcd-xhci.c:3339:66: error: '%d' directive output may be truncated writing between 1 and 10 bytes into a region of size 5 [-Werror=format-truncation=]
|
||||
hw/usb/hcd-xhci.c:3339:66: error: %d directive output may be truncated writing between 1 and 10 bytes into a region of size 5 [-Werror=format-truncation=]
|
||||
3339 | snprintf(port->name, sizeof(port->name), "usb2 port #%d", i+1);
|
||||
| ^~
|
||||
hw/usb/hcd-xhci.c:3339:54: note: directive argument in the range [1, 2147483647]
|
||||
@ -12,7 +15,7 @@ hw/usb/hcd-xhci.c:3339:54: note: directive argument in the range [1, 2147483647]
|
||||
In file included from /usr/include/stdio.h:867,
|
||||
from /home/alistair/qemu/include/qemu/osdep.h:99,
|
||||
from hw/usb/hcd-xhci.c:21:
|
||||
/usr/include/bits/stdio2.h:67:10: note: '__builtin___snprintf_chk' output between 13 and 22 bytes into a destination of size 16
|
||||
/usr/include/bits/stdio2.h:67:10: note: __builtin___snprintf_chk output between 13 and 22 bytes into a destination of size 16
|
||||
67 | return __builtin___snprintf_chk (__s, __n, __USE_FORTIFY_LEVEL - 1,
|
||||
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
68 | __bos (__s), __fmt, __va_arg_pack ());
|
||||
@ -25,10 +28,10 @@ Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/hw/usb/hcd-xhci.c b/hw/usb/hcd-xhci.c
|
||||
index ec28bee319..2b061772b2 100644
|
||||
index 5894a186633414970fe748dbd9f4..47ea8dd3a5f6a09e361f0f59c7b9 100644
|
||||
--- a/hw/usb/hcd-xhci.c
|
||||
+++ b/hw/usb/hcd-xhci.c
|
||||
@@ -3322,6 +3322,7 @@ static void usb_xhci_init(XHCIState *xhci)
|
||||
@@ -3324,6 +3324,7 @@ static void usb_xhci_init(XHCIState *xhci)
|
||||
usb_bus_new(&xhci->bus, sizeof(xhci->bus), &xhci_bus_ops, dev);
|
||||
|
||||
for (i = 0; i < usbports; i++) {
|
@ -5,21 +5,21 @@ MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
References: bnc#812836
|
||||
|
||||
qemu-kvm 0.15 had a VMSTATE_UINT32(flags, PITState) field that
|
||||
qemu 1.4 does not have.
|
||||
|
||||
Addresses part of BNC#812836.
|
||||
|
||||
Signed-off-by: Andreas Färber <afaerber@suse.de>
|
||||
---
|
||||
hw/timer/i8254_common.c | 7 +++++++
|
||||
1 file changed, 7 insertions(+)
|
||||
|
||||
diff --git a/hw/timer/i8254_common.c b/hw/timer/i8254_common.c
|
||||
index 6190b6fc5d..177b1acf37 100644
|
||||
index 76ca6ec4446998f62d384a909814..fb9d5047f8c50df8ad0e662a42ac 100644
|
||||
--- a/hw/timer/i8254_common.c
|
||||
+++ b/hw/timer/i8254_common.c
|
||||
@@ -259,6 +259,12 @@ static int pit_dispatch_post_load(void *opaque, int version_id)
|
||||
@@ -261,6 +261,12 @@ static int pit_dispatch_post_load(void *opaque, int version_id)
|
||||
return 0;
|
||||
}
|
||||
|
||||
@ -32,7 +32,7 @@ index 6190b6fc5d..177b1acf37 100644
|
||||
static const VMStateDescription vmstate_pit_common = {
|
||||
.name = "i8254",
|
||||
.version_id = 3,
|
||||
@@ -268,6 +274,7 @@ static const VMStateDescription vmstate_pit_common = {
|
||||
@@ -270,6 +276,7 @@ static const VMStateDescription vmstate_pit_common = {
|
||||
.pre_save = pit_dispatch_pre_save,
|
||||
.post_load = pit_dispatch_post_load,
|
||||
.fields = (VMStateField[]) {
|
@ -18,10 +18,10 @@ Signed-off-by: Andreas Färber <afaerber@suse.de>
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/target/i386/cpu.h b/target/i386/cpu.h
|
||||
index 83fb522554..572290c3d6 100644
|
||||
index 8b3dc5533e6994bf9066f88f1a5e..3440f1e4297940d8db2e533d5cb1 100644
|
||||
--- a/target/i386/cpu.h
|
||||
+++ b/target/i386/cpu.h
|
||||
@@ -1708,7 +1708,7 @@ uint64_t cpu_get_tsc(CPUX86State *env);
|
||||
@@ -1713,7 +1713,7 @@ uint64_t cpu_get_tsc(CPUX86State *env);
|
||||
/* XXX: This value should match the one returned by CPUID
|
||||
* and in exec.c */
|
||||
# if defined(TARGET_X86_64)
|
@ -1,4 +1,8 @@
|
||||
ipxe:Makefile: fix issues of build reproducibility
|
||||
From: Bruce Rogers <brogers@suse.com>
|
||||
Date: Thu, 27 Jun 2019 10:15:24 -0600
|
||||
Subject: ipxe:Makefile: fix issues of build reproducibility
|
||||
|
||||
References: bsc#1011213
|
||||
|
||||
It is desirable to produce the same bits on subsequent
|
||||
builds when the actual code of the package doesn't
|
||||
@ -6,12 +10,14 @@ change. (bsc#1011213)
|
||||
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
src/Makefile.housekeeping | 13 ++++++++++---
|
||||
src/Makefile.housekeeping | 13 ++++++++++---
|
||||
1 file changed, 10 insertions(+), 3 deletions(-)
|
||||
|
||||
--- a/src/Makefile.housekeeping
|
||||
+++ b/src/Makefile.housekeeping
|
||||
@@ -1079,11 +1079,18 @@ blib : $(BLIB)
|
||||
diff --git a/roms/ipxe/src/Makefile.housekeeping b/roms/ipxe/src/Makefile.housekeeping
|
||||
index f8334921b8b93cbd03f0a0de9910..97fa325bb52314e05192d0414436 100644
|
||||
--- a/roms/ipxe/src/Makefile.housekeeping
|
||||
+++ b/roms/ipxe/src/Makefile.housekeeping
|
||||
@@ -1162,11 +1162,18 @@ blib : $(BLIB)
|
||||
# Command to generate build ID. Must be unique for each $(BIN)/%.tmp,
|
||||
# even within the same build run.
|
||||
#
|
||||
@ -32,7 +38,7 @@ Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
|
||||
# Build version
|
||||
#
|
||||
@@ -1103,7 +1110,7 @@ $(BIN)/version.%.o : core/version.c $(MA
|
||||
@@ -1186,7 +1193,7 @@ $(BIN)/version.%.o : core/version.c $(MAKEDEPS) $(GIT_INDEX)
|
||||
$(BIN)/%.tmp : $(BIN)/version.%.o $(BLIB) $(MAKEDEPS) $(LDSCRIPT)
|
||||
$(QM)$(ECHO) " [LD] $@"
|
||||
$(Q)$(LD) $(LDFLAGS) -T $(LDSCRIPT) $(TGT_LD_FLAGS) $< $(BLIB) -o $@ \
|
@ -1,35 +0,0 @@
|
||||
From 0ee72a15887b838d967c3b05070d5ad86f0d729a Mon Sep 17 00:00:00 2001
|
||||
From: Bruce Rogers <brogers@suse.com>
|
||||
Date: Fri, 25 Jan 2019 10:29:16 -0700
|
||||
Subject: [PATCH] [build] Disable gcc address of packed member warning
|
||||
|
||||
GCC 9.0 introduces a new warning for using pointers to packed
|
||||
structure and union members. ipxe code is replete with this usage,
|
||||
partly because the architectures it is designed for handle unaligned
|
||||
accesses. Therefore this warning is not very helpful and since the
|
||||
default build considers warnings to be errors, needs to be disabled.
|
||||
|
||||
[BR: BSC#1121464]
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
--- a/src/Makefile.housekeeping
|
||||
+++ b/src/Makefile.housekeeping
|
||||
@@ -187,6 +187,19 @@ WNST_FLAGS := $(shell $(WNST_TEST) && $(
|
||||
WORKAROUND_CFLAGS += $(WNST_FLAGS)
|
||||
endif
|
||||
|
||||
+# GCC 9.0 introduces a new warning for using pointers to packed
|
||||
+# structure and union members. ipxe code is replete with this usage,
|
||||
+# partly because the architectures it is designed for handle unaligned
|
||||
+# accesses. Therefore this warning is not very helpful and since the
|
||||
+# default build considers warnings to be errors, needs to be disabled.
|
||||
+#
|
||||
+ifeq ($(CCTYPE),gcc)
|
||||
+WNAOPM_TEST = $(CC) -Waddress-of-packed-member -x c -c /dev/null -o /dev/null \
|
||||
+ >/dev/null 2>&1
|
||||
+WNAOPM_FLAGS := $(shell $(WNAOPM_TEST) && $(ECHO) '-Wno-address-of-packed-member')
|
||||
+WORKAROUND_CFLAGS += $(WNAOPM_FLAGS)
|
||||
+endif
|
||||
+
|
||||
# Some versions of gas choke on division operators, treating them as
|
||||
# comment markers. Specifying --divide will work around this problem,
|
||||
# but isn't available on older gas versions.
|
@ -1,37 +0,0 @@
|
||||
From 16a934b5fc715cd0f213390c88df0b4ec73d85f1 Mon Sep 17 00:00:00 2001
|
||||
From: Bruce Rogers <brogers@suse.com>
|
||||
Date: Mon, 25 Feb 2019 15:21:06 -0700
|
||||
Subject: [PATCH] efi: Avoid string op warning with cross gcc 7 compile
|
||||
|
||||
When we started cross compiling using the gcc7 arm compiler, the
|
||||
a string op warning popped up that isn't addressed by the mechanism
|
||||
already in place. Add a kludge to address it.
|
||||
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
src/util/elf2efi.c | 9 ++++++++-
|
||||
1 file changed, 8 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/src/util/elf2efi.c b/src/util/elf2efi.c
|
||||
index 2c5b9df8..7d1cf03f 100644
|
||||
--- a/src/util/elf2efi.c
|
||||
+++ b/src/util/elf2efi.c
|
||||
@@ -494,7 +494,14 @@ static struct pe_section * process_section ( struct elf_file *elf,
|
||||
memset ( new, 0, sizeof ( *new ) + section_filesz );
|
||||
|
||||
/* Fill in section header details */
|
||||
- strncpy ( ( char * ) new->hdr.Name, name, sizeof ( new->hdr.Name ) );
|
||||
+ /*
|
||||
+ * The arm cross gcc 7 compiler warns about string problem here. Avoid
|
||||
+ * it by doing operation in two stages
|
||||
+ */
|
||||
+ strncpy ( ( char * ) new->hdr.Name, name, sizeof ( new->hdr.Name ) -1 );
|
||||
+ if (strlen(name) == sizeof( new->hdr.Name ) -1 ) {
|
||||
+ *(( char * ) new->hdr.Name + sizeof( new->hdr.Name ) -1) = '\0';
|
||||
+ }
|
||||
new->hdr.Misc.VirtualSize = section_memsz;
|
||||
new->hdr.VirtualAddress = shdr->sh_addr;
|
||||
new->hdr.SizeOfRawData = section_filesz;
|
||||
--
|
||||
2.20.1
|
||||
|
@ -1,42 +0,0 @@
|
||||
From 1280c1f65b73d6d0c4833e39a3bb8194bd03f906 Mon Sep 17 00:00:00 2001
|
||||
From: Bruce Rogers <brogers@suse.com>
|
||||
Date: Fri, 25 Jan 2019 09:37:44 -0700
|
||||
Subject: [PATCH] [efi] Simplify diagnostic for NULL handle
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
Compiling with GCC 9 now warns as follows:
|
||||
interface/efi/efi_debug.c:334:3: error: ‘%s’ directive argument is null [-Werror=format-overflow=]
|
||||
334 | printf ( "HANDLE %s could not retrieve protocols\n",
|
||||
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
335 | efi_handle_name ( handle ) );
|
||||
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
cc1: all warnings being treated as errors
|
||||
|
||||
Simplify this diagnostic by simply indicating a <NULL> has been
|
||||
passed as a handle.
|
||||
|
||||
[BR: BSC#1121464]
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
src/interface/efi/efi_debug.c | 3 +--
|
||||
1 file changed, 1 insertion(+), 2 deletions(-)
|
||||
|
||||
diff --git a/src/interface/efi/efi_debug.c b/src/interface/efi/efi_debug.c
|
||||
index 8ea0a822..19fba767 100644
|
||||
--- a/src/interface/efi/efi_debug.c
|
||||
+++ b/src/interface/efi/efi_debug.c
|
||||
@@ -331,8 +331,7 @@ void dbg_efi_protocols ( EFI_HANDLE handle ) {
|
||||
|
||||
/* Sanity check */
|
||||
if ( ! handle ) {
|
||||
- printf ( "HANDLE %s could not retrieve protocols\n",
|
||||
- efi_handle_name ( handle ) );
|
||||
+ printf ( "HANDLE <NULL> could not retrieve protocols\n" );
|
||||
return;
|
||||
}
|
||||
|
||||
--
|
||||
2.20.1
|
||||
|
@ -1,36 +0,0 @@
|
||||
ipxe: use gcc6 for more compact code
|
||||
|
||||
We have a strict size limit of 64K which needs to be enforced for
|
||||
pxe-virtio.rom for migration compatibility. The v4.8 gcc compiler
|
||||
used in SLE12 doesn't produce as compact code as does more recent
|
||||
gcc compilers, and the pxe-virtio.rom produced with it doesn't fit
|
||||
in 64K anymore without taking extraordinary efforts. I was unable
|
||||
to find enough opportunities in the ipxe code and data to reduce
|
||||
its size, and found that using a more recent compiler would be the
|
||||
best solution to keeping the rom size within the 64K size limit.
|
||||
|
||||
I also discovered that $(WORKAROUND_CFLAGS) is specific to CC, but
|
||||
gets used with HOST_CC, so we'd better keep those the same version
|
||||
to not get in trouble with different supported options.
|
||||
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
--- a/src/Makefile
|
||||
+++ b/src/Makefile
|
||||
@@ -15,7 +15,7 @@ CROSS_COMPILE ?= $(CROSS)
|
||||
#
|
||||
# Locations of tools
|
||||
#
|
||||
-HOST_CC := gcc
|
||||
+HOST_CC := gcc-6
|
||||
RM := rm -f
|
||||
TOUCH := touch
|
||||
MKDIR := mkdir
|
||||
@@ -24,7 +24,7 @@ ECHO := echo
|
||||
PRINTF := printf
|
||||
PERL := perl
|
||||
TRUE := true
|
||||
-CC := $(CROSS_COMPILE)gcc
|
||||
+CC := $(CROSS_COMPILE)gcc-6
|
||||
CPP := $(CC) -E
|
||||
AS := $(CROSS_COMPILE)as
|
||||
LD := $(CROSS_COMPILE)ld
|
@ -17,17 +17,18 @@ Signed-off-by: Alexander Graf <agraf@suse.de>
|
||||
[AF: Rebased for v1.6 and v1.7]
|
||||
Signed-off-by: Andreas Färber <afaerber@suse.de>
|
||||
---
|
||||
linux-user/syscall.c | 20 ++++++++++++++++++++
|
||||
1 file changed, 20 insertions(+)
|
||||
linux-user/syscall.c | 24 ++++++++++++++++++++++++
|
||||
1 file changed, 24 insertions(+)
|
||||
|
||||
diff --git a/linux-user/syscall.c b/linux-user/syscall.c
|
||||
index 958f94ab2a..fade440440 100644
|
||||
index cf5de07a09235e6d92735332dc7f..3bb2c8921fc203264bbc0a37fe1d 100644
|
||||
--- a/linux-user/syscall.c
|
||||
+++ b/linux-user/syscall.c
|
||||
@@ -6711,6 +6711,25 @@ static int open_self_stat(void *cpu_env, int fd)
|
||||
@@ -6958,6 +6958,27 @@ static int open_self_stat(void *cpu_env, int fd)
|
||||
return 0;
|
||||
}
|
||||
|
||||
+#if defined(TARGET_ARM)
|
||||
+static int open_cpuinfo(void *cpu_env, int fd)
|
||||
+{
|
||||
+ dprintf(fd,
|
||||
@ -46,15 +47,18 @@ index 958f94ab2a..fade440440 100644
|
||||
+
|
||||
+ return 0;
|
||||
+}
|
||||
+#endif
|
||||
+
|
||||
static int open_self_auxv(void *cpu_env, int fd)
|
||||
{
|
||||
CPUState *cpu = ENV_GET_CPU((CPUArchState *)cpu_env);
|
||||
@@ -6831,6 +6850,7 @@ static int do_openat(void *cpu_env, int dirfd, const char *pathname, int flags,
|
||||
#if defined(HOST_WORDS_BIGENDIAN) != defined(TARGET_WORDS_BIGENDIAN)
|
||||
{ "/proc/net/route", open_net_route, is_proc },
|
||||
CPUState *cpu = env_cpu((CPUArchState *)cpu_env);
|
||||
@@ -7100,6 +7121,9 @@ static int do_openat(void *cpu_env, int dirfd, const char *pathname, int flags,
|
||||
#if defined(TARGET_SPARC)
|
||||
{ "/proc/cpuinfo", open_cpuinfo, is_proc },
|
||||
#endif
|
||||
+#if defined(TARGET_ARM)
|
||||
+ { "cpuinfo", open_cpuinfo, is_proc_myself },
|
||||
{ NULL, NULL, NULL }
|
||||
};
|
||||
|
||||
+#endif
|
||||
#if defined(TARGET_M68K)
|
||||
{ "/proc/hardware", open_hardware, is_proc },
|
||||
#endif
|
@ -35,7 +35,7 @@ Signed-off-by: Andreas Färber <afaerber@suse.de>
|
||||
3 files changed, 57 insertions(+)
|
||||
|
||||
diff --git a/Makefile.target b/Makefile.target
|
||||
index ae02495951..53fd5aa01e 100644
|
||||
index 933b27453a1dbb9273e0a9ff2d58..6e401da667fe4295acec4dc11302 100644
|
||||
--- a/Makefile.target
|
||||
+++ b/Makefile.target
|
||||
@@ -42,6 +42,10 @@ STPFILES=
|
||||
@ -49,7 +49,7 @@ index ae02495951..53fd5aa01e 100644
|
||||
config-target.h: config-target.h-timestamp
|
||||
config-target.h-timestamp: config-target.mak
|
||||
|
||||
@@ -130,6 +134,8 @@ QEMU_CFLAGS+=-I$(SRC_PATH)/linux-user/$(TARGET_ABI_DIR) \
|
||||
@@ -134,6 +138,8 @@ QEMU_CFLAGS+=-I$(SRC_PATH)/linux-user/$(TARGET_ABI_DIR) \
|
||||
obj-y += linux-user/
|
||||
obj-y += gdbstub.o thunk.o
|
||||
|
||||
@ -58,7 +58,7 @@ index ae02495951..53fd5aa01e 100644
|
||||
endif #CONFIG_LINUX_USER
|
||||
|
||||
#########################################################
|
||||
@@ -170,7 +176,11 @@ GENERATED_FILES += hmp-commands.h hmp-commands-info.h
|
||||
@@ -175,7 +181,11 @@ generated-files-y += config-devices.h
|
||||
|
||||
endif # CONFIG_SOFTMMU
|
||||
|
||||
@ -70,7 +70,7 @@ index ae02495951..53fd5aa01e 100644
|
||||
all-obj-y := $(obj-y)
|
||||
|
||||
include $(SRC_PATH)/Makefile.objs
|
||||
@@ -207,6 +217,9 @@ ifdef CONFIG_DARWIN
|
||||
@@ -212,6 +222,9 @@ ifdef CONFIG_DARWIN
|
||||
$(call quiet-command,SetFile -a C $@,"SETFILE","$(TARGET_DIR)$@")
|
||||
endif
|
||||
|
||||
@ -81,18 +81,18 @@ index ae02495951..53fd5aa01e 100644
|
||||
$(call quiet-command,rm -f $@ && $(SHELL) $(SRC_PATH)/scripts/feature_to_c.sh $@ $(TARGET_XML_FILES),"GEN","$(TARGET_DIR)$@")
|
||||
|
||||
diff --git a/linux-user/Makefile.objs b/linux-user/Makefile.objs
|
||||
index 769b8d8336..d48837313d 100644
|
||||
index d2f33beb5e52efce6adc7fb85b7f..ffc6b095e253d4c448000a974d4d 100644
|
||||
--- a/linux-user/Makefile.objs
|
||||
+++ b/linux-user/Makefile.objs
|
||||
@@ -7,3 +7,5 @@ obj-$(TARGET_HAS_BFLT) += flatload.o
|
||||
obj-$(TARGET_I386) += vm86.o
|
||||
@@ -8,3 +8,5 @@ obj-$(TARGET_I386) += vm86.o
|
||||
obj-$(TARGET_ARM) += arm/nwfpe/
|
||||
obj-$(TARGET_M68K) += m68k-sim.o
|
||||
obj-$(TARGET_ARM) += arm/semihost.o
|
||||
obj-$(TARGET_AARCH64) += arm/semihost.o
|
||||
+
|
||||
+obj-binfmt-y = binfmt.o
|
||||
diff --git a/linux-user/binfmt.c b/linux-user/binfmt.c
|
||||
new file mode 100644
|
||||
index 0000000000..cd1f513b33
|
||||
index 0000000000000000000000000000000000000000..cd1f513b334f3b263d9e4b5adb1981e376429fa6
|
||||
--- /dev/null
|
||||
+++ b/linux-user/binfmt.c
|
||||
@@ -0,0 +1,42 @@
|
@ -11,7 +11,7 @@ Signed-off-by: Alexander Graf <agraf@suse.de>
|
||||
1 file changed, 26 insertions(+)
|
||||
|
||||
diff --git a/linux-user/binfmt.c b/linux-user/binfmt.c
|
||||
index cd1f513b33..458f136fb4 100644
|
||||
index cd1f513b334f3b263d9e4b5adb19..458f136fb41727702854cae4e542 100644
|
||||
--- a/linux-user/binfmt.c
|
||||
+++ b/linux-user/binfmt.c
|
||||
@@ -5,6 +5,9 @@
|
@ -15,10 +15,10 @@ Signed-off-by: Alexander Graf <agraf@suse.de>
|
||||
1 file changed, 7 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/linux-user/syscall.c b/linux-user/syscall.c
|
||||
index f2d1f8669f..5088649781 100644
|
||||
index 8aa653262154326beced64bbe782..5360786be3466c44554b373b4238 100644
|
||||
--- a/linux-user/syscall.c
|
||||
+++ b/linux-user/syscall.c
|
||||
@@ -7342,8 +7342,13 @@ static abi_long do_syscall1(void *cpu_env, int num, abi_ulong arg1,
|
||||
@@ -7619,8 +7619,13 @@ static abi_long do_syscall1(void *cpu_env, int num, abi_ulong arg1,
|
||||
return ret;
|
||||
#endif
|
||||
#ifdef TARGET_NR_lseek
|
@ -15,10 +15,10 @@ Signed-off-by: Andreas Schwab <schwab@suse.de>
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/linux-user/syscall.c b/linux-user/syscall.c
|
||||
index 5088649781..ed1c76e304 100644
|
||||
index 5360786be3466c44554b373b4238..330fbecb120ebc9ebc1c0ec121f6 100644
|
||||
--- a/linux-user/syscall.c
|
||||
+++ b/linux-user/syscall.c
|
||||
@@ -9360,7 +9360,7 @@ static abi_long do_syscall1(void *cpu_env, int num, abi_ulong arg1,
|
||||
@@ -9646,7 +9646,7 @@ static abi_long do_syscall1(void *cpu_env, int num, abi_ulong arg1,
|
||||
{
|
||||
struct timespec ts, *pts;
|
||||
|
@ -16,10 +16,10 @@ Signed-off-by: Alexander Graf <agraf@suse.de>
|
||||
2 files changed, 13 insertions(+), 13 deletions(-)
|
||||
|
||||
diff --git a/linux-user/qemu.h b/linux-user/qemu.h
|
||||
index ef400cb78a..ccb198f666 100644
|
||||
index aac0334627003fbf375dfd4c88d0..abd0b4569699ff87d015c951e651 100644
|
||||
--- a/linux-user/qemu.h
|
||||
+++ b/linux-user/qemu.h
|
||||
@@ -206,10 +206,10 @@ abi_long memcpy_to_target(abi_ulong dest, const void *src,
|
||||
@@ -207,10 +207,10 @@ abi_long memcpy_to_target(abi_ulong dest, const void *src,
|
||||
void target_set_brk(abi_ulong new_brk);
|
||||
abi_long do_brk(abi_ulong new_brk);
|
||||
void syscall_init(void);
|
||||
@ -35,10 +35,10 @@ index ef400cb78a..ccb198f666 100644
|
||||
extern __thread CPUState *thread_cpu;
|
||||
void cpu_loop(CPUArchState *env);
|
||||
diff --git a/linux-user/syscall.c b/linux-user/syscall.c
|
||||
index fade440440..f2d1f8669f 100644
|
||||
index 3bb2c8921fc203264bbc0a37fe1d..8aa653262154326beced64bbe782 100644
|
||||
--- a/linux-user/syscall.c
|
||||
+++ b/linux-user/syscall.c
|
||||
@@ -6988,10 +6988,10 @@ static int host_to_target_cpu_mask(const unsigned long *host_mask,
|
||||
@@ -7264,10 +7264,10 @@ static int host_to_target_cpu_mask(const unsigned long *host_mask,
|
||||
* of syscall results, can be performed.
|
||||
* All errnos that do_syscall() returns must be -TARGET_<errcode>.
|
||||
*/
|
||||
@ -51,18 +51,18 @@ index fade440440..f2d1f8669f 100644
|
||||
+ abi_ulong arg5, abi_ulong arg6, abi_ulong arg7,
|
||||
+ abi_ulong arg8)
|
||||
{
|
||||
CPUState *cpu = ENV_GET_CPU(cpu_env);
|
||||
CPUState *cpu = env_cpu(cpu_env);
|
||||
abi_long ret;
|
||||
@@ -9727,7 +9727,7 @@ static abi_long do_syscall1(void *cpu_env, int num, abi_long arg1,
|
||||
@@ -10013,7 +10013,7 @@ static abi_long do_syscall1(void *cpu_env, int num, abi_long arg1,
|
||||
*/
|
||||
ret = -TARGET_EINVAL;
|
||||
if (cpu_isar_feature(aa64_sve, arm_env_get_cpu(cpu_env))
|
||||
if (cpu_isar_feature(aa64_sve, env_archcpu(cpu_env))
|
||||
- && arg2 >= 0 && arg2 <= 512 * 16 && !(arg2 & 15)) {
|
||||
+ && arg2 <= 512 * 16 && !(arg2 & 15)) {
|
||||
CPUARMState *env = cpu_env;
|
||||
ARMCPU *cpu = arm_env_get_cpu(env);
|
||||
ARMCPU *cpu = env_archcpu(env);
|
||||
uint32_t vq, old_vq;
|
||||
@@ -11630,10 +11630,10 @@ static abi_long do_syscall1(void *cpu_env, int num, abi_long arg1,
|
||||
@@ -11993,10 +11993,10 @@ static abi_long do_syscall1(void *cpu_env, int num, abi_long arg1,
|
||||
return ret;
|
||||
}
|
||||
|
||||
@ -75,5 +75,5 @@ index fade440440..f2d1f8669f 100644
|
||||
+ abi_ulong arg5, abi_ulong arg6, abi_ulong arg7,
|
||||
+ abi_ulong arg8)
|
||||
{
|
||||
CPUState *cpu = ENV_GET_CPU(cpu_env);
|
||||
CPUState *cpu = env_cpu(cpu_env);
|
||||
abi_long ret;
|
44
memory-Provide-an-equality-function-for-.patch
Normal file
44
memory-Provide-an-equality-function-for-.patch
Normal file
@ -0,0 +1,44 @@
|
||||
From: "Dr. David Alan Gilbert" <dgilbert@redhat.com>
|
||||
Date: Wed, 14 Aug 2019 18:55:34 +0100
|
||||
Subject: memory: Provide an equality function for MemoryRegionSections
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
Git-commit: 9366cf02e4e31c2a8128904d4d8290a0fad5f888
|
||||
|
||||
Provide a comparison function that checks all the fields are the same.
|
||||
|
||||
Signed-off-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
|
||||
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
|
||||
Message-Id: <20190814175535.2023-3-dgilbert@redhat.com>
|
||||
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
|
||||
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
include/exec/memory.h | 12 ++++++++++++
|
||||
1 file changed, 12 insertions(+)
|
||||
|
||||
diff --git a/include/exec/memory.h b/include/exec/memory.h
|
||||
index bb0961ddb96788539e7138d4f5b3..25bc7ef1adc04d6de1ce1a41a38a 100644
|
||||
--- a/include/exec/memory.h
|
||||
+++ b/include/exec/memory.h
|
||||
@@ -496,6 +496,18 @@ struct MemoryRegionSection {
|
||||
bool nonvolatile;
|
||||
};
|
||||
|
||||
+static inline bool MemoryRegionSection_eq(MemoryRegionSection *a,
|
||||
+ MemoryRegionSection *b)
|
||||
+{
|
||||
+ return a->mr == b->mr &&
|
||||
+ a->fv == b->fv &&
|
||||
+ a->offset_within_region == b->offset_within_region &&
|
||||
+ a->offset_within_address_space == b->offset_within_address_space &&
|
||||
+ int128_eq(a->size, b->size) &&
|
||||
+ a->readonly == b->readonly &&
|
||||
+ a->nonvolatile == b->nonvolatile;
|
||||
+}
|
||||
+
|
||||
/**
|
||||
* memory_region_init: Initialize a memory region
|
||||
*
|
50
mirror-Keep-mirror_top_bs-drained-after-.patch
Normal file
50
mirror-Keep-mirror_top_bs-drained-after-.patch
Normal file
@ -0,0 +1,50 @@
|
||||
From: Kevin Wolf <kwolf@redhat.com>
|
||||
Date: Mon, 22 Jul 2019 17:44:27 +0200
|
||||
Subject: mirror: Keep mirror_top_bs drained after dropping permissions
|
||||
|
||||
Git-commit: d2da5e288a2e71e82866c8fdefd41b5727300124
|
||||
|
||||
mirror_top_bs is currently implicitly drained through its connection to
|
||||
the source or the target node. However, the drain section for target_bs
|
||||
ends early after moving mirror_top_bs from src to target_bs, so that
|
||||
requests can already be restarted while mirror_top_bs is still present
|
||||
in the chain, but has dropped all permissions and therefore runs into an
|
||||
assertion failure like this:
|
||||
|
||||
qemu-system-x86_64: block/io.c:1634: bdrv_co_write_req_prepare:
|
||||
Assertion `child->perm & BLK_PERM_WRITE' failed.
|
||||
|
||||
Keep mirror_top_bs drained until all graph changes have completed.
|
||||
|
||||
Cc: qemu-stable@nongnu.org
|
||||
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
|
||||
Reviewed-by: Max Reitz <mreitz@redhat.com>
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
block/mirror.c | 6 +++++-
|
||||
1 file changed, 5 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/block/mirror.c b/block/mirror.c
|
||||
index 9f5c59ece1df391babc4461f63cb..642d6570cc97e1239b119a46c457 100644
|
||||
--- a/block/mirror.c
|
||||
+++ b/block/mirror.c
|
||||
@@ -656,7 +656,10 @@ static int mirror_exit_common(Job *job)
|
||||
s->target = NULL;
|
||||
|
||||
/* We don't access the source any more. Dropping any WRITE/RESIZE is
|
||||
- * required before it could become a backing file of target_bs. */
|
||||
+ * required before it could become a backing file of target_bs. Not having
|
||||
+ * these permissions any more means that we can't allow any new requests on
|
||||
+ * mirror_top_bs from now on, so keep it drained. */
|
||||
+ bdrv_drained_begin(mirror_top_bs);
|
||||
bs_opaque->stop = true;
|
||||
bdrv_child_refresh_perms(mirror_top_bs, mirror_top_bs->backing,
|
||||
&error_abort);
|
||||
@@ -724,6 +727,7 @@ static int mirror_exit_common(Job *job)
|
||||
bs_opaque->job = NULL;
|
||||
|
||||
bdrv_drained_end(src);
|
||||
+ bdrv_drained_end(mirror_top_bs);
|
||||
s->in_drain = false;
|
||||
bdrv_unref(mirror_top_bs);
|
||||
bdrv_unref(src);
|
@ -11,7 +11,7 @@ Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/pc-bios/s390-ccw/netboot.mak b/pc-bios/s390-ccw/netboot.mak
|
||||
index 14e96b2aa6..c965a4cfd4 100644
|
||||
index 5eefb7c289395ca37fcd241ce53d..ea2994722cde7e8a65796d374dc7 100644
|
||||
--- a/pc-bios/s390-ccw/netboot.mak
|
||||
+++ b/pc-bios/s390-ccw/netboot.mak
|
||||
@@ -53,6 +53,7 @@ libc.a: $(LIBCOBJS)
|
37
pr-manager-Fix-invalid-g_free-crash-bug.patch
Normal file
37
pr-manager-Fix-invalid-g_free-crash-bug.patch
Normal file
@ -0,0 +1,37 @@
|
||||
From: Markus Armbruster <armbru@redhat.com>
|
||||
Date: Thu, 22 Aug 2019 15:38:46 +0200
|
||||
Subject: pr-manager: Fix invalid g_free() crash bug
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
Git-commit: 6b9d62c2a9e83bbad73fb61406f0ff69b46ff6f3
|
||||
|
||||
pr_manager_worker() passes its @opaque argument to g_free(). Wrong;
|
||||
it points to pr_manager_worker()'s automatic @data. Broken when
|
||||
commit 2f3a7ab39be converted @data from heap- to stack-allocated. Fix
|
||||
by deleting the g_free().
|
||||
|
||||
Fixes: 2f3a7ab39bec4ba8022dc4d42ea641165b004e3e
|
||||
Cc: qemu-stable@nongnu.org
|
||||
Signed-off-by: Markus Armbruster <armbru@redhat.com>
|
||||
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
|
||||
Acked-by: Paolo Bonzini <pbonzini@redhat.com>
|
||||
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
scsi/pr-manager.c | 1 -
|
||||
1 file changed, 1 deletion(-)
|
||||
|
||||
diff --git a/scsi/pr-manager.c b/scsi/pr-manager.c
|
||||
index ee43663576ed32c3d27649157e83..0c866e869835930767dacd3a0b21 100644
|
||||
--- a/scsi/pr-manager.c
|
||||
+++ b/scsi/pr-manager.c
|
||||
@@ -39,7 +39,6 @@ static int pr_manager_worker(void *opaque)
|
||||
int fd = data->fd;
|
||||
int r;
|
||||
|
||||
- g_free(data);
|
||||
trace_pr_manager_run(fd, hdr->cmdp[0], hdr->cmdp[1]);
|
||||
|
||||
/* The reference was taken in pr_manager_execute. */
|
@ -1,8 +0,0 @@
|
||||
#!/bin/sh
|
||||
|
||||
cp qemu.changes qemu-testsuite.changes
|
||||
|
||||
if [ "$1" != "-q" ]; then
|
||||
echo "Note that the patch queue needs to be regenerated via update_git.sh"
|
||||
echo "before running $0."
|
||||
fi
|
56
qcow2-Fix-the-calculation-of-the-maximum.patch
Normal file
56
qcow2-Fix-the-calculation-of-the-maximum.patch
Normal file
@ -0,0 +1,56 @@
|
||||
From: Alberto Garcia <berto@igalia.com>
|
||||
Date: Fri, 16 Aug 2019 15:17:42 +0300
|
||||
Subject: qcow2: Fix the calculation of the maximum L2 cache size
|
||||
|
||||
Git-commit: b70d08205b2e4044c529eefc21df2c8ab61b473b
|
||||
|
||||
The size of the qcow2 L2 cache defaults to 32 MB, which can be easily
|
||||
larger than the maximum amount of L2 metadata that the image can have.
|
||||
For example: with 64 KB clusters the user would need a qcow2 image
|
||||
with a virtual size of 256 GB in order to have 32 MB of L2 metadata.
|
||||
|
||||
Because of that, since commit b749562d9822d14ef69c9eaa5f85903010b86c30
|
||||
we forbid the L2 cache to become larger than the maximum amount of L2
|
||||
metadata for the image, calculated using this formula:
|
||||
|
||||
uint64_t max_l2_cache = virtual_disk_size / (s->cluster_size / 8);
|
||||
|
||||
The problem with this formula is that the result should be rounded up
|
||||
to the cluster size because an L2 table on disk always takes one full
|
||||
cluster.
|
||||
|
||||
For example, a 1280 MB qcow2 image with 64 KB clusters needs exactly
|
||||
160 KB of L2 metadata, but we need 192 KB on disk (3 clusters) even if
|
||||
the last 32 KB of those are not going to be used.
|
||||
|
||||
However QEMU rounds the numbers down and only creates 2 cache tables
|
||||
(128 KB), which is not enough for the image.
|
||||
|
||||
A quick test doing 4KB random writes on a 1280 MB image gives me
|
||||
around 500 IOPS, while with the correct cache size I get 16K IOPS.
|
||||
|
||||
Cc: qemu-stable@nongnu.org
|
||||
Signed-off-by: Alberto Garcia <berto@igalia.com>
|
||||
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
block/qcow2.c | 6 +++++-
|
||||
1 file changed, 5 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/block/qcow2.c b/block/qcow2.c
|
||||
index 039bdc2f7e799f935f5364daed5c..865839682cd639d1b7aba0cc328f 100644
|
||||
--- a/block/qcow2.c
|
||||
+++ b/block/qcow2.c
|
||||
@@ -826,7 +826,11 @@ static void read_cache_sizes(BlockDriverState *bs, QemuOpts *opts,
|
||||
bool l2_cache_entry_size_set;
|
||||
int min_refcount_cache = MIN_REFCOUNT_CACHE_SIZE * s->cluster_size;
|
||||
uint64_t virtual_disk_size = bs->total_sectors * BDRV_SECTOR_SIZE;
|
||||
- uint64_t max_l2_cache = virtual_disk_size / (s->cluster_size / 8);
|
||||
+ uint64_t max_l2_entries = DIV_ROUND_UP(virtual_disk_size, s->cluster_size);
|
||||
+ /* An L2 table is always one cluster in size so the max cache size
|
||||
+ * should be a multiple of the cluster size. */
|
||||
+ uint64_t max_l2_cache = ROUND_UP(max_l2_entries * sizeof(uint64_t),
|
||||
+ s->cluster_size);
|
||||
|
||||
combined_cache_size_set = qemu_opt_get(opts, QCOW2_OPT_CACHE_SIZE);
|
||||
l2_cache_size_set = qemu_opt_get(opts, QCOW2_OPT_L2_CACHE_SIZE);
|
@ -1,3 +0,0 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:13a93dfe75b86734326f8d5b475fde82ec692d5b5a338b4262aeeb6b0fa4e469
|
||||
size 55628624
|
Binary file not shown.
3
qemu-4.1.0.tar.xz
Normal file
3
qemu-4.1.0.tar.xz
Normal file
@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:656e60218689bdeec69903087fd7582d5d3e72238d02f4481d8dc6d79fd909c6
|
||||
size 54001708
|
BIN
qemu-4.1.0.tar.xz.sig
Normal file
BIN
qemu-4.1.0.tar.xz.sig
Normal file
Binary file not shown.
@ -13,7 +13,7 @@ Signed-off-by: Andreas Färber <afaerber@suse.de>
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/scripts/qemu-binfmt-conf.sh b/scripts/qemu-binfmt-conf.sh
|
||||
index b5a16742a1..4f1358e2fd 100755
|
||||
index b5a16742a149c0d2e08c6a34d08e..4f1358e2fd8c0da34cf06a763ca8 100755
|
||||
--- a/scripts/qemu-binfmt-conf.sh
|
||||
+++ b/scripts/qemu-binfmt-conf.sh
|
||||
@@ -319,7 +319,7 @@ BINFMT_SET=qemu_register_interpreter
|
@ -12,7 +12,7 @@ Signed-off-by: Andreas Färber <afaerber@suse.de>
|
||||
1 file changed, 3 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/scripts/qemu-binfmt-conf.sh b/scripts/qemu-binfmt-conf.sh
|
||||
index 4f1358e2fd..13add7775e 100755
|
||||
index 4f1358e2fd8c0da34cf06a763ca8..13add7775eb7d24c52735b02cd51 100755
|
||||
--- a/scripts/qemu-binfmt-conf.sh
|
||||
+++ b/scripts/qemu-binfmt-conf.sh
|
||||
@@ -262,7 +262,7 @@ qemu_generate_register() {
|
@ -5,11 +5,12 @@ MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
References: boo#988279
|
||||
|
||||
Change from using glib alloc and free routines to those
|
||||
from libc. Also perform safety measure of dropping privs
|
||||
to user if configured no-caps.
|
||||
|
||||
[BR: BOO#988279]
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
[AF: Rebased for v2.7.0-rc2]
|
||||
Signed-off-by: Andreas Färber <afaerber@suse.de>
|
||||
@ -18,11 +19,11 @@ Signed-off-by: Andreas Färber <afaerber@suse.de>
|
||||
1 file changed, 25 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/qemu-bridge-helper.c b/qemu-bridge-helper.c
|
||||
index 5396fbfbb6..cafe2bf27b 100644
|
||||
index 3d50ec094c794b9c0835628f10c5..f2291b398f8e4589f649af226dba 100644
|
||||
--- a/qemu-bridge-helper.c
|
||||
+++ b/qemu-bridge-helper.c
|
||||
@@ -110,7 +110,12 @@ static int parse_acl_file(const char *filename, ACLList *acl_list)
|
||||
*argend = 0;
|
||||
@@ -123,7 +123,12 @@ static int parse_acl_file(const char *filename, ACLList *acl_list)
|
||||
}
|
||||
|
||||
if (strcmp(cmd, "deny") == 0) {
|
||||
- acl_rule = g_malloc(sizeof(*acl_rule));
|
||||
@ -35,7 +36,7 @@ index 5396fbfbb6..cafe2bf27b 100644
|
||||
if (strcmp(arg, "all") == 0) {
|
||||
acl_rule->type = ACL_DENY_ALL;
|
||||
} else {
|
||||
@@ -119,7 +124,12 @@ static int parse_acl_file(const char *filename, ACLList *acl_list)
|
||||
@@ -132,7 +137,12 @@ static int parse_acl_file(const char *filename, ACLList *acl_list)
|
||||
}
|
||||
QSIMPLEQ_INSERT_TAIL(acl_list, acl_rule, entry);
|
||||
} else if (strcmp(cmd, "allow") == 0) {
|
||||
@ -49,7 +50,7 @@ index 5396fbfbb6..cafe2bf27b 100644
|
||||
if (strcmp(arg, "all") == 0) {
|
||||
acl_rule->type = ACL_ALLOW_ALL;
|
||||
} else {
|
||||
@@ -413,6 +423,18 @@ int main(int argc, char **argv)
|
||||
@@ -433,6 +443,18 @@ int main(int argc, char **argv)
|
||||
goto cleanup;
|
||||
}
|
||||
|
||||
@ -68,7 +69,7 @@ index 5396fbfbb6..cafe2bf27b 100644
|
||||
/* write fd to the domain socket */
|
||||
if (send_fd(unixfd, fd) == -1) {
|
||||
fprintf(stderr, "failed to write fd to unix socket: %s\n",
|
||||
@@ -434,7 +456,7 @@ cleanup:
|
||||
@@ -454,7 +476,7 @@ cleanup:
|
||||
}
|
||||
while ((acl_rule = QSIMPLEQ_FIRST(&acl_list)) != NULL) {
|
||||
QSIMPLEQ_REMOVE_HEAD(&acl_list, entry);
|
@ -11,10 +11,10 @@ Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
1 file changed, 3 insertions(+)
|
||||
|
||||
diff --git a/linux-user/syscall.c b/linux-user/syscall.c
|
||||
index 96cd4bf86d..cb0019b3df 100644
|
||||
index 8367cb138dfe075e06ca455009cc..17914fadfc9f3390d4b8ab8d74a6 100644
|
||||
--- a/linux-user/syscall.c
|
||||
+++ b/linux-user/syscall.c
|
||||
@@ -8173,6 +8173,9 @@ static abi_long do_syscall1(void *cpu_env, int num, abi_long arg1,
|
||||
@@ -8446,6 +8446,9 @@ static abi_long do_syscall1(void *cpu_env, int num, abi_long arg1,
|
||||
case TARGET_NR_gettimeofday:
|
||||
{
|
||||
struct timeval tv;
|
@ -13,10 +13,10 @@ Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
1 file changed, 13 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/linux-user/syscall.c b/linux-user/syscall.c
|
||||
index cb0019b3df..4d4112adf9 100644
|
||||
index 17914fadfc9f3390d4b8ab8d74a6..25fd641816c0a54e49a167f5e818 100644
|
||||
--- a/linux-user/syscall.c
|
||||
+++ b/linux-user/syscall.c
|
||||
@@ -4824,7 +4824,19 @@ static abi_long do_ioctl(int fd, int cmd, abi_long arg)
|
||||
@@ -5043,7 +5043,19 @@ static abi_long do_ioctl(int fd, int cmd, abi_long arg)
|
||||
ie = ioctl_entries;
|
||||
for(;;) {
|
||||
if (ie->target_cmd == 0) {
|
@ -16,10 +16,10 @@ Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
1 file changed, 8 insertions(+)
|
||||
|
||||
diff --git a/linux-user/syscall.c b/linux-user/syscall.c
|
||||
index 4d4112adf9..958f94ab2a 100644
|
||||
index 25fd641816c0a54e49a167f5e818..cf5de07a09235e6d92735332dc7f 100644
|
||||
--- a/linux-user/syscall.c
|
||||
+++ b/linux-user/syscall.c
|
||||
@@ -4865,6 +4865,13 @@ static abi_long do_ioctl(int fd, int cmd, abi_long arg)
|
||||
@@ -5084,6 +5084,13 @@ static abi_long do_ioctl(int fd, int cmd, abi_long arg)
|
||||
arg_type++;
|
||||
target_size = thunk_type_size(arg_type, 0);
|
||||
switch(ie->access) {
|
||||
@ -33,7 +33,7 @@ index 4d4112adf9..958f94ab2a 100644
|
||||
case IOC_R:
|
||||
ret = get_errno(safe_ioctl(fd, ie->host_cmd, buf_temp));
|
||||
if (!is_error(ret)) {
|
||||
@@ -4883,6 +4890,7 @@ static abi_long do_ioctl(int fd, int cmd, abi_long arg)
|
||||
@@ -5102,6 +5109,7 @@ static abi_long do_ioctl(int fd, int cmd, abi_long arg)
|
||||
unlock_user(argptr, arg, 0);
|
||||
ret = get_errno(safe_ioctl(fd, ie->host_cmd, buf_temp));
|
||||
break;
|
File diff suppressed because it is too large
Load Diff
@ -1,369 +0,0 @@
|
||||
#
|
||||
# spec file for package qemu-linux-user
|
||||
#
|
||||
# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
|
||||
#
|
||||
# All modifications and additions to the file contributed by third parties
|
||||
# remain the property of their copyright owners, unless otherwise agreed
|
||||
# upon. The license for this file, and modifications and additions to the
|
||||
# file, is the same license as for the pristine package itself (unless the
|
||||
# license for the pristine package is not an Open Source License, in which
|
||||
# case the license is the MIT License). An "Open Source License" is a
|
||||
# license that conforms to the Open Source Definition (Version 1.9)
|
||||
# published by the Open Source Initiative.
|
||||
|
||||
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
||||
#
|
||||
|
||||
|
||||
%define build_in_tree 1
|
||||
|
||||
%define srcname qemu
|
||||
Name: qemu-linux-user
|
||||
Url: https://www.qemu.org/
|
||||
Summary: CPU emulator for user space
|
||||
License: BSD-2-Clause AND BSD-3-Clause AND GPL-2.0-only AND GPL-2.0-or-later AND LGPL-2.1-or-later AND MIT
|
||||
Group: System/Emulators/PC
|
||||
%define qemuver 4.0.0
|
||||
%define srcver 4.0.0
|
||||
Version: %qemuver
|
||||
Release: 0
|
||||
Source: https://wiki.qemu.org/download/%{srcname}-%{srcver}.tar.xz
|
||||
Source99: https://wiki.qemu.org/download/%{srcname}-%{srcver}.tar.xz.sig
|
||||
Source100: %{srcname}.keyring
|
||||
Source400: update_git.sh
|
||||
# Upstream First -- https://wiki.qemu.org/Contribute/SubmitAPatch
|
||||
# This patch queue is auto-generated from https://github.com/openSUSE/qemu
|
||||
Patch0001: 0001-XXX-dont-dump-core-on-sigabort.patch
|
||||
Patch0002: 0002-qemu-binfmt-conf-Modify-default-pat.patch
|
||||
Patch0003: 0003-qemu-cvs-gettimeofday.patch
|
||||
Patch0004: 0004-qemu-cvs-ioctl_debug.patch
|
||||
Patch0005: 0005-qemu-cvs-ioctl_nodirection.patch
|
||||
Patch0006: 0006-linux-user-add-binfmt-wrapper-for-a.patch
|
||||
Patch0007: 0007-PPC-KVM-Disable-mmu-notifier-check.patch
|
||||
Patch0008: 0008-linux-user-binfmt-support-host-bina.patch
|
||||
Patch0009: 0009-linux-user-Fake-proc-cpuinfo.patch
|
||||
Patch0010: 0010-linux-user-use-target_ulong.patch
|
||||
Patch0011: 0011-Make-char-muxer-more-robust-wrt-sma.patch
|
||||
Patch0012: 0012-linux-user-lseek-explicitly-cast-no.patch
|
||||
Patch0013: 0013-AIO-Reduce-number-of-threads-for-32.patch
|
||||
Patch0014: 0014-xen_disk-Add-suse-specific-flush-di.patch
|
||||
Patch0015: 0015-qemu-bridge-helper-reduce-security-.patch
|
||||
Patch0016: 0016-qemu-binfmt-conf-use-qemu-ARCH-binf.patch
|
||||
Patch0017: 0017-linux-user-properly-test-for-infini.patch
|
||||
Patch0018: 0018-roms-Makefile-pass-a-packaging-time.patch
|
||||
Patch0019: 0019-Raise-soft-address-space-limit-to-h.patch
|
||||
Patch0020: 0020-increase-x86_64-physical-bits-to-42.patch
|
||||
Patch0021: 0021-vga-Raise-VRAM-to-16-MiB-for-pc-0.1.patch
|
||||
Patch0022: 0022-i8254-Fix-migration-from-SLE11-SP2.patch
|
||||
Patch0023: 0023-acpi_piix4-Fix-migration-from-SLE11.patch
|
||||
Patch0024: 0024-Switch-order-of-libraries-for-mpath.patch
|
||||
Patch0025: 0025-Make-installed-scripts-explicitly-p.patch
|
||||
Patch0026: 0026-hw-smbios-handle-both-file-formats-.patch
|
||||
Patch0027: 0027-tests-test-thread-pool-is-racy-add-.patch
|
||||
Patch0028: 0028-xen-add-block-resize-support-for-xe.patch
|
||||
Patch0029: 0029-tests-qemu-iotests-Triple-timeout-o.patch
|
||||
Patch0030: 0030-tests-block-io-test-130-needs-some-.patch
|
||||
Patch0031: 0031-xen-ignore-live-parameter-from-xen-.patch
|
||||
Patch0032: 0032-tests-Fix-Makefile-handling-of-chec.patch
|
||||
Patch0033: 0033-Conditionalize-ui-bitmap-installati.patch
|
||||
Patch0034: 0034-Revert-target-i386-kvm-add-VMX-migr.patch
|
||||
Patch0035: 0035-tests-change-error-message-in-test-.patch
|
||||
Patch0036: 0036-sockets-avoid-string-truncation-war.patch
|
||||
Patch0037: 0037-hw-usb-hcd-xhci-Fix-GCC-9-build-war.patch
|
||||
Patch0038: 0038-hw-usb-dev-mtp-Fix-GCC-9-build-warn.patch
|
||||
Patch0039: 0039-linux-user-avoid-string-truncation-.patch
|
||||
Patch0040: 0040-linux-user-elfload-Fix-GCC-9-build-.patch
|
||||
Patch0041: 0041-qxl-avoid-unaligned-pointer-reads-w.patch
|
||||
Patch0042: 0042-libvhost-user-fix-Waddress-of-packe.patch
|
||||
Patch0043: 0043-target-i386-define-md-clear-bit.patch
|
||||
Patch0044: 0044-hw-intc-exynos4210_gic-provide-more.patch
|
||||
Patch0045: 0045-kbd-state-fix-autorepeat-handling.patch
|
||||
Patch0046: 0046-target-ppc-ensure-we-get-null-termi.patch
|
||||
Patch0047: 0047-configure-only-populate-roms-if-sof.patch
|
||||
Patch0048: 0048-pc-bios-s390-ccw-net-avoid-warning-.patch
|
||||
Patch0049: 0049-qxl-check-release-info-object.patch
|
||||
Patch0050: 0050-qemu-bridge-helper-restrict-interfa.patch
|
||||
Patch0051: 0051-linux-user-fix-to-handle-variably-s.patch
|
||||
# Please do not add QEMU patches manually here.
|
||||
# Run update_git.sh to regenerate this queue.
|
||||
ExcludeArch: s390
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||
BuildRequires: e2fsprogs-devel
|
||||
BuildRequires: fdupes
|
||||
BuildRequires: gcc-c++
|
||||
BuildRequires: glib2-devel-static
|
||||
BuildRequires: glibc-devel-static
|
||||
BuildRequires: makeinfo
|
||||
BuildRequires: pcre-devel-static
|
||||
%if 0%{?suse_version} > 1320
|
||||
BuildRequires: python3-base
|
||||
%else
|
||||
BuildRequires: python-base
|
||||
%endif
|
||||
BuildRequires: zlib-devel-static
|
||||
# we must not install the qemu-linux-user package when under QEMU build
|
||||
%if 0%{?qemu_user_space_build:1}
|
||||
#!BuildIgnore: post-build-checks
|
||||
%endif
|
||||
|
||||
%description
|
||||
QEMU provides CPU emulation along with other related capabilities. This package
|
||||
provides programs to run user space binaries and libraries meant for another
|
||||
architecture. The syscall interface is intercepted and execution below the
|
||||
syscall layer occurs on the native hardware and operating system.
|
||||
|
||||
%prep
|
||||
%setup -q -n %{srcname}-%{expand:%%(SV=%{srcver};echo ${SV%%%%+git*})}
|
||||
%patch0001 -p1
|
||||
%patch0002 -p1
|
||||
%patch0003 -p1
|
||||
%patch0004 -p1
|
||||
%patch0005 -p1
|
||||
%patch0006 -p1
|
||||
%patch0007 -p1
|
||||
%patch0008 -p1
|
||||
%patch0009 -p1
|
||||
%patch0010 -p1
|
||||
%patch0011 -p1
|
||||
%patch0012 -p1
|
||||
%patch0013 -p1
|
||||
%patch0014 -p1
|
||||
%patch0015 -p1
|
||||
%patch0016 -p1
|
||||
%patch0017 -p1
|
||||
%patch0018 -p1
|
||||
%patch0019 -p1
|
||||
%patch0020 -p1
|
||||
%patch0021 -p1
|
||||
%patch0022 -p1
|
||||
%patch0023 -p1
|
||||
%patch0024 -p1
|
||||
%patch0025 -p1
|
||||
%patch0026 -p1
|
||||
%patch0027 -p1
|
||||
%patch0028 -p1
|
||||
%patch0029 -p1
|
||||
%patch0030 -p1
|
||||
%patch0031 -p1
|
||||
%patch0032 -p1
|
||||
%patch0033 -p1
|
||||
%patch0034 -p1
|
||||
%patch0035 -p1
|
||||
%patch0036 -p1
|
||||
%patch0037 -p1
|
||||
%patch0038 -p1
|
||||
%patch0039 -p1
|
||||
%patch0040 -p1
|
||||
%patch0041 -p1
|
||||
%patch0042 -p1
|
||||
%patch0043 -p1
|
||||
%patch0044 -p1
|
||||
%patch0045 -p1
|
||||
%patch0046 -p1
|
||||
%patch0047 -p1
|
||||
%patch0048 -p1
|
||||
%patch0049 -p1
|
||||
%patch0050 -p1
|
||||
%patch0051 -p1
|
||||
|
||||
%build
|
||||
%define _lto_cflags %{nil}
|
||||
|
||||
%if %build_in_tree
|
||||
%define mybuilddir %{_builddir}/%buildsubdir
|
||||
%else
|
||||
%define mybuilddir %{_builddir}/mybuilddir
|
||||
mkdir -p %mybuilddir
|
||||
cd %mybuilddir
|
||||
%endif
|
||||
|
||||
%{_builddir}/%buildsubdir/configure \
|
||||
--prefix=%_prefix \
|
||||
--sysconfdir=%_sysconfdir \
|
||||
--libdir=%_libdir \
|
||||
--libexecdir=%_libexecdir \
|
||||
--localstatedir=%_localstatedir \
|
||||
%if 0%{?suse_version} > 1320
|
||||
--python=%_bindir/python3 \
|
||||
%else
|
||||
--python=%_bindir/python2 \
|
||||
%endif
|
||||
--extra-cflags="%{optflags}" \
|
||||
--disable-stack-protector \
|
||||
--disable-strip \
|
||||
--without-default-devices \
|
||||
--disable-system --enable-linux-user \
|
||||
--disable-tools --disable-guest-agent \
|
||||
--static \
|
||||
--disable-modules \
|
||||
--disable-pie \
|
||||
--disable-docs \
|
||||
--audio-drv-list="" \
|
||||
--enable-attr \
|
||||
--disable-auth-pam \
|
||||
--disable-blobs \
|
||||
--disable-bluez \
|
||||
--disable-bochs \
|
||||
--disable-brlapi \
|
||||
--disable-bzip2 \
|
||||
--disable-cap-ng \
|
||||
--disable-capstone \
|
||||
--disable-cloop \
|
||||
--enable-coroutine-pool \
|
||||
--disable-curl \
|
||||
--disable-curses \
|
||||
--disable-dmg \
|
||||
--disable-fdt \
|
||||
--disable-gcrypt \
|
||||
--disable-glusterfs \
|
||||
--disable-gnutls \
|
||||
--disable-gtk \
|
||||
--disable-hax \
|
||||
--disable-hvf \
|
||||
--disable-iconv \
|
||||
--disable-jemalloc \
|
||||
--disable-kvm \
|
||||
--disable-libiscsi \
|
||||
--disable-libnfs \
|
||||
--disable-libpmem \
|
||||
--disable-libssh2 \
|
||||
--disable-libusb \
|
||||
--disable-libxml2 \
|
||||
--disable-linux-aio \
|
||||
--disable-lzfse \
|
||||
--disable-lzo \
|
||||
--disable-malloc-trim \
|
||||
--enable-membarrier \
|
||||
--disable-mpath \
|
||||
--disable-netmap \
|
||||
--disable-nettle \
|
||||
--disable-numa \
|
||||
--disable-opengl \
|
||||
--disable-parallels \
|
||||
--disable-pvrdma \
|
||||
--disable-qcow1 \
|
||||
--disable-qed \
|
||||
--disable-rbd \
|
||||
--disable-rdma \
|
||||
--disable-replication \
|
||||
--disable-sanitizers \
|
||||
--disable-sdl \
|
||||
--disable-sdl-image \
|
||||
--disable-seccomp \
|
||||
--disable-sheepdog \
|
||||
--disable-slirp \
|
||||
--disable-smartcard \
|
||||
--disable-snappy \
|
||||
--disable-spice \
|
||||
--disable-tcmalloc \
|
||||
--disable-tpm \
|
||||
--disable-usb-redir \
|
||||
--disable-vde \
|
||||
--disable-vdi \
|
||||
--disable-vhost-crypto \
|
||||
--disable-vhost-kernel \
|
||||
--disable-vhost-net \
|
||||
--disable-vhost-scsi \
|
||||
--disable-vhost-user \
|
||||
--disable-vhost-vsock \
|
||||
--disable-virglrenderer \
|
||||
--disable-virtfs \
|
||||
--disable-vnc \
|
||||
--disable-vnc-jpeg \
|
||||
--disable-vnc-png \
|
||||
--disable-vnc-sasl \
|
||||
--disable-vte \
|
||||
--disable-vvfat \
|
||||
--enable-werror \
|
||||
--disable-whpx \
|
||||
--disable-xen \
|
||||
--disable-xen-pci-passthrough \
|
||||
--disable-xfsctl \
|
||||
|
||||
make %{?_smp_mflags} V=1
|
||||
|
||||
%ifarch %ix86
|
||||
%define qemu_arch i386
|
||||
%endif
|
||||
%ifarch x86_64
|
||||
%define qemu_arch x86_64
|
||||
%endif
|
||||
%ifarch %arm
|
||||
%define qemu_arch arm
|
||||
%endif
|
||||
%ifarch aarch64
|
||||
%define qemu_arch aarch64
|
||||
%endif
|
||||
%ifarch ppc
|
||||
%define qemu_arch ppc
|
||||
%endif
|
||||
%ifarch ppc64
|
||||
%define qemu_arch ppc64
|
||||
%endif
|
||||
%ifarch ppc64le
|
||||
%define qemu_arch ppc64le
|
||||
%endif
|
||||
%ifarch s390x
|
||||
%define qemu_arch s390x
|
||||
%endif
|
||||
|
||||
%ifarch %ix86 x86_64 %arm aarch64 ppc ppc64 ppc64le s390x
|
||||
%check
|
||||
cd %mybuilddir
|
||||
%{qemu_arch}-linux-user/qemu-%{qemu_arch} %_bindir/ls > /dev/null
|
||||
make %{?_smp_mflags} check-softfloat
|
||||
%endif
|
||||
|
||||
%install
|
||||
cd %mybuilddir
|
||||
make %{?_smp_mflags} install DESTDIR=%{buildroot}
|
||||
rm -rf %{buildroot}%_datadir/qemu/keymaps
|
||||
unlink %{buildroot}%_datadir/qemu/trace-events-all
|
||||
install -d -m 755 %{buildroot}%_sbindir
|
||||
install -m 755 scripts/qemu-binfmt-conf.sh %{buildroot}%_sbindir
|
||||
%fdupes -s %{buildroot}
|
||||
|
||||
%files
|
||||
%defattr(-, root, root)
|
||||
%doc Changelog README VERSION
|
||||
%license COPYING COPYING.LIB LICENSE
|
||||
%_bindir/qemu-aarch64
|
||||
%_bindir/qemu-aarch64_be
|
||||
%_bindir/qemu-alpha
|
||||
%_bindir/qemu-arm
|
||||
%_bindir/qemu-armeb
|
||||
%_bindir/qemu-cris
|
||||
%_bindir/qemu-hppa
|
||||
%_bindir/qemu-i386
|
||||
%_bindir/qemu-m68k
|
||||
%_bindir/qemu-microblaze
|
||||
%_bindir/qemu-microblazeel
|
||||
%_bindir/qemu-mips
|
||||
%_bindir/qemu-mipsel
|
||||
%_bindir/qemu-mipsn32
|
||||
%_bindir/qemu-mipsn32el
|
||||
%_bindir/qemu-mips64
|
||||
%_bindir/qemu-mips64el
|
||||
%_bindir/qemu-nios2
|
||||
%_bindir/qemu-or1k
|
||||
%_bindir/qemu-ppc64abi32
|
||||
%_bindir/qemu-ppc64
|
||||
%_bindir/qemu-ppc64le
|
||||
%_bindir/qemu-ppc
|
||||
%_bindir/qemu-riscv32
|
||||
%_bindir/qemu-riscv64
|
||||
%_bindir/qemu-s390x
|
||||
%_bindir/qemu-sh4
|
||||
%_bindir/qemu-sh4eb
|
||||
%_bindir/qemu-sparc32plus
|
||||
%_bindir/qemu-sparc64
|
||||
%_bindir/qemu-sparc
|
||||
%_bindir/qemu-tilegx
|
||||
%_bindir/qemu-x86_64
|
||||
%_bindir/qemu-xtensa
|
||||
%_bindir/qemu-xtensaeb
|
||||
%_bindir/qemu-*-binfmt
|
||||
%_sbindir/qemu-binfmt-conf.sh
|
||||
|
||||
%changelog
|
@ -1,266 +0,0 @@
|
||||
#
|
||||
# spec file for package qemu-linux-user
|
||||
#
|
||||
# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
|
||||
#
|
||||
# All modifications and additions to the file contributed by third parties
|
||||
# remain the property of their copyright owners, unless otherwise agreed
|
||||
# upon. The license for this file, and modifications and additions to the
|
||||
# file, is the same license as for the pristine package itself (unless the
|
||||
# license for the pristine package is not an Open Source License, in which
|
||||
# case the license is the MIT License). An "Open Source License" is a
|
||||
# license that conforms to the Open Source Definition (Version 1.9)
|
||||
# published by the Open Source Initiative.
|
||||
|
||||
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
||||
#
|
||||
|
||||
|
||||
%define build_in_tree 1
|
||||
|
||||
%define srcname qemu
|
||||
Name: qemu-linux-user
|
||||
Url: https://www.qemu.org/
|
||||
Summary: CPU emulator for user space
|
||||
License: BSD-2-Clause AND BSD-3-Clause AND GPL-2.0-only AND GPL-2.0-or-later AND LGPL-2.1-or-later AND MIT
|
||||
Group: System/Emulators/PC
|
||||
QEMU_VERSION
|
||||
Release: 0
|
||||
Source: https://wiki.qemu.org/download/%{srcname}-%{srcver}.tar.xz
|
||||
Source100: %{srcname}.keyring
|
||||
Source400: update_git.sh
|
||||
# Upstream First -- https://wiki.qemu.org/Contribute/SubmitAPatch
|
||||
# This patch queue is auto-generated from https://github.com/openSUSE/qemu
|
||||
PATCH_FILES
|
||||
# Please do not add QEMU patches manually here.
|
||||
# Run update_git.sh to regenerate this queue.
|
||||
ExcludeArch: s390
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||
BuildRequires: e2fsprogs-devel
|
||||
BuildRequires: fdupes
|
||||
BuildRequires: gcc-c++
|
||||
BuildRequires: glib2-devel-static
|
||||
BuildRequires: glibc-devel-static
|
||||
BuildRequires: makeinfo
|
||||
BuildRequires: pcre-devel-static
|
||||
%if 0%{?suse_version} > 1320
|
||||
BuildRequires: python3-base
|
||||
%else
|
||||
BuildRequires: python-base
|
||||
%endif
|
||||
BuildRequires: zlib-devel-static
|
||||
# we must not install the qemu-linux-user package when under QEMU build
|
||||
%if 0%{?qemu_user_space_build:1}
|
||||
#!BuildIgnore: post-build-checks
|
||||
%endif
|
||||
|
||||
%description
|
||||
QEMU provides CPU emulation along with other related capabilities. This package
|
||||
provides programs to run user space binaries and libraries meant for another
|
||||
architecture. The syscall interface is intercepted and execution below the
|
||||
syscall layer occurs on the native hardware and operating system.
|
||||
|
||||
%prep
|
||||
%setup -q -n %{srcname}-%{expand:%%(SV=%{srcver};echo ${SV%%%%+git*})}
|
||||
PATCH_EXEC
|
||||
|
||||
%build
|
||||
%define _lto_cflags %{nil}
|
||||
|
||||
%if %build_in_tree
|
||||
%define mybuilddir %{_builddir}/%buildsubdir
|
||||
%else
|
||||
%define mybuilddir %{_builddir}/mybuilddir
|
||||
mkdir -p %mybuilddir
|
||||
cd %mybuilddir
|
||||
%endif
|
||||
|
||||
%{_builddir}/%buildsubdir/configure \
|
||||
--prefix=%_prefix \
|
||||
--sysconfdir=%_sysconfdir \
|
||||
--libdir=%_libdir \
|
||||
--libexecdir=%_libexecdir \
|
||||
--localstatedir=%_localstatedir \
|
||||
%if 0%{?suse_version} > 1320
|
||||
--python=%_bindir/python3 \
|
||||
%else
|
||||
--python=%_bindir/python2 \
|
||||
%endif
|
||||
--extra-cflags="%{optflags}" \
|
||||
--disable-stack-protector \
|
||||
--disable-strip \
|
||||
--without-default-devices \
|
||||
--disable-system --enable-linux-user \
|
||||
--disable-tools --disable-guest-agent \
|
||||
--static \
|
||||
--disable-modules \
|
||||
--disable-pie \
|
||||
--disable-docs \
|
||||
--audio-drv-list="" \
|
||||
--enable-attr \
|
||||
--disable-auth-pam \
|
||||
--disable-blobs \
|
||||
--disable-bluez \
|
||||
--disable-bochs \
|
||||
--disable-brlapi \
|
||||
--disable-bzip2 \
|
||||
--disable-cap-ng \
|
||||
--disable-capstone \
|
||||
--disable-cloop \
|
||||
--enable-coroutine-pool \
|
||||
--disable-curl \
|
||||
--disable-curses \
|
||||
--disable-dmg \
|
||||
--disable-fdt \
|
||||
--disable-gcrypt \
|
||||
--disable-glusterfs \
|
||||
--disable-gnutls \
|
||||
--disable-gtk \
|
||||
--disable-hax \
|
||||
--disable-hvf \
|
||||
--disable-iconv \
|
||||
--disable-jemalloc \
|
||||
--disable-kvm \
|
||||
--disable-libiscsi \
|
||||
--disable-libnfs \
|
||||
--disable-libpmem \
|
||||
--disable-libssh2 \
|
||||
--disable-libusb \
|
||||
--disable-libxml2 \
|
||||
--disable-linux-aio \
|
||||
--disable-lzfse \
|
||||
--disable-lzo \
|
||||
--disable-malloc-trim \
|
||||
--enable-membarrier \
|
||||
--disable-mpath \
|
||||
--disable-netmap \
|
||||
--disable-nettle \
|
||||
--disable-numa \
|
||||
--disable-opengl \
|
||||
--disable-parallels \
|
||||
--disable-pvrdma \
|
||||
--disable-qcow1 \
|
||||
--disable-qed \
|
||||
--disable-rbd \
|
||||
--disable-rdma \
|
||||
--disable-replication \
|
||||
--disable-sanitizers \
|
||||
--disable-sdl \
|
||||
--disable-sdl-image \
|
||||
--disable-seccomp \
|
||||
--disable-sheepdog \
|
||||
--disable-slirp \
|
||||
--disable-smartcard \
|
||||
--disable-snappy \
|
||||
--disable-spice \
|
||||
--disable-tcmalloc \
|
||||
--disable-tpm \
|
||||
--disable-usb-redir \
|
||||
--disable-vde \
|
||||
--disable-vdi \
|
||||
--disable-vhost-crypto \
|
||||
--disable-vhost-kernel \
|
||||
--disable-vhost-net \
|
||||
--disable-vhost-scsi \
|
||||
--disable-vhost-user \
|
||||
--disable-vhost-vsock \
|
||||
--disable-virglrenderer \
|
||||
--disable-virtfs \
|
||||
--disable-vnc \
|
||||
--disable-vnc-jpeg \
|
||||
--disable-vnc-png \
|
||||
--disable-vnc-sasl \
|
||||
--disable-vte \
|
||||
--disable-vvfat \
|
||||
--enable-werror \
|
||||
--disable-whpx \
|
||||
--disable-xen \
|
||||
--disable-xen-pci-passthrough \
|
||||
--disable-xfsctl \
|
||||
|
||||
make %{?_smp_mflags} V=1
|
||||
|
||||
%ifarch %ix86
|
||||
%define qemu_arch i386
|
||||
%endif
|
||||
%ifarch x86_64
|
||||
%define qemu_arch x86_64
|
||||
%endif
|
||||
%ifarch %arm
|
||||
%define qemu_arch arm
|
||||
%endif
|
||||
%ifarch aarch64
|
||||
%define qemu_arch aarch64
|
||||
%endif
|
||||
%ifarch ppc
|
||||
%define qemu_arch ppc
|
||||
%endif
|
||||
%ifarch ppc64
|
||||
%define qemu_arch ppc64
|
||||
%endif
|
||||
%ifarch ppc64le
|
||||
%define qemu_arch ppc64le
|
||||
%endif
|
||||
%ifarch s390x
|
||||
%define qemu_arch s390x
|
||||
%endif
|
||||
|
||||
%ifarch %ix86 x86_64 %arm aarch64 ppc ppc64 ppc64le s390x
|
||||
%check
|
||||
cd %mybuilddir
|
||||
%{qemu_arch}-linux-user/qemu-%{qemu_arch} %_bindir/ls > /dev/null
|
||||
make %{?_smp_mflags} check-softfloat
|
||||
%endif
|
||||
|
||||
%install
|
||||
cd %mybuilddir
|
||||
make %{?_smp_mflags} install DESTDIR=%{buildroot}
|
||||
rm -rf %{buildroot}%_datadir/qemu/keymaps
|
||||
unlink %{buildroot}%_datadir/qemu/trace-events-all
|
||||
install -d -m 755 %{buildroot}%_sbindir
|
||||
install -m 755 scripts/qemu-binfmt-conf.sh %{buildroot}%_sbindir
|
||||
%fdupes -s %{buildroot}
|
||||
|
||||
%files
|
||||
%defattr(-, root, root)
|
||||
%doc Changelog README VERSION
|
||||
%license COPYING COPYING.LIB LICENSE
|
||||
%_bindir/qemu-aarch64
|
||||
%_bindir/qemu-aarch64_be
|
||||
%_bindir/qemu-alpha
|
||||
%_bindir/qemu-arm
|
||||
%_bindir/qemu-armeb
|
||||
%_bindir/qemu-cris
|
||||
%_bindir/qemu-hppa
|
||||
%_bindir/qemu-i386
|
||||
%_bindir/qemu-m68k
|
||||
%_bindir/qemu-microblaze
|
||||
%_bindir/qemu-microblazeel
|
||||
%_bindir/qemu-mips
|
||||
%_bindir/qemu-mipsel
|
||||
%_bindir/qemu-mipsn32
|
||||
%_bindir/qemu-mipsn32el
|
||||
%_bindir/qemu-mips64
|
||||
%_bindir/qemu-mips64el
|
||||
%_bindir/qemu-nios2
|
||||
%_bindir/qemu-or1k
|
||||
%_bindir/qemu-ppc64abi32
|
||||
%_bindir/qemu-ppc64
|
||||
%_bindir/qemu-ppc64le
|
||||
%_bindir/qemu-ppc
|
||||
%_bindir/qemu-riscv32
|
||||
%_bindir/qemu-riscv64
|
||||
%_bindir/qemu-s390x
|
||||
%_bindir/qemu-sh4
|
||||
%_bindir/qemu-sh4eb
|
||||
%_bindir/qemu-sparc32plus
|
||||
%_bindir/qemu-sparc64
|
||||
%_bindir/qemu-sparc
|
||||
%_bindir/qemu-tilegx
|
||||
%_bindir/qemu-x86_64
|
||||
%_bindir/qemu-xtensa
|
||||
%_bindir/qemu-xtensaeb
|
||||
%_bindir/qemu-*-binfmt
|
||||
%_sbindir/qemu-binfmt-conf.sh
|
||||
|
||||
%changelog
|
File diff suppressed because it is too large
Load Diff
1874
qemu-testsuite.spec
1874
qemu-testsuite.spec
File diff suppressed because it is too large
Load Diff
254
qemu.changes
254
qemu.changes
@ -1,3 +1,257 @@
|
||||
-------------------------------------------------------------------
|
||||
Wed Oct 2 15:52:16 UTC 2019 - Bruce Rogers <brogers@suse.com>
|
||||
|
||||
- Since our spec file has bashisms, include the following in the
|
||||
spec file: %define _buildshell /bin/bash
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Oct 2 13:36:46 UTC 2019 - Bruce Rogers <brogers@suse.com>
|
||||
|
||||
- Disable some block tests which randomly fail. This is in context
|
||||
of the build service build of qemu-testsuite
|
||||
tests-Disable-some-block-tests-for-now.patch
|
||||
- Patch queue updated from git://github.com/openSUSE/qemu.git opensuse-4.1
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Tue Oct 1 22:07:37 UTC 2019 - Bruce Rogers <brogers@suse.com>
|
||||
|
||||
- Add some post v4.1.0 upstream stable patches
|
||||
* Patches added:
|
||||
mirror-Keep-mirror_top_bs-drained-after-.patch
|
||||
s390x-tcg-Fix-VERIM-with-32-64-bit-eleme.patch
|
||||
target-alpha-fix-tlb_fill-trap_arg2-valu.patch
|
||||
target-arm-Free-TCG-temps-in-trans_VMOV_.patch
|
||||
target-arm-Don-t-abort-on-M-profile-exce.patch
|
||||
qcow2-Fix-the-calculation-of-the-maximum.patch
|
||||
block-file-posix-Reduce-xfsctl-use.patch
|
||||
pr-manager-Fix-invalid-g_free-crash-bug.patch
|
||||
vpc-Return-0-from-vpc_co_create-on-succe.patch
|
||||
block-nfs-tear-down-aio-before-nfs_close.patch
|
||||
block-create-Do-not-abort-if-a-block-dri.patch
|
||||
curl-Keep-pointer-to-the-CURLState-in-CU.patch
|
||||
curl-Keep-socket-until-the-end-of-curl_s.patch
|
||||
curl-Check-completion-in-curl_multi_do.patch
|
||||
curl-Pass-CURLSocket-to-curl_multi_do.patch
|
||||
curl-Report-only-ready-sockets.patch
|
||||
curl-Handle-success-in-multi_check_compl.patch
|
||||
blockjob-update-nodes-head-while-removin.patch
|
||||
memory-Provide-an-equality-function-for-.patch
|
||||
vhost-Fix-memory-region-section-comparis.patch
|
||||
hw-arm-boot.c-Set-NSACR.-CP11-CP10-for-N.patch
|
||||
s390-PCI-fix-IOMMU-region-init.patch
|
||||
hw-core-loader-Fix-possible-crash-in-rom.patch
|
||||
- Patch queue updated from git://github.com/openSUSE/qemu.git opensuse-4.1
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Sep 11 14:31:26 UTC 2019 - Bruce Rogers <brogers@suse.com>
|
||||
|
||||
- Include more tweaks to our packaging workflow scripts
|
||||
- Produce qemu-linux-user and qemu-testsuite via the build service
|
||||
multibuild capability, instead of duplicating the spec file and
|
||||
using package link in build service
|
||||
* combine qemu-linux-user spec file into main qemu spec file. Since
|
||||
this model uses a single changelog, here are some historicial
|
||||
mentions from the now unused qemu-linux-user.changes (delta from
|
||||
qemu's was quite minimal):
|
||||
- Adjust to a v5.2 linux kernel change regarding SIOCGSTAMP
|
||||
- Fix pwrite64/pread64 to return 0 over -1 for a
|
||||
zero length NULL buffer in qemu (bsc#1121600)
|
||||
* bsc#1112499
|
||||
* Since qemu-testsuite.spec and qemu-testsuite.changes were just
|
||||
copies of the main qemu version nothing needs to be done there
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Fri Sep 6 16:10:18 UTC 2019 - Bruce Rogers <brogers@suse.com>
|
||||
|
||||
- Build opensbi from source on riscv64
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Fri Sep 6 16:04:15 UTC 2019 - Bruce Rogers <brogers@suse.com>
|
||||
|
||||
- Update to v4.1.0: See http://wiki.qemu.org/ChangeLog/4.1
|
||||
Take note that ongoing feature deprecation is tracked at both
|
||||
http://wiki.qemu-project.org/Features/LegacyRemoval and in
|
||||
Appendix B of the qemu-doc.* files installed with the qemu package
|
||||
Some noteworthy changes:
|
||||
* x86: CPU models are now versioned
|
||||
* x86: CPU die topology can now be configured
|
||||
* x86: New Hygon Dhyana and Intel Snowridge CPU models
|
||||
* s390: The bios now supports IPL (boot) from ECKD DASD assigned
|
||||
to the guest via vfio-ccw
|
||||
* s390: The bios now tolerates the presence of bootmap signature
|
||||
entries written by zipl
|
||||
* PowerPC: pseries machine now supports KVM acceleration
|
||||
(kernel_irqchip=on) of the XIVE interrupt controller
|
||||
* PowerPC: pseries now supports hot-plug of PCI bridges and hot-plug
|
||||
and unplug of devices under PCI bridges
|
||||
* ARM: QEMU now supports emulating an FPU for Cortex-M CPUs, and the
|
||||
Cortex-M4 and Cortex-M33 now provide the FP
|
||||
* Python 2 support is deprecated
|
||||
* UEFI platform firmware binaries, and matching variable store
|
||||
templates are now installed
|
||||
* Now it's possible to specify memory-less NUMA node when using
|
||||
"-numa node,memdev" options
|
||||
* Possible to trigger self announcement on specific network interfaces
|
||||
* Default memory distribution between NUMA nodes is now deprecated
|
||||
* Fallback to normal RAM allocation if QEMU is not able to allocate
|
||||
from the "-mem-path" provided file/filesystem is now deprecated
|
||||
* virtio-gpu 2d/3d rendering may now be offloaded to an external
|
||||
vhost-user process, such as QEMU vhost-user-gpu
|
||||
* QEMU will automatically try to use the MAP_SYNC mmap flag for memory
|
||||
backends configured with pmem=on,share=on
|
||||
* Additional SeaVGABIOS patches added for vga-ati compatibility
|
||||
- Drop attempt at build compatibility with SLE12
|
||||
- New sub-packages: qemu-edk2, qemu-vhost-user-gpu
|
||||
- Conditionalize building of qemu-edk2 (and leave unbuilt for now)
|
||||
- Implement new packaging workflow, includes no longer numbering
|
||||
patches, and having the "current git repo" stored with the package
|
||||
in the form of git bundles
|
||||
* Patches dropped (upstream unless otherwise noted):
|
||||
0027-tests-test-thread-pool-is-racy-add-.patch
|
||||
0032-tests-Fix-Makefile-handling-of-chec.patch
|
||||
0034-Revert-target-i386-kvm-add-VMX-migr.patch
|
||||
0036-sockets-avoid-string-truncation-war.patch
|
||||
0039-linux-user-avoid-string-truncation-.patch
|
||||
0040-linux-user-elfload-Fix-GCC-9-build-.patch
|
||||
0041-qxl-avoid-unaligned-pointer-reads-w.patch
|
||||
0042-libvhost-user-fix-Waddress-of-packe.patch
|
||||
0043-target-i386-define-md-clear-bit.patch
|
||||
0045-kbd-state-fix-autorepeat-handling.patch
|
||||
0046-target-ppc-ensure-we-get-null-termi.patch
|
||||
0049-qxl-check-release-info-object.patch
|
||||
0050-qemu-bridge-helper-restrict-interfa.patch
|
||||
0051-linux-user-fix-to-handle-variably-s.patch
|
||||
ipxe-use-gcc6-for-more-compact-code.patch (no longer needed)
|
||||
(the next three are replaced by the upstream equivalent)
|
||||
ipxe-efi-Simplify-diagnostic-for-NULL-handle.patch
|
||||
ipxe-build-Disable-gcc-address-of-packed-member-warning.patch
|
||||
ipxe-efi-Avoid-string-op-warning-with-cross-gcc-7-compile.patch
|
||||
slirp-fix-heap-overflow-in-ip_reass-on-big-packet-input.patch
|
||||
* Patches renamed:
|
||||
0001-XXX-dont-dump-core-on-sigabort.patch
|
||||
-> XXX-dont-dump-core-on-sigabort.patch
|
||||
0002-qemu-binfmt-conf-Modify-default-pat.patch
|
||||
-> qemu-binfmt-conf-Modify-default-path.patch
|
||||
0003-qemu-cvs-gettimeofday.patch
|
||||
-> qemu-cvs-gettimeofday.patch
|
||||
0004-qemu-cvs-ioctl_debug.patch
|
||||
-> qemu-cvs-ioctl_debug.patch
|
||||
0005-qemu-cvs-ioctl_nodirection.patch
|
||||
-> qemu-cvs-ioctl_nodirection.patch
|
||||
0006-linux-user-add-binfmt-wrapper-for-a.patch
|
||||
-> linux-user-add-binfmt-wrapper-for-argv-0.patch
|
||||
0007-PPC-KVM-Disable-mmu-notifier-check.patch
|
||||
-> PPC-KVM-Disable-mmu-notifier-check.patch
|
||||
0008-linux-user-binfmt-support-host-bina.patch
|
||||
-> linux-user-binfmt-support-host-binaries.patch
|
||||
0009-linux-user-Fake-proc-cpuinfo.patch
|
||||
-> linux-user-Fake-proc-cpuinfo.patch
|
||||
0010-linux-user-use-target_ulong.patch
|
||||
-> linux-user-use-target_ulong.patch
|
||||
0011-Make-char-muxer-more-robust-wrt-sma.patch
|
||||
-> Make-char-muxer-more-robust-wrt-small-FI.patch
|
||||
0012-linux-user-lseek-explicitly-cast-no.patch
|
||||
-> linux-user-lseek-explicitly-cast-non-set.patch
|
||||
0013-AIO-Reduce-number-of-threads-for-32.patch
|
||||
-> AIO-Reduce-number-of-threads-for-32bit-h.patch
|
||||
0014-xen_disk-Add-suse-specific-flush-di.patch
|
||||
-> xen_disk-Add-suse-specific-flush-disable.patch
|
||||
0015-qemu-bridge-helper-reduce-security-.patch
|
||||
-> qemu-bridge-helper-reduce-security-profi.patch
|
||||
0016-qemu-binfmt-conf-use-qemu-ARCH-binf.patch
|
||||
-> qemu-binfmt-conf-use-qemu-ARCH-binfmt.patch
|
||||
0017-linux-user-properly-test-for-infini.patch
|
||||
-> linux-user-properly-test-for-infinite-ti.patch
|
||||
0018-roms-Makefile-pass-a-packaging-time.patch
|
||||
-> roms-Makefile-pass-a-packaging-timestamp.patch
|
||||
0019-Raise-soft-address-space-limit-to-h.patch
|
||||
-> Raise-soft-address-space-limit-to-hard-l.patch
|
||||
0020-increase-x86_64-physical-bits-to-42.patch
|
||||
-> increase-x86_64-physical-bits-to-42.patch
|
||||
0021-vga-Raise-VRAM-to-16-MiB-for-pc-0.1.patch
|
||||
-> vga-Raise-VRAM-to-16-MiB-for-pc-0.15-and.patch
|
||||
0022-i8254-Fix-migration-from-SLE11-SP2.patch
|
||||
-> i8254-Fix-migration-from-SLE11-SP2.patch
|
||||
0023-acpi_piix4-Fix-migration-from-SLE11.patch
|
||||
-> acpi_piix4-Fix-migration-from-SLE11-SP2.patch
|
||||
0024-Switch-order-of-libraries-for-mpath.patch
|
||||
-> Switch-order-of-libraries-for-mpath-supp.patch
|
||||
0025-Make-installed-scripts-explicitly-p.patch
|
||||
-> Make-installed-scripts-explicitly-python.patch
|
||||
0026-hw-smbios-handle-both-file-formats-.patch
|
||||
-> hw-smbios-handle-both-file-formats-regar.patch
|
||||
0028-xen-add-block-resize-support-for-xe.patch
|
||||
-> xen-add-block-resize-support-for-xen-dis.patch
|
||||
0029-tests-qemu-iotests-Triple-timeout-o.patch
|
||||
-> tests-qemu-iotests-Triple-timeout-of-i-o.patch
|
||||
0030-tests-block-io-test-130-needs-some-.patch
|
||||
-> tests-block-io-test-130-needs-some-delay.patch
|
||||
0031-xen-ignore-live-parameter-from-xen-.patch
|
||||
-> xen-ignore-live-parameter-from-xen-save-.patch
|
||||
0033-Conditionalize-ui-bitmap-installati.patch
|
||||
-> Conditionalize-ui-bitmap-installation-be.patch
|
||||
0035-tests-change-error-message-in-test-.patch
|
||||
-> tests-change-error-message-in-test-162.patch
|
||||
0037-hw-usb-hcd-xhci-Fix-GCC-9-build-war.patch
|
||||
-> hw-usb-hcd-xhci-Fix-GCC-9-build-warning.patch
|
||||
0038-hw-usb-dev-mtp-Fix-GCC-9-build-warn.patch
|
||||
-> hw-usb-dev-mtp-Fix-GCC-9-build-warning.patch
|
||||
0044-hw-intc-exynos4210_gic-provide-more.patch
|
||||
-> hw-intc-exynos4210_gic-provide-more-room.patch
|
||||
0047-configure-only-populate-roms-if-sof.patch
|
||||
-> configure-only-populate-roms-if-softmmu.patch
|
||||
0048-pc-bios-s390-ccw-net-avoid-warning-.patch
|
||||
-> pc-bios-s390-ccw-net-avoid-warning-about.patch
|
||||
keycodemapdb-make-keycode-gen-output-reproducible.patch
|
||||
-> Make-keycode-gen-output-reproducible-use.patch
|
||||
ipxe-stub-out-the-SAN-req-s-in-int13.patch
|
||||
-> stub-out-the-SAN-req-s-in-int13.patch
|
||||
sgabios-fix-cross-build.patch deleted
|
||||
-> roms-sgabios-Fix-csum8-to-be-built-by-ho.patch
|
||||
sgabios-stable-buildid.patch
|
||||
-> sgabios-Makefile-fix-issues-of-build-rep.patch
|
||||
skiboot-gcc9-compat.patch
|
||||
-> Disable-Waddress-of-packed-member-for-GC.patch
|
||||
ipxe-stable-buildid.patch
|
||||
-> ipxe-Makefile-fix-issues-of-build-reprod.patch
|
||||
seabios-fix_cross_compilation.patch
|
||||
-> enable-cross-compilation-on-ARM.patch
|
||||
* Patches added:
|
||||
roms-change-cross-compiler-naming-to-be-.patch
|
||||
roms-Makefile.edk2-don-t-invoke-git-sinc.patch
|
||||
vga-move-modelist-from-bochsvga.c-to-new.patch
|
||||
vga-make-memcpy_high-public.patch
|
||||
vga-add-atiext-driver.patch
|
||||
vga-add-ati-bios-tables.patch
|
||||
vbe-add-edid-support.patch
|
||||
ati-add-edid-support.patch
|
||||
ati-vga-make-less-verbose.patch
|
||||
ati-vga-fix-ati_read.patch
|
||||
ati-vga-make-i2c-register-and-bits-confi.patch
|
||||
ati-vga-try-vga-ddc-first.patch
|
||||
ati-vga-add-rage128-edid-support.patch
|
||||
Fix-s-directive-argument-is-null-error.patch
|
||||
Workaround-compilation-error-with-gcc-9..patch
|
||||
Do-not-apply-WORKAROUND_CFLAGS-for-host-.patch
|
||||
hdata-vpd-fix-printing-char-0x00.patch
|
||||
|
||||
- Patch queue updated from git://github.com/openSUSE/qemu.git opensuse-4.1
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Fri Aug 9 14:04:52 UTC 2019 - Bruce Rogers <brogers@suse.com>
|
||||
|
||||
- Since we build seabios, take advantage of ability to add our own
|
||||
identifying version info by changing SEABIOS_EXTRAVERSION from
|
||||
"-prebuilt.qemu.org" to "-rebuilt.suse.com" (or
|
||||
"-rebuilt.opensuse.org for openSUSE releases)
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Aug 7 02:40:53 UTC 2019 - Liang Yan <lyan@suse.com>
|
||||
|
||||
- Security fix for heap overflow in ip_reass on big packet input
|
||||
(CVE-2019-14378, bsc#1143794)
|
||||
slirp-fix-heap-overflow-in-ip_reass-on-big-packet-input.patch
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Tue Aug 6 14:45:35 UTC 2019 - Bruce Rogers <brogers@suse.com>
|
||||
|
||||
|
895
qemu.spec.in
895
qemu.spec.in
File diff suppressed because it is too large
Load Diff
@ -3,6 +3,8 @@ Date: Sat, 19 Nov 2016 08:06:30 -0700
|
||||
Subject: roms/Makefile: pass a packaging timestamp to subpackages with date
|
||||
info
|
||||
|
||||
References: bsc#1011213
|
||||
|
||||
Certain rom subpackages build from qemu git-submodules call the date
|
||||
program to include date information in the packaged binaries. This
|
||||
causes repeated builds of the package to be different, wkere the only
|
||||
@ -12,17 +14,16 @@ prompted to update packages needlessly, we'll use the timestamp of the
|
||||
VERSION file as the packaging timestamp for all packages that build in a
|
||||
timestamp for whatever reason.
|
||||
|
||||
[BR: BSC#1011213]
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
roms/Makefile | 14 ++++++++++++--
|
||||
1 file changed, 12 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/roms/Makefile b/roms/Makefile
|
||||
index 1ff78b63bb..b4a3adccb2 100644
|
||||
index 775c963f9dd55bfa17772afb73f4..6efeb1ef7c38fb71556b762d6bf1 100644
|
||||
--- a/roms/Makefile
|
||||
+++ b/roms/Makefile
|
||||
@@ -49,6 +49,12 @@ SEABIOS_EXTRAVERSION="-prebuilt.qemu.org"
|
||||
@@ -51,6 +51,12 @@ SEABIOS_EXTRAVERSION="-prebuilt.qemu.org"
|
||||
#
|
||||
EDK2_EFIROM = edk2/BaseTools/Source/C/bin/EfiRom
|
||||
|
||||
@ -35,7 +36,7 @@ index 1ff78b63bb..b4a3adccb2 100644
|
||||
default:
|
||||
@echo "nothing is build by default"
|
||||
@echo "available build targets:"
|
||||
@@ -91,7 +97,7 @@ build-seabios-config-%: config.%
|
||||
@@ -99,7 +105,7 @@ build-seabios-config-%: config.%
|
||||
|
||||
.PHONY: sgabios skiboot
|
||||
sgabios:
|
||||
@ -44,7 +45,7 @@ index 1ff78b63bb..b4a3adccb2 100644
|
||||
cp sgabios/sgabios.bin ../pc-bios
|
||||
|
||||
|
||||
@@ -111,11 +117,13 @@ efi-rom-%: build-pxe-roms build-efi-roms $(EDK2_EFIROM)
|
||||
@@ -119,11 +125,13 @@ efi-rom-%: build-pxe-roms build-efi-roms edk2-basetools
|
||||
|
||||
build-pxe-roms:
|
||||
$(MAKE) -C ipxe/src CONFIG=qemu \
|
||||
@ -58,7 +59,7 @@ index 1ff78b63bb..b4a3adccb2 100644
|
||||
CROSS_COMPILE=$(x86_64_cross_prefix) \
|
||||
$(patsubst %,bin-i386-efi/%.efidrv,$(pxerom_targets)) \
|
||||
$(patsubst %,bin-x86_64-efi/%.efidrv,$(pxerom_targets))
|
||||
@@ -137,7 +145,9 @@ $(EDK2_EFIROM):
|
||||
@@ -145,7 +153,9 @@ edk2-basetools:
|
||||
EXTRA_LDFLAGS='$(EDK2_BASETOOLS_LDFLAGS)'
|
||||
|
||||
slof:
|
22
roms-Makefile.edk2-don-t-invoke-git-sinc.patch
Normal file
22
roms-Makefile.edk2-don-t-invoke-git-sinc.patch
Normal file
@ -0,0 +1,22 @@
|
||||
From: Bruce Rogers <brogers@suse.com>
|
||||
Date: Thu, 20 Jun 2019 18:45:36 -0600
|
||||
Subject: roms/Makefile.edk2: don't invoke git, since the tarball is complete
|
||||
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
roms/Makefile.edk2 | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/roms/Makefile.edk2 b/roms/Makefile.edk2
|
||||
index c2f2ff59d5b1d8b3fa394ed42c8d..98328b883c6578dd9591f069cd2d 100644
|
||||
--- a/roms/Makefile.edk2
|
||||
+++ b/roms/Makefile.edk2
|
||||
@@ -47,7 +47,7 @@ all: $(foreach flashdev,$(flashdevs),../pc-bios/edk2-$(flashdev).fd.bz2) \
|
||||
.INTERMEDIATE: $(foreach flashdev,$(flashdevs),../pc-bios/edk2-$(flashdev).fd)
|
||||
|
||||
submodules:
|
||||
- cd edk2 && git submodule update --init --force
|
||||
+ cd edk2
|
||||
|
||||
# See notes on the ".NOTPARALLEL" target and the "+" indicator in
|
||||
# "tests/uefi-test-tools/Makefile".
|
30
roms-change-cross-compiler-naming-to-be-.patch
Normal file
30
roms-change-cross-compiler-naming-to-be-.patch
Normal file
@ -0,0 +1,30 @@
|
||||
From: Bruce Rogers <brogers@suse.com>
|
||||
Date: Thu, 20 Jun 2019 17:58:37 -0600
|
||||
Subject: roms: change cross compiler naming to be suse specific
|
||||
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
roms/edk2-funcs.sh | 10 +++++++++-
|
||||
1 file changed, 9 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/roms/edk2-funcs.sh b/roms/edk2-funcs.sh
|
||||
index a9fae7ee891bc4cadbe1a3cb3f54..d70bed1729cf0a3ce41ab72df78e 100644
|
||||
--- a/roms/edk2-funcs.sh
|
||||
+++ b/roms/edk2-funcs.sh
|
||||
@@ -113,7 +113,15 @@ qemu_edk2_get_cross_prefix()
|
||||
# no cross-compiler needed
|
||||
:
|
||||
else
|
||||
- printf '%s-linux-gnu-\n' "$gcc_arch"
|
||||
+ if [ "$emulation_target" == arm ]; then
|
||||
+ printf '%s-suse-linux-gnueabi-\n' "$gcc_arch"
|
||||
+ else
|
||||
+ if [ "$gcc_arch" == i686 ]; then
|
||||
+ printf '%s-suse-linux-\n' "i586"
|
||||
+ else
|
||||
+ printf '%s-suse-linux-\n' "$gcc_arch"
|
||||
+ fi
|
||||
+ fi
|
||||
fi
|
||||
}
|
||||
|
22
roms-sgabios-Fix-csum8-to-be-built-by-ho.patch
Normal file
22
roms-sgabios-Fix-csum8-to-be-built-by-ho.patch
Normal file
@ -0,0 +1,22 @@
|
||||
From: Bruce Rogers <brogers@suse.com>
|
||||
Date: Thu, 27 Jun 2019 09:38:43 -0600
|
||||
Subject: roms/sgabios: Fix csum8 to be built by host compiler
|
||||
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com
|
||||
---
|
||||
Makefile | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/roms/sgabios/Makefile b/roms/sgabios/Makefile
|
||||
index d2934c9f678dadfae5201b8507e9..d7e108faf69007056ddc08c4e63c 100644
|
||||
--- a/roms/sgabios/Makefile
|
||||
+++ b/roms/sgabios/Makefile
|
||||
@@ -55,7 +55,7 @@ sgabios.elf: .depend $(OBJS) $(LDSCRIPT) csum8
|
||||
$(LD) $(LDFLAGS) $(OBJS) -o $@
|
||||
|
||||
csum8: csum8.c
|
||||
- $(CC) -Wall -O2 -o $@ $<
|
||||
+ $(HOSTCC) -Wall -O2 -o $@ $<
|
||||
|
||||
sgabios.o: buildinfo
|
||||
|
48
s390-PCI-fix-IOMMU-region-init.patch
Normal file
48
s390-PCI-fix-IOMMU-region-init.patch
Normal file
@ -0,0 +1,48 @@
|
||||
From: Matthew Rosato <mjrosato@linux.ibm.com>
|
||||
Date: Thu, 26 Sep 2019 10:10:36 -0400
|
||||
Subject: s390: PCI: fix IOMMU region init
|
||||
|
||||
Git-commit: 7df1dac5f1c85312474df9cb3a8fcae72303da62
|
||||
|
||||
The fix in dbe9cf606c shrinks the IOMMU memory region to a size
|
||||
that seems reasonable on the surface, however is actually too
|
||||
small as it is based against a 0-mapped address space. This
|
||||
causes breakage with small guests as they can overrun the IOMMU window.
|
||||
|
||||
Let's go back to the prior method of initializing iommu for now.
|
||||
|
||||
Fixes: dbe9cf606c ("s390x/pci: Set the iommu region size mpcifc request")
|
||||
Cc: qemu-stable@nongnu.org
|
||||
Reviewed-by: Pierre Morel <pmorel@linux.ibm.com>
|
||||
Reported-by: Boris Fiuczynski <fiuczy@linux.ibm.com>
|
||||
Tested-by: Boris Fiuczynski <fiuczy@linux.ibm.com>
|
||||
Reported-by: Stefan Zimmerman <stzi@linux.ibm.com>
|
||||
Signed-off-by: Matthew Rosato <mjrosato@linux.ibm.com>
|
||||
Message-Id: <1569507036-15314-1-git-send-email-mjrosato@linux.ibm.com>
|
||||
Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com>
|
||||
Signed-off-by: Bruce Rogers <brogers@suse.com>
|
||||
---
|
||||
hw/s390x/s390-pci-bus.c | 7 ++++++-
|
||||
1 file changed, 6 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/hw/s390x/s390-pci-bus.c b/hw/s390x/s390-pci-bus.c
|
||||
index 2c6e084e2c2636b55980799b5837..9a935f22b5b06a67c8fbd7b6abb6 100644
|
||||
--- a/hw/s390x/s390-pci-bus.c
|
||||
+++ b/hw/s390x/s390-pci-bus.c
|
||||
@@ -694,10 +694,15 @@ static const MemoryRegionOps s390_msi_ctrl_ops = {
|
||||
|
||||
void s390_pci_iommu_enable(S390PCIIOMMU *iommu)
|
||||
{
|
||||
+ /*
|
||||
+ * The iommu region is initialized against a 0-mapped address space,
|
||||
+ * so the smallest IOMMU region we can define runs from 0 to the end
|
||||
+ * of the PCI address space.
|
||||
+ */
|
||||
char *name = g_strdup_printf("iommu-s390-%04x", iommu->pbdev->uid);
|
||||
memory_region_init_iommu(&iommu->iommu_mr, sizeof(iommu->iommu_mr),
|
||||
TYPE_S390_IOMMU_MEMORY_REGION, OBJECT(&iommu->mr),
|
||||
- name, iommu->pal - iommu->pba + 1);
|
||||
+ name, iommu->pal + 1);
|
||||
iommu->enabled = true;
|
||||
memory_region_add_subregion(&iommu->mr, 0, MEMORY_REGION(&iommu->iommu_mr));
|
||||
g_free(name);
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user