* [PATCH] KEYS: remove CONFIG_KEYS_COMPAT
@ 2017-06-13 6:09 ` Eric Biggers
0 siblings, 0 replies; 10+ messages in thread
From: Eric Biggers @ 2017-06-13 6:09 UTC (permalink / raw)
To: linux-security-module
From: Eric Biggers <ebiggers@google.com>
KEYS_COMPAT now always takes the value of COMPAT && KEYS. But the
security/keys/ directory is only compiled if KEYS is enabled, so in
practice KEYS_COMPAT is the same as COMPAT. Therefore, remove the
unnecessary KEYS_COMPAT and just use COMPAT directly.
(Also remove an outdated comment from compat.c.)
Signed-off-by: Eric Biggers <ebiggers@google.com>
---
security/keys/Kconfig | 4 ----
security/keys/Makefile | 2 +-
security/keys/compat.c | 5 -----
security/keys/internal.h | 4 ++--
4 files changed, 3 insertions(+), 12 deletions(-)
diff --git a/security/keys/Kconfig b/security/keys/Kconfig
index a7a23b5541f8..f5d96996baa6 100644
--- a/security/keys/Kconfig
+++ b/security/keys/Kconfig
@@ -20,10 +20,6 @@ config KEYS
If you are unsure as to whether this is required, answer N.
-config KEYS_COMPAT
- def_bool y
- depends on COMPAT && KEYS
-
config PERSISTENT_KEYRINGS
bool "Enable register of persistent per-UID keyrings"
depends on KEYS
diff --git a/security/keys/Makefile b/security/keys/Makefile
index 57dff0c15809..6d31eca7c602 100644
--- a/security/keys/Makefile
+++ b/security/keys/Makefile
@@ -16,7 +16,7 @@ obj-y := \
request_key_auth.o \
user_defined.o
compat-obj-$(CONFIG_KEY_DH_OPERATIONS) += compat_dh.o
-obj-$(CONFIG_KEYS_COMPAT) += compat.o $(compat-obj-y)
+obj-$(CONFIG_COMPAT) += compat.o $(compat-obj-y)
obj-$(CONFIG_PROC_FS) += proc.o
obj-$(CONFIG_SYSCTL) += sysctl.o
obj-$(CONFIG_PERSISTENT_KEYRINGS) += persistent.o
diff --git a/security/keys/compat.c b/security/keys/compat.c
index e87c89c0177c..d7445946b701 100644
--- a/security/keys/compat.c
+++ b/security/keys/compat.c
@@ -50,11 +50,6 @@ static long compat_keyctl_instantiate_key_iov(
/*
* The key control system call, 32-bit compatibility version for 64-bit archs
- *
- * This should only be called if the 64-bit arch uses weird pointers in 32-bit
- * mode or doesn't guarantee that the top 32-bits of the argument registers on
- * taking a 32-bit syscall are zero. If you can, you should call sys_keyctl()
- * directly.
*/
COMPAT_SYSCALL_DEFINE5(keyctl, u32, option,
u32, arg2, u32, arg3, u32, arg4, u32, arg5)
diff --git a/security/keys/internal.h b/security/keys/internal.h
index c0f8682eba69..0cc7333408d0 100644
--- a/security/keys/internal.h
+++ b/security/keys/internal.h
@@ -271,7 +271,7 @@ extern long keyctl_dh_compute(struct keyctl_dh_params __user *, char __user *,
size_t, struct keyctl_kdf_params __user *);
extern long __keyctl_dh_compute(struct keyctl_dh_params __user *, char __user *,
size_t, struct keyctl_kdf_params *);
-#ifdef CONFIG_KEYS_COMPAT
+#ifdef CONFIG_COMPAT
extern long compat_keyctl_dh_compute(struct keyctl_dh_params __user *params,
char __user *buffer, size_t buflen,
struct compat_keyctl_kdf_params __user *kdf);
@@ -286,7 +286,7 @@ static inline long keyctl_dh_compute(struct keyctl_dh_params __user *params,
return -EOPNOTSUPP;
}
-#ifdef CONFIG_KEYS_COMPAT
+#ifdef CONFIG_COMPAT
static inline long compat_keyctl_dh_compute(
struct keyctl_dh_params __user *params,
char __user *buffer, size_t buflen,
--
2.13.1
^ permalink raw reply related [flat|nested] 10+ messages in thread
* [PATCH] KEYS: remove CONFIG_KEYS_COMPAT
@ 2017-06-13 6:09 ` Eric Biggers
0 siblings, 0 replies; 10+ messages in thread
From: Eric Biggers @ 2017-06-13 6:09 UTC (permalink / raw)
To: linux-security-module
From: Eric Biggers <ebiggers@google.com>
KEYS_COMPAT now always takes the value of COMPAT && KEYS. But the
security/keys/ directory is only compiled if KEYS is enabled, so in
practice KEYS_COMPAT is the same as COMPAT. Therefore, remove the
unnecessary KEYS_COMPAT and just use COMPAT directly.
(Also remove an outdated comment from compat.c.)
Signed-off-by: Eric Biggers <ebiggers@google.com>
---
security/keys/Kconfig | 4 ----
security/keys/Makefile | 2 +-
security/keys/compat.c | 5 -----
security/keys/internal.h | 4 ++--
4 files changed, 3 insertions(+), 12 deletions(-)
diff --git a/security/keys/Kconfig b/security/keys/Kconfig
index a7a23b5541f8..f5d96996baa6 100644
--- a/security/keys/Kconfig
+++ b/security/keys/Kconfig
@@ -20,10 +20,6 @@ config KEYS
If you are unsure as to whether this is required, answer N.
-config KEYS_COMPAT
- def_bool y
- depends on COMPAT && KEYS
-
config PERSISTENT_KEYRINGS
bool "Enable register of persistent per-UID keyrings"
depends on KEYS
diff --git a/security/keys/Makefile b/security/keys/Makefile
index 57dff0c15809..6d31eca7c602 100644
--- a/security/keys/Makefile
+++ b/security/keys/Makefile
@@ -16,7 +16,7 @@ obj-y := \
request_key_auth.o \
user_defined.o
compat-obj-$(CONFIG_KEY_DH_OPERATIONS) += compat_dh.o
-obj-$(CONFIG_KEYS_COMPAT) += compat.o $(compat-obj-y)
+obj-$(CONFIG_COMPAT) += compat.o $(compat-obj-y)
obj-$(CONFIG_PROC_FS) += proc.o
obj-$(CONFIG_SYSCTL) += sysctl.o
obj-$(CONFIG_PERSISTENT_KEYRINGS) += persistent.o
diff --git a/security/keys/compat.c b/security/keys/compat.c
index e87c89c0177c..d7445946b701 100644
--- a/security/keys/compat.c
+++ b/security/keys/compat.c
@@ -50,11 +50,6 @@ static long compat_keyctl_instantiate_key_iov(
/*
* The key control system call, 32-bit compatibility version for 64-bit archs
- *
- * This should only be called if the 64-bit arch uses weird pointers in 32-bit
- * mode or doesn't guarantee that the top 32-bits of the argument registers on
- * taking a 32-bit syscall are zero. If you can, you should call sys_keyctl()
- * directly.
*/
COMPAT_SYSCALL_DEFINE5(keyctl, u32, option,
u32, arg2, u32, arg3, u32, arg4, u32, arg5)
diff --git a/security/keys/internal.h b/security/keys/internal.h
index c0f8682eba69..0cc7333408d0 100644
--- a/security/keys/internal.h
+++ b/security/keys/internal.h
@@ -271,7 +271,7 @@ extern long keyctl_dh_compute(struct keyctl_dh_params __user *, char __user *,
size_t, struct keyctl_kdf_params __user *);
extern long __keyctl_dh_compute(struct keyctl_dh_params __user *, char __user *,
size_t, struct keyctl_kdf_params *);
-#ifdef CONFIG_KEYS_COMPAT
+#ifdef CONFIG_COMPAT
extern long compat_keyctl_dh_compute(struct keyctl_dh_params __user *params,
char __user *buffer, size_t buflen,
struct compat_keyctl_kdf_params __user *kdf);
@@ -286,7 +286,7 @@ static inline long keyctl_dh_compute(struct keyctl_dh_params __user *params,
return -EOPNOTSUPP;
}
-#ifdef CONFIG_KEYS_COMPAT
+#ifdef CONFIG_COMPAT
static inline long compat_keyctl_dh_compute(
struct keyctl_dh_params __user *params,
char __user *buffer, size_t buflen,
--
2.13.1
--
To unsubscribe from this list: send the line "unsubscribe linux-security-module" in
the body of a message to majordomo at vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply related [flat|nested] 10+ messages in thread
* Re: [PATCH] KEYS: remove CONFIG_KEYS_COMPAT
2017-06-13 6:09 ` Eric Biggers
@ 2017-06-27 9:27 ` David Howells
-1 siblings, 0 replies; 10+ messages in thread
From: David Howells @ 2017-06-27 9:27 UTC (permalink / raw)
To: linux-security-module
Eric Biggers <ebiggers3@gmail.com> wrote:
> diff --git a/security/keys/Kconfig b/security/keys/Kconfig
> index a7a23b5541f8..f5d96996baa6 100644
> --- a/security/keys/Kconfig
> +++ b/security/keys/Kconfig
> @@ -20,10 +20,6 @@ config KEYS
>
> If you are unsure as to whether this is required, answer N.
>
> -config KEYS_COMPAT
> - def_bool y
> - depends on COMPAT && KEYS
> -
> config PERSISTENT_KEYRINGS
> bool "Enable register of persistent per-UID keyrings"
> depends on KEYS
Hmmm... This is in linus/master, but not in security/next. I'll hold your
patch till later in the merge window or just after -rc1.
David
^ permalink raw reply [flat|nested] 10+ messages in thread
* [PATCH] KEYS: remove CONFIG_KEYS_COMPAT
@ 2017-06-27 9:27 ` David Howells
0 siblings, 0 replies; 10+ messages in thread
From: David Howells @ 2017-06-27 9:27 UTC (permalink / raw)
To: linux-security-module
Eric Biggers <ebiggers3@gmail.com> wrote:
> diff --git a/security/keys/Kconfig b/security/keys/Kconfig
> index a7a23b5541f8..f5d96996baa6 100644
> --- a/security/keys/Kconfig
> +++ b/security/keys/Kconfig
> @@ -20,10 +20,6 @@ config KEYS
>
> If you are unsure as to whether this is required, answer N.
>
> -config KEYS_COMPAT
> - def_bool y
> - depends on COMPAT && KEYS
> -
> config PERSISTENT_KEYRINGS
> bool "Enable register of persistent per-UID keyrings"
> depends on KEYS
Hmmm... This is in linus/master, but not in security/next. I'll hold your
patch till later in the merge window or just after -rc1.
David
--
To unsubscribe from this list: send the line "unsubscribe linux-security-module" in
the body of a message to majordomo at vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH] KEYS: remove CONFIG_KEYS_COMPAT
2017-06-27 9:27 ` David Howells
@ 2017-08-16 2:52 ` Eric Biggers
-1 siblings, 0 replies; 10+ messages in thread
From: Eric Biggers @ 2017-08-16 2:52 UTC (permalink / raw)
To: linux-security-module
On Tue, Jun 27, 2017 at 10:27:54AM +0100, David Howells wrote:
> Eric Biggers <ebiggers3@gmail.com> wrote:
>
> > diff --git a/security/keys/Kconfig b/security/keys/Kconfig
> > index a7a23b5541f8..f5d96996baa6 100644
> > --- a/security/keys/Kconfig
> > +++ b/security/keys/Kconfig
> > @@ -20,10 +20,6 @@ config KEYS
> >
> > If you are unsure as to whether this is required, answer N.
> >
> > -config KEYS_COMPAT
> > - def_bool y
> > - depends on COMPAT && KEYS
> > -
> > config PERSISTENT_KEYRINGS
> > bool "Enable register of persistent per-UID keyrings"
> > depends on KEYS
>
> Hmmm... This is in linus/master, but not in security/next. I'll hold your
> patch till later in the merge window or just after -rc1.
>
> David
Hi David, are you still planning to apply this patch?
Eric
^ permalink raw reply [flat|nested] 10+ messages in thread
* [PATCH] KEYS: remove CONFIG_KEYS_COMPAT
@ 2017-08-16 2:52 ` Eric Biggers
0 siblings, 0 replies; 10+ messages in thread
From: Eric Biggers @ 2017-08-16 2:52 UTC (permalink / raw)
To: linux-security-module
On Tue, Jun 27, 2017 at 10:27:54AM +0100, David Howells wrote:
> Eric Biggers <ebiggers3@gmail.com> wrote:
>
> > diff --git a/security/keys/Kconfig b/security/keys/Kconfig
> > index a7a23b5541f8..f5d96996baa6 100644
> > --- a/security/keys/Kconfig
> > +++ b/security/keys/Kconfig
> > @@ -20,10 +20,6 @@ config KEYS
> >
> > If you are unsure as to whether this is required, answer N.
> >
> > -config KEYS_COMPAT
> > - def_bool y
> > - depends on COMPAT && KEYS
> > -
> > config PERSISTENT_KEYRINGS
> > bool "Enable register of persistent per-UID keyrings"
> > depends on KEYS
>
> Hmmm... This is in linus/master, but not in security/next. I'll hold your
> patch till later in the merge window or just after -rc1.
>
> David
Hi David, are you still planning to apply this patch?
Eric
--
To unsubscribe from this list: send the line "unsubscribe linux-security-module" in
the body of a message to majordomo at vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH] KEYS: remove CONFIG_KEYS_COMPAT
2017-08-16 2:52 ` Eric Biggers
@ 2017-10-09 20:25 ` Eric Biggers
-1 siblings, 0 replies; 10+ messages in thread
From: Eric Biggers @ 2017-10-09 20:25 UTC (permalink / raw)
To: linux-security-module
On Tue, Aug 15, 2017 at 07:52:44PM -0700, Eric Biggers wrote:
> On Tue, Jun 27, 2017 at 10:27:54AM +0100, David Howells wrote:
> > Eric Biggers <ebiggers3@gmail.com> wrote:
> >
> > > diff --git a/security/keys/Kconfig b/security/keys/Kconfig
> > > index a7a23b5541f8..f5d96996baa6 100644
> > > --- a/security/keys/Kconfig
> > > +++ b/security/keys/Kconfig
> > > @@ -20,10 +20,6 @@ config KEYS
> > >
> > > If you are unsure as to whether this is required, answer N.
> > >
> > > -config KEYS_COMPAT
> > > - def_bool y
> > > - depends on COMPAT && KEYS
> > > -
> > > config PERSISTENT_KEYRINGS
> > > bool "Enable register of persistent per-UID keyrings"
> > > depends on KEYS
> >
> > Hmmm... This is in linus/master, but not in security/next. I'll hold your
> > patch till later in the merge window or just after -rc1.
> >
> > David
>
> Hi David, are you still planning to apply this patch?
>
> Eric
Ping.
^ permalink raw reply [flat|nested] 10+ messages in thread
* [PATCH] KEYS: remove CONFIG_KEYS_COMPAT
@ 2017-10-09 20:25 ` Eric Biggers
0 siblings, 0 replies; 10+ messages in thread
From: Eric Biggers @ 2017-10-09 20:25 UTC (permalink / raw)
To: linux-security-module
On Tue, Aug 15, 2017 at 07:52:44PM -0700, Eric Biggers wrote:
> On Tue, Jun 27, 2017 at 10:27:54AM +0100, David Howells wrote:
> > Eric Biggers <ebiggers3@gmail.com> wrote:
> >
> > > diff --git a/security/keys/Kconfig b/security/keys/Kconfig
> > > index a7a23b5541f8..f5d96996baa6 100644
> > > --- a/security/keys/Kconfig
> > > +++ b/security/keys/Kconfig
> > > @@ -20,10 +20,6 @@ config KEYS
> > >
> > > If you are unsure as to whether this is required, answer N.
> > >
> > > -config KEYS_COMPAT
> > > - def_bool y
> > > - depends on COMPAT && KEYS
> > > -
> > > config PERSISTENT_KEYRINGS
> > > bool "Enable register of persistent per-UID keyrings"
> > > depends on KEYS
> >
> > Hmmm... This is in linus/master, but not in security/next. I'll hold your
> > patch till later in the merge window or just after -rc1.
> >
> > David
>
> Hi David, are you still planning to apply this patch?
>
> Eric
Ping.
--
To unsubscribe from this list: send the line "unsubscribe linux-security-module" in
the body of a message to majordomo at vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH] KEYS: remove CONFIG_KEYS_COMPAT
2017-10-09 20:25 ` Eric Biggers
@ 2017-11-13 22:56 ` Eric Biggers
-1 siblings, 0 replies; 10+ messages in thread
From: Eric Biggers @ 2017-11-13 22:56 UTC (permalink / raw)
To: linux-security-module
On Mon, Oct 09, 2017 at 01:25:34PM -0700, Eric Biggers wrote:
> On Tue, Aug 15, 2017 at 07:52:44PM -0700, Eric Biggers wrote:
> > On Tue, Jun 27, 2017 at 10:27:54AM +0100, David Howells wrote:
> > > Eric Biggers <ebiggers3@gmail.com> wrote:
> > >
> > > > diff --git a/security/keys/Kconfig b/security/keys/Kconfig
> > > > index a7a23b5541f8..f5d96996baa6 100644
> > > > --- a/security/keys/Kconfig
> > > > +++ b/security/keys/Kconfig
> > > > @@ -20,10 +20,6 @@ config KEYS
> > > >
> > > > If you are unsure as to whether this is required, answer N.
> > > >
> > > > -config KEYS_COMPAT
> > > > - def_bool y
> > > > - depends on COMPAT && KEYS
> > > > -
> > > > config PERSISTENT_KEYRINGS
> > > > bool "Enable register of persistent per-UID keyrings"
> > > > depends on KEYS
> > >
> > > Hmmm... This is in linus/master, but not in security/next. I'll hold your
> > > patch till later in the merge window or just after -rc1.
> > >
> > > David
> >
> > Hi David, are you still planning to apply this patch?
> >
> > Eric
>
> Ping.
Ping.
^ permalink raw reply [flat|nested] 10+ messages in thread
* [PATCH] KEYS: remove CONFIG_KEYS_COMPAT
@ 2017-11-13 22:56 ` Eric Biggers
0 siblings, 0 replies; 10+ messages in thread
From: Eric Biggers @ 2017-11-13 22:56 UTC (permalink / raw)
To: linux-security-module
On Mon, Oct 09, 2017 at 01:25:34PM -0700, Eric Biggers wrote:
> On Tue, Aug 15, 2017 at 07:52:44PM -0700, Eric Biggers wrote:
> > On Tue, Jun 27, 2017 at 10:27:54AM +0100, David Howells wrote:
> > > Eric Biggers <ebiggers3@gmail.com> wrote:
> > >
> > > > diff --git a/security/keys/Kconfig b/security/keys/Kconfig
> > > > index a7a23b5541f8..f5d96996baa6 100644
> > > > --- a/security/keys/Kconfig
> > > > +++ b/security/keys/Kconfig
> > > > @@ -20,10 +20,6 @@ config KEYS
> > > >
> > > > If you are unsure as to whether this is required, answer N.
> > > >
> > > > -config KEYS_COMPAT
> > > > - def_bool y
> > > > - depends on COMPAT && KEYS
> > > > -
> > > > config PERSISTENT_KEYRINGS
> > > > bool "Enable register of persistent per-UID keyrings"
> > > > depends on KEYS
> > >
> > > Hmmm... This is in linus/master, but not in security/next. I'll hold your
> > > patch till later in the merge window or just after -rc1.
> > >
> > > David
> >
> > Hi David, are you still planning to apply this patch?
> >
> > Eric
>
> Ping.
Ping.
--
To unsubscribe from this list: send the line "unsubscribe linux-security-module" in
the body of a message to majordomo at vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 10+ messages in thread
end of thread, other threads:[~2017-11-13 22:56 UTC | newest]
Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-06-13 6:09 [PATCH] KEYS: remove CONFIG_KEYS_COMPAT Eric Biggers
2017-06-13 6:09 ` Eric Biggers
2017-06-27 9:27 ` David Howells
2017-06-27 9:27 ` David Howells
2017-08-16 2:52 ` Eric Biggers
2017-08-16 2:52 ` Eric Biggers
2017-10-09 20:25 ` Eric Biggers
2017-10-09 20:25 ` Eric Biggers
2017-11-13 22:56 ` Eric Biggers
2017-11-13 22:56 ` Eric Biggers
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.