package/qemu: Bump to version 4.2.0
PATCH 1/3 package/qemu: Bump to version 4.2.0
From: Adam Duskett <[email protected]>
Other changes:
- Remove upstream patches
- Update COPYING.LIB hash as upstream updated the file to match the new LGPL 2.1 license from upstream. See:
https://github.com/qemu/qemu/commit/f0d44cc4462f112bce5ec556e87eff4eec682e39
--- ...age-of-mcontext-structure-on-ARM-uCl.patch | 35 +++++++++++++++ ...fix-crash-when-compiling-with-uClibc.patch | 43 +++++++++++++++++++ package/qemu/qemu.hash | 4 +- package/qemu/qemu.mk | 2 +- 4 files changed, 81 insertions(+), 3 deletions(-) create mode 100644 package/qemu/4.2.0/0001-user-exec-fix-usage-of-mcontext-structure-on-ARM-uCl.patch create mode 100644 package/qemu/4.2.0/0002-util-cacheinfo-fix-crash-when-compiling-with-uClibc.patch
package/qemu/4.2.0/0001-user-exec-fix-usage-of-mcontext-structure-on-ARM-uCl.patch new file +35 -0
@@ -0,0 +1,35 @@ +From d3f1e7e9ff9aae3f770b0bcb9aa3c2f787f76a1b Mon Sep 17 00:00:00 2001 +From: Thomas Petazzoni <[email protected]> +Date: Fri, 5 May 2017 09:07:15 +0200 +Subject: [PATCH] user-exec: fix usage of mcontext structure on ARM/uClibc + +user-exec.c has some conditional code to decide how to use the +mcontext structure. Unfortunately, since uClibc defines __GLIBC__, but +with old versions of __GLIBC__ and __GLIBC_MINOR__, an old code path +gets used, which doesn't apply to uClibc. + +Fix this by excluding __UCLIBC__, which ensures we fall back to the +general case of using uc_mcontext.arm_pc, which works fine with +uClibc. + +Signed-off-by: Thomas Petazzoni <[email protected]> +--- + user-exec.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/accel/tcg/user-exec.c b/accel/tcg/user-exec.c +index 6db0758..2b3d116 100644 +--- a/accel/tcg/user-exec.c ++++ b/accel/tcg/user-exec.c +@@ -506,7 +506,7 @@ int cpu_signal_handler(int host_signum, void *pinfo, + + #if defined(__NetBSD__) + pc = uc->uc_mcontext.__gregs[_REG_R15]; +-#elif defined(__GLIBC__) && (__GLIBC__ < 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ <= 3)) ++#elif defined(__GLIBC__) && !defined(__UCLIBC__) && (__GLIBC__ < 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ <= 3)) + pc = uc->uc_mcontext.gregs[R15]; + #else + pc = uc->uc_mcontext.arm_pc; +-- +2.7.4 +
package/qemu/4.2.0/0002-util-cacheinfo-fix-crash-when-compiling-with-uClibc.patch new file +43 -0
43 lines not on this page · raw message
package/qemu/qemu.hash +2 -2
@@ -1,7 +1,7 @@ # Locally computed, tarball verified with GPG signature -sha256 b148fc3c7382c5addd915db433383160ca7b840bc6ea90bb0d35c6b253526d56 qemu-3.1.1.1.tar.xz +sha256 d3481d4108ce211a053ef15be69af1bdd9dde1510fda80d92be0f6c3e98768f0 qemu-4.2.0.tar.xz sha256 6f04ae8364d0079a192b14635f4b1da294ce18724c034c39a6a41d1b09df6100 COPYING -sha256 48ffe9fc7f1d5462dbd19340bc4dd1d8a9e37c61ed535813e614cbe4a5f0d4df COPYING.LIB +sha256 dc626520dcd53a22f727af3ee42c770e56c97a64fe3adb063799d8ab032fe551 COPYING.LIB # Locally computed sha256 61091767ffd16002e77f005155d096208094e69dee35e6d5ddcaa6c8a13b5e26 qemu-b517e1dc3125a57555d67a8deed9eac7b42288e2.tar.gz
package/qemu/qemu.mk +1 -1
@@ -8,7 +8,7 @@ ifeq ($(BR2_csky),y) QEMU_VERSION = b517e1dc3125a57555d67a8deed9eac7b42288e2 QEMU_SITE = $(call github,c-sky,qemu,$(QEMU_VERSION)) else -QEMU_VERSION = 3.1.1.1 +QEMU_VERSION = 4.2.0 QEMU_SOURCE = qemu-$(QEMU_VERSION).tar.xz QEMU_SITE = http://download.qemu.org endif
Signature · 1 line
2.21.1 (Apple Git-122.3)
PATCH 2/3 package/qemu: do not support x86_steamroller or x86_core_avx2
From: Adam Duskett <[email protected]>
These CPU's cause segfaults with qemu.
--- package/qemu/Config.in.host | 1 + 1 file changed, 1 insertion(+)
package/qemu/Config.in.host +1 -0
@@ -20,6 +20,7 @@ config BR2_PACKAGE_HOST_QEMU_ARCH_SUPPORTS default y if BR2_sparc64 default y if BR2_xtensa default y if BR2_x86_64 + depends on !BR2_x86_steamroller && !BR2_x86_core_avx2 depends on !BR2_powerpc_620 && !BR2_powerpc_630 && !BR2_powerpc_970 config BR2_PACKAGE_HOST_QEMU_SYSTEM_ARCH_SUPPORTS
Signature · 1 line
2.21.1 (Apple Git-122.3)
PATCH 3/3 package/qemu: add support for sparc64
In reply to aduskett at gmail.comFrom: Adam Duskett <[email protected]>
This prevents illegal instruction errors when running qemu.
--- package/qemu/qemu.mk | 3 +++ 1 file changed, 3 insertions(+)
package/qemu/qemu.mk +3 -0
@@ -237,6 +237,9 @@ endif ifeq ($(HOST_QEMU_ARCH),sh4aeb) HOST_QEMU_ARCH = sh4eb endif +ifeq ($(HOST_QEMU_ARCH),sparc64) +HOST_QEMU_ARCH = sparc64 +endif ifeq ($(HOST_QEMU_ARCH),csky) ifeq ($(BR2_ck610),y) HOST_QEMU_ARCH = cskyv1
Signature · 1 line
2.21.1 (Apple Git-122.3)
PATCH 1/3 package/qemu: Bump to version 4.2.0
In reply to aduskett at gmail.comHi Adam,
Quoted 4 lines · aduskett at gmail.com
From: Adam Duskett <[email protected]>
Other changes:
- Remove upstream patches
I see no patches being removed in this patch. It looks like patches in package/qemu/3.1.1.1/ should be removed.
baruch
Quoted 123 lines
- Update COPYING.LIB hash as upstream updated the file to match the new LGPL 2.1 license from upstream. See:
https://github.com/qemu/qemu/commit/f0d44cc4462f112bce5ec556e87eff4eec682e39Signed-off-by Adam Duskett <[email protected]>--- ...age-of-mcontext-structure-on-ARM-uCl.patch | 35 +++++++++++++++ ...fix-crash-when-compiling-with-uClibc.patch | 43 +++++++++++++++++++ package/qemu/qemu.hash | 4 +- package/qemu/qemu.mk | 2 +- 4 files changed, 81 insertions(+), 3 deletions(-) create mode 100644 package/qemu/4.2.0/0001-user-exec-fix-usage-of-mcontext-structure-on-ARM-uCl.patch create mode 100644 package/qemu/4.2.0/0002-util-cacheinfo-fix-crash-when-compiling-with-uClibc.patchpackage/qemu/4.2.0/0001-user-exec-fix-usage-of-mcontext-structure-on-ARM-uCl.patch new file +35
-0@@ -0,0 +1,35 @@ +From d3f1e7e9ff9aae3f770b0bcb9aa3c2f787f76a1b Mon Sep 17 00:00:00 2001 +From: Thomas Petazzoni <[email protected]> +Date: Fri, 5 May 2017 09:07:15 +0200 +Subject: [PATCH] user-exec: fix usage of mcontext structure on ARM/uClibc + +user-exec.c has some conditional code to decide how to use the +mcontext structure. Unfortunately, since uClibc defines __GLIBC__, but +with old versions of __GLIBC__ and __GLIBC_MINOR__, an old code path +gets used, which doesn't apply to uClibc. + +Fix this by excluding __UCLIBC__, which ensures we fall back to the +general case of using uc_mcontext.arm_pc, which works fine with +uClibc. + +Signed-off-by: Thomas Petazzoni <[email protected]> +--- + user-exec.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/accel/tcg/user-exec.c b/accel/tcg/user-exec.c +index 6db0758..2b3d116 100644 +--- a/accel/tcg/user-exec.c ++++ b/accel/tcg/user-exec.c +@@ -506,7 +506,7 @@ int cpu_signal_handler(int host_signum, void *pinfo, + + #if defined(__NetBSD__) + pc = uc->uc_mcontext.__gregs[_REG_R15]; +-#elif defined(__GLIBC__) && (__GLIBC__ < 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ <= 3)) ++#elif defined(__GLIBC__) && !defined(__UCLIBC__) && (__GLIBC__ < 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ <= 3)) + pc = uc->uc_mcontext.gregs[R15]; + #else + pc = uc->uc_mcontext.arm_pc; +-- +2.7.4 +package/qemu/4.2.0/0002-util-cacheinfo-fix-crash-when-compiling-with-uClibc.patch new file +43
-0@@ -0,0 +1,43 @@ +From d82b8540ecaf3cb09a033e4971d8645d3343211e Mon Sep 17 00:00:00 2001 +From: Carlos Santos <[email protected]> +Date: Wed, 16 Oct 2019 22:27:30 -0300 +Subject: [PATCH] util/cacheinfo: fix crash when compiling with uClibc + +uClibc defines _SC_LEVEL1_ICACHE_LINESIZE and _SC_LEVEL1_DCACHE_LINESIZE +but the corresponding sysconf calls returns -1, which is a valid result, +meaning that the limit is indeterminate. + +Handle this situation using the fallback values instead of crashing due +to an assertion failure. + +Signed-off-by: Carlos Santos <[email protected]> +--- + util/cacheinfo.c | 10 ++++++++-- + 1 file changed, 8 insertions(+), 2 deletions(-) + +diff --git a/util/cacheinfo.c b/util/cacheinfo.c +index ea6f3e99bf..d94dc6adc8 100644 +--- a/util/cacheinfo.c ++++ b/util/cacheinfo.c +@@ -93,10 +93,16 @@ static void sys_cache_info(int *isize, int *dsize) + static void sys_cache_info(int *isize, int *dsize) + { + # ifdef _SC_LEVEL1_ICACHE_LINESIZE +- *isize = sysconf(_SC_LEVEL1_ICACHE_LINESIZE); ++ int tmp_isize = (int) sysconf(_SC_LEVEL1_ICACHE_LINESIZE); ++ if (tmp_isize > 0) { ++ *isize = tmp_isize; ++ } + # endif + # ifdef _SC_LEVEL1_DCACHE_LINESIZE +- *dsize = sysconf(_SC_LEVEL1_DCACHE_LINESIZE); ++ int tmp_dsize = (int) sysconf(_SC_LEVEL1_DCACHE_LINESIZE); ++ if (tmp_dsize > 0) { ++ *dsize = tmp_dsize; ++ } + # endif + } + #endif /* sys_cache_info */ +-- +2.18.1 +package/qemu/qemu.hash +2
-2@@ -1,7 +1,7 @@ # Locally computed, tarball verified with GPG signature -sha256 b148fc3c7382c5addd915db433383160ca7b840bc6ea90bb0d35c6b253526d56 qemu-3.1.1.1.tar.xz +sha256 d3481d4108ce211a053ef15be69af1bdd9dde1510fda80d92be0f6c3e98768f0 qemu-4.2.0.tar.xz sha256 6f04ae8364d0079a192b14635f4b1da294ce18724c034c39a6a41d1b09df6100 COPYING -sha256 48ffe9fc7f1d5462dbd19340bc4dd1d8a9e37c61ed535813e614cbe4a5f0d4df COPYING.LIB +sha256 dc626520dcd53a22f727af3ee42c770e56c97a64fe3adb063799d8ab032fe551 COPYING.LIB # Locally computed sha256 61091767ffd16002e77f005155d096208094e69dee35e6d5ddcaa6c8a13b5e26 qemu-b517e1dc3125a57555d67a8deed9eac7b42288e2.tar.gzpackage/qemu/qemu.mk +0
-0
package/qemu/qemu.mk ifeq ($(BR2_csky),y) · line 14
Quoted 8 lines
package/qemu/qemu.mk +1
-1@@ -8,7 +8,7 @@ ifeq ($(BR2_csky),y) QEMU_VERSION = b517e1dc3125a57555d67a8deed9eac7b42288e2 QEMU_SITE = $(call github,c-sky,qemu,$(QEMU_VERSION)) else -QEMU_VERSION = 3.1.1.1 +QEMU_VERSION = 4.2.0 QEMU_SOURCE = qemu-$(QEMU_VERSION).tar.xz QEMU_SITE = http://download.qemu.org endif
--
http://baruch.siach.name/blog/ ~. .~ Tk Open Systems
=}------------------------------------------------ooO--U--Ooo------------{=
- baruch at tkos.co.il - tel: +972.52.368.4656, http://www.tkos.co.il -
PATCH 1/3 package/qemu: Bump to version 4.2.0
In reply to aduskett at gmail.comQuoted 10 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
"aduskett" == aduskett <[email protected]> writes:
From: Adam Duskett <[email protected]>
Other changes:
- Remove upstream patches
- Update COPYING.LIB hash as upstream updated the file to match the new LGPL 2.1 license from upstream. See:
https://github.com/qemu/qemu/commit/f0d44cc4462f112bce5ec556e87eff4eec682e39Signed-off-by Adam Duskett <[email protected]>
Committed after fixing the libssh2/libssh change, thanks.
Signature · 1 line
Bye, Peter Korsgaard
PATCH 1/3 package/qemu: Bump to version 4.2.0
Hi Peter, Adam, Guo,
Le 16/02/2020 ? 20:38, Peter Korsgaard a ?crit?:
Quoted 9 lines
Quoted 8 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
"aduskett" == aduskett <[email protected]> writes:
From: Adam Duskett <[email protected]>
Other changes:
- Remove upstream patches
- Update COPYING.LIB hash as upstream updated the file to match the new LGPL 2.1 license from upstream. See:
https://github.com/qemu/qemu/commit/f0d44cc4462f112bce5ec556e87eff4eec682e39
Quoted 4 lines
Quoted 1 line
Signed-off-by Adam Duskett <[email protected]>Committed after fixing the libssh2/libssh change, thanks.
I just noticed that we have a qemu fork for csky cpus [1] but since this version bump and libssh2/libssh change the build is broken.
The fork is based on Qemu 3.0.0 and I'm not sure we want to support all old options. Note the github repository has been removed [2], so the only remaining archive is located on http://sources.buildroot.net...
What do we do ? Remove the csky fork ? Nobody noticed the problem with 2020.02...
[1]
https://git.buildroot.net/buildroot/commit/?id=f816e5b276f1ef15840bec6667f1e8219717ab7d
[2] https://github.com/c-sky/qemu
Best regards,
Romain
PATCH 1/3 package/qemu: Bump to version 4.2.0
Quoted 25 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
"Romain" == Romain Naour <[email protected]> writes:
Hi Peter, Adam, Guo,
Le 16/02/2020 ? 20:38, Peter Korsgaard a ?crit?:Quoted 9 lines
Quoted 8 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
"aduskett" == aduskett <[email protected]> writes:
From: Adam Duskett <[email protected]>
Other changes:
- Remove upstream patches
- Update COPYING.LIB hash as upstream updated the file to match the new LGPL 2.1 license from upstream. See:
https://github.com/qemu/qemu/commit/f0d44cc4462f112bce5ec556e87eff4eec682e39Quoted 4 lines
Quoted 1 line
Signed-off-by Adam Duskett <[email protected]>Committed after fixing the libssh2/libssh change, thanks.
I just noticed that we have a qemu fork for csky cpus [1] but since this version bump and libssh2/libssh change the build is broken.
The fork is based on Qemu 3.0.0 and I'm not sure we want to support all old options. Note the github repository has been removed [2], so the only remaining archive is located on http://sources.buildroot.net...
Quoted 5 lines
What do we do ? Remove the csky fork ? Nobody noticed the problem with 2020.02...
[1]
https://git.buildroot.net/buildroot/commit/?id=f816e5b276f1ef15840bec6667f1e8219717ab7d
[2] https://github.com/c-sky/qemu
Yes, if it causes problems and isn't actively maintained, then I would prefer to remove it.
C-SKY people, what do you say?
Signature · 1 line
Bye, Peter Korsgaard