• Jens Axboe's avatar
    mm: never attempt async page lock if we've transferred data already · 0abed7c6
    Jens Axboe authored
    We catch the case where we enter generic_file_buffered_read() with data
    already transferred, but we also need to be careful not to allow an async
    page lock if we're looping transferring data. If not, we could be
    returning -EIOCBQUEUED instead of the transferred amount, and it could
    result in double waitqueue additions as well.
    
    Cc: stable@vger.kernel.org # v5.9
    Fixes: 1a0a7853 ("mm: support async buffered reads in generic_file_buffered_read()")
    Signed-off-by: default avatarJens Axboe <axboe@kernel.dk>
    0abed7c6
filemap.c 98 KB