dcache: restore error on restart in prepend_path
authorMikulas Patocka <mpatocka@redhat.com>
Tue, 29 Apr 2014 21:09:54 +0000 (17:09 -0400)
committerJiri Slaby <jslaby@suse.cz>
Mon, 5 May 2014 09:19:42 +0000 (11:19 +0200)
We need to restore all variables including error (as it is done in the
upstream kernel). The variable error was errorneously not restored when
backporting the patch ede4cebce16f5643c61aedd6d88d9070a1d23a68
(prepend_path() needs to reinitialize dentry/vfsmount/mnt on restarts).

This should be applied only to the 3.12 series.

Signed-off-by: Mikulas Patocka <mpatocka@redhat.com>
Signed-off-by: Jiri Slaby <jslaby@suse.cz>
fs/dcache.c

index 30b38e23caa79b01783ca67b856e7f621f56696b..008f524e195a27dd338ff4e181138b7a2fca6973 100644 (file)
@@ -2893,6 +2893,7 @@ static int prepend_path(const struct path *path,
 restart:
        bptr = *buffer;
        blen = *buflen;
+       error = 0;
        dentry = path->dentry;
        vfsmnt = path->mnt;
        mnt = real_mount(vfsmnt);