summaryrefslogtreecommitdiff
path: root/fs/eventpoll.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/eventpoll.c')
-rw-r--r--fs/eventpoll.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/fs/eventpoll.c b/fs/eventpoll.c
index e6a26429d70c..b484d4500687 100644
--- a/fs/eventpoll.c
+++ b/fs/eventpoll.c
@@ -1235,14 +1235,22 @@ static int ep_create_wakeup_source(struct epitem *epi)
{
struct name_snapshot n;
struct wakeup_source *ws;
+ char task_comm_buf[TASK_COMM_LEN];
+ char buf[64];
+
+ get_task_comm(task_comm_buf, current);
if (!epi->ep->ws) {
- epi->ep->ws = wakeup_source_register("eventpoll");
+ snprintf(buf, sizeof(buf), "epoll_%.*s_epollfd",
+ (int)sizeof(task_comm_buf), task_comm_buf);
+ epi->ep->ws = wakeup_source_register(buf);
if (!epi->ep->ws)
return -ENOMEM;
}
take_dentry_name_snapshot(&n, epi->ffd.file->f_path.dentry);
+ snprintf(buf, sizeof(buf), "epoll_%.*s_file:%s",
+ (int)sizeof(task_comm_buf), task_comm_buf, n.name);
ws = wakeup_source_register(n.name);
release_dentry_name_snapshot(&n);