s3: Remove the gpfs_hsm_notify module
authorVolker Lendecke <vl@samba.org>
Wed, 8 Aug 2012 08:38:36 +0000 (10:38 +0200)
committerChristian Ambach <ambi@samba.org>
Fri, 17 Aug 2012 16:25:53 +0000 (18:25 +0200)
The functionality has been merged into vfs_gpfs

Signed-off-by: Christian Ambach <ambi@samba.org>
packaging/RHEL-CTDB/configure.rpm
packaging/RHEL-CTDB/samba.spec.tmpl
source3/Makefile.in
source3/configure.in
source3/modules/vfs_gpfs_hsm_notify.c [deleted file]
source3/modules/wscript_build
source3/wscript

index c2a030295c5424721639aaa30ac4cb5aa81fbf26..5e2b88e778b68bb5f96e1a0ef5ce52d481a58cce 100755 (executable)
@@ -51,7 +51,7 @@ CC="$CC" CFLAGS="-Wall -g -D_GNU_SOURCE -O3" ./configure -C \
        --without-smbwrapper \
        --with-pam \
        --with-quotas \
-       --with-shared-modules=idmap_rid,idmap_ad,idmap_tdb2,vfs_gpfs,vfs_tsmsm,vfs_gpfs_hsm_notify \
+       --with-shared-modules=idmap_rid,idmap_ad,idmap_tdb2,vfs_gpfs,vfs_tsmsm \
        --with-syslog \
        --with-utmp \
        --with-cluster-support \
index a9111d27bbc961d08b46116defb5df385edb0594..80237e76d87c2fa8bfe009234d254525ef608651 100644 (file)
@@ -186,7 +186,7 @@ CFLAGS="$RPM_OPT_FLAGS $EXTRA -D_GNU_SOURCE" ./configure \
         --without-smbwrapper \
        --with-pam \
        --with-quotas \
-       --with-shared-modules=idmap_rid,idmap_ad,idmap_tdb2,vfs_gpfs,vfs_tsmsm,vfs_gpfs_hsm_notify \
+       --with-shared-modules=idmap_rid,idmap_ad,idmap_tdb2,vfs_gpfs,vfs_tsmsm \
        --with-syslog \
        --with-utmp \
        --with-cluster-support \
@@ -416,7 +416,6 @@ exit 0
 %{_libarchdir}/samba/vfs/fileid.so
 %{_libarchdir}/samba/vfs/full_audit.so
 %{_libarchdir}/samba/vfs/gpfs.so
-%{_libarchdir}/samba/vfs/gpfs_hsm_notify.so
 %{_libarchdir}/samba/vfs/linux_xfs_sgid.so
 %{_libarchdir}/samba/vfs/netatalk.so
 %{_libarchdir}/samba/vfs/preopen.so
index b8b055a5939225dfa6dccecbb4eb738d3b69de1e..57c6c1db1c4aecefcf5b9128a1584b9fe74e120a 100644 (file)
@@ -882,7 +882,6 @@ VFS_CACHEPRIME_OBJ = modules/vfs_cacheprime.o
 VFS_PREALLOC_OBJ = modules/vfs_prealloc.o
 VFS_COMMIT_OBJ = modules/vfs_commit.o
 VFS_GPFS_OBJ = modules/vfs_gpfs.o modules/gpfs.o modules/nfs4_acls.o
-VFS_GPFS_HSM_NOTIFY_OBJ = modules/vfs_gpfs_hsm_notify.o
 VFS_NOTIFY_FAM_OBJ = modules/vfs_notify_fam.o
 VFS_READAHEAD_OBJ = modules/vfs_readahead.o
 VFS_TSMSM_OBJ = modules/vfs_tsmsm.o
@@ -2849,10 +2848,6 @@ bin/gpfs.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_GPFS_OBJ)
        @echo "Building plugin $@"
        @$(SHLD_MODULE) $(VFS_GPFS_OBJ)
 
-bin/gpfs_hsm_notify.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_GPFS_HSM_NOTIFY_OBJ)
-       @echo "Building plugin $@"
-       @$(SHLD_MODULE) $(VFS_GPFS_HSM_NOTIFY_OBJ)
-
 bin/notify_fam.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_NOTIFY_FAM_OBJ)
        @echo "Building plugin $@"
        @$(SHLD_MODULE) $(VFS_NOTIFY_FAM_OBJ) @SMB_FAM_LIBS@
index 44fd38dd9c55ca9bdb6639c6e59cd2d990b06d4c..28894f154a01f7a579b236618bbb23dd445a83e1 100644 (file)
@@ -1000,7 +1000,6 @@ AC_CHECK_HEADERS(gpfs_gpl.h)
 if test x"$ac_cv_header_gpfs_gpl_h" = x"yes"; then
     AC_DEFINE(HAVE_GPFS,1,[Whether GPFS GPL headers are available])
     default_shared_modules="$default_shared_modules vfs_gpfs"
-    default_shared_modules="$default_shared_modules vfs_gpfs_hsm_notify"
 fi
 
 # Note that all the libunwind symbols in the API are defined to internal
@@ -6556,7 +6555,6 @@ SMB_MODULE(vfs_cacheprime, \$(VFS_CACHEPRIME_OBJ), "bin/cacheprime.$SHLIBEXT", V
 SMB_MODULE(vfs_prealloc, \$(VFS_PREALLOC_OBJ), "bin/prealloc.$SHLIBEXT", VFS)
 SMB_MODULE(vfs_commit, \$(VFS_COMMIT_OBJ), "bin/commit.$SHLIBEXT", VFS)
 SMB_MODULE(vfs_gpfs, \$(VFS_GPFS_OBJ), "bin/gpfs.$SHLIBEXT", VFS)
-SMB_MODULE(vfs_gpfs_hsm_notify, \$(VFS_GPFS_PREFETCH_OBJ), "bin/gpfs_hsm_notify.$SHLIBEXT", VFS)
 SMB_MODULE(vfs_readahead, \$(VFS_READAHEAD_OBJ), "bin/readahead.$SHLIBEXT", VFS)
 SMB_MODULE(vfs_tsmsm, \$(VFS_TSMSM_OBJ), "bin/tsmsm.$SHLIBEXT", VFS)
 SMB_MODULE(vfs_fileid, \$(VFS_FILEID_OBJ), "bin/fileid.$SHLIBEXT", VFS)
diff --git a/source3/modules/vfs_gpfs_hsm_notify.c b/source3/modules/vfs_gpfs_hsm_notify.c
deleted file mode 100644 (file)
index d53363c..0000000
+++ /dev/null
@@ -1,110 +0,0 @@
-/*
-   Unix SMB/CIFS implementation.
-   Make sure offline->online changes are propagated by notifies
-
-   This module must come before aio_fork in the chain, because
-   aio_fork (correcly!) does not propagate the aio calls further
-
-   Copyright (C) Volker Lendecke 2011
-
-   This program is free software; you can redistribute it and/or modify
-   it under the terms of the GNU General Public License as published by
-   the Free Software Foundation; either version 3 of the License, or
-   (at your option) any later version.
-
-   This program is distributed in the hope that it will be useful,
-   but WITHOUT ANY WARRANTY; without even the implied warranty of
-   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-   GNU General Public License for more details.
-
-   You should have received a copy of the GNU General Public License
-   along with this program.  If not, see <http://www.gnu.org/licenses/>.
-*/
-
-#include "includes.h"
-#include "smbd/smbd.h"
-#include "librpc/gen_ndr/ndr_xattr.h"
-#include "include/smbprofile.h"
-
-#undef DBGC_CLASS
-#define DBGC_CLASS DBGC_VFS
-
-#include <gpfs_gpl.h>
-#include "nfs4_acls.h"
-#include "vfs_gpfs.h"
-
-static ssize_t vfs_gpfs_hsm_notify_pread(vfs_handle_struct *handle, files_struct *fsp,
-                             void *data, size_t n, off_t offset)
-{
-       ssize_t ret;
-
-       ret = SMB_VFS_NEXT_PREAD(handle, fsp, data, n, offset);
-
-       DEBUG(10, ("vfs_private = %x\n",
-                  (unsigned int)fsp->fsp_name->st.vfs_private));
-
-       if ((ret != -1) &&
-           ((fsp->fsp_name->st.vfs_private & GPFS_WINATTR_OFFLINE) != 0)) {
-               fsp->fsp_name->st.vfs_private &= ~GPFS_WINATTR_OFFLINE;
-               notify_fname(handle->conn, NOTIFY_ACTION_MODIFIED,
-                            FILE_NOTIFY_CHANGE_ATTRIBUTES,
-                            fsp->fsp_name->base_name);
-       }
-
-       return ret;
-}
-
-static ssize_t vfs_gpfs_hsm_notify_pwrite(struct vfs_handle_struct *handle,
-                              struct files_struct *fsp,
-                              const void *data, size_t n, off_t offset)
-{
-       ssize_t ret;
-
-       ret = SMB_VFS_NEXT_PWRITE(handle, fsp, data, n, offset);
-
-       if ((ret != -1) &&
-           ((fsp->fsp_name->st.vfs_private & GPFS_WINATTR_OFFLINE) != 0)) {
-               fsp->fsp_name->st.vfs_private &= ~GPFS_WINATTR_OFFLINE;
-               notify_fname(handle->conn, NOTIFY_ACTION_MODIFIED,
-                            FILE_NOTIFY_CHANGE_ATTRIBUTES,
-                            fsp->fsp_name->base_name);
-       }
-
-       return ret;
-}
-
-static ssize_t vfs_gpfs_hsm_notify_aio_return(struct vfs_handle_struct *handle,
-                                  struct files_struct *fsp,
-                                  SMB_STRUCT_AIOCB *aiocb)
-{
-       ssize_t ret;
-
-       ret = SMB_VFS_NEXT_AIO_RETURN(handle, fsp, aiocb);
-
-       DEBUG(10, ("vfs_gpfs_hsm_notify_aio_return: vfs_private = %x\n",
-                  (unsigned int)fsp->fsp_name->st.vfs_private));
-
-       if ((ret != -1) &&
-           ((fsp->fsp_name->st.vfs_private & GPFS_WINATTR_OFFLINE) != 0)) {
-               fsp->fsp_name->st.vfs_private &= ~GPFS_WINATTR_OFFLINE;
-               DEBUG(10, ("sending notify\n"));
-               notify_fname(handle->conn, NOTIFY_ACTION_MODIFIED,
-                            FILE_NOTIFY_CHANGE_ATTRIBUTES,
-                            fsp->fsp_name->base_name);
-       }
-
-       return ret;
-}
-
-static struct vfs_fn_pointers vfs_gpfs_hsm_notify_fns = {
-       .pread_fn = vfs_gpfs_hsm_notify_pread,
-       .pwrite_fn = vfs_gpfs_hsm_notify_pwrite,
-       .aio_return_fn = vfs_gpfs_hsm_notify_aio_return
-};
-
-NTSTATUS vfs_gpfs_hsm_notify_init(void);
-NTSTATUS vfs_gpfs_hsm_notify_init(void)
-{
-       return smb_register_vfs(SMB_VFS_INTERFACE_VERSION, "gpfs_hsm_notify",
-                               &vfs_gpfs_hsm_notify_fns);
-}
index 40432920697d825a24135d74e3ed6625bfbbb7f5..eccbfadcd0aa90c35e5c59da8f8273101b1fd9cb 100644 (file)
@@ -31,7 +31,6 @@ VFS_CACHEPRIME_SRC = 'vfs_cacheprime.c'
 VFS_PREALLOC_SRC = 'vfs_prealloc.c'
 VFS_COMMIT_SRC = 'vfs_commit.c'
 VFS_GPFS_SRC = 'vfs_gpfs.c gpfs.c'
-VFS_GPFS_HSM_NOTIFY_SRC = 'vfs_gpfs_hsm_notify.c'
 VFS_NOTIFY_FAM_SRC = 'vfs_notify_fam.c'
 VFS_READAHEAD_SRC = 'vfs_readahead.c'
 VFS_TSMSM_SRC = 'vfs_tsmsm.c'
@@ -317,13 +316,6 @@ bld.SAMBA3_MODULE('vfs_gpfs',
                  internal_module=bld.SAMBA3_IS_STATIC_MODULE('vfs_gpfs'),
                  enabled=bld.SAMBA3_IS_ENABLED_MODULE('vfs_gpfs'))
 
-bld.SAMBA3_MODULE('vfs_gpfs_hsm_notify',
-                 subsystem='vfs',
-                 source=VFS_GPFS_HSM_NOTIFY_SRC,
-                 init_function='',
-                 internal_module=bld.SAMBA3_IS_STATIC_MODULE('vfs_gpfs_hsm_notify'),
-                 enabled=bld.SAMBA3_IS_ENABLED_MODULE('vfs_gpfs_hsm_notify'))
-
 bld.SAMBA3_MODULE('vfs_notify_fam',
                  subsystem='vfs',
                  source=VFS_NOTIFY_FAM_SRC,
index 9b059fa1b37403cd126f20a227e82c9a22889f0f..c807ddcfc9169b4f7dbdb00ac855b7a054b6c8e1 100755 (executable)
@@ -1507,7 +1507,7 @@ main() {
         default_static_modules.extend(TO_LIST('charset_macosxfs'))
 
     if conf.CONFIG_SET('HAVE_GPFS'):
-        default_shared_modules.extend(TO_LIST('vfs_gpfs vfs_gpfs_hsm_notify'))
+       default_shared_modules.extend(TO_LIST('vfs_gpfs'))
 
     explicit_shared_modules = TO_LIST(Options.options.shared_modules, delimiter=',')
     explicit_static_modules = TO_LIST(Options.options.static_modules, delimiter=',')