remove check for disallowing clones of backup or ro volumes
authorJacob Thebault-Spieker <summatusmentis@gmail.com>
Tue, 19 Jul 2011 16:02:49 +0000 (09:02 -0700)
committerDerrick Brashear <shadow@dementix.org>
Mon, 24 Oct 2011 20:14:53 +0000 (13:14 -0700)
removes the if-statement ensuring that the volume being cloned is
not a backup volume, nor a read-only volume. This allows clones
from any type of volume to a given volume. Parent volume meta-data
is maintained, only the cloneId value changes.

Change-Id: If8444fcabc9b9106db7db7df881ae07e8d287915
Reviewed-on: http://gerrit.openafs.org/5046
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@dementix.org>

src/volser/volprocs.c

index 227a632..8083cc2 100644 (file)
@@ -930,12 +930,6 @@ VolReClone(struct rx_call *acid, afs_int32 atrans, afs_int32 cloneId)
     TSetRxCall(tt, acid, "ReClone");
 
     originalvp = tt->volume;
-    if ((V_type(originalvp) == backupVolume)
-       || (V_type(originalvp) == readonlyVolume)) {
-       Log("1 Volser: Clone: The volume to be cloned must be a read/write; aborted\n");
-       error = EROFS;
-       goto fail;
-    }
     if ((V_destroyMe(originalvp) == DESTROY_ME) || !V_inService(originalvp)) {
        Log("1 Volser: Clone: Volume %d is offline and cannot be cloned\n",
            V_id(originalvp));