LKML Archive on
 help / color / Atom feed
From: Arnd Bergmann <>
To: "Theodore Ts'o" <>, Arnd Bergmann <>,
	Greg Kroah-Hartman <>
Cc: youling 257 <>,
Subject: [PATCH] char: random: fix urandom ioctl support
Date: Sat,  7 Dec 2019 19:58:20 +0100
Message-ID: <> (raw)

My patch to move the /dev/random compat handling from
fs/compat_ioctl.c int drivers missed the corresponding
/dev/urandom support.

Use the same compat_ptr_ioctl() in both devices.

Fixes: 507e4e2b430b ("compat_ioctl: remove /dev/random commands")
Reported-by: youling 257 <>
Signed-off-by: Arnd Bergmann <>
 drivers/char/random.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/char/random.c b/drivers/char/random.c
index 46afd14facb7..9280ca4d85c0 100644
--- a/drivers/char/random.c
+++ b/drivers/char/random.c
@@ -2176,6 +2176,7 @@ const struct file_operations urandom_fops = {
 	.read  = urandom_read,
 	.write = random_write,
 	.unlocked_ioctl = random_ioctl,
+	.compat_ioctl = compat_ptr_ioctl,
 	.fasync = random_fasync,
 	.llseek = noop_llseek,

                 reply index

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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:

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \ \ \ \ \ \ \

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

LKML Archive on

Archives are clonable:
	git clone --mirror lkml/git/0.git
	git clone --mirror lkml/git/1.git
	git clone --mirror lkml/git/2.git
	git clone --mirror lkml/git/3.git
	git clone --mirror lkml/git/4.git
	git clone --mirror lkml/git/5.git
	git clone --mirror lkml/git/6.git
	git clone --mirror lkml/git/7.git
	git clone --mirror lkml/git/8.git
	git clone --mirror lkml/git/9.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 lkml lkml/ \
	public-inbox-index lkml

Example config snippet for mirrors

Newsgroup available over NNTP:

AGPL code for this site: git clone