Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions drivers/char/hw_random/core.c
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@ static int hwrng_init(struct hwrng *rng)
return 0;
}

static int rng_dev_open(struct inode *inode, struct file *filp)
static int rng_dev_chk_perm(struct inode *inode, struct file *filp)
{
/* enforce read-only access to this chrdev */
if ((filp->f_mode & FMODE_READ) == 0)
Expand Down Expand Up @@ -286,7 +286,7 @@ static ssize_t rng_dev_read(struct file *filp, char __user *buf,

static const struct file_operations rng_chrdev_ops = {
.owner = THIS_MODULE,
.open = rng_dev_open,
.open = rng_dev_chk_perm,
.read = rng_dev_read,
.llseek = noop_llseek,
};
Expand Down