aboutsummaryrefslogtreecommitdiff
path: root/fs/ntfs
AgeCommit message (Collapse)Author
2006-03-26[PATCH] bitops: ntfs: remove generic_ffs()Akinobu Mita
Now the only user who are using generic_ffs() is ntfs filesystem. This patch isolates generic_ffs() as ntfs_ffs() for ntfs. Signed-off-by: Akinobu Mita <mita@miraclelinux.com> Cc: Anton Altaparmakov <aia21@cantab.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-24[PATCH] cpuset memory spread: slab cache filesystemsPaul Jackson
Mark file system inode and similar slab caches subject to SLAB_MEM_SPREAD memory spreading. If a slab cache is marked SLAB_MEM_SPREAD, then anytime that a task that's in a cpuset with the 'memory_spread_slab' option enabled goes to allocate from such a slab cache, the allocations are spread evenly over all the memory nodes (task->mems_allowed) allowed to that task, instead of favoring allocation on the node local to the current cpu. The following inode and similar caches are marked SLAB_MEM_SPREAD: file cache ==== ===== fs/adfs/super.c adfs_inode_cache fs/affs/super.c affs_inode_cache fs/befs/linuxvfs.c befs_inode_cache fs/bfs/inode.c bfs_inode_cache fs/block_dev.c bdev_cache fs/cifs/cifsfs.c cifs_inode_cache fs/coda/inode.c coda_inode_cache fs/dquot.c dquot fs/efs/super.c efs_inode_cache fs/ext2/super.c ext2_inode_cache fs/ext2/xattr.c (fs/mbcache.c) ext2_xattr fs/ext3/super.c ext3_inode_cache fs/ext3/xattr.c (fs/mbcache.c) ext3_xattr fs/fat/cache.c fat_cache fs/fat/inode.c fat_inode_cache fs/freevxfs/vxfs_super.c vxfs_inode fs/hpfs/super.c hpfs_inode_cache fs/isofs/inode.c isofs_inode_cache fs/jffs/inode-v23.c jffs_fm fs/jffs2/super.c jffs2_i fs/jfs/super.c jfs_ip fs/minix/inode.c minix_inode_cache fs/ncpfs/inode.c ncp_inode_cache fs/nfs/direct.c nfs_direct_cache fs/nfs/inode.c nfs_inode_cache fs/ntfs/super.c ntfs_big_inode_cache_name fs/ntfs/super.c ntfs_inode_cache fs/ocfs2/dlm/dlmfs.c dlmfs_inode_cache fs/ocfs2/super.c ocfs2_inode_cache fs/proc/inode.c proc_inode_cache fs/qnx4/inode.c qnx4_inode_cache fs/reiserfs/super.c reiser_inode_cache fs/romfs/inode.c romfs_inode_cache fs/smbfs/inode.c smb_inode_cache fs/sysv/inode.c sysv_inode_cache fs/udf/super.c udf_inode_cache fs/ufs/super.c ufs_inode_cache net/socket.c sock_inode_cache net/sunrpc/rpc_pipe.c rpc_inode_cache The choice of which slab caches to so mark was quite simple. I marked those already marked SLAB_RECLAIM_ACCOUNT, except for fs/xfs, dentry_cache, inode_cache, and buffer_head, which were marked in a previous patch. Even though SLAB_RECLAIM_ACCOUNT is for a different purpose, it marks the same potentially large file system i/o related slab caches as we need for memory spreading. Given that the rule now becomes "wherever you would have used a SLAB_RECLAIM_ACCOUNT slab cache flag before (usually the inode cache), use the SLAB_MEM_SPREAD flag too", this should be easy enough to maintain. Future file system writers will just copy one of the existing file system slab cache setups and tend to get it right without thinking. Signed-off-by: Paul Jackson <pj@sgi.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-23NTFS: 2.1.27 - Various bug fixes and cleanups.Anton Altaparmakov
Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2006-03-23NTFS: Semaphore to mutex conversion.Ingo Molnar
The conversion was generated via scripts, and the result was validated automatically via a script as well. Signed-off-by: Ingo Molnar <mingo@elte.hu> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2006-03-23NTFS: Handle the recently introduced -ENAMETOOLONG return value fromAnton Altaparmakov
fs/ntfs/unistr.c::ntfs_nlstoucs() in fs/ntfs/namei.c::ntfs_lookup(). Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2006-03-23NTFS: Add a missing call to flush_dcache_mft_record_page() inAnton Altaparmakov
fs/ntfs/inode.c::ntfs_write_inode(). Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2006-03-23NTFS: Fix a bug in fs/ntfs/inode.c::ntfs_read_locked_index_inode() where weAnton Altaparmakov
forgot to update a temporary variable so loading index inodes which have an index allocation attribute failed. Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2006-03-23NTFS: Improve comments on file attribute flags in fs/ntfs/layout.h.Anton Altaparmakov
Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2006-03-23NTFS: Limit name length in fs/ntfs/unistr.c::ntfs_nlstoucs() to maximumAnton Altaparmakov
allowed by NTFS, i.e. 255 Unicode characters, not including the terminating NULL (which is not stored on disk). Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2006-03-23NTFS: Remove all the make_bad_inode() calls. This should only be calledAnton Altaparmakov
from read inode and new inode code paths. Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2006-03-23NTFS: Add support for sparse files which have a compression unit of 0.Anton Altaparmakov
Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2006-03-23NTFS: Fix comparison of $MFT and $MFTMirr to not bail out when there areAnton Altaparmakov
unused, invalid mft records which are the same in both $MFT and $MFTMirr. Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2006-03-23NTFS: Use buffer_migrate_page() for the ->migratepage function of all ntfsAnton Altaparmakov
address space operations. Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2006-03-23NTFS: Fix a buggette in an "should be impossible" case handling where weAnton Altaparmakov
continued the attribute lookup loop instead of aborting it. Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2006-03-23NTFS: Fix an (innocent) off-by-one error in the runlist code.Anton Altaparmakov
Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2006-03-07NTFS: Fix two compiler warnings on Alpha. Thanks to Andrew Morton forAnton Altaparmakov
reporting them. Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2006-02-24NTFS: Do more detailed reporting of why we cannot mount read-write byAnton Altaparmakov
special casing the VOLUME_MODIFIED_BY_CHKDSK flag. Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2006-02-24NTFS: Implement support for sector sizes above 512 bytes (up to the maximumAnton Altaparmakov
supported by NTFS which is 4096 bytes).
2006-02-24Merge ../ntfs-2.6-develAnton Altaparmakov
2006-02-24NTFS: - Cope with attribute list attribute having invalid flags.Anton Altaparmakov
Windows copes with this and even chkdsk does not detect or fix this so we have to cope with it, too. Thanks to Pawel Kot for reporting the problem. - Miscellaneous updates to layout.h. Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2006-02-05NTFS: We have struct kmem_cache now so use it instead of the typedef.Pekka Enberg
Signed-off-by: Pekka Enberg <penberg@cs.helsinki.fi> Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2006-01-19Merge branch 'master' of /usr/src/ntfs-2.6/Anton Altaparmakov
2006-01-10[PATCH] ntfs: remove superflous MS_NOATIME/MS_NODIRATIME assignmentsChristoph Hellwig
MS_RDONLU implies not atime updates at all, no need for the MS_NOATIME and MS_NODIRATIME flags. Signed-off-by: Christoph Hellwig <hch@lst.de> Cc: Anton Altaparmakov <aia21@cantab.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-01-10[PATCH] replace inode_update_time with file_update_timeChristoph Hellwig
To allow various options to work per-mount instead of per-sb we need a struct vfsmount when updating ctime and mtime. This preparation patch replaces the inode_update_time routine with a file_update_atime routine so we can easily get at the vfsmount. (and the file makes more sense in this context anyway). Also get rid of the unused second argument - we always want to update the ctime when calling this routine. Signed-off-by: Christoph Hellwig <hch@lst.de> Cc: Al Viro <viro@ftp.linux.org.uk> Cc: Anton Altaparmakov <aia21@cantab.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-01-09[PATCH] mutex subsystem, semaphore to mutex: VFS, ->i_semJes Sorensen
This patch converts the inode semaphore to a mutex. I have tested it on XFS and compiled as much as one can consider on an ia64. Anyway your luck with it might be different. Modified-by: Ingo Molnar <mingo@elte.hu> (finished the conversion) Signed-off-by: Jes Sorensen <jes@sgi.com> Signed-off-by: Ingo Molnar <mingo@elte.hu>
2006-01-03update the email address of Randy DunlapAdrian Bunk
This patch removes all references to the bouncing address rddunlap@osdl.org and one dead web page from the kernel. Signed-off-by: Adrian Bunk <bunk@stusta.de> Acked-by: Randy Dunlap <rdunlap@xenotime.net>
2005-11-24NTFS: Fix a potential overflow by casting (index + 1) to s64 before doing aAnton Altaparmakov
left shift using PAGE_CACHE_SHIFT in fs/ntfs/file.c. Thanks to Andrew Morton pointing this out to. Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2005-11-01NTFS: Fix a stupid bug causing writes to non-initialized pages to segfault.Anton Altaparmakov
Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2005-10-24NTFS: Document extended attribute ($EA) NEED_EA flag. (Based on libntfsAnton Altaparmakov
patch by Yura Pakhuchiy.) Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2005-10-24NTFS: Fix compilation warnings with gcc-4.0.2 on SUSE 10.0.Anton Altaparmakov
Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2005-10-24NTFS: Use %z for size_t to fix compilation warnings. (Andrew Morton)Anton Altaparmakov
Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2005-10-19NTFS: Fix serious data corruption issue when writing.Anton Altaparmakov
Many thanks to Alberto Patino for testing and reporting the data corruption. And many apologies for corrupting his partition. Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2005-10-19NTFS: $EA attributes can be both resident non-resident.Anton Altaparmakov
Minor tidying. Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2005-10-11NTFS: The big ntfs write(2) rewrite has arrived. We now implement our ownAnton Altaparmakov
file operations ->write(), ->aio_write(), and ->writev() for regular files. This replaces the old use of generic_file_write(), et al and the address space operations ->prepare_write and ->commit_write. This means that both sparse and non-sparse (unencrypted and uncompressed) files can now be extended using the normal write(2) code path. There are two limitations at present and these are that we never create sparse files and that we only have limited support for highly fragmented files, i.e. ones whose data attribute is split across multiple extents. When such a case is encountered, EOPNOTSUPP is returned. Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2005-10-11NTFS: Remove address space operations ->prepare_write and ->commit_write inAnton Altaparmakov
preparation for the big rewrite of write(2) support in ntfs. Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2005-10-11NTFS: In attrib.c::ntfs_attr_set() call balance_dirty_pages_ratelimited()Anton Altaparmakov
and cond_resched() in the main loop as we could be dirtying a lot of pages and this ensures we play nice with the VM and the system as a whole. Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2005-10-11Merge branch 'master' of /usr/src/ntfs-2.6/Anton Altaparmakov
2005-10-08[PATCH] gfp flags annotations - part 1Al Viro
- added typedef unsigned int __nocast gfp_t; - replaced __nocast uses for gfp flags with gfp_t - it gives exactly the same warnings as far as sparse is concerned, doesn't change generated code (from gcc point of view we replaced unsigned int with typedef) and documents what's going on far better. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-04NTFS: Enable ATTR_SIZE attribute changes in ntfs_setattr(). This completesAnton Altaparmakov
the initial implementation of file truncation. Now both open(2)ing a file with the O_TRUNC flag and the {,f}truncate(2) system calls will resize a file appropriately. The limitations are that only uncompressed and unencrypted files are supported. Also, there is only very limited support for highly fragmented files (the ones whose $DATA attribute is split into multiple attribute extents). Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2005-10-04NTFS: Implement fs/ntfs/inode.[hc]::ntfs_truncate(). It only supportsAnton Altaparmakov
uncompressed and unencrypted files. Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2005-10-04NTFS: Add fs/ntfs/attrib.[hc]::ntfs_attr_extend_allocation(), a function toAnton Altaparmakov
extend the allocation of an attributes. Optionally, the data size, but not the initialized size can be extended, too. Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2005-10-04NTFS: Fix ntfs_attr_make_non_resident() to update the vfs inode i_blocksAnton Altaparmakov
which is zero for a resident attribute but should no longer be zero once the attribute is non-resident as it then has real clusters allocated. Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2005-10-04NTFS: Change ntfs_attr_make_non_resident to take the attribute value sizeAnton Altaparmakov
as an extra parameter. This is needed since we need to know the size before we can map the mft record and our callers always know it. The reason we cannot simply read the size from the vfs inode i_size is that this is not necessarily uptodate. This happens when ntfs_attr_make_non_resident() is called in the ->truncate call path. Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2005-10-04NTFS: - Change ntfs_cluster_alloc() to take an extra boolean parameterAnton Altaparmakov
specifying whether the cluster are being allocated to extend an attribute or to fill a hole. - Change ntfs_attr_make_non_resident() to call ntfs_cluster_alloc() with @is_extension set to TRUE and remove the runlist terminator fixup code as this is now done by ntfs_cluster_alloc(). Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2005-10-04NTFS: - Change {__,}ntfs_cluster_free() to also take an optional attributeAnton Altaparmakov
search context as argument. This allows calling it with the mft record mapped. Update all callers. - Fix potential deadlock in ntfs_mft_data_extend_allocation_nolock() error handling by passing in the active search context when calling ntfs_cluster_free(). Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2005-10-04NTFS: Change ntfs_attr_find_vcn_nolock() to also take an optional attributeAnton Altaparmakov
search context as argument. This allows calling it with the mft record mapped. Update all callers. Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2005-10-04NTFS: Change ntfs_map_runlist_nolock() to also take an optional attributeAnton Altaparmakov
search context. This allows calling it with the mft record mapped. Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2005-10-04NTFS: Fix a 64-bitness bug where a left-shift could overflow a 32-bit variableAnton Altaparmakov
which we now cast to 64-bit first (fs/ntfs/mft.c::map_mft_record_page(). Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2005-10-04NTFS: Fix a stupid bug in __ntfs_bitmap_set_bits_in_run() which caused theAnton Altaparmakov
count to become negative and hence we had a wild memset() scribbling all over the system's ram. Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
2005-09-26NTFS: Re-fix sparse warnings in a more correct way, i.e. don't use an enum withAnton Altaparmakov
different types in it but #define the two constants instead. Signed-off-by: Anton Altaparmakov <aia21@cantab.net>