lkml.org 
[lkml]   [2017]   [Oct]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [BUG] fs/aio: A possible sleep-in-atomic bug in aio_migratepage
On Sat, Oct 07, 2017 at 09:36:48AM +0800, Jia-Ju Bai wrote:
> According to fs/aio.c, cond_resched is called under a spinlock,
> and the function call path is:
> aio_migratepage (acquire the spinlock)
> migrate_page_copy
> copy_huge_page
> __copy_gigantic_page
> cond_resched
> might_sleep
>
> This bug is found by my static analysis tool and my code review.
> A possible fix is to remove cond_resched in __copy_gigantic_page.

How the hell would a huge page end up in page cache of inode created
by aio_private_file()???

\
 
 \ /
  Last update: 2017-10-07 04:33    [W:0.025 / U:0.928 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site