]> git.baikalelectronics.ru Git - kernel.git/commit
jbd2: get rid of open coded allocation retry loop
authorMichal Hocko <mhocko@suse.cz>
Mon, 15 Jun 2015 19:45:58 +0000 (15:45 -0400)
committerTheodore Ts'o <tytso@mit.edu>
Mon, 15 Jun 2015 19:45:58 +0000 (15:45 -0400)
commit21cf2856d13aabc051db29c67e54a825276b6ff0
tree7ec312baa0aee40eb0d1773b238b686fff1436b6
parenta26a1a49727cfd18fc4eae0161c71d330b5bf810
jbd2: get rid of open coded allocation retry loop

insert_revoke_hash does an open coded endless allocation loop if
journal_oom_retry is true. It doesn't implement any allocation fallback
strategy between the retries, though. The memory allocator doesn't know
about the never fail requirement so it cannot potentially help to move
on with the allocation (e.g. use memory reserves).

Get rid of the retry loop and use __GFP_NOFAIL instead. We will lose the
debugging message but I am not sure it is anyhow helpful.

Do the same for journal_alloc_journal_head which is doing a similar
thing.

Signed-off-by: Michal Hocko <mhocko@suse.cz>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
fs/jbd2/journal.c
fs/jbd2/revoke.c