From: Maxim Ostapenko <m.ostapenko@partner.samsung.com>
To: Peter Maydell <peter.maydell@linaro.org>
Cc: QEMU Trivial <qemu-trivial@nongnu.org>,
Slava Garbuzov <v.garbuzov@samsung.com>,
Riku Voipio <riku.voipio@iki.fi>,
QEMU Developers <qemu-devel@nongnu.org>,
Yury Gribov <y.gribov@samsung.com>
Subject: [Qemu-trivial] [PATCH v2] Fix ABI incompatibility between Qemu-aarch64 and Linux Kernel in signal handling.
Date: Mon, 02 Feb 2015 18:18:29 +0400 [thread overview]
Message-ID: <54CF8735.3080806@partner.samsung.com> (raw)
Thanks again,
I've updated the patch. Is this correct now?
-Maxim
From 5b035df58f9f17e64b35311b6b5f55097c7f8ce1 Mon Sep 17 00:00:00 2001
From: Max Ostapenko <m.ostapenko@partner.samsung.com>
Date: Mon, 2 Feb 2015 12:03:20 +0400
Subject: [PATCH] linux-user: wrong TARGET_SI_PAD_SIZE value for some
targets.
Fix TARGET_SI_PAD_SIZE calculation to match the way the kernel does it.
Use different TARGET_SI_PREAMBLE_SIZE for 32-bit and 64-bit targets.
Signed-off-by: Maxim Ostapenko <m.ostapenko@partner.samsung.com>
---
linux-user/syscall_defs.h | 9 ++++++++-
1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/linux-user/syscall_defs.h b/linux-user/syscall_defs.h
index ebb3be1..9ed6de8 100644
--- a/linux-user/syscall_defs.h
+++ b/linux-user/syscall_defs.h
@@ -655,7 +655,14 @@ typedef struct {
#endif
#define TARGET_SI_MAX_SIZE 128
-#define TARGET_SI_PAD_SIZE ((TARGET_SI_MAX_SIZE/sizeof(int)) - 3)
+
+#if TARGET_ABI_BITS == 32
+#define TARGET_SI_PREAMBLE_SIZE (3 * sizeof(int))
+#else
+#define TARGET_SI_PREAMBLE_SIZE (4 * sizeof(int))
+#endif
+
+#define TARGET_SI_PAD_SIZE ((TARGET_SI_MAX_SIZE -
TARGET_SI_PREAMBLE_SIZE) / sizeof(int))
typedef struct target_siginfo {
#ifdef TARGET_MIPS
--
1.8.5.2.2930.gf745acb
WARNING: multiple messages have this Message-ID (diff)
From: Maxim Ostapenko <m.ostapenko@partner.samsung.com>
To: Peter Maydell <peter.maydell@linaro.org>
Cc: QEMU Trivial <qemu-trivial@nongnu.org>,
Slava Garbuzov <v.garbuzov@samsung.com>,
Riku Voipio <riku.voipio@iki.fi>,
QEMU Developers <qemu-devel@nongnu.org>,
Yury Gribov <y.gribov@samsung.com>
Subject: [Qemu-devel] [PATCH v2] Fix ABI incompatibility between Qemu-aarch64 and Linux Kernel in signal handling.
Date: Mon, 02 Feb 2015 18:18:29 +0400 [thread overview]
Message-ID: <54CF8735.3080806@partner.samsung.com> (raw)
Thanks again,
I've updated the patch. Is this correct now?
-Maxim
From 5b035df58f9f17e64b35311b6b5f55097c7f8ce1 Mon Sep 17 00:00:00 2001
From: Max Ostapenko <m.ostapenko@partner.samsung.com>
Date: Mon, 2 Feb 2015 12:03:20 +0400
Subject: [PATCH] linux-user: wrong TARGET_SI_PAD_SIZE value for some
targets.
Fix TARGET_SI_PAD_SIZE calculation to match the way the kernel does it.
Use different TARGET_SI_PREAMBLE_SIZE for 32-bit and 64-bit targets.
Signed-off-by: Maxim Ostapenko <m.ostapenko@partner.samsung.com>
---
linux-user/syscall_defs.h | 9 ++++++++-
1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/linux-user/syscall_defs.h b/linux-user/syscall_defs.h
index ebb3be1..9ed6de8 100644
--- a/linux-user/syscall_defs.h
+++ b/linux-user/syscall_defs.h
@@ -655,7 +655,14 @@ typedef struct {
#endif
#define TARGET_SI_MAX_SIZE 128
-#define TARGET_SI_PAD_SIZE ((TARGET_SI_MAX_SIZE/sizeof(int)) - 3)
+
+#if TARGET_ABI_BITS == 32
+#define TARGET_SI_PREAMBLE_SIZE (3 * sizeof(int))
+#else
+#define TARGET_SI_PREAMBLE_SIZE (4 * sizeof(int))
+#endif
+
+#define TARGET_SI_PAD_SIZE ((TARGET_SI_MAX_SIZE -
TARGET_SI_PREAMBLE_SIZE) / sizeof(int))
typedef struct target_siginfo {
#ifdef TARGET_MIPS
--
1.8.5.2.2930.gf745acb
next reply other threads:[~2015-02-02 15:19 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-02-02 14:18 Maxim Ostapenko [this message]
2015-02-02 14:18 ` [Qemu-devel] [PATCH v2] Fix ABI incompatibility between Qemu-aarch64 and Linux Kernel in signal handling Maxim Ostapenko
2015-02-02 15:23 ` [Qemu-trivial] " Peter Maydell
2015-02-02 15:23 ` [Qemu-devel] " Peter Maydell
2015-02-07 9:23 ` [Qemu-trivial] " Michael Tokarev
2015-02-07 9:23 ` [Qemu-devel] " Michael Tokarev
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=54CF8735.3080806@partner.samsung.com \
--to=m.ostapenko@partner.samsung.com \
--cc=peter.maydell@linaro.org \
--cc=qemu-devel@nongnu.org \
--cc=qemu-trivial@nongnu.org \
--cc=riku.voipio@iki.fi \
--cc=v.garbuzov@samsung.com \
--cc=y.gribov@samsung.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.