]> git.michaelhowe.org Git - packages/o/openafs.git/commitdiff
libafs: remove linux conditionals for md5 inode number calculation
authorMichael Meffie <mmeffie@sinenomine.net>
Wed, 29 Apr 2015 15:54:45 +0000 (11:54 -0400)
committerStephan Wiesand <stephan.wiesand@desy.de>
Wed, 7 Jun 2017 16:11:18 +0000 (12:11 -0400)
Remove the conditionals which hide the md5 digest calculation for inode
numbers on non-linux platforms.  This feature was originally added to
support sites running on linux, but is generally useful and the
implementation is not specific to linux.

Reviewed-on: http://gerrit.openafs.org/11854
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Perry Ruiter <pruiter@sinenomine.net>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
(cherry picked from commit ac05e8ceebd05c2d8496759e70cf7b1b92541134)

Change-Id: I8fd613c436120a6436f48920ce4f33570dfb1fb8
Reviewed-on: https://gerrit.openafs.org/12632
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
Reviewed-by: Michael Meffie <mmeffie@sinenomine.net>
Reviewed-by: Mark Vitale <mvitale@sinenomine.net>
Reviewed-by: Stephan Wiesand <stephan.wiesand@desy.de>
src/afs/afs_util.c

index e0f6cd1cda5384792917f226d3b8144e84b48f18..a18c8902103a9896a6dcbc3c62220903dcfeeb62 100644 (file)
@@ -36,9 +36,7 @@
 #include "afsincludes.h"       /* Afs-based standard headers */
 #include "afs/afs_stats.h"     /* afs statistics */
 
-#ifdef AFS_LINUX20_ENV
-#include "afs/afs_md5.h"       /* For MD5 inodes - Linux only */
-#endif
+#include "afs/afs_md5.h"       /* For MD5 inodes */
 
 #if    defined(AFS_SUN56_ENV)
 #include <inet/led.h>
@@ -364,8 +362,6 @@ afs_data_pointer_to_int32(const void *p)
     return ip.i32[i32_sub];
 }
 
-#ifdef AFS_LINUX20_ENV
-
 afs_int32
 afs_calc_inum(afs_int32 cell, afs_int32 volume, afs_int32 vnode)
 {
@@ -401,13 +397,3 @@ afs_calc_inum(afs_int32 cell, afs_int32 volume, afs_int32 vnode)
     ino &= 0x7fffffff;      /* Assumes 32 bit ino_t ..... */
     return ino;
 }
-
-#else
-
-afs_int32
-afs_calc_inum(afs_int32 cell, afs_int32 volume, afs_int32 vnode)
-{
-    return (volume << 16) + vnode;
-}
-
-#endif