]> git.michaelhowe.org Git - packages/o/openafs.git/commitdiff
vol: allow clones of readonly volumes
authorDerrick Brashear <shadow@dementix.org>
Tue, 13 Dec 2011 17:00:52 +0000 (12:00 -0500)
committerDerrick Brashear <shadow@dementix.org>
Thu, 23 Feb 2012 17:33:09 +0000 (09:33 -0800)
allow writing of data where it's not user data we're changing
(e.g. allow a vnode to be marked cloned in the vnode index)

Reviewed-on: http://gerrit.openafs.org/6251
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Alistair Ferguson <alistair.ferguson@mac.com>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
(cherry picked from commit 4b93c42513785d1094c5336b5c9cc4add1b89c5e)

Change-Id: I9849897ae69a426026f6d030ca4e50e8cd7066b2
Reviewed-on: http://gerrit.openafs.org/6762
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Alistair Ferguson <alistair.ferguson@mac.com>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
src/vol/clone.c

index 0841302fe349e00928e31ef12c03f646a1c72f71..3d20b8a7cbb5c638fc22bf520a1e5afc2b6d11f4 100644 (file)
@@ -176,7 +176,12 @@ DoCloneIndex(Volume * rwvp, Volume * clvp, VnodeClass class, int reclone)
     afs_ino_str_t stmp;
 
     struct VnodeClassInfo *vcp = &VnodeClassInfo[class];
-    int ReadWriteOriginal = VolumeWriteable(rwvp);
+    /*
+     * The fileserver's -readonly switch should make this false, but we
+     * have no useful way to know in the volserver.
+     * This doesn't make client data mutable.
+     */
+    int ReadWriteOriginal = 1;
 
     /* Correct number of files in volume: this assumes indexes are always
        cloned starting with vLarge */