linux/fs/cachefiles
Kiran Kumar Modukuri b1f5b8b5e8 cachefiles: Wait rather than BUG'ing on "Unexpected object collision"
commit c2412ac45a upstream.

If we meet a conflicting object that is marked FSCACHE_OBJECT_IS_LIVE in
the active object tree, we have been emitting a BUG after logging
information about it and the new object.

Instead, we should wait for the CACHEFILES_OBJECT_ACTIVE flag to be cleared
on the old object (or return an error).  The ACTIVE flag should be cleared
after it has been removed from the active object tree.  A timeout of 60s is
used in the wait, so we shouldn't be able to get stuck there.

Fixes: 9ae326a690 ("CacheFiles: A cache that backs onto a mounted filesystem")
Signed-off-by: Kiran Kumar Modukuri <kiran.modukuri@gmail.com>
Signed-off-by: David Howells <dhowells@redhat.com>
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
History 2018-11-20 18:05:50 +00:00
..
bind.c fscache: Fix reference overput in fscache_attach_object() error handling 2018-11-20 18:05:49 +00:00
daemon.c fs/cachefiles: add missing \n to kerror conversions 2014-10-05 13:41:07 -07:00
interface.c fs/cachefiles: replace kerror by pr_err 2014-06-06 16:08:14 -07:00
internal.h fs/cachefiles: add missing \n to kerror conversions 2014-10-05 13:41:07 -07:00
Kconfig CacheFiles: A cache that backs onto a mounted filesystem 2009-04-03 16:42:41 +01:00
key.c CacheFiles: Downgrade the requirements passed to the allocator 2012-12-20 21:58:25 +00:00
main.c fs/cachefiles: add missing \n to kerror conversions 2014-10-05 13:41:07 -07:00
Makefile CacheFiles: A cache that backs onto a mounted filesystem 2009-04-03 16:42:41 +01:00
namei.c cachefiles: Wait rather than BUG'ing on "Unexpected object collision" 2018-11-20 18:05:50 +00:00
proc.c CacheFiles: A cache that backs onto a mounted filesystem 2009-04-03 16:42:41 +01:00
rdwr.c cachefiles: Fix refcounting bug in backing-file read monitoring 2018-11-20 18:05:49 +00:00
security.c fs/cachefiles: replace kerror by pr_err 2014-06-06 16:08:14 -07:00
xattr.c fs/cachefiles: add missing \n to kerror conversions 2014-10-05 13:41:07 -07:00