Skip to content

Commit

Permalink
Revert "io_uring: disable polling pollfree files"
Browse files Browse the repository at this point in the history
Fix early boot crash.

This reverts commit fc78b2f.
  • Loading branch information
frno7 committed Mar 7, 2024
1 parent f5a3a13 commit b364d55
Show file tree
Hide file tree
Showing 4 changed files with 0 additions and 6 deletions.
1 change: 0 additions & 1 deletion drivers/android/binder.c
Original file line number Diff line number Diff line change
Expand Up @@ -6095,7 +6095,6 @@ const struct file_operations binder_fops = {
.open = binder_open,
.flush = binder_flush,
.release = binder_release,
.may_pollfree = true,
};

static int __init init_binder_device(const char *name)
Expand Down
3 changes: 0 additions & 3 deletions fs/io_uring.c
Original file line number Diff line number Diff line change
Expand Up @@ -1908,9 +1908,6 @@ static int io_poll_add(struct io_kiocb *req, const struct io_uring_sqe *sqe)
__poll_t mask;
u16 events;

if (req->file->f_op->may_pollfree)
return -EOPNOTSUPP;

if (unlikely(req->ctx->flags & IORING_SETUP_IOPOLL))
return -EINVAL;
if (sqe->addr || sqe->ioprio || sqe->off || sqe->len || sqe->buf_index)
Expand Down
1 change: 0 additions & 1 deletion fs/signalfd.c
Original file line number Diff line number Diff line change
Expand Up @@ -248,7 +248,6 @@ static const struct file_operations signalfd_fops = {
.poll = signalfd_poll,
.read = signalfd_read,
.llseek = noop_llseek,
.may_pollfree = true,
};

static int do_signalfd4(int ufd, sigset_t *mask, int flags)
Expand Down
1 change: 0 additions & 1 deletion include/linux/fs.h
Original file line number Diff line number Diff line change
Expand Up @@ -1859,7 +1859,6 @@ struct file_operations {
struct file *file_out, loff_t pos_out,
loff_t len, unsigned int remap_flags);
int (*fadvise)(struct file *, loff_t, loff_t, int);
bool may_pollfree;
} __randomize_layout;

struct inode_operations {
Expand Down

0 comments on commit b364d55

Please sign in to comment.