]> git.michaelhowe.org Git - packages/o/openafs.git/commitdiff
STABLE14-tbutc-solaris-and-vos-api-fixes-20051024
authorDerrick Brashear <shadow@dementia.org>
Tue, 25 Oct 2005 07:35:55 +0000 (07:35 +0000)
committerDerrick Brashear <shadow@dementia.org>
Tue, 25 Oct 2005 07:35:55 +0000 (07:35 +0000)
FIXES 22063

as tested for this and 22316

====================
This delta was composed from multiple commits as part of the CVS->Git migration.
The checkin message with each commit was inconsistent.
The following are the additional commit messages.
====================
FIXES 22316

the rest of this, since i forgot to apply the other file earlier
oops

(cherry picked from commit 834507571e397dc3a07550ef86ca2c159068d1ff)

src/cf/osconf.m4
src/libadmin/vos/afs_vosAdmin.c
src/libadmin/vos/vosutils.c
src/libadmin/vos/vosutils.h
src/libadmin/vos/vsprocs.c
src/tbutc/Makefile.in

index ce98b3adc05fba57f0045797053f073d338aad18..112be0d51b4dc0c231b13993ce59766469b667f0 100644 (file)
@@ -707,6 +707,7 @@ case $AFS_SYSNAME in
                XLIBS="${LIB_AFSDB} -lsocket -lnsl -lintl -ldl"
                LD="/usr/ccs/bin/ld"
                SHLIB_LINKER="${CC} -G -dy -Wl,-M\$(srcdir)/mapfile -Bsymbolic -z text"
+               LWP_OPTMZ="-g"
                ;;
 
        sun4x_56)
@@ -727,6 +728,7 @@ case $AFS_SYSNAME in
                XLIBKVM="-lkvm"
                XLIBS="${LIB_AFSDB} -lsocket -lnsl -lintl -ldl"
                SHLIB_LINKER="${CC} -G -dy -Wl,-M\$(srcdir)/mapfile -Bsymbolic -z text"
+               LWP_OPTMZ="-g"
                ;;
 
        sun4x_57)
@@ -748,6 +750,7 @@ case $AFS_SYSNAME in
                XLIBKVM="-lkvm"
                XLIBS="${LIB_AFSDB} -lsocket -lnsl -lintl -ldl"
                SHLIB_LINKER="${CC} -G -dy -Wl,-M\$(srcdir)/mapfile -Bsymbolic -z text"
+               LWP_OPTMZ="-g"
                ;;
 
        sun4x_58)
@@ -769,6 +772,7 @@ case $AFS_SYSNAME in
                XLIBKVM="-lkvm"
                XLIBS="${LIB_AFSDB} -lsocket -lnsl -lintl -ldl"
                SHLIB_LINKER="${CC} -G -dy -Wl,-M\$(srcdir)/mapfile -Bsymbolic -z text"
+               LWP_OPTMZ="-g"
                ;;
 
        sun4x_59)
@@ -790,6 +794,7 @@ case $AFS_SYSNAME in
                XLIBKVM="-lkvm"
                XLIBS="${LIB_AFSDB} -lsocket -lnsl -lintl -ldl"
                SHLIB_LINKER="${CC} -G -dy -Wl,-M\$(srcdir)/mapfile -Bsymbolic -z text"
+               LWP_OPTMZ="-g"
                ;;
 
        sun4x_510)
@@ -811,6 +816,7 @@ case $AFS_SYSNAME in
                XLIBKVM="-lkvm"
                XLIBS="${LIB_AFSDB} -lsocket -lnsl -lintl -ldl"
                SHLIB_LINKER="${CC} -G -dy -Wl,-M\$(srcdir)/mapfile -Bsymbolic -z text"
+               LWP_OPTMZ="-g"
                ;;
 
        sunx86_57)
index c29eb13f5d5398b28f9fc1fc29ae97f20167503a..058d30e8000a6d901e70c281e66d9789668455de 100644 (file)
@@ -1975,11 +1975,11 @@ vos_VLDBGet(const void *cellHandle, vos_MessageCallBack_t callBack,
        if (!ValidateVolumeName(volumeName, &tst)) {
            goto fail_vos_VLDBGet;
        }
-       if (!VLDB_GetEntryByName(c_handle, volumeName, &entry, &tst)) {
+       if (!aVLDB_GetEntryByName(c_handle, volumeName, &entry, &tst)) {
            goto fail_vos_VLDBGet;
        }
     } else {
-       if (!VLDB_GetEntryByID(c_handle, *volumeId, -1, &entry, &tst)) {
+       if (!aVLDB_GetEntryByID(c_handle, *volumeId, -1, &entry, &tst)) {
            goto fail_vos_VLDBGet;
        }
     }
@@ -2919,7 +2919,7 @@ vos_VolumeCreate(const void *cellHandle, const void *serverHandle,
      * Check that the volume doesn't already exist
      */
 
-    if (VLDB_GetEntryByName(c_handle, volumeName, &vinfo, &tst)) {
+    if (aVLDB_GetEntryByName(c_handle, volumeName, &vinfo, &tst)) {
        tst = ADMVOSVOLUMENAMEDUP;
        goto fail_vos_VolumeCreate;
     }
@@ -3067,7 +3067,7 @@ vos_VolumeRename(const void *cellHandle, vos_MessageCallBack_t callBack,
      * Retrieve the entry
      */
 
-    if (!VLDB_GetEntryByID(c_handle, readWriteVolumeId, -1, &entry, &tst)) {
+    if (!aVLDB_GetEntryByID(c_handle, readWriteVolumeId, -1, &entry, &tst)) {
        goto fail_vos_VolumeRename;
     }
 
@@ -3261,7 +3261,7 @@ vos_VolumeRestore(const void *cellHandle, const void *serverHandle,
      */
 
     if (volumeId != NULL) {
-       if (!VLDB_GetEntryByID(c_handle, *volumeId, -1, &entry, &tst)) {
+       if (!aVLDB_GetEntryByID(c_handle, *volumeId, -1, &entry, &tst)) {
            goto fail_vos_VolumeRestore;
        }
        volid = *volumeId;
@@ -3289,7 +3289,7 @@ vos_VolumeRestore(const void *cellHandle, const void *serverHandle,
        close(fd);
     }
 
-    if (!VLDB_GetEntryByName(c_handle, volumeName, &entry, &tst)) {
+    if (!aVLDB_GetEntryByName(c_handle, volumeName, &entry, &tst)) {
        restoreflags = RV_FULLRST;
     } else if (Lp_GetRwIndex(c_handle, &entry, 0) == -1) {
        restoreflags = RV_FULLRST;
index 4b62878a6ae6c14cca7480746a6b39fa3c88db0b..fbdb0e6d7d53c5a7162e6d9780b6668502ae3c14 100644 (file)
@@ -133,7 +133,7 @@ VLDB_CreateEntry(afs_cell_handle_p cellHandle, struct nvldbentry *entryp,
 }
 
 int
-VLDB_GetEntryByID(afs_cell_handle_p cellHandle, afs_int32 volid,
+aVLDB_GetEntryByID(afs_cell_handle_p cellHandle, afs_int32 volid,
                  afs_int32 voltype, struct nvldbentry *entryp,
                  afs_status_p st)
 {
@@ -171,7 +171,7 @@ VLDB_GetEntryByID(afs_cell_handle_p cellHandle, afs_int32 volid,
 }
 
 int
-VLDB_GetEntryByName(afs_cell_handle_p cellHandle, const char *namep,
+aVLDB_GetEntryByName(afs_cell_handle_p cellHandle, const char *namep,
                    struct nvldbentry *entryp, afs_status_p st)
 {
     struct vldbentry oentry;
@@ -412,7 +412,7 @@ GetVolumeInfo(afs_cell_handle_p cellHandle, unsigned int volid,
     afs_status_t tst;
     int i, index = -1;
 
-    if (!VLDB_GetEntryByID(cellHandle, volid, -1, rentry, &tst)) {
+    if (!aVLDB_GetEntryByID(cellHandle, volid, -1, rentry, &tst)) {
        rc = 0;
        goto fail_GetVolumeInfo;
     }
index 5ae468f51aa363e55c2ebcca214b52aaac776e6e..d886e12e911b06e68df76e9f5a491093400bef6b 100644 (file)
 extern int VLDB_CreateEntry(afs_cell_handle_p cellHandle,
                            struct nvldbentry *entryp, afs_status_p st);
 
-extern int VLDB_GetEntryByID(afs_cell_handle_p cellHandle, afs_int32 volid,
+extern int aVLDB_GetEntryByID(afs_cell_handle_p cellHandle, afs_int32 volid,
                             afs_int32 voltype, struct nvldbentry *entryp,
                             afs_status_p st);
 
 
-extern int VLDB_GetEntryByName(afs_cell_handle_p cellHandle,
+extern int aVLDB_GetEntryByName(afs_cell_handle_p cellHandle,
                               const char *namep, struct nvldbentry *entryp,
                               afs_status_p st);
 
index 76378c778044dd43029cb24587b488e630fc7606..33eb73f6480ffd1dcab75938ed4b933df27ea980 100644 (file)
@@ -239,7 +239,7 @@ UV_DeleteVolume(afs_cell_handle_p cellHandle, struct rx_connection *server,
     } else {
        islocked = 1;
 
-       if (!VLDB_GetEntryByID(cellHandle, volumeId, avoltype, &entry, &tst)) {
+       if (!aVLDB_GetEntryByID(cellHandle, volumeId, avoltype, &entry, &tst)) {
            goto fail_UV_DeleteVolume;
        }
 
@@ -427,7 +427,7 @@ UV_MoveVolume(afs_cell_handle_p cellHandle, afs_int32 afromvol,
     backupId = 0;
     newVol = 0;
 
-    if (!VLDB_GetEntryByID(cellHandle, afromvol, -1, &entry, &tst)) {
+    if (!aVLDB_GetEntryByID(cellHandle, afromvol, -1, &entry, &tst)) {
        goto fail_UV_MoveVolume;
     }
 
@@ -443,7 +443,7 @@ UV_MoveVolume(afs_cell_handle_p cellHandle, afs_int32 afromvol,
     }
     islocked = 1;
 
-    if (!VLDB_GetEntryByID(cellHandle, afromvol, RWVOL, &entry, &tst)) {
+    if (!aVLDB_GetEntryByID(cellHandle, afromvol, RWVOL, &entry, &tst)) {
        goto fail_UV_MoveVolume;
     }
 
@@ -890,7 +890,7 @@ UV_MoveVolume(afs_cell_handle_p cellHandle, afs_int32 afromvol,
        AFSVolEndTrans(fromconn, fromtid, &rcode);
     }
 
-    if (!VLDB_GetEntryByID(cellHandle, afromvol, -1, &entry, &tst)) {
+    if (!aVLDB_GetEntryByID(cellHandle, afromvol, -1, &entry, &tst)) {
        goto done;
     }
 
@@ -1005,7 +1005,7 @@ UV_BackupVolume(afs_cell_handle_p cellHandle, afs_int32 aserver,
 
     /* the calls to VLDB will succeed only if avolid is a RW volume,
      * since we are following the RW hash chain for searching */
-    if (!VLDB_GetEntryByID(cellHandle, avolid, RWVOL, &entry, &tst)) {
+    if (!aVLDB_GetEntryByID(cellHandle, avolid, RWVOL, &entry, &tst)) {
        goto fail_UV_BackupVolume;
     }
 
@@ -1026,7 +1026,7 @@ UV_BackupVolume(afs_cell_handle_p cellHandle, afs_int32 aserver,
        vldblocked = 1;
 
        /* Reread the vldb entry */
-       if (!VLDB_GetEntryByID(cellHandle, avolid, RWVOL, &entry, &tst)) {
+       if (!aVLDB_GetEntryByID(cellHandle, avolid, RWVOL, &entry, &tst)) {
            goto fail_UV_BackupVolume;
        }
     }
@@ -1503,7 +1503,7 @@ UV_ReleaseVolume(afs_cell_handle_p cellHandle, afs_int32 afromvol,
     islocked = 1;
 
     /* Get the vldb entry in readable format */
-    if (!VLDB_GetEntryByID(cellHandle, afromvol, RWVOL, &entry, &tst)) {
+    if (!aVLDB_GetEntryByID(cellHandle, afromvol, RWVOL, &entry, &tst)) {
        goto fail_UV_ReleaseVolume;
     }
 
@@ -2118,7 +2118,7 @@ UV_DumpVolume(afs_cell_handle_p cellHandle, afs_int32 afromvol,
     fromcall = (struct rx_call *)0;
 
     islocked = 0;
-    if (!VLDB_GetEntryByID(cellHandle, afromvol, -1, &entry, &tst)) {
+    if (!aVLDB_GetEntryByID(cellHandle, afromvol, -1, &entry, &tst)) {
        goto fail_UV_DumpVolume;
     }
 
@@ -2329,7 +2329,7 @@ UV_RestoreVolume(afs_cell_handle_p cellHandle, afs_int32 toserver,
     pvolid = tovolid;
     toconn = UV_Bind(cellHandle, toserver, AFSCONF_VOLUMEPORT);
     if (pvolid == 0) {         /*alot a new id if needed */
-       VLDB_GetEntryByName(cellHandle, tovolname, &entry, &tst);
+       aVLDB_GetEntryByName(cellHandle, tovolname, &entry, &tst);
        if (tst == VL_NOENT) {
            tst =
                ubik_Call(VL_GetNewVolumeId, cellHandle->vos, 0, 1, &pvolid);
@@ -2450,7 +2450,7 @@ UV_RestoreVolume(afs_cell_handle_p cellHandle, afs_int32 toserver,
        /* Volume was restored on the file server, update the 
         * VLDB to reflect the change.
         */
-       VLDB_GetEntryByID(cellHandle, pvolid, RWVOL, &entry, &tst);
+       aVLDB_GetEntryByID(cellHandle, pvolid, RWVOL, &entry, &tst);
        if (tst && tst != VL_NOENT && tst != VL_ENTDELETED) {
            goto fail_UV_RestoreVolume;
        }
@@ -2613,7 +2613,7 @@ UV_AddSite(afs_cell_handle_p cellHandle, afs_int32 server, afs_int32 part,
     }
     islocked = 1;
 
-    if (!VLDB_GetEntryByID(cellHandle, volid, RWVOL, &entry, &tst)) {
+    if (!aVLDB_GetEntryByID(cellHandle, volid, RWVOL, &entry, &tst)) {
        goto fail_UV_AddSite;
     }
     if (!ISNAMEVALID(entry.name)) {
@@ -2692,7 +2692,7 @@ UV_RemoveSite(afs_cell_handle_p cellHandle, afs_int32 server, afs_int32 part,
     }
     islocked = 1;
 
-    if (!VLDB_GetEntryByID(cellHandle, volid, RWVOL, &entry, &tst)) {
+    if (!aVLDB_GetEntryByID(cellHandle, volid, RWVOL, &entry, &tst)) {
        goto fail_UV_RemoveSite;
     }
     if (!Lp_ROMatch(cellHandle, &entry, server, part, &tst)) {
@@ -3006,7 +3006,7 @@ ProcessEntries(afs_cell_handle_p cellHandle, struct qHead *myQueue,
            maxVolid += temp2;
 
        }
-       VLDB_GetEntryByID(cellHandle, elem.ids[RWVOL], RWVOL, &entry, &tst);
+       aVLDB_GetEntryByID(cellHandle, elem.ids[RWVOL], RWVOL, &entry, &tst);
        if (tst && (tst != VL_NOENT)) {
            noError = 0;
            totalCE++;
@@ -3495,7 +3495,7 @@ CheckVldb(afs_cell_handle_p cellHandle, struct nvldbentry *entry,
        }
        islocked = 1;
 
-       if (!VLDB_GetEntryByID
+       if (!aVLDB_GetEntryByID
            (cellHandle, entry->volumeId[RWVOL], RWVOL, entry, &tst)) {
            goto fail_CheckVldb;
        }
index af7a09760947dde997a9839ff0842bf8fa373e0d..60e8ab1e62a3b0b62009e252866607ffe8f1c1f8 100644 (file)
@@ -24,7 +24,7 @@ VOLSER  = ${srcdir}/../volser
 BUCOORDOBJS=ubik_db_if.o ../bucoord/volstub.o ../bucoord/dlq.o \
            status.o ../bucoord/bucoord_errs.o
 
-VOLSEROBJS=vsprocs.o
+VOLSEROBJS=vsprocs.o vsutils.o
 VOLSERLIBS=${TOP_LIBDIR}/libvosadmin.a ${TOP_LIBDIR}/libafsadminutil.a
 
 LWPOBJS     =lock.o
@@ -109,6 +109,9 @@ ubik_db_if.o: ${BUCOORD}/ubik_db_if.c
 status.o: ${BUCOORD}/status.c
        ${CC} ${CFLAGS} -c ${BUCOORD}/status.c
 
+vsutils.o: ${VOLSER}/vsutils.c
+       ${CC} ${CFLAGS} -c ${VOLSER}/vsutils.c
+
 vsprocs.o: ${VOLSER}/vsprocs.c
        ${CC} ${CFLAGS} -c ${VOLSER}/vsprocs.c