diff options
author | Sebastian Andrzej Siewior <bigeasy@linutronix.de> | 2018-08-17 18:44:04 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2018-08-17 19:20:27 -0400 |
commit | a10dcebacdb0cf6eb29c211e99cf190cd131a16a (patch) | |
tree | d85f53c3e3582e99406da0fee740c63d791971f1 /fs/ntfs/aops.c | |
parent | bed95c43c15eb6b1ccc5b09e5ae08cac726c456d (diff) |
fs/ntfs/aops.c: don't disable interrupts during kmap_atomic()
ntfs_end_buffer_async_read() disables interrupts around kmap_atomic().
This is a leftover from the old kmap_atomic() implementation which
relied on fixed mapping slots, so the caller had to make sure that the
same slot could not be reused from an interrupting context.
kmap_atomic() was changed to dynamic slots long ago and commit
1ec9c5ddc17a ("include/linux/highmem.h: remove the second argument of
k[un]map_atomic()") removed the slot assignements, but the callers were
not checked for now redundant interrupt disabling.
Remove the conditional interrupt disable.
Link: http://lkml.kernel.org/r/20180611144913.gln5mklhqcrfsoom@linutronix.de
Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Cc: Anton Altaparmakov <anton@tuxera.com>
Cc: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'fs/ntfs/aops.c')
-rw-r--r-- | fs/ntfs/aops.c | 4 |
1 files changed, 0 insertions, 4 deletions
diff --git a/fs/ntfs/aops.c b/fs/ntfs/aops.c index 3a2e509c77c5..01c770979921 100644 --- a/fs/ntfs/aops.c +++ b/fs/ntfs/aops.c | |||
@@ -93,13 +93,11 @@ static void ntfs_end_buffer_async_read(struct buffer_head *bh, int uptodate) | |||
93 | ofs = 0; | 93 | ofs = 0; |
94 | if (file_ofs < init_size) | 94 | if (file_ofs < init_size) |
95 | ofs = init_size - file_ofs; | 95 | ofs = init_size - file_ofs; |
96 | local_irq_save(flags); | ||
97 | kaddr = kmap_atomic(page); | 96 | kaddr = kmap_atomic(page); |
98 | memset(kaddr + bh_offset(bh) + ofs, 0, | 97 | memset(kaddr + bh_offset(bh) + ofs, 0, |
99 | bh->b_size - ofs); | 98 | bh->b_size - ofs); |
100 | flush_dcache_page(page); | 99 | flush_dcache_page(page); |
101 | kunmap_atomic(kaddr); | 100 | kunmap_atomic(kaddr); |
102 | local_irq_restore(flags); | ||
103 | } | 101 | } |
104 | } else { | 102 | } else { |
105 | clear_buffer_uptodate(bh); | 103 | clear_buffer_uptodate(bh); |
@@ -146,13 +144,11 @@ static void ntfs_end_buffer_async_read(struct buffer_head *bh, int uptodate) | |||
146 | recs = PAGE_SIZE / rec_size; | 144 | recs = PAGE_SIZE / rec_size; |
147 | /* Should have been verified before we got here... */ | 145 | /* Should have been verified before we got here... */ |
148 | BUG_ON(!recs); | 146 | BUG_ON(!recs); |
149 | local_irq_save(flags); | ||
150 | kaddr = kmap_atomic(page); | 147 | kaddr = kmap_atomic(page); |
151 | for (i = 0; i < recs; i++) | 148 | for (i = 0; i < recs; i++) |
152 | post_read_mst_fixup((NTFS_RECORD*)(kaddr + | 149 | post_read_mst_fixup((NTFS_RECORD*)(kaddr + |
153 | i * rec_size), rec_size); | 150 | i * rec_size), rec_size); |
154 | kunmap_atomic(kaddr); | 151 | kunmap_atomic(kaddr); |
155 | local_irq_restore(flags); | ||
156 | flush_dcache_page(page); | 152 | flush_dcache_page(page); |
157 | if (likely(page_uptodate && !PageError(page))) | 153 | if (likely(page_uptodate && !PageError(page))) |
158 | SetPageUptodate(page); | 154 | SetPageUptodate(page); |