From: Arnd Bergmann <arnd@arndb.de>
To: Johannes Berg <johannes@sipsolutions.net>
Cc: linux-wireless@vger.kernel.org, netdev@vger.kernel.org
Subject: Re: [RFC/HACK] net/compat/wext: allow sending different messages to compat tasks
Date: Mon, 22 Jun 2009 00:03:22 +0200 [thread overview]
Message-ID: <200906220003.22458.arnd@arndb.de> (raw)
In-Reply-To: <1245589835.5003.2.camel@johannes.local>
On Sunday 21 June 2009, Johannes Berg wrote:
> --- wireless-testing.orig/net/compat.c 2009-06-19 17:50:30.000000000 +0200
> +++ wireless-testing/net/compat.c 2009-06-19 17:53:13.000000000 +0200
> @@ -782,16 +782,18 @@ asmlinkage long compat_sys_socketcall(in
> ret = sys_socketpair(a0, a1, a[2], compat_ptr(a[3]));
> break;
> case SYS_SEND:
> - ret = sys_send(a0, compat_ptr(a1), a[2], a[3]);
> + ret = sys_send(a0, compat_ptr(a1), a[2], a[3] | MSG_CMSG_COMPAT);
> break;
> case SYS_SENDTO:
> - ret = sys_sendto(a0, compat_ptr(a1), a[2], a[3], compat_ptr(a[4]), a[5]);
> + ret = sys_sendto(a0, compat_ptr(a1), a[2], a[3] | MSG_CMSG_COMPAT,
> + compat_ptr(a[4]), a[5]);
> break;
> case SYS_RECV:
> - ret = sys_recv(a0, compat_ptr(a1), a[2], a[3]);
> + ret = sys_recv(a0, compat_ptr(a1), a[2], a[3] | MSG_CMSG_COMPAT);
> break;
> case SYS_RECVFROM:
> - ret = sys_recvfrom(a0, compat_ptr(a1), a[2], a[3], compat_ptr(a[4]), compat_ptr(a[5]));
> + ret = sys_recvfrom(a0, compat_ptr(a1), a[2], a[3] | MSG_CMSG_COMPAT,
> + compat_ptr(a[4]), compat_ptr(a[5]));
> break;
> case SYS_SHUTDOWN:
> ret = sys_shutdown(a0,a1);
I suppose if you do this, you also need to introduce a
compat_sys_{send,sendto,recv,recvfrom} entry point
for architectures that do not go through sys_socket but
call sys_{send,sendto,recv,recvfrom} directly. I think
this is only sparc and mips.
Arnd <><
next prev parent reply other threads:[~2009-06-21 22:03 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-06-21 13:10 [RFC/HACK] net/compat/wext: allow sending different messages to compat tasks Johannes Berg
2009-06-21 22:03 ` Arnd Bergmann [this message]
2009-06-22 5:57 ` Johannes Berg
2009-06-24 8:48 ` Johannes Berg
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=200906220003.22458.arnd@arndb.de \
--to=arnd@arndb.de \
--cc=johannes@sipsolutions.net \
--cc=linux-wireless@vger.kernel.org \
--cc=netdev@vger.kernel.org \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).