summaryrefslogtreecommitdiffstats
path: root/fs/jffs2
Commit message (Collapse)AuthorAgeFilesLines
* [PATCH] cpuset memory spread: slab cache formatPaul Jackson2006-03-241-1/+2
| | | | | | | | | | Rewrap the overly long source code lines resulting from the previous patch's addition of the slab cache flag SLAB_MEM_SPREAD. This patch contains only formatting changes, and no function change. Signed-off-by: Paul Jackson <pj@sgi.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] cpuset memory spread: slab cache filesystemsPaul Jackson2006-03-241-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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>
* [PATCH] vfs: MS_VERBOSE should be MS_SILENTTheodore Ts'o2006-03-241-2/+2
| | | | | | | | | | | | | | | | | | | | | | The meaning of MS_VERBOSE is backwards; if the bit is set, it really means, "don't be verbose". This is confusing and counter-intuitive. In addition, there is also no way to set the MS_VERBOSE flag in the mount(8) program in util-linux, but interesting, it does define options which would do the right thing if MS_SILENT were defined, which unfortunately we do not: #ifdef MS_SILENT { "quiet", 0, 0, MS_SILENT }, /* be quiet */ { "loud", 0, 1, MS_SILENT }, /* print out messages. */ #endif So the obvious fix is to deprecate the use of MS_VERBOSE and replace it with MS_SILENT. Signed-off-by: "Theodore Ts'o" <tytso@mit.edu> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] mtd: 64 bit fixesAtsushi Nemoto2006-03-092-2/+3
| | | | | | | | | | | | | | | Fix some bugs in mtd/jffs2 on 64bit platform. The MEMGETBADBLOCK/MEMSETBADBLOCK ioctl are not listed in compat_ioctl.h. And some variables in jffs2 are declared as uint32_t but used to hold size_t values. Signed-off-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp> Cc: Thomas Gleixner <tglx@linutronix.de> Acked-by: David Woodhouse <dwmw2@infradead.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] jffs2: avoid divide-by-zeroDavid Woodhouse2006-03-081-1/+1
| | | | | Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] Unlinline a bunch of other functionsArjan van de Ven2006-01-142-3/+3
| | | | | | | | | | | Remove the "inline" keyword from a bunch of big functions in the kernel with the goal of shrinking it by 30kb to 40kb Signed-off-by: Arjan van de Ven <arjan@infradead.org> Signed-off-by: Ingo Molnar <mingo@elte.hu> Acked-by: Jeff Garzik <jgarzik@pobox.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] capable/capability.h (fs/)Randy Dunlap2006-01-111-0/+1
| | | | | | | | | fs: Use <linux/capability.h> where capable() is used. Signed-off-by: Randy Dunlap <rdunlap@xenotime.net> Acked-by: Tim Schmielau <tim@physik3.uni-rostock.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [JFFS2] Fix the slab cache constructor of 'struct jffs2_inode_info' objects.Thomas Gleixner2005-11-292-1/+3
| | | | | | | | | | | | | | | JFFS2 initialize f->sem mutex as "locked" in the slab constructor which is a bug. Objects are freed with unlocked f->sem mutex. So, when they allocated again, f->sem is unlocked because the slab cache constructor is not called for them. The constructor is called only once when memory pages are allocated for objects (namely, when the slab layer allocates new slabs). So, sometimes 'struct jffs2_inode_info' are allocated with unlocked f->sem, sometimes with locked. This is a bug. Instead, initialize f->sem as unlocked in the constructor. I.e., in the "constructed" state f->sem must be unlocked. From: Keijiro Yano <keijiro_yano@yahoo.co.jp> Acked-by: Artem B. Bityutskiy <dedekind@infradead.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
* [PATCH] jffs2 debug gcc-2.9x fixAndrew Morton2005-11-231-4/+4
| | | | | | | | Work around gcc-2.95.x macro expansion bug. Cc: David Woodhouse <dwmw2@infradead.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [JFFS2] Remove broken and useless debug codeThomas Gleixner2005-11-131-3/+0
| | | | Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
* Merge master.kernel.org:/pub/scm/linux/kernel/git/tglx/mtd-2.6Linus Torvalds2005-11-0736-2133/+4529
|\ | | | | | | Some manual fixups for clashing kfree() cleanups etc.
| * [JFFS2] Clean up trailing white spacesThomas Gleixner2005-11-0732-585/+584
| | | | | | | | Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * [JFFS2] Fix broken compile when debug level = 2Artem B. Bityutskiy2005-11-061-3/+3
| | | | | | | | | | Signed-off-by: Artem B. Bityutskiy <dedekind@infradead.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * [JFFS2] Return 0, not number of bytes written, for success at commit_writeTodd Poynor2005-11-061-3/+3
| | | | | | | | | | | | | | | | | | | | Some callers to block-layer commit_write function treat non-zero return as error, notably the loopback mount driver sometimes used in conjunction with JFFS2 on NAND flash for bad block avoidance, etc. Return zero for success as do various other commit_write functions. Signed-off-by: Todd Poynor <tpoynor@mvista.com> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * [JFFS2] Fix dataflash supportArtem B. Bityutskiy2005-11-063-22/+40
| | | | | | | | | | | | | | | | | | | | - assume wbuf may be of size which is not power of 2 - don't make strange assumption about not padding wbuf for DataFlash - use wbuf = DataFlash page and eraseblock >= 8 Dataflash pages From: Peter Menzebach <pm-mtd@mw-itcon.de> Acked-by: Artem B. Bityutskiy <dedekind@infradead.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * [JFFS2] Use memset(struct) instead of nulling struct members one by oneArtem B. Bityutskiy2005-11-061-10/+7
| | | | | | | | | | Signed-off-by: Artem B. Bityutskiy <dedekind@infradead.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * [JFFS2] Remove stale commentArtem B. Bityutskiy2005-11-061-2/+1
| | | | | | | | | | Signed-off-by: Artem B. Bityutskiy <dedekind@infradead.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * [JFFS2] Rename jffs2_summary_node to jffs2_raw_summaryFerenc Havasi2005-11-062-9/+9
| | | | | | | | | | Signed-off-by: Ferenc Havasi <havasi@inf.u-szeged.hu> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * [JFFS2] Debug code simplification, update TODOArtem B. Bityutskiy2005-11-0613-264/+232
| | | | | | | | | | | | | | | | Simplify the debugging code further. Update the TODO list Signed-off-by: Artem B. Bityutskiy <dedekind@infradead.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * [JFFS2] Account summary space in reserved_size.Ferenc Havasi2005-11-061-1/+3
| | | | | | | | | | | | | | | | | | | | | | Always keep valid data in reserved_size. It did not cause problems, but the reservation code was unoptimal when centralized summary was active or the size of the erase block was very small. Signed-off-by: Ferenc Havasi <havasi@inf.u-szeged.hu> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * [JFFS2] Debug message format clean upArtem B. Bityutskiy2005-11-062-159/+120
| | | | | | | | | | Signed-off-by: Artem B. Bityutskiy <dedekind@infradead.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * [JFFS2] Call summary collector for all mtd devices with writev supportFerenc Havasi2005-11-061-5/+6
| | | | | | | | | | | | | | | | | | Do the summary collection in the right place. If the device was not writebuffered but had c->mtd->writev function (e.g. blkmtd) the summary collector function was not called. Signed-off-by: Ferenc Havasi <havasi@inf.u-szeged.hu> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * [JFFS2] Return real jffs2_sum_init() error codeFerenc Havasi2005-11-061-3/+5
| | | | | | | | | | Signed-off-by: Ferenc Havasi <havasi@inf.u-szeged.hu> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * [JFFS2] Add erase block summary support (mount time improvement)Ferenc Havasi2005-11-0617-197/+1359
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The goal of summary is to speed up the mount time. Erase block summary (EBS) stores summary information at the end of every (closed) erase block. It is no longer necessary to scan all nodes separetly (and read all pages of them) just read this "small" summary, where every information is stored which is needed at mount time. This summary information is stored in a JFFS2_FEATURE_RWCOMPAT_DELETE. During the mount process if there is no summary info the orignal scan process will be executed. EBS works with NAND and NOR flashes, too. There is a user space tool called sumtool to generate this summary information for a JFFS2 image. Signed-off-by: Ferenc Havasi <havasi@inf.u-szeged.hu> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * [JFFS2] Remove support for virtual blocksFerenc Havasi2005-11-064-23/+13
| | | | | | | | | | | | | | | | | | | | | | Remove support for virtual blocks, which are build by concatenation of multiple physical erase blocks. For more information please read the MTD mailing list thread "[PATCH] remove support for virtual blocks" Signed-off-by: Ferenc Havasi <havasi@inf.u-szeged.hu> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * [JFFS2] Solve BUG caused by frag->node representing a hole in fragtreeArtem B. Bityutskiy2005-11-061-2/+2
| | | | | | | | | | Signed-off-by: Artem B. Bityutskiy <dedekind@infradead.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * [JFFS2] Calculate CRC check starting point correctlyArtem B. Bityutskiy2005-11-062-8/+9
| | | | | | | | | | | | | | | | | | | | When data starts from the beginning of NAND page, 'len' must be zero, not c->wbuf_page. Thanks to Zoltan Sogor for reporting this problem. Signed-off-by: Artem B. Bityutskiy <dedekind@infradead.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * [JFFS2] More message formatting cleanupsArtem B. Bityutskiy2005-11-062-7/+7
| | | | | | | | | | Signed-off-by: Artem B. Bityutskiy <dedekind@infradead.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * [JFFS2] Fix JFFS2 [mc]time handlingArtem B. Bityutskiy2005-11-065-17/+37
| | | | | | | | | | | | | | From: David Woodhouse <dwmw2@infradead.org> Signed-off-by: Artem B. Bityutskiy <dedekind@infradead.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * [JFFS2] Make the JFFS2 messages a bit nicerArtem B. Bityutskiy2005-11-061-5/+5
| | | | | | | | | | Signed-off-by: Artem B. Bityutskiy <dedekind@infradead.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * [JFFS2] Teach JFFS2 about Sibley flashNicolas Pitre2005-11-063-5/+46
| | | | | | | | | | | | | | Intels Sibley flash needs JFFS2 write buffer functionality Signed-off-by: Nicolas Pitre <nico@cam.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * [JFFS2] Debug code clean up - step 7Artem B. Bityutskiy2005-11-064-64/+71
| | | | | | | | | | | | | | | | Remove more noisy debugs. Add current->pid to debug messages. Remove bogus includes. Signed-off-by: Artem B. Bityutskiy <dedekind@infradead.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * [JFFS2] Correct buggy length checksArtem B. Bityutskiy2005-11-062-4/+4
| | | | | | | | | | | | | | The previous changes introduced wrong length calculations. Signed-off-by: Artem B. Bityutskiy <dedekind@infradead.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * [JFFS2] Debug code clean up - step 6Artem B. Bityutskiy2005-11-063-28/+15
| | | | | | | | | | | | | | Remove extra noisy debugs Signed-off-by: Artem B. Bityutskiy <dedekind@infradead.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * [JFFS2] Build fragtree in reverse orderArtem B. Bityutskiy2005-11-063-253/+868
| | | | | | | | | | | | | | | | | | Instead of building fragtree starting from node with the smallest version number, start from the highest. This helps to avoid reading and checking obsolete nodes. Signed-off-by: Artem B. Bityutskiy <dedekind@infradead.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * [JFFS2] Refine fragtree debug macrosArtem B. Bityutskiy2005-11-061-6/+6
| | | | | | | | | | Signed-off-by: Artem B. Bityutskiy <dedekind@infradead.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * [JFFS2] Move another fragtree-related function to nodelist.cArtem B. Bityutskiy2005-11-063-28/+28
| | | | | | | | | | Signed-off-by: Artem B. Bityutskiy <dedekind@infradead.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * [JFFS2] Fix up new debug code for eCos buildAndrew Lunn2005-11-063-10/+16
| | | | | | | | | | | | | | The debug code cleanup broke the eCos build. Signed-off-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * [JFFS2] Debug code clean up - step 5Artem B. Bityutskiy2005-11-062-143/+117
| | | | | | | | | | | | | | Replace the D1(printk()) style debugging with the new debug macros Signed-off-by: Artem B. Bityutskiy <dedekind@infradead.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * [JFFS2] Move scattered function into related filesArtem B. Bityutskiy2005-11-063-800/+790
| | | | | | | | | | | | | | | | Move functions to read inodes into readinode.c Move functions to handle fragtree and dentry lists into nodelist.[ch] Signed-off-by: Artem B. Bityutskiy <dedekind@infradead.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * [JFFS2] Debug code clean up - step 4Artem B. Bityutskiy2005-11-062-44/+54
| | | | | | | | | | | | | | Small comment cleanups. Remove a unused macro Signed-off-by: Artem B. Bityutskiy <dedekind@infradead.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * [jffs2] Remove compressor lzo and lzariFerenc Havasi2005-11-062-22/+2
| | | | | | | | | | | | | | Remove unused compressor code Signed-off-by: Ferenc Havasi <havasi@inf.u-szeged.hu> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * [JFFS2] Namespace clean upArtem B. Bityutskiy2005-11-064-27/+8
| | | | | | | | | | | | | | | | Rename functions to a name matching the functionality. Remove stall debug code Signed-off-by: Artem B. Bityutskiy <dedekind@infradead.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * [JFFS2] Debug code clean up - step 3Artem B. Bityutskiy2005-11-0614-239/+630
| | | | | | | | | | | | | | | | Various simplifiactions. printk format corrections. Convert more code to use the new debug functions. Signed-off-by: Artem B. Bityutskiy <dedekind@infradead.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * [JFFS2] Fix slab panicArtem B. Bityutskiy2005-11-061-3/+2
| | | | | | | | | | | | | | | | | | | | When JFFS22 is unable to read the root inode, the bad root inode object is not freed and remains sticked in the jffs2_i slab cache. When we further try to free the slab cache (e.g., on rmmod jffs2), slab allocator subsystem panics. Fix this bug. Signed-off-by: Artem B. Bityutskiy <dedekind@infradead.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * [JFFS2] Debug code clean up - step 2Artem B. Bityutskiy2005-11-065-13/+13
| | | | | | | | | | | | | | | | If debugging is disabled, define debugging functions as empty macros, instead of using Dx() explicitly. Signed-off-by: Artem B. Bityutskiy <dedekind@infradead.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * [JFFS2] Use f->target instead of f->dents for symlink targetArtem B. Bityutskiy2005-11-064-46/+40
| | | | | | | | | | | | | | | | | | | | JFFS2 uses f->dents to store the pointer to the symlink target string (in case the inode is symlink). This is somewhat ugly to use the same field for different reasons. Introduce distinct field f->target for this purpose. Note, f->fragtree, f->dents, f->target may probably be put in a union. Signed-off-by: Artem B. Bityutskiy <dedekind@infradead.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * [JFFS2] Debug code clean up - step 1Artem B. Bityutskiy2005-11-0614-439/+663
| | | | | | | | | | | | | | Move debug functions into a seperate source file Signed-off-by: Artem B. Bityutskiy <dedekind@infradead.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| * [JFFS2] Split a large routine on several smaller.Artem B. Bityutskiy2005-11-061-261/+336
| | | | | | | | | | Signed-off-by: Artem B. Bityutskiy <dedekind@infradead.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
* | [PATCH] kfree cleanup: fsJesper Juhl2005-11-072-7/+4
|/ | | | | | | | | | This is the fs/ part of the big kfree cleanup patch. Remove pointless checks for NULL prior to calling kfree() in fs/. Signed-off-by: Jesper Juhl <jesper.juhl@gmail.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
OpenPOWER on IntegriCloud