summaryrefslogtreecommitdiffstats
path: root/source3/modules
Commit message (Collapse)AuthorAgeFilesLines
* s3/vfs: change fallocate mode flags from enum->uint32_tDavid Disseldorp2015-03-098-18/+16
| | | | | | | | | | | | | | | | | | | | The Linux fallocate syscall offers a mode parameter which can take the following flags: FALLOC_FL_KEEP_SIZE FALLOC_FL_PUNCH_HOLE (since 2.6.38) FALLOC_FL_COLLAPSE_RANGE (since 3.15) FALLOC_FL_ZERO_RANGE (since 3.14) The flags are not exclusive, e.g. FALLOC_FL_PUNCH_HOLE must be specified alongside FALLOC_FL_KEEP_SIZE. Samba currently takes a vfs_fallocate_mode enum parameter for the VFS fallocate hook, taking either an EXTEND_SIZE or KEEP_SIZE value. This commit changes the fallocate hook such that it accepts a uint32_t flags parameter, in preparation for PUNCH_HOLE and ZERO_RANGE support. Signed-off-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* vfs_fruit: Fix CID 1273290 Uninitialized scalar variableVolker Lendecke2015-03-061-1/+2
| | | | | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Ralph Boehme <slow@samba.org> Autobuild-User(master): Volker Lendecke <vl@samba.org> Autobuild-Date(master): Fri Mar 6 23:56:36 CET 2015 on sn-devel-104
* perfcount: Fix CID 1035494 Out-of-bounds readVolker Lendecke2015-03-051-1/+1
| | | | | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Ira Cooper <ira@samba.org> Autobuild-User(master): Ira Cooper <ira@samba.org> Autobuild-Date(master): Thu Mar 5 18:28:44 CET 2015 on sn-devel-104
* perfcount: Fix CID 1035493 Out-of-bounds readVolker Lendecke2015-03-051-1/+1
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Ira Cooper <ira@samba.org>
* perfcount: Fix CID 1035492 Out-of-bounds readVolker Lendecke2015-03-051-1/+1
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Ira Cooper <ira@samba.org>
* perfcount: Fix CID 1274043 Division or modulo by zeroVolker Lendecke2015-03-051-0/+4
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Ira Cooper <ira@samba.org>
* aio_fork: Fix CID 1273291 Uninitialized scalar variableVolker Lendecke2015-03-031-3/+1
| | | | | | | The previous code left msg.msg_flags uninitialized Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Ralph Boehme <slow@samba.org>
* gpfs: Add include guard to gpfswrap.hChristof Schmitt2015-03-031-0/+5
| | | | | | | | Signed-off-by: Christof Schmitt <cs@samba.org> Reviewed-by: Ralph Böhme <slow@samba.org> Autobuild-User(master): Christof Schmitt <cs@samba.org> Autobuild-Date(master): Tue Mar 3 01:01:25 CET 2015 on sn-devel-104
* gpfs: Rename library wrapper to gpfswrapChristof Schmitt2015-03-024-3/+3
| | | | | | | | | The code in gpfs.c and vfs_gpfs.h now only wraps the gpfs library. Rename the files to gpfswrap to make it clear that this is the only purpose of that file. Signed-off-by: Christof Schmitt <cs@samba.org> Reviewed-by: Ralph Böhme <slow@samba.org>
* gpfs: Update file headersChristof Schmitt2015-03-023-45/+43
| | | | | | | | Update file headers to reflect the new code organization and reformat for consistency. Signed-off-by: Christof Schmitt <cs@samba.org> Reviewed-by: Ralph Böhme <slow@samba.org>
* gpfs: Remove unncessary includes from gpfs.cChristof Schmitt2015-03-021-5/+1
| | | | | | | replace.h provides everything that is required (errno and ENOSYS). Signed-off-by: Christof Schmitt <cs@samba.org> Reviewed-by: Ralph Böhme <slow@samba.org>
* gpfs: Move DBGC_CLASS definition below includesChristof Schmitt2015-03-021-4/+3
| | | | | Signed-off-by: Christof Schmitt <cs@samba.org> Reviewed-by: Ralph Böhme <slow@samba.org>
* gpfs: Include gpfs_fcntl.h only from vfs_gpfs header fileChristof Schmitt2015-03-023-2/+2
| | | | | Signed-off-by: Christof Schmitt <cs@samba.org> Reviewed-by: Ralph Böhme <slow@samba.org>
* gpfs: Move definition of GPFS_GETACL_NATIVE to vfs_gpfs.cChristof Schmitt2015-03-022-4/+4
| | | | | Signed-off-by: Christof Schmitt <cs@samba.org> Reviewed-by: Ralph Böhme <slow@samba.org>
* gpfs: Move smbd_gpfs_set_times_path to vfs_gpfs.cChristof Schmitt2015-03-023-39/+38
| | | | | Signed-off-by: Christof Schmitt <cs@samba.org> Reviewed-by: Ralph Böhme <slow@samba.org>
* gpfs: Move get_gpfs_fset_id to vfs_gpfs.cChristof Schmitt2015-03-023-45/+44
| | | | | Signed-off-by: Christof Schmitt <cs@samba.org> Reviewed-by: Ralph Böhme <slow@samba.org>
* gpfs: Move get_gpfs_quota to vfs_gpfs.cChristof Schmitt2015-03-023-29/+27
| | | | | Signed-off-by: Christof Schmitt <cs@samba.org> Reviewed-by: Ralph Böhme <slow@samba.org>
* gpfs: Move set_gpfs_lease to vfs_gpfs.cChristof Schmitt2015-03-023-21/+20
| | | | | Signed-off-by: Christof Schmitt <cs@samba.org> Reviewed-by: Ralph Böhme <slow@samba.org>
* gpfs: Move set_gpfs_sharemode to vfs_gpfs.cChristof Schmitt2015-03-023-48/+46
| | | | | Signed-off-by: Christof Schmitt <cs@samba.org> Reviewed-by: Ralph Böhme <slow@samba.org>
* gpfs: Introduce wrapper for gpfs_getfilesetidChristof Schmitt2015-03-022-9/+15
| | | | | Signed-off-by: Christof Schmitt <cs@samba.org> Reviewed-by: Ralph Böhme <slow@samba.org>
* gpfs: Introduce wrapper for gpfs_fcntlChristof Schmitt2015-03-022-5/+18
| | | | | Signed-off-by: Christof Schmitt <cs@samba.org> Reviewed-by: Ralph Böhme <slow@samba.org>
* gpfs: Introduce wrapper for gpfs_quotactlChristof Schmitt2015-03-022-9/+15
| | | | | Signed-off-by: Christof Schmitt <cs@samba.org> Reviewed-by: Ralph Böhme <slow@samba.org>
* gpfs: Introduce wrapper for gpfs_set_times_pathChristof Schmitt2015-03-022-7/+15
| | | | | Signed-off-by: Christof Schmitt <cs@samba.org> Reviewed-by: Ralph Böhme <slow@samba.org>
* gpfs: Rename wrapper for gpfs_lib_initChristof Schmitt2015-03-023-14/+12
| | | | | Signed-off-by: Christof Schmitt <cs@samba.org> Reviewed-by: Ralph Böhme <slow@samba.org>
* gpfs: Rename wrapper for gpfs_ftruncateChristof Schmitt2015-03-023-12/+12
| | | | | Signed-off-by: Christof Schmitt <cs@samba.org> Reviewed-by: Ralph Böhme <slow@samba.org>
* gpfs: Rename wrapper for gpfs_preallocChristof Schmitt2015-03-023-13/+13
| | | | | Signed-off-by: Christof Schmitt <cs@samba.org> Reviewed-by: Ralph Böhme <slow@samba.org>
* gpfs: Rename wrapper for gpfs_get_winattrsChristof Schmitt2015-03-023-12/+12
| | | | | Signed-off-by: Christof Schmitt <cs@samba.org> Reviewed-by: Ralph Böhme <slow@samba.org>
* gpfs: Rename wrapper for gpfs_get_winattrs_pathChristof Schmitt2015-03-023-16/+17
| | | | | Signed-off-by: Christof Schmitt <cs@samba.org> Reviewed-by: Ralph Böhme <slow@samba.org>
* gpfs: Rename wrapper for gpfs_set_winattrs_pathChristof Schmitt2015-03-023-17/+20
| | | | | Signed-off-by: Christof Schmitt <cs@samba.org> Reviewed-by: Ralph Böhme <slow@samba.org>
* gpfs: Rename wrapper for gpfs_get_realfilename_pathChristof Schmitt2015-03-023-16/+14
| | | | | Signed-off-by: Christof Schmitt <cs@samba.org> Reviewed-by: Ralph Böhme <slow@samba.org>
* gpfs: Rename wrapper for gpfs_putaclChristof Schmitt2015-03-023-18/+18
| | | | | Signed-off-by: Christof Schmitt <cs@samba.org> Reviewed-by: Ralph Böhme <slow@samba.org>
* gpfs: Rename wrapper for gpfs_getaclChristof Schmitt2015-03-023-12/+12
| | | | | Signed-off-by: Christof Schmitt <cs@samba.org> Reviewed-by: Ralph Böhme <slow@samba.org>
* gpfs: Introduce wrapper for gpfs_set_leaseChristof Schmitt2015-03-022-7/+13
| | | | | Signed-off-by: Christof Schmitt <cs@samba.org> Reviewed-by: Ralph Böhme <slow@samba.org>
* gpfs: Introduce wrapper for gpfs_set_shareChristof Schmitt2015-03-022-7/+15
| | | | | Signed-off-by: Christof Schmitt <cs@samba.org> Reviewed-by: Ralph Böhme <slow@samba.org>
* gpfs: Simplify initialization for gpfs library wrapperChristof Schmitt2015-03-023-66/+39
| | | | | | | Merge the code for initializing the function pointers in one function. Signed-off-by: Christof Schmitt <cs@samba.org> Reviewed-by: Ralph Böhme <slow@samba.org>
* gpfs: Remove search for libgpfs_gpl.soChristof Schmitt2015-03-021-10/+2
| | | | | | | | Similar to the header files, libgpfs_gpl.so no longer exists. The library is now always called libgpfs.so. Signed-off-by: Christof Schmitt <cs@samba.org> Reviewed-by: Ralph Böhme <slow@samba.org>
* gpfs: Look for gpfs header files also in /usr/lpp/mmfs/include/Christof Schmitt2015-03-021-1/+2
| | | | | | | That is the default directory for the gpfs header files. Signed-off-by: Christof Schmitt <cs@samba.org> Reviewed-by: Ralph Böhme <slow@samba.org>
* gpfs: Always use gpfs_fcntl.h headerfileChristof Schmitt2015-03-022-3/+2
| | | | | | | | | gpfs_gpl.h no longer exists, everything from that header file has been merged to gpfs.h. gpfs_fcntl.h implicitly includes gpfs.h. Simplify the code by only looking for gpfs_fcntl.h and including that file. Signed-off-by: Christof Schmitt <cs@samba.org> Reviewed-by: Ralph Böhme <slow@samba.org>
* vfs_catia: Simplify init_mappings()Volker Lendecke2015-02-261-1/+2
| | | | | | | | | | No else required after return Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Thu Feb 26 21:22:30 CET 2015 on sn-devel-104
* s3/vfs: remove unused SMB_VFS_DISK_FREE() small_query parameterDavid Disseldorp2015-02-179-42/+33
| | | | | | | | | | | | | | | The small_query parameter for SMB_VFS_DISK_FREE() was, prior to the previous commit, used to obtain 16-bit wide free-space information for the deprecated dskattr SMB_COM_QUERY_INFORMATION_DISK command. With the dskattr handler now performing the 16-bit collapse directly, the small_query parameter can be removed from the entire code path. Signed-off-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Tue Feb 17 05:37:20 CET 2015 on sn-devel-104
* vfs_ceph: fix disk_free_fn callbackYan, Zheng2015-02-161-2/+3
| | | | | | | | | | | | Free space and available space should be in unit of block size. Besides, we should call disk_norm() to adjust the returned values. Signed-off-by: Yan, Zheng <zyan@redhat.com> Reviewed-by: Ira Cooper <ira@samba.org> Reviewed-by: David Disseldorp <ddiss@samba.org> Autobuild-User(master): Ira Cooper <ira@samba.org> Autobuild-Date(master): Mon Feb 16 18:14:02 CET 2015 on sn-devel-104
* vfs_prealloc: Remove call to gpfs_preallocChristof Schmitt2015-02-111-9/+0
| | | | | | | | | | | | | | | Calling gpfs_prealloc changes the actual size of the file, and this should not be done implicitly. Also this code does not compile due to the missing dependency to the gpfs library. The best way solution here is probably removing the call to gpfs_prealloc. The vfs_gpfs module already implements the call to gpfs_prelloc when this can be done safely. Signed-off-by: Christof Schmitt <cs@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Wed Feb 11 02:03:09 CET 2015 on sn-devel-104
* nfs4: Fix a confusing debug messageVolker Lendecke2015-02-091-1/+1
| | | | | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Ralph Boehme <slow@samba.org> Autobuild-User(master): Ralph Böhme <slow@samba.org> Autobuild-Date(master): Mon Feb 9 12:25:06 CET 2015 on sn-devel-104
* Fix a couple of DEBUG statements that were copied from elsewhere. Removed ↵Richard Sharpe2015-01-251-4/+2
| | | | | | | | | | the misleading function name since the DEBUG message will print out the function name anyway. Signed-of-by: Richard Sharpe <rsharpe@samba.org> Reviewed-by: Volker Lendecke <vl@samba.org> Autobuild-User(master): Volker Lendecke <vl@samba.org> Autobuild-Date(master): Sun Jan 25 12:58:08 CET 2015 on sn-devel-104
* vfs_glusterfs: Add comments to the pipe(2) code.Ira Cooper2015-01-231-0/+17
| | | | | | | | | | | The guarantees around read(2) and write(2) and pipes are critical to understanding this code. Hopefully these comments will help. Signed-off-by: Ira Cooper <ira@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Fri Jan 23 20:58:51 CET 2015 on sn-devel-104
* vfs: Fix a typoVolker Lendecke2015-01-221-1/+1
| | | | | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org> Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org> Autobuild-Date(master): Thu Jan 22 13:14:38 CET 2015 on sn-devel-104
* vfs:glusterfs: whitespace fix.Michael Adam2015-01-221-3/+3
| | | | | | | | Signed-off-by: Michael Adam <obnox@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Thu Jan 22 03:20:17 CET 2015 on sn-devel-104
* vfs_snapper: encode and decode Snapper DBus stringsDavid Disseldorp2015-01-221-16/+94
| | | | | | | | | | | | Snapper uses a special character encoding for strings used in DBus requests and responses. This change ensures that Samba packs and unpacks strings in the corresponding format, using the previously added encode/decode helper functions. Bug: https://bugzilla.samba.org/show_bug.cgi?id=11055 Signed-off-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* vfs_snapper: add DBus string encoding and decoding helpersDavid Disseldorp2015-01-221-0/+124
| | | | | | | | | | | | | | Snapper uses the following mechanism for encoding and decoding strings used in DBus traffic: Characters above 127 (0x7F - ASCII DEL) must be encoded hexadecimal as "\x??". As a consequence "\" must be encoded as "\\". This change adds string encoding and decoding helpers to vfs_snapper. Bug: https://bugzilla.samba.org/show_bug.cgi?id=11055 Signed-off-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* vfs_snapper: free dbus req messages in error pathsDavid Disseldorp2015-01-221-0/+4
| | | | | | | Bug: https://bugzilla.samba.org/show_bug.cgi?id=11055 Signed-off-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>