mm/filemap.c: enable error injection at add_to_page_cache()

Recently I messed up the error handling in filemap_fault() because of an
unexpected ENOMEM (related to cgroup memory limits) in add_to_page_cache.
Enable error injection at this point so I can add a testcase to xfstests
to verify I don't mess this up again.

[ include linux/error-injection.h]
Signed-off-by: Josef Bacik <>
Reviewed-by: William Kucharski <>
Signed-off-by: Andrew Morton <>
Signed-off-by: Linus Torvalds <>
1 file changed