[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20180912151422.571531-4-arnd@arndb.de>
Date: Wed, 12 Sep 2018 17:13:05 +0200
From: Arnd Bergmann <arnd@...db.de>
To: viro@...iv.linux.org.uk
Cc: linux-fsdevel@...r.kernel.org, Arnd Bergmann <arnd@...db.de>,
"Theodore Ts'o" <tytso@....edu>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Jann Horn <jannh@...gle.com>, linux-kernel@...r.kernel.org
Subject: [PATCH v2 13/17] compat_ioctl: remove /dev/random commands
These are all handled by the random driver, so instead of listing
each ioctl, we can just use the same function to deal with both
native and compat commands.
Signed-off-by: Arnd Bergmann <arnd@...db.de>
---
drivers/char/random.c | 1 +
fs/compat_ioctl.c | 7 -------
2 files changed, 1 insertion(+), 7 deletions(-)
diff --git a/drivers/char/random.c b/drivers/char/random.c
index bf5f99fc36f1..d1b2cdebc598 100644
--- a/drivers/char/random.c
+++ b/drivers/char/random.c
@@ -2021,6 +2021,7 @@ const struct file_operations random_fops = {
.write = random_write,
.poll = random_poll,
.unlocked_ioctl = random_ioctl,
+ .compat_ioctl = generic_compat_ioctl_ptrarg,
.fasync = random_fasync,
.llseek = noop_llseek,
};
diff --git a/fs/compat_ioctl.c b/fs/compat_ioctl.c
index ca7f83976a3f..d5b8380fb1b1 100644
--- a/fs/compat_ioctl.c
+++ b/fs/compat_ioctl.c
@@ -764,13 +764,6 @@ COMPATIBLE_IOCTL(WDIOC_SETTIMEOUT)
COMPATIBLE_IOCTL(WDIOC_GETTIMEOUT)
COMPATIBLE_IOCTL(WDIOC_SETPRETIMEOUT)
COMPATIBLE_IOCTL(WDIOC_GETPRETIMEOUT)
-/* Big R */
-COMPATIBLE_IOCTL(RNDGETENTCNT)
-COMPATIBLE_IOCTL(RNDADDTOENTCNT)
-COMPATIBLE_IOCTL(RNDGETPOOL)
-COMPATIBLE_IOCTL(RNDADDENTROPY)
-COMPATIBLE_IOCTL(RNDZAPENTCNT)
-COMPATIBLE_IOCTL(RNDCLEARPOOL)
/* Bluetooth */
COMPATIBLE_IOCTL(HCIDEVUP)
COMPATIBLE_IOCTL(HCIDEVDOWN)
--
2.18.0
Powered by blists - more mailing lists