* [PATCH] KEYS: Enable the compat keyctl wrapper on s390x
@ 2012-02-14 14:50 David Howells
2012-02-14 15:06 ` Christian Borntraeger
0 siblings, 1 reply; 4+ messages in thread
From: David Howells @ 2012-02-14 14:50 UTC (permalink / raw)
To: keyrings
Cc: linux-kernel, David Howells, dan, Carsten Otte,
Christian Borntraeger, linux-s390, stable
Enable the compat keyctl wrapper on s390x so that 32-bit s390 userspace can
call the keyctl() syscall.
There's an s390x assembly wrapper that truncates all the register values to
32-bits and this then calls compat_sys_keyctl() - but the latter only exists if
CONFIG_KEYS_COMPAT is enabled, and the s390 Kconfig doesn't enable it.
Without this patch, 32-bit calls to the keyctl() syscall are given an ENOSYS
error:
[root@devel4 ~]# keyctl show
Session Keyring
-3: key inaccessible (Function not implemented)
Signed-off-by: David Howells <dhowells@redhat.com>
Acked-by: dan@danny.cz
cc: Carsten Otte <cotte@de.ibm.com>
cc: Christian Borntraeger <borntraeger@de.ibm.com>
cc: linux-s390@vger.kernel.org
cc: stable@vger.kernel.org
---
arch/s390/Kconfig | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/arch/s390/Kconfig b/arch/s390/Kconfig
index d172758..6d99a5f 100644
--- a/arch/s390/Kconfig
+++ b/arch/s390/Kconfig
@@ -227,6 +227,9 @@ config COMPAT
config SYSVIPC_COMPAT
def_bool y if COMPAT && SYSVIPC
+config KEYS_COMPAT
+ def_bool y if COMPAT && KEYS
+
config AUDIT_ARCH
def_bool y
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] KEYS: Enable the compat keyctl wrapper on s390x
2012-02-14 14:50 [PATCH] KEYS: Enable the compat keyctl wrapper on s390x David Howells
@ 2012-02-14 15:06 ` Christian Borntraeger
2012-02-14 15:22 ` David Howells
0 siblings, 1 reply; 4+ messages in thread
From: Christian Borntraeger @ 2012-02-14 15:06 UTC (permalink / raw)
To: David Howells
Cc: keyrings, linux-kernel, dan, Carsten Otte, linux-s390, stable,
Heiko Carstens, Martin Schwidefsky
On 14/02/12 15:50, David Howells wrote:
> Enable the compat keyctl wrapper on s390x so that 32-bit s390 userspace can
> call the keyctl() syscall.
>
> There's an s390x assembly wrapper that truncates all the register values to
> 32-bits and this then calls compat_sys_keyctl() - but the latter only exists if
> CONFIG_KEYS_COMPAT is enabled, and the s390 Kconfig doesn't enable it.
>
> Without this patch, 32-bit calls to the keyctl() syscall are given an ENOSYS
> error:
>
> [root@devel4 ~]# keyctl show
> Session Keyring
> -3: key inaccessible (Function not implemented)
>
> Signed-off-by: David Howells <dhowells@redhat.com>
> Acked-by: dan@danny.cz
> cc: Carsten Otte <cotte@de.ibm.com>
> cc: Christian Borntraeger <borntraeger@de.ibm.com>
> cc: linux-s390@vger.kernel.org
> cc: stable@vger.kernel.org
Patch looks sane.
Reviewed-by: Christian Borntraeger <borntraeger@de.ibm.com>
Do you want to push this change via Martins s390 tree or via other
trees?
> ---
>
> arch/s390/Kconfig | 3 +++
> 1 files changed, 3 insertions(+), 0 deletions(-)
>
> diff --git a/arch/s390/Kconfig b/arch/s390/Kconfig
> index d172758..6d99a5f 100644
> --- a/arch/s390/Kconfig
> +++ b/arch/s390/Kconfig
> @@ -227,6 +227,9 @@ config COMPAT
> config SYSVIPC_COMPAT
> def_bool y if COMPAT && SYSVIPC
>
> +config KEYS_COMPAT
> + def_bool y if COMPAT && KEYS
> +
> config AUDIT_ARCH
> def_bool y
>
>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] KEYS: Enable the compat keyctl wrapper on s390x
2012-02-14 15:06 ` Christian Borntraeger
@ 2012-02-14 15:22 ` David Howells
2012-02-14 16:58 ` Heiko Carstens
0 siblings, 1 reply; 4+ messages in thread
From: David Howells @ 2012-02-14 15:22 UTC (permalink / raw)
To: Christian Borntraeger
Cc: dhowells, keyrings, linux-kernel, dan, Carsten Otte, linux-s390,
stable, Heiko Carstens, Martin Schwidefsky
Christian Borntraeger <borntraeger@de.ibm.com> wrote:
> Do you want to push this change via Martins s390 tree or via other
> trees?
I've no objection to it going via Martin's tree. It's really an S390 fix
rather than a keyrings/security fix.
David
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] KEYS: Enable the compat keyctl wrapper on s390x
2012-02-14 15:22 ` David Howells
@ 2012-02-14 16:58 ` Heiko Carstens
0 siblings, 0 replies; 4+ messages in thread
From: Heiko Carstens @ 2012-02-14 16:58 UTC (permalink / raw)
To: David Howells
Cc: Christian Borntraeger, keyrings, linux-kernel, dan, Carsten Otte,
linux-s390, stable, Martin Schwidefsky
On Tue, Feb 14, 2012 at 03:22:38PM +0000, David Howells wrote:
> Christian Borntraeger <borntraeger@de.ibm.com> wrote:
>
> > Do you want to push this change via Martins s390 tree or via other
> > trees?
>
> I've no objection to it going via Martin's tree. It's really an S390 fix
> rather than a keyrings/security fix.
Applied. Thanks!
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2012-02-14 16:58 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-02-14 14:50 [PATCH] KEYS: Enable the compat keyctl wrapper on s390x David Howells
2012-02-14 15:06 ` Christian Borntraeger
2012-02-14 15:22 ` David Howells
2012-02-14 16:58 ` Heiko Carstens
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox