From: Chas Williams Date: Mon, 14 Aug 2006 23:07:14 +0000 (+0000) Subject: STABLE14-linux-kernel-updates-20060804 X-Git-Tag: openafs-stable-1_4_2rc1~13 X-Git-Url: https://git.michaelhowe.org/gitweb/?a=commitdiff_plain;h=fb8b12ed0d7c39ad8572dbf1338deb0834ff8339;p=packages%2Fo%2Fopenafs.git STABLE14-linux-kernel-updates-20060804 updates for new stuff in linux kernels (cherry picked from commit a901d2b8ad9cfb3060b7824179b92b16e5f3dd14) --- diff --git a/acinclude.m4 b/acinclude.m4 index 61557c88d..60dcafc8a 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -121,6 +121,10 @@ case $system in LINUX_KERNEL_PATH="/usr/src/linux" fi fi + if test -f "$LINUX_KERNEL_PATH/include/linux/utsrelease.h"; then + linux_kvers=`fgrep UTS_RELEASE $LINUX_KERNEL_PATH/include/linux/utsrelease.h |awk 'BEGIN { FS="\"" } { print $[]2 }'|tail -n 1` + LINUX_VERSION="$linux_kvers" + else if test -f "$LINUX_KERNEL_PATH/include/linux/version.h"; then linux_kvers=`fgrep UTS_RELEASE $LINUX_KERNEL_PATH/include/linux/version.h |awk 'BEGIN { FS="\"" } { print $[]2 }'|tail -n 1` if test "x$linux_kvers" = "x"; then @@ -143,6 +147,7 @@ case $system in else enable_kernel_module="no" fi + fi if test ! -f "$LINUX_KERNEL_PATH/include/linux/autoconf.h"; then enable_kernel_module="no" fi diff --git a/src/afs/LINUX/osi_vfsops.c b/src/afs/LINUX/osi_vfsops.c index 172bd4bef..c562594e4 100644 --- a/src/afs/LINUX/osi_vfsops.c +++ b/src/afs/LINUX/osi_vfsops.c @@ -49,7 +49,6 @@ static void iattr2vattr(struct vattr *vattrp, struct iattr *iattrp); static int afs_root(struct super_block *afsp); struct super_block *afs_read_super(struct super_block *sb, void *data, int silent); int afs_fill_super(struct super_block *sb, void *data, int silent); -static struct super_block *afs_get_sb(struct file_system_type *fs_type, int flags, const char *dev_name, void *data); /* afs_file_system * VFS entry for Linux - installed in init_module @@ -64,6 +63,29 @@ struct backing_dev_info afs_backing_dev_info = { .state = 0, }; + +/* afs_read_super + * read the "super block" for AFS - roughly eguivalent to struct vfs. + * dev, covered, s_rd_only, s_dirt, and s_type will be set by read_super. + */ +#if defined(AFS_LINUX26_ENV) +static struct super_block * +#ifdef GET_SB_HAS_STRUCT_VFSMOUNT +afs_get_sb(struct file_system_type *fs_type, int flags, + const char *dev_name, void *data, struct vfsmount *mnt) +#else +afs_get_sb(struct file_system_type *fs_type, int flags, + const char *dev_name, void *data) +#endif +{ +#ifdef GET_SB_HAS_STRUCT_VFSMOUNT + return get_sb_nodev(fs_type, flags, data, afs_fill_super, mnt); +#else + return get_sb_nodev(fs_type, flags, data, afs_fill_super); +#endif +} + + struct file_system_type afs_fs_type = { .owner = THIS_MODULE, .name = "afs", @@ -83,16 +105,6 @@ struct file_system_type afs_fs_type = { }; #endif -/* afs_read_super - * read the "super block" for AFS - roughly eguivalent to struct vfs. - * dev, covered, s_rd_only, s_dirt, and s_type will be set by read_super. - */ -#if defined(AFS_LINUX26_ENV) -static struct super_block * -afs_get_sb(struct file_system_type *fs_type, int flags, const char *dev_name, void *data) -{ - return get_sb_nodev(fs_type, flags, data, afs_fill_super); -} int afs_fill_super(struct super_block *sb, void *data, int silent)