summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* configfs: remove unnecessary dentry_unhash on rmdir, dir renameSage Weil2011-05-281-2/+0
| | | | | | | | configfs does not have problems with references to unlinked directories. CC: Joel Becker <jlbec@evilplan.org> Signed-off-by: Sage Weil <sage@newdream.net> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* fat: remove unnecessary dentry_unhash on rmdir, dir renameSage Weil2011-05-282-10/+0
| | | | | | | | fat does not have problems with references to unlinked directories. CC: OGAWA Hirofumi <hirofumi@mail.parknet.co.jp> Signed-off-by: Sage Weil <sage@newdream.net> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* hpfs: remove unnecessary dentry_unhash on rmdir, dir renameSage Weil2011-05-281-5/+0
| | | | | | | | | | | | Hpfs has no problems with references to unlinked directories. We leave one dentry_unhash call in place, in hpfs_unlink's strange path where it tries to truncate a file because the disk is full. I'm not sure what the full story is there. CC: Mikulas Patocka <mikulas@artax.karlin.mff.cuni.cz> Signed-off-by: Sage Weil <sage@newdream.net> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* minix: remove unnecessary dentry_unhash on rmdir, dir renameSage Weil2011-05-281-5/+0
| | | | | | | Minix has no issues with references to unlinked directories. Signed-off-by: Sage Weil <sage@newdream.net> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* fuse: remove unnecessary dentry_unhash on rmdir, dir renameSage Weil2011-05-281-5/+0
| | | | | | | | | Fuse has no problems with references to unlinked directories. CC: Miklos Szeredi <miklos@szeredi.hu> CC: fuse-devel@lists.sourceforge.net Signed-off-by: Sage Weil <sage@newdream.net> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* coda: remove unnecessary dentry_unhash on rmdir, dir renameSage Weil2011-05-281-5/+0
| | | | | | | | | | Coda has no problems with references to unlinked directories. CC: Jan Harkes <jaharkes@cs.cmu.edu> CC: coda@cs.cmu.edu CC: codalist@coda.cs.cmu.edu Signed-off-by: Sage Weil <sage@newdream.net> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* afs: remove unnecessary dentry_unhash on rmdir, dir renameSage Weil2011-05-281-5/+0
| | | | | | | | | afs has no problems with references to unlinked directories. CC: David Howells <dhowells@redhat.com> CC: linux-afs@lists.infradead.org Signed-off-by: Sage Weil <sage@newdream.net> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* affs: remove unnecessary dentry_unhash on rmdir, dir renameSage Weil2011-05-281-5/+0
| | | | | | | affs has no problems with references to unlinked directories. Signed-off-by: Sage Weil <sage@newdream.net> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* 9p: remove unnecessary dentry_unhash on rmdir, dir renameSage Weil2011-05-281-4/+0
| | | | | | | | | | | 9p has no problems with references to unlinked directories. CC: Eric Van Hensbergen <ericvh@gmail.com> CC: Ron Minnich <rminnich@sandia.gov> CC: Latchesar Ionkov <lucho@ionkov.net> CC: v9fs-developer@lists.sourceforge.net Signed-off-by: Sage Weil <sage@newdream.net> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* ncpfs: fix rename over directory with dangling referencesSage Weil2011-05-281-1/+9
| | | | | | | | | | | ncpfs does not handle references to unlinked directories (or so it would seem given the ncp_rmdir check). Since it is also possible to rename over an empty directory, perform the same check here. CC: Petr Vandrovec <petr@vandrovec.name> CC: linux-kernel@vger.kernel.org Signed-off-by: Sage Weil <sage@newdream.net> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* ncpfs: document dentry_unhash usageSage Weil2011-05-281-1/+4
| | | | | | | | | | ncpfs returns EBUSY if there are any references to the directory. The dentry_unhash call only unhashes the dentry if there are no references. CC: Petr Vandrovec <petr@vandrovec.name> CC: linux-kernel@vger.kernel.org Signed-off-by: Sage Weil <sage@newdream.net> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* ecryptfs: remove unnecessary dentry_unhash on rmdir, dir renameSage Weil2011-05-281-5/+0
| | | | | | | | | | ecryptfs does not have problems with references to unlinked directories. CC: Tyler Hicks <tyhicks@linux.vnet.ibm.com> CC: Dustin Kirkland <kirkland@canonical.com> CC: ecryptfs-devel@lists.launchpad.net Signed-off-by: Sage Weil <sage@newdream.net> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* hostfs: remove unnecessary dentry_unhash on rmdir, dir renameSage Weil2011-05-281-5/+0
| | | | | | | | | | hostfs does not have problems with references to unlinked directories. CC: Jeff Dike <jdike@addtoit.com> CC: Richard Weinberger <richard@nod.at> CC: user-mode-linux-devel@lists.sourceforge.net Signed-off-by: Sage Weil <sage@newdream.net> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* hfsplus: remove unnecessary dentry_unhash on rmdir, dir renameSage Weil2011-05-281-6/+2
| | | | | | | hfsplus does not have problems with references to unlinked directories. Signed-off-by: Sage Weil <sage@newdream.net> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* hfs: remove unnecessary dentry_unhash on rmdir, dir renameSage Weil2011-05-281-6/+0
| | | | | | | hfs does not have problems with references to unlinked directories. Signed-off-by: Sage Weil <sage@newdream.net> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* omfs: remove unnecessary dentry_unhash on rmdir, dir rneameSage Weil2011-05-281-8/+3
| | | | | | | | | omfs does not have problems with references to unlinked directories. CC: Bob Copeland <me@bobcopeland.com> CC: linux-karma-devel@lists.sourceforge.net Signed-off-by: Sage Weil <sage@newdream.net> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* udf: remove unnecessary dentry_unhash from rmdir, dir renameSage Weil2011-05-281-5/+0
| | | | | | | | udf does not have problems with references to unlinked directories. CC: Jan Kara <jack@suse.cz> Signed-off-by: Sage Weil <sage@newdream.net> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* reiserfs: remove unnecessary dentry_unhash from rmdir, dir renameSage Weil2011-05-282-6/+0
| | | | | | | | Reiserfs does not have problems with references to unlinked directories. CC: reiserfs-devel@vger.kernel.org Signed-off-by: Sage Weil <sage@newdream.net> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* ufs: remove unnecessary dentry_unhash from rmdir, dir renameSage Weil2011-05-281-5/+0
| | | | | | | | ufs does not have problems with references to unlinked directories. CC: Evgeniy Dushistov <dushistov@mail.ru> Signed-off-by: Sage Weil <sage@newdream.net> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* ubifs: remove unnecessary dentry_unhash from rmdir, dir renameSage Weil2011-05-281-5/+0
| | | | | | | | | | ubifs does not have problems with references to unlinked directories. CC: Artem Bityutskiy <dedekind1@gmail.com> CC: Adrian Hunter <adrian.hunter@nokia.com> CC: linux-mtd@lists.infradead.org Signed-off-by: Sage Weil <sage@newdream.net> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* nilfs2: remove unnecessary dentry_unhash from rmdir, dir renameSage Weil2011-05-281-5/+0
| | | | | | | | | nilfs2 does not have problems with references to unlinked directories. CC: KONISHI Ryusuke <konishi.ryusuke@lab.ntt.co.jp> CC: linux-nilfs@vger.kernel.org Signed-off-by: Sage Weil <sage@newdream.net> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* logfs: remove unnecessary dentry_unhash from rmdir, dir renameSage Weil2011-05-281-5/+0
| | | | | | | | | logfs does not have problems with references to unlinked directories. CC: Joern Engel <joern@logfs.org> CC: logfs@logfs.org Signed-off-by: Sage Weil <sage@newdream.net> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* jfs: remove unnecessary dentry_unhash from rmdir, dir renameSage Weil2011-05-281-5/+0
| | | | | | | | | jfs does not have problems with references to unlinked directories. CC: Dave Kleikamp <shaggy@kernel.org> CC: jfs-discussion@lists.sourceforge.net Signed-off-by: Sage Weil <sage@newdream.net> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* jffs2: remove unnecessary dentry_unhash from rmdir, dir renameSage Weil2011-05-281-5/+0
| | | | | | | | | jffs2 does not have problems with references to unlinked directories. CC: David Woodhouse <dwmw2@infradead.org> CC: linux-mtd@lists.infradead.org Signed-off-by: Sage Weil <sage@newdream.net> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* sysv: remove unnecessary dentry_unhash from rmdir, dir renameSage Weil2011-05-281-5/+0
| | | | | | | | sysv does not have problems with references to unlinked directories. CC: Christoph Hellwig <hch@infradead.org> Signed-off-by: Sage Weil <sage@newdream.net> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* bfs: remove unnecessary dentry_unhash on dir renameSage Weil2011-05-281-3/+0
| | | | | | | | Bfs does not have problems with references to unlinked directories. CC: tigran@aivazian.fsnet.co.uk Signed-off-by: Sage Weil <sage@newdream.net> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* fs: cosmetic inode.c cleanupsChristoph Hellwig2011-05-271-49/+5
| | | | | | | | | | Move the lock order description after all the includes, remove several fairly outdated and/or incorrect comments, move Andrea's copyright/changelog to the top where it belongs, remove the pointless filename in the top of the file comment, and remove to useless macros. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* vfs: Improve the bio_add_page() and bio_add_pc_page() descriptionsAndreas Gruenbacher2011-05-271-8/+8
| | | | | | | | The descriptions of bio_add_page() and bio_add_pc_page() are slightly inconsistent; improve them. Signed-off-by: Andreas Gruenbacher <agruen@kernel.org> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* xattr: Fix error results for non-existent / invisible attributesAndreas Gruenbacher2011-05-271-6/+10
| | | | | | | | | | | | | | | Return -ENODATA when trying to read a user.* attribute which cannot exist: user space otherwise does not have a reasonable way to distinguish between non-existent and inaccessible attributes. Likewise, return -ENODATA when an unprivileged process tries to read a trusted.* attribute: to unprivileged processes, those attributes are invisible (listxattr() won't include them). Related to this bug report: https://bugzilla.redhat.com/660613 Signed-off-by: Andreas Gruenbacher <agruen@kernel.org> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* fs: pass exact type of data dirties to ->dirty_inodeChristoph Hellwig2011-05-2719-23/+21
| | | | | | | | | | | | | | | | | Tell the filesystem if we just updated timestamp (I_DIRTY_SYNC) or anything else, so that the filesystem can track internally if it needs to push out a transaction for fdatasync or not. This is just the prototype change with no user for it yet. I plan to push large XFS changes for the next merge window, and getting this trivial infrastructure in this window would help a lot to avoid tree interdependencies. Also remove incorrect comments that ->dirty_inode can't block. That has been changed a long time ago, and many implementations rely on it. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* Lift the check for automount points into do_lookup()Al Viro2011-05-271-5/+5
| | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* Trim excessive arguments of follow_mount_rcu()Al Viro2011-05-271-18/+8
| | | | | | | | | | ... and kill a useless local variable in follow_dotdot_rcu(), while we are at it - follow_mount_rcu(nd, path, inode) *always* assigned value to *inode, and always it had been path->dentry->d_inode (aka nd->path.dentry->d_inode, since it always got &nd->path as the second argument). Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* split __follow_mount_rcu() into normal and .. casesAl Viro2011-05-271-9/+26
| | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* Merge branch 'upstream/tidy-xen-mmu-2.6.39' of ↵Linus Torvalds2011-05-263-275/+50
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/jeremy/xen * 'upstream/tidy-xen-mmu-2.6.39' of git://git.kernel.org/pub/scm/linux/kernel/git/jeremy/xen: xen: fix compile without CONFIG_XEN_DEBUG_FS Use arbitrary_virt_to_machine() to deal with ioremapped pud updates. Use arbitrary_virt_to_machine() to deal with ioremapped pmd updates. xen/mmu: remove all ad-hoc stats stuff xen: use normal virt_to_machine for ptes xen: make a pile of mmu pvop functions static vmalloc: remove vmalloc_sync_all() from alloc_vm_area() xen: condense everything onto xen_set_pte xen: use mmu_update for xen_set_pte_at() xen: drop all the special iomap pte paths.
| * xen: fix compile without CONFIG_XEN_DEBUG_FSJeremy Fitzhardinge2011-05-201-0/+2
| | | | | | | | Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
| * Use arbitrary_virt_to_machine() to deal with ioremapped pud updates.Jeremy Fitzhardinge2011-05-201-1/+1
| | | | | | | | Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
| * Use arbitrary_virt_to_machine() to deal with ioremapped pmd updates.Jeremy Fitzhardinge2011-05-201-1/+1
| | | | | | | | Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
| * xen/mmu: remove all ad-hoc stats stuffJeremy Fitzhardinge2011-05-201-138/+0
| | | | | | | | | | | | To make way for tracing. Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
| * xen: use normal virt_to_machine for ptesJeremy Fitzhardinge2011-05-201-5/+5
| | | | | | | | | | | | | | | | We no longer support HIGHPTE allocations, so ptes should always be within the kernel's direct map, and don't need pagetable walks to convert to machine addresses. Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
| * xen: make a pile of mmu pvop functions staticJeremy Fitzhardinge2011-05-202-60/+23
| | | | | | | | Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
| * vmalloc: remove vmalloc_sync_all() from alloc_vm_area()Jeremy Fitzhardinge2011-05-201-4/+0
| | | | | | | | | | | | | | There's no need for it: it will get faulted into the current pagetable as needed. Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
| * xen: condense everything onto xen_set_pteJeremy Fitzhardinge2011-05-201-46/+27
| | | | | | | | | | | | | | | | | | | | | | xen_set_pte_at and xen_clear_pte are essentially identical to xen_set_pte, so just make them all common. When batched set_pte and pte_clear are the same, but the unbatch operation must be different: they need to update the two halves of the pte in different order. Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
| * xen: use mmu_update for xen_set_pte_at()Jeremy Fitzhardinge2011-05-201-15/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In principle update_va_mapping is a good match for set_pte_at, since it gets the address being mapped, which allows Xen to use its linear pagetable mapping. However that assumes that the pmd for the address is attached to the current pagetable, which may not be true for a given user address space because the kernel pmd is not shared (at least on 32-bit guests). Normally the kernel will automatically sync a missing part of the pagetable with the init_mm pagetable transparently via faults, but that fails when a missing address is passed to Xen. And while the linear pagetable mapping is very useful for 32-bit Xen (as it avoids an explicit domain mapping), 32-bit Xen is deprecated. 64-bit Xen has all memory mapped all the time, so it makes no real difference. The upshot is that we should use mmu_update, since it can operate on non-current pagetables or detached pagetables. Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
| * xen: drop all the special iomap pte paths.Jeremy Fitzhardinge2011-05-201-25/+0
| | | | | | | | | | | | | | Xen can work out when we're doing IO mappings for itself, so we don't need to do anything special, and the extra tests just clog things up. Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
* | selinux: don't pass in NULL avd to avc_has_perm_noauditLinus Torvalds2011-05-262-11/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Right now security_get_user_sids() will pass in a NULL avd pointer to avc_has_perm_noaudit(), which then forces that function to have a dummy entry for that case and just generally test it. Don't do it. The normal callers all pass a real avd pointer, and this helper function is incredibly hot. So don't make avc_has_perm_noaudit() do conditional stuff that isn't needed for the common case. This also avoids some duplicated stack space. Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | Merge git://git.kernel.org/pub/scm/linux/kernel/git/pkl/squashfs-linusLinus Torvalds2011-05-2623-151/+203
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * git://git.kernel.org/pub/scm/linux/kernel/git/pkl/squashfs-linus: Squashfs: update email address Squashfs: add extra sanity checks at mount time Squashfs: add sanity checks to fragment reading at mount time Squashfs: add sanity checks to lookup table reading at mount time Squashfs: add sanity checks to id reading at mount time Squashfs: add sanity checks to xattr reading at mount time Squashfs: reverse order of filesystem table reading Squashfs: move table allocation into squashfs_read_table()
| * | Squashfs: update email addressPhillip Lougher2011-05-2623-24/+24
| | | | | | | | | | | | | | | | | | | | | My existing email address may stop working in a month or two, so update email to one that will continue working. Signed-off-by: Phillip Lougher <phillip@lougher.demon.co.uk>
| * | Squashfs: add extra sanity checks at mount timePhillip Lougher2011-05-251-2/+16
| | | | | | | | | | | | | | | | | | Add some extra sanity checks of the inode and directory structures. Signed-off-by: Phillip Lougher <phillip@lougher.demon.co.uk>
| * | Squashfs: add sanity checks to fragment reading at mount timePhillip Lougher2011-05-253-4/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fsfuzzer generates corrupted filesystems which throw a warn_on in kmalloc. One of these is due to a corrupted superblock fragments field. Fix this by checking that the number of bytes to be read (and allocated) does not extend into the next filesystem structure. Also add a couple of other sanity checks of the mount-time fragment table structures. Signed-off-by: Phillip Lougher <phillip@lougher.demon.co.uk>
| * | Squashfs: add sanity checks to lookup table reading at mount timePhillip Lougher2011-05-253-4/+30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fsfuzzer generates corrupted filesystems which throw a warn_on in kmalloc. One of these is due to a corrupted superblock inodes field. Fix this by checking that the number of bytes to be read (and allocated) does not extend into the next filesystem structure. Also add a couple of other sanity checks of the mount-time lookup table structures. Signed-off-by: Phillip Lougher <phillip@lougher.demon.co.uk>
OpenPOWER on IntegriCloud