All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jens Axboe <axboe@kernel.dk>
To: io-uring@vger.kernel.org
Cc: linux-fsdevel@vger.kernel.org, brauner@kernel.org,
	Jens Axboe <axboe@kernel.dk>
Subject: [PATCH 2/5] eventpoll: export is_file_epoll()
Date: Sun,  3 May 2026 02:49:13 -0600	[thread overview]
Message-ID: <20260503085101.112698-3-axboe@kernel.dk> (raw)
In-Reply-To: <20260503085101.112698-1-axboe@kernel.dk>

Make is_file_epoll() available outside of epoll. This is in preparation
from using it from io_uring.

Signed-off-by: Jens Axboe <axboe@kernel.dk>
---
 fs/eventpoll.c            | 2 +-
 include/linux/eventpoll.h | 1 +
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/fs/eventpoll.c b/fs/eventpoll.c
index f464f2f39e0e..9ea6a2bd3d87 100644
--- a/fs/eventpoll.c
+++ b/fs/eventpoll.c
@@ -334,7 +334,7 @@ static void __init epoll_sysctls_init(void)
 
 static const struct file_operations eventpoll_fops;
 
-static inline int is_file_epoll(struct file *f)
+int is_file_epoll(struct file *f)
 {
 	return f->f_op == &eventpoll_fops;
 }
diff --git a/include/linux/eventpoll.h b/include/linux/eventpoll.h
index 728fb5dee5ed..7bf30e9f90d7 100644
--- a/include/linux/eventpoll.h
+++ b/include/linux/eventpoll.h
@@ -63,6 +63,7 @@ static inline void eventpoll_release(struct file *file)
 
 int do_epoll_ctl(int epfd, int op, int fd, struct epoll_event *epds,
 		 bool nonblock);
+int is_file_epoll(struct file *f);
 
 /* Tells if the epoll_ctl(2) operation needs an event copy from userspace */
 static inline int ep_op_has_event(int op)
-- 
2.53.0


  parent reply	other threads:[~2026-05-03  8:51 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-05-03  8:49 [PATCHSET 0/5] io_uring related epoll cleanups Jens Axboe
2026-05-03  8:49 ` [PATCH 1/5] eventpoll: pass struct epoll_filefd through ep_find() and ep_insert() Jens Axboe
2026-05-12 19:50   ` Christian Brauner
2026-05-03  8:49 ` Jens Axboe [this message]
2026-05-12 19:50   ` [PATCH 2/5] eventpoll: export is_file_epoll() Christian Brauner
2026-05-03  8:49 ` [PATCH 3/5] eventpoll: add file based control interface Jens Axboe
2026-05-12 19:50   ` Christian Brauner
2026-05-12 20:03     ` Jens Axboe
2026-05-03  8:49 ` [PATCH 4/5] io_uring/epoll: switch to using do_epoll_ctl_file() interface Jens Axboe
2026-05-03  8:49 ` [PATCH 5/5] io_uring/epoll: disallow adding an epoll file to an epoll context Jens Axboe
2026-05-12 19:50   ` Christian Brauner
2026-05-12 20:04     ` Jens Axboe
2026-05-12 19:50 ` [PATCHSET 0/5] io_uring related epoll cleanups Christian Brauner
2026-05-12 20:04   ` Jens Axboe

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:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

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

  git send-email \
    --in-reply-to=20260503085101.112698-3-axboe@kernel.dk \
    --to=axboe@kernel.dk \
    --cc=brauner@kernel.org \
    --cc=io-uring@vger.kernel.org \
    --cc=linux-fsdevel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.