diff options
Diffstat (limited to 'arch/arm/mm/flush.c')
-rw-r--r-- | arch/arm/mm/flush.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/arch/arm/mm/flush.c b/arch/arm/mm/flush.c index 43474d8752a6..82f4b06bf6b4 100644 --- a/arch/arm/mm/flush.c +++ b/arch/arm/mm/flush.c | |||
@@ -189,7 +189,16 @@ static void __flush_dcache_aliases(struct address_space *mapping, struct page *p | |||
189 | */ | 189 | */ |
190 | void flush_dcache_page(struct page *page) | 190 | void flush_dcache_page(struct page *page) |
191 | { | 191 | { |
192 | struct address_space *mapping = page_mapping(page); | 192 | struct address_space *mapping; |
193 | |||
194 | /* | ||
195 | * The zero page is never written to, so never has any dirty | ||
196 | * cache lines, and therefore never needs to be flushed. | ||
197 | */ | ||
198 | if (page == ZERO_PAGE(0)) | ||
199 | return; | ||
200 | |||
201 | mapping = page_mapping(page); | ||
193 | 202 | ||
194 | #ifndef CONFIG_SMP | 203 | #ifndef CONFIG_SMP |
195 | if (!PageHighMem(page) && mapping && !mapping_mapped(mapping)) | 204 | if (!PageHighMem(page) && mapping && !mapping_mapped(mapping)) |