From 7d5473963f25b23237a274ac5bb419e81dcbda61 Mon Sep 17 00:00:00 2001 From: Michael Meffie Date: Wed, 29 Apr 2015 11:54:45 -0400 Subject: [PATCH] libafs: remove linux conditionals for md5 inode number calculation 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 Reviewed-by: Perry Ruiter Reviewed-by: Benjamin Kaduk (cherry picked from commit ac05e8ceebd05c2d8496759e70cf7b1b92541134) Change-Id: I8fd613c436120a6436f48920ce4f33570dfb1fb8 Reviewed-on: https://gerrit.openafs.org/12632 Tested-by: BuildBot Reviewed-by: Benjamin Kaduk Reviewed-by: Michael Meffie Reviewed-by: Mark Vitale Reviewed-by: Stephan Wiesand --- src/afs/afs_util.c | 16 +--------------- 1 file changed, 1 insertion(+), 15 deletions(-) diff --git a/src/afs/afs_util.c b/src/afs/afs_util.c index e0f6cd1cd..a18c89021 100644 --- a/src/afs/afs_util.c +++ b/src/afs/afs_util.c @@ -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 @@ -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 -- 2.39.5