diff options
Diffstat (limited to 'mm/shmem.c')
-rw-r--r-- | mm/shmem.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/mm/shmem.c b/mm/shmem.c index 185836ba53ef..73ba1df7c8ba 100644 --- a/mm/shmem.c +++ b/mm/shmem.c | |||
@@ -1536,7 +1536,7 @@ static ssize_t shmem_file_read_iter(struct kiocb *iocb, struct iov_iter *to) | |||
1536 | * holes of a sparse file, we actually need to allocate those pages, | 1536 | * holes of a sparse file, we actually need to allocate those pages, |
1537 | * and even mark them dirty, so it cannot exceed the max_blocks limit. | 1537 | * and even mark them dirty, so it cannot exceed the max_blocks limit. |
1538 | */ | 1538 | */ |
1539 | if (segment_eq(get_fs(), KERNEL_DS)) | 1539 | if (!iter_is_iovec(to)) |
1540 | sgp = SGP_DIRTY; | 1540 | sgp = SGP_DIRTY; |
1541 | 1541 | ||
1542 | index = *ppos >> PAGE_CACHE_SHIFT; | 1542 | index = *ppos >> PAGE_CACHE_SHIFT; |