diff -pruN linux-2.6.32.orig/include/linux/ve_nfs.h linux-2.6.32/include/linux/ve_nfs.h --- linux-2.6.32.orig/include/linux/ve_nfs.h 2012-08-28 15:43:31 +0400 +++ linux-2.6.32/include/linux/ve_nfs.h 2012-09-05 16:17:42 +0400 @@ -66,6 +66,7 @@ struct ve_nlm_data { #define NLM_CTX_FIELD(arg) (get_exec_env()->nlm_data->_##arg) #define NFS_CTX_FIELD(arg) (get_exec_env()->nfs_data->_##arg) +#if defined(CONFIG_SUNRPC) || defined(CONFIG_SUNRPC_MODULE) static inline void ve_rpc_data_init(void) { atomic_set(&get_exec_env()->rpc_data->_users, 1); @@ -93,7 +94,9 @@ static inline void ve_rpc_data_put(struc } (void)set_exec_env(curr_ve); } +#endif +#if defined(CONFIG_NFS_FS) || defined(CONFIG_NFS_FS_MODULE) static inline void ve_nfs_data_init(struct ve_nfs_data *data) { atomic_set(&data->_users, 1); @@ -122,6 +125,7 @@ static inline void ve_nfs_data_put(struc } (void)set_exec_env(curr_ve); } +#endif #else /* CONFIG_VE */ diff -pruN linux-2.6.32.orig/kernel/cpt/cpt_dump.c linux-2.6.32/kernel/cpt/cpt_dump.c --- linux-2.6.32.orig/kernel/cpt/cpt_dump.c 2012-08-28 15:43:31 +0400 +++ linux-2.6.32/kernel/cpt/cpt_dump.c 2012-09-05 16:51:40 +0400 @@ -1004,18 +1004,22 @@ int cpt_vps_suspend(struct cpt_context * old_ns = current->nsproxy; current->nsproxy = env->ve_ns; +#if defined(CONFIG_NFS_FS) || defined(CONFIG_NFS_FS_MODULE) /* Start syncing NFS */ ve_nfs_sync(env, 0); +#endif /* Find and stop all the tasks */ if ((err = vps_stop_tasks(ctx)) != 0) goto out; +#if defined(CONFIG_NFS_FS) || defined(CONFIG_NFS_FS_MODULE) /* Wait for syncing NFS mounts */ if ((err = ve_nfs_sync(env, 1)) != 0) { eprintk_ctx("failed to sync nfs\n"); goto out_wake; } +#endif if ((err = cpt_suspend_network(ctx)) != 0) goto out_wake; diff -pruN linux-2.6.32.orig/kernel/cpt/cpt_files.c linux-2.6.32/kernel/cpt/cpt_files.c --- linux-2.6.32.orig/kernel/cpt/cpt_files.c 2012-08-28 15:43:31 +0400 +++ linux-2.6.32/kernel/cpt/cpt_files.c 2012-09-05 17:04:51 +0400 @@ -325,8 +325,10 @@ int cpt_dump_string(const char *s, struc cpt_object_t *cpt_lookup_vfsmount_obj(struct vfsmount *mnt, struct cpt_context *ctx) { +#if defined(CONFIG_NFS_FS) || defined(CONFIG_NFS_FS_MODULE) while (is_nfs_automount(mnt)) mnt = mnt->mnt_parent; +#endif if (is_autofs_mount(mnt->mnt_parent)) mnt = mnt->mnt_parent; @@ -1759,8 +1761,10 @@ static int collect_vfsmount_tree(struct if (is_autofs_mount(mnt->mnt_parent)) continue; +#if defined(CONFIG_NFS_FS) || defined(CONFIG_NFS_FS_MODULE) if (is_nfs_automount(mnt)) continue; +#endif if (cpt_need_delayfs(mnt->mnt_parent)) { eprintk_ctx("unsupported delayfs submount: %s\n", path); diff -pruN linux-2.6.32.orig/kernel/cpt/rst_delayfs.c linux-2.6.32/kernel/cpt/rst_delayfs.c --- linux-2.6.32.orig/kernel/cpt/rst_delayfs.c 2012-08-28 15:43:31 +0400 +++ linux-2.6.32/kernel/cpt/rst_delayfs.c 2012-09-05 17:00:42 +0400 @@ -235,10 +235,12 @@ static void delayed_flock(struct delayed int err; struct file_lock *fl = dfi->fl; +#if defined(CONFIG_SUNRPC) || defined(CONFIG_SUNRPC_MODULE) err = nlmclnt_set_lockowner(file->f_dentry->d_inode, fl, (fl_owner_t)file, dfi->svid); if (err) goto out; +#endif fl->fl_file = file; fl->fl_flags |= FL_LOCAL; @@ -942,8 +944,10 @@ static void delayfs_nfs_handle_mount_fai static void delayfs_nfs_restore_mount_params(struct delay_sb_info *si) { +#if defined(CONFIG_NFS_FS) || defined(CONFIG_NFS_FS_MODULE) nfs_change_server_params(si->real->mnt_sb->s_fs_info, si->nfs_mnt_soft, si->nfs_delay_tmo, si->nfs_mnt_retrans); +#endif } static void delayfs_prepare_for_remount_loop(struct delay_sb_info *si) @@ -1614,9 +1618,11 @@ int rst_delay_flock(struct file *f, stru goto out; } +#if defined(CONFIG_SUNRPC) || defined(CONFIG_SUNRPC_MODULE) err = nlmclnt_reserve_pid(fli->cpt_svid); if (err) goto out; +#endif err = -ENOMEM; dfi = kmalloc(sizeof(*dfi), GFP_KERNEL);