diff options
| -rw-r--r-- | fs/dax.c | 5 | ||||
| -rw-r--r-- | fs/iomap.c | 3 |
2 files changed, 8 insertions, 0 deletions
| @@ -1031,6 +1031,11 @@ dax_iomap_actor(struct inode *inode, loff_t pos, loff_t length, void *data, | |||
| 1031 | struct blk_dax_ctl dax = { 0 }; | 1031 | struct blk_dax_ctl dax = { 0 }; |
| 1032 | ssize_t map_len; | 1032 | ssize_t map_len; |
| 1033 | 1033 | ||
| 1034 | if (fatal_signal_pending(current)) { | ||
| 1035 | ret = -EINTR; | ||
| 1036 | break; | ||
| 1037 | } | ||
| 1038 | |||
| 1034 | dax.sector = dax_iomap_sector(iomap, pos); | 1039 | dax.sector = dax_iomap_sector(iomap, pos); |
| 1035 | dax.size = (length + offset + PAGE_SIZE - 1) & PAGE_MASK; | 1040 | dax.size = (length + offset + PAGE_SIZE - 1) & PAGE_MASK; |
| 1036 | map_len = dax_map_atomic(iomap->bdev, &dax); | 1041 | map_len = dax_map_atomic(iomap->bdev, &dax); |
diff --git a/fs/iomap.c b/fs/iomap.c index 354a123f170e..a51cb4c07d4d 100644 --- a/fs/iomap.c +++ b/fs/iomap.c | |||
| @@ -114,6 +114,9 @@ iomap_write_begin(struct inode *inode, loff_t pos, unsigned len, unsigned flags, | |||
| 114 | 114 | ||
| 115 | BUG_ON(pos + len > iomap->offset + iomap->length); | 115 | BUG_ON(pos + len > iomap->offset + iomap->length); |
| 116 | 116 | ||
| 117 | if (fatal_signal_pending(current)) | ||
| 118 | return -EINTR; | ||
| 119 | |||
| 117 | page = grab_cache_page_write_begin(inode->i_mapping, index, flags); | 120 | page = grab_cache_page_write_begin(inode->i_mapping, index, flags); |
| 118 | if (!page) | 121 | if (!page) |
| 119 | return -ENOMEM; | 122 | return -ENOMEM; |
