]> git.michaelhowe.org Git - packages/o/openafs.git/commitdiff
Revert "modify FindIndex to compare uuids"
authorJeffrey Altman <jaltman@your-file-system.com>
Sat, 5 Mar 2011 04:40:31 +0000 (23:40 -0500)
committerDerrick Brashear <shadow@dementia.org>
Sat, 5 Mar 2011 13:52:44 +0000 (05:52 -0800)
This reverts commit 9aad0979e9ff0601c249eb66a6ecfb3e76264702.

This is being pulled as the entire nvldbentry to uvldbentry
conversion is being reverted.

Reviewed-on: http://gerrit.openafs.org/4130
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@dementia.org>
Tested-by: Derrick Brashear <shadow@dementia.org>
(cherry picked from commit ca0ae15d621dbd90339408a26715a107d1f69f23)

Change-Id: If97b81e874c87b10a4c4e5f190f573781fc3c158
Reviewed-on: http://gerrit.openafs.org/4132
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@dementia.org>
src/volser/lockprocs.c

index d98d1baff5182473dfd6951c89f8511164d484d7..cc93a52389002bb560e0ece6a2eb516df46873a0 100644 (file)
@@ -31,7 +31,6 @@
 #include <afs/vlserver.h>
 #include <afs/nfs.h>
 #include <afs/afsint.h>
-#include <ubik.h>
 #include "volint.h"
 #include "volser.h"
 #include "lockdata.h"
@@ -39,8 +38,6 @@
 #include "vsutils_prototypes.h"
 #include "lockprocs_prototypes.h"
 
-struct ubik_client *cstruct;
-
 /* Finds an index in VLDB entry that matches the volume type, server, and partition.
  * If type is zero, will match first index of ANY type (RW, BK, or RO).
  * If server is zero, will match first index of ANY server and partition
@@ -51,34 +48,13 @@ FindIndex(struct uvldbentry *entry, afs_uint32 server, afs_int32 part, afs_int32
 {
     int e;
     afs_int32 error = 0;
-    afsUUID m_uuid;
-    int uuid_valid = 0;
-
-    if (server && !afs_uuid_is_nil(&entry->serverNumber[0])) {
-        afs_int32 vcode, m_uniq=0;
-        bulkaddrs m_addrs;
-        ListAddrByAttributes m_attrs;
-        afs_int32 m_nentries;
-
-        m_attrs.Mask = VLADDR_IPADDR;
-        m_attrs.ipaddr = htonl(server);
-        m_nentries = 0;
-        m_addrs.bulkaddrs_val = 0;
-        m_addrs.bulkaddrs_len = 0;
-        vcode =
-            ubik_VL_GetAddrsU( cstruct, 0, &m_attrs,
-                               &m_uuid,
-                               &m_uniq, &m_nentries,
-                               &m_addrs);
-        uuid_valid = (vcode == 0);
-    }
 
     for (e = 0; (e < entry->nServers) && !error; e++) {
        if (!type || (entry->serverFlags[e] & type)) {
            if ((!server || (entry->serverPartition[e] == part))
                && (!server
-                    || (uuid_valid && afs_uuid_equal(&m_uuid, &entry->serverNumber[e]))
-                   || VLDB_IsSameAddrs(entry->serverUnique[e], server, &error)))
+                   || VLDB_IsSameAddrs(entry->serverUnique[e], server,
+                                       &error)))
                break;
            if (type == ITSRWVOL)
                return -1;      /* quit when we are looking for RW entry (there's only 1) */