summaryrefslogtreecommitdiffstats
path: root/fs
Commit message (Collapse)AuthorAgeFilesLines
* jffs2: remove unnecessary GC pass on umountArtem Bityutskiy2012-05-301-3/+0
| | | | | | | | | | | | | | | We do not need to call 'jffs2_write_super()' on unmount. This function causes a GC pass to make sure the current contents is pushed out with the data which we already have on the media. But this is not needed on unmount and only slows unmount down unnecessarily. It is enough to just sync the write-buffer. This call was added by one of the generic VFS rework patch-sets, see 8c85e125124a473d6f3e9bb187b0b84207f81d91. Signed-off-by: Artem Bityutskiy <artem.bityutskiy@linux.intel.com> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* jffs2: remove lock_superArtem Bityutskiy2012-05-301-3/+0
| | | | | | | We do not need 'lock_super()'/'unlock_super()' in JFFS2 - kill them. Signed-off-by: Artem Bityutskiy <artem.bityutskiy@linux.intel.com> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* get rid of idiotic misplaced __kernel_mode_t in ncfps kernel-private data ↵Al Viro2012-05-291-5/+5
| | | | | | structure Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* brlocks/lglocks: API cleanupsAndi Kleen2012-05-296-95/+96
| | | | | | | | | | | | | | | | | | | | | lglocks and brlocks are currently generated with some complicated macros in lglock.h. But there's no reason to not just use common utility functions and put all the data into a common data structure. In preparation, this patch changes the API to look more like normal function calls with pointers, not magic macros. The patch is rather large because I move over all users in one go to keep it bisectable. This impacts the VFS somewhat in terms of lines changed. But no actual behaviour change. [akpm@linux-foundation.org: checkpatch fixes] Signed-off-by: Andi Kleen <ak@linux.intel.com> Cc: Al Viro <viro@zeniv.linux.org.uk> Cc: Rusty Russell <rusty@rustcorp.com.au> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* brlocks/lglocks: turn into functionsAndi Kleen2012-05-292-2/+1
| | | | | | | | | | | | | | | | | | | | | lglocks and brlocks are currently generated with some complicated macros in lglock.h. But there's no reason to not just use common utility functions and put all the data into a common data structure. Since there are at least two users it makes sense to share this code in a library. This is also easier maintainable than a macro forest. This will also make it later possible to dynamically allocate lglocks and also use them in modules (this would both still need some additional, but now straightforward, code) [akpm@linux-foundation.org: checkpatch fixes] Signed-off-by: Andi Kleen <ak@linux.intel.com> Cc: Al Viro <viro@zeniv.linux.org.uk> Cc: Rusty Russell <rusty@rustcorp.com.au> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* ocfs: simplify symlink handlingAl Viro2012-05-294-104/+31
| | | | | | | | seeing that "fast" symlinks still get allocation + copy, we might as well simply switch them to pagecache-based variant of ->follow_link(); just need an appropriate ->readpage() for them... Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* get rid of pointless allocations and copying in ecryptfs_follow_link()Al Viro2012-05-291-39/+9
| | | | | | switch to generic_readlink(), while we are at it Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* hpfs: assorted endianness annotationsAl Viro2012-05-294-60/+60
| | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* hpfs: annotate eaAl Viro2012-05-291-2/+2
| | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* hpfs: annotate struct hpfs_direntAl Viro2012-05-293-12/+12
| | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* hpfs: annotate struct anodeAl Viro2012-05-291-4/+4
| | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* hpfs: annotate struct fnodeAl Viro2012-05-291-14/+14
| | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* hpfs: annotate btree nodes, get rid of bitfields messAl Viro2012-05-293-51/+52
| | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* hpfs: annotate struct dnodeAl Viro2012-05-291-4/+4
| | | | | | little-endians... Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* hpfs: bitmaps are little-endianAl Viro2012-05-293-12/+12
| | | | | | annotate properly... Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* hpfs: get rid of bitfields in struct fnodeAl Viro2012-05-298-38/+32
| | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* hpfs: get rid of bitfields endianness wanking in extended_attributeAl Viro2012-05-293-34/+35
| | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* fs: fix inode.c kernel-doc warningsRandy Dunlap2012-05-291-2/+1
| | | | | | | | | | | Fix kernel-doc warnings in fs/inode.c: Warning(fs/inode.c:1493): No description found for parameter 'path' Warning(fs/inode.c:1493): Excess function parameter 'mnt' description in 'touch_atime' Warning(fs/inode.c:1493): Excess function parameter 'dentry' description in 'touch_atime' Signed-off-by: Randy Dunlap <rdunlap@xenotime.net> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* hpfs: endianness bugsAl Viro2012-05-292-3/+3
| | | | | | | a couple of le32 and le16 used with wrong le..._to_cpu(), plus idiotic use of le32_to_cpu() on 1-bit bitfield Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* btrfs: trivial endianness annotationsAl Viro2012-05-293-7/+8
| | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* ocfs2: kill endianness abuses in blockcheck.cAl Viro2012-05-291-20/+22
| | | | | | | | ocfs2_block_check is for little-endian contents; if we just want to its fields converted to host-endian in a couple of functions, just put those values into local u32 and u16... Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* ocfs2: deal with __user misannotationsAl Viro2012-05-292-21/+16
| | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* ocfs2: trivial endianness misannotationsAl Viro2012-05-293-5/+5
| | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* affs: bury unused macrosAl Viro2012-05-291-8/+0
| | | | | | ... unused since 2.4.4. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* kill v9fs_dentry_from_dir_inode()Al Viro2012-05-291-21/+3
| | | | | | | In *all* callers we have a dentry of child of that directory. Just use ->d_parent of that one, for fsck sake... Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* ceph: move encode_fh to new APISage Weil2012-05-291-13/+21
| | | | | | | | | Use parent_inode has a flag for whether nfsd wants a connectable fh, but generate one opportunistically so that we can take advantage of the additional info in there. Signed-off-by: Sage Weil <sage@newdream.net> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* ->encode_fh() API changeAl Viro2012-05-2913-130/+88
| | | | | | | | | pass inode + parent's inode or NULL instead of dentry + bool saying whether we want the parent or not. NOTE: that needs ceph fix folded in. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* ubifs: use generic_fillattr()Al Viro2012-05-291-10/+1
| | | | | | don't open-code it... Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* xfs: switch to proper __bitwise type for KM_... flagsAl Viro2012-05-296-19/+20
| | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* switch utimes() to fget_light/fput_lightAl Viro2012-05-291-2/+3
| | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* switch statfs to fget_light/fput_lightAl Viro2012-05-291-2/+3
| | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* switch flock to fget_light/fput_lightAl Viro2012-05-291-2/+3
| | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* switch signalfd4() to fget_light/fput_lightAl Viro2012-05-291-3/+4
| | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* switch fcntl to fget_raw_light/fput_lightAl Viro2012-05-291-25/+17
| | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* switch xattr syscalls to fget_light/fput_lightAl Viro2012-05-291-8/+12
| | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* switch readdir/getdents to fget_light/fput_lightAl Viro2012-05-292-38/+28
| | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* switch do_fsync() to fget_light()Al Viro2012-05-291-2/+3
| | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* Merge branch 'for-next' of git://git.samba.org/sfrench/cifs-2.6Linus Torvalds2012-05-2917-587/+1039
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Pull CIFS updates from Steve French. * 'for-next' of git://git.samba.org/sfrench/cifs-2.6: (29 commits) cifs: fix oops while traversing open file list (try #4) cifs: Fix comment as d_alloc_root() is replaced by d_make_root() CIFS: Introduce SMB2 mounts as vers=2.1 CIFS: Introduce SMB2 Kconfig option CIFS: Move add/set_credits and get_credits_field to ops structure CIFS: Move protocol specific demultiplex thread calls to ops struct CIFS: Move protocol specific part from cifs_readv_receive to ops struct CIFS: Move header_size/max_header_size to ops structure CIFS: Move protocol specific part from SendReceive2 to ops struct cifs: Include backup intent search flags during searches {try #2) CIFS: Separate protocol specific part from setlk CIFS: Separate protocol specific part from getlk CIFS: Separate protocol specific lock type handling CIFS: Convert lock type to 32 bit variable CIFS: Move locks to cifsFileInfo structure cifs: convert send_nt_cancel into a version specific op cifs: add a smb_version_operations/values structures and a smb_version enum cifs: remove the vers= and version= synonyms for ver= cifs: add warning about change in default cache semantics in 3.7 cifs: display cache= option in /proc/mounts ...
| * cifs: fix oops while traversing open file list (try #4)Shirish Pargaonkar2012-05-232-24/+34
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | While traversing the linked list of open file handles, if the identfied file handle is invalid, a reopen is attempted and if it fails, we resume traversing where we stopped and cifs can oops while accessing invalid next element, for list might have changed. So mark the invalid file handle and attempt reopen if no valid file handle is found in rest of the list. If reopen fails, move the invalid file handle to the end of the list and start traversing the list again from the begining. Repeat this four times before giving up and returning an error if file reopen keeps failing. Cc: <stable@vger.kernel.org> Signed-off-by: Shirish Pargaonkar <shirishpargaonkar@gmail.com> Reviewed-by: Jeff Layton <jlayton@redhat.com> Signed-off-by: Steve French <sfrench@us.ibm.com>
| * cifs: Fix comment as d_alloc_root() is replaced by d_make_root()Sedat Dilek2012-05-231-1/+1
| | | | | | | | | | | | | | For more details see <file: Documentation/filesystems/porting>. Signed-off-by: Sedat Dilek <sedat.dilek@gmail.com> Signed-off-by: Steve French <sfrench@us.ibm.com>
| * CIFS: Introduce SMB2 mounts as vers=2.1Steve French2012-05-234-1/+41
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | As with Linux nfs client, which uses "nfsvers=" or "vers=" to indicate which protocol to use for mount, specifying "vers=2.1" will force an SMB2 mount. When vers is not specified CIFS is used "vers=1" We can eventually autonegotiate down from SMB2 to CIFS when SMB2 is stable enough to make it the default, but this is for the future. At that time we could also implement a "maxprotocol" mount option as smbclient and Samba have today, but that would be premature until SMB2 is stable. Intially the SMB2 Kconfig option will depend on "BROKEN" until the merge is complete, and then be "EXPERIMENTAL" When it is no longer experimental we can consider changing the default protocol to attempt first. Signed-off-by: Pavel Shilovsky <piastry@etersoft.ru> Signed-off-by: Jeff Layton <jlayton@redhat.com> Acked-by: Shirish Pargaonkar <shirishpargaonkar@gmail.com> Signed-off-by: Steve French <sfrench@us.ibm.com>
| * CIFS: Introduce SMB2 Kconfig optionSteve French2012-05-231-0/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | SMB2 is the followon to the CIFS (and SMB) protocols and the default for Windows since Windows Vista, and also now implemented by various non-Windows servers. SMB2 is more secure, has various performance advantages, including larger i/o sizes, flow control, better caching model and more. SMB2 also resolves some scalability limits in the CIFS protocol and adds many new features while being much simpler (only a few dozen commands instead of hundreds) and since the protocol is clearer it is also more consistently implemented across servers and thus easier to optimize. After much discussion with Jeff Layton, Jeremy Allison and others at Connectathon, we decided to move the SMB2 code from a distinct .ko and fstype into distinct C files that optionally build in cifs.ko. As a result the Kconfig gets simpler. To avoid destabilizing CIFS, the SMB2 code is going to be moved into its own experimental CONFIG_CIFS_SMB2 ifdef as it is merged and rereviewed. The changes to stable CIFS (builds with the SMB2 ifdef off) are expected to be fairly small. Reviewed-by: Jeff Layton <jlayton@redhat.com> Signed-off-by: Steve French <sfrench@us.ibm.com> Signed-off-by: Pavel Shilovsky <piastry@etersoft.ru> Signed-off-by: Steve French <sfrench@us.ibm.com>
| * CIFS: Move add/set_credits and get_credits_field to ops structurePavel Shilovsky2012-05-237-50/+62
| | | | | | | | | | | | | | Acked-by: Shirish Pargaonkar <shirishpargaonkar@gmail.com> Reviewed-by: Jeff Layton <jlayton@redhat.com> Signed-off-by: Pavel Shilovsky <piastry@etersoft.ru> Signed-off-by: Steve French <sfrench@us.ibm.com>
| * CIFS: Move protocol specific demultiplex thread calls to ops structPavel Shilovsky2012-05-235-27/+39
| | | | | | | | | | | | Acked-by: Shirish Pargaonkar <shirishpargaonkar@gmail.com> Signed-off-by: Pavel Shilovsky <piastry@etersoft.ru> Signed-off-by: Steve French <sfrench@us.ibm.com>
| * CIFS: Move protocol specific part from cifs_readv_receive to ops structPavel Shilovsky2012-05-233-27/+33
| | | | | | | | | | | | | | Acked-by: Shirish Pargaonkar <shirishpargaonkar@gmail.com> Reviewed-by: Jeff Layton <jlayton@redhat.com> Signed-off-by: Pavel Shilovsky <piastry@etersoft.ru> Signed-off-by: Steve French <sfrench@us.ibm.com>
| * CIFS: Move header_size/max_header_size to ops structurePavel Shilovsky2012-05-234-23/+20
| | | | | | | | | | | | | | Acked-by: Shirish Pargaonkar <shirishpargaonkar@gmail.com> Reviewed-by: Jeff Layton <jlayton@redhat.com> Signed-off-by: Pavel Shilovsky <piastry@etersoft.ru> Signed-off-by: Steve French <sfrench@us.ibm.com>
| * CIFS: Move protocol specific part from SendReceive2 to ops structPavel Shilovsky2012-05-234-3/+15
| | | | | | | | | | | | | | Acked-by: Shirish Pargaonkar <shirishpargaonkar@gmail.com> Reviewed-by: Jeff Layton <jlayton@redhat.com> Signed-off-by: Pavel Shilovsky <piastry@etersoft.ru> Signed-off-by: Steve French <sfrench@us.ibm.com>
| * cifs: Include backup intent search flags during searches {try #2)Shirish Pargaonkar2012-05-173-11/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | As observed and suggested by Tushar Gosavi... --------- readdir calls these function to send TRANS2_FIND_FIRST and TRANS2_FIND_NEXT command to the server. The current cifs module is not specifying CIFS_SEARCH_BACKUP_SEARCH flag while sending these command when backupuid/backupgid is specified. This can be resolved by specifying CIFS_SEARCH_BACKUP_SEARCH flag. --------- Cc: <stable@kernel.org> Reported-and-Tested-by: Tushar Gosavi <tugosavi@in.ibm.com> Signed-off-by: Shirish Pargaonkar <shirishpargaonkar@gmail.com> Acked-by: Jeff Layton <jlayton@redhat.com> Signed-off-by: Steve French <sfrench@us.ibm.com>
| * CIFS: Separate protocol specific part from setlkPavel Shilovsky2012-05-171-2/+2
| | | | | | | | Signed-off-by: Pavel Shilovsky <piastry@etersoft.ru>
| * CIFS: Separate protocol specific part from getlkPavel Shilovsky2012-05-173-22/+39
| | | | | | | | Signed-off-by: Pavel Shilovsky <piastry@etersoft.ru>