diff options
author | Jens Axboe <axboe@kernel.dk> | 2021-03-02 21:00:33 -0700 |
---|---|---|
committer | Jens Axboe <axboe@kernel.dk> | 2021-03-02 21:00:33 -0700 |
commit | 44a23ff1f089e87d28c7035a1c58126c6de9da81 (patch) | |
tree | df9bc4af2b093a626d16325bec0e743d567f55cb | |
parent | c9387501192c24c14e5a97f97bc1f60cdd071a29 (diff) |
io_uring: debug messagessyzbot-test
Signed-off-by: Jens Axboe <axboe@kernel.dk>
-rw-r--r-- | fs/io_uring.c | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/fs/io_uring.c b/fs/io_uring.c index dc30034f453f..6e78f03f9346 100644 --- a/fs/io_uring.c +++ b/fs/io_uring.c @@ -4920,8 +4920,14 @@ static int io_poll_double_wake(struct wait_queue_entry *wait, unsigned mode, list_del_init(&wait->entry); if (poll && poll->head) { + struct io_poll_iocb *dpoll = io_poll_get_double(req); bool done; + if (dpoll->head == poll->head) + printk(KERN_ERR "poll and dpoll head identical\n"); + else + printk(KERN_ERR "poll and dpoll head different\n"); + spin_lock(&poll->head->lock); done = list_empty(&poll->wait.entry); if (!done) @@ -4969,8 +4975,12 @@ static void __io_queue_proc(struct io_poll_iocb *poll, struct io_poll_table *pt, return; } /* double add on the same waitqueue head, ignore */ - if (poll->head == head) + if (poll->head == head) { + printk(KERN_ERR "Ignore double poll same head\n"); return; + } else { + printk(KERN_ERR "Double poll %lx %lx\n", (long) poll->head, (long) head); + } poll = kmalloc(sizeof(*poll), GFP_ATOMIC); if (!poll) { pt->error = -ENOMEM; |