diff options
Diffstat (limited to 'fs/jbd2/transaction.c')
-rw-r--r-- | fs/jbd2/transaction.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/fs/jbd2/transaction.c b/fs/jbd2/transaction.c index 8088e00..f32ec4c 100644 --- a/fs/jbd2/transaction.c +++ b/fs/jbd2/transaction.c @@ -1683,8 +1683,20 @@ int jbd2_journal_try_to_free_buffers(journal_t *journal, __journal_try_to_free_buffer(journal, bh); jbd2_journal_put_journal_head(jh); jbd_unlock_bh_state(bh); +#ifndef CONFIG_DMA_CMA if (buffer_jbd(bh)) goto busy; +#else + if (buffer_jbd(bh)) { + /* + * Workaround: In case of CMA page, just commit journal. + */ + if (is_cma_pageblock(page)) + jbd2_journal_force_commit(journal); + else + goto busy; + } +#endif } while ((bh = bh->b_this_page) != head); ret = try_to_free_buffers(page); |