* IA-32 support patch: msgsnd/msgrcv return value off by 4
@ 2003-06-24 22:12 Arun Sharma
2003-06-30 16:30 ` Bjorn Helgaas
0 siblings, 1 reply; 2+ messages in thread
From: Arun Sharma @ 2003-06-24 22:12 UTC (permalink / raw)
To: linux-ia64
[-- Attachment #1: Type: text/plain, Size: 181 bytes --]
The return value of do_sys32_msgsnd() is off by 4. This seems to be a bug inherited from sparc64, fixed in the x86_64 tree in 2.5.
Please apply to both 2.4 and 2.5 trees.
-Arun
[-- Attachment #2: msgrcv.19.txt --]
[-- Type: text/plain, Size: 926 bytes --]
--- linux/arch/ia64/ia32/sys_ia32.c- 2003-06-23 09:30:13.000000000 +0800
+++ linux/arch/ia64/ia32/sys_ia32.c 2003-06-23 09:29:20.000000000 +0800
@@ -2262,7 +2262,7 @@
static int
do_sys32_msgsnd (int first, int second, int third, void *uptr)
{
- struct msgbuf *p = kmalloc(second + sizeof(struct msgbuf) + 4, GFP_USER);
+ struct msgbuf *p = kmalloc(second + sizeof(struct msgbuf), GFP_USER);
struct msgbuf32 *up = (struct msgbuf32 *)uptr;
mm_segment_t old_fs;
int err;
@@ -2304,12 +2304,12 @@
msgtyp = ipck.msgtyp;
}
err = -ENOMEM;
- p = kmalloc(second + sizeof(struct msgbuf) + 4, GFP_USER);
+ p = kmalloc(second + sizeof(struct msgbuf), GFP_USER);
if (!p)
goto out;
old_fs = get_fs();
set_fs(KERNEL_DS);
- err = sys_msgrcv(first, p, second + 4, msgtyp, third);
+ err = sys_msgrcv(first, p, second, msgtyp, third);
set_fs(old_fs);
if (err < 0)
goto free_then_out;
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: IA-32 support patch: msgsnd/msgrcv return value off by 4
2003-06-24 22:12 IA-32 support patch: msgsnd/msgrcv return value off by 4 Arun Sharma
@ 2003-06-30 16:30 ` Bjorn Helgaas
0 siblings, 0 replies; 2+ messages in thread
From: Bjorn Helgaas @ 2003-06-30 16:30 UTC (permalink / raw)
To: linux-ia64
On Tuesday 24 June 2003 4:12 pm, Arun Sharma wrote:
>
> The return value of do_sys32_msgsnd() is off by 4. This seems to be a bug inherited from sparc64, fixed in the x86_64 tree in 2.5.
>
> Please apply to both 2.4 and 2.5 trees.
Applied to 2.4 (and David put it in 2.5 as well).
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2003-06-30 16:30 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-06-24 22:12 IA-32 support patch: msgsnd/msgrcv return value off by 4 Arun Sharma
2003-06-30 16:30 ` Bjorn Helgaas
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox