22 Feb, 2018

1 commit

  • commit 3876bbe27d04b848750d5310a37d6b76b593f648 upstream.

    KMSAN reported use of uninitialized |entry->e_referenced| in a condition
    in mb_cache_shrink():

    ==================================================================
    BUG: KMSAN: use of uninitialized memory in mb_cache_shrink+0x3b4/0xc50 fs/mbcache.c:287
    CPU: 2 PID: 816 Comm: kswapd1 Not tainted 4.11.0-rc5+ #2877
    Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS Bochs
    01/01/2011
    Call Trace:
    __dump_stack lib/dump_stack.c:16 [inline]
    dump_stack+0x172/0x1c0 lib/dump_stack.c:52
    kmsan_report+0x12a/0x180 mm/kmsan/kmsan.c:927
    __msan_warning_32+0x61/0xb0 mm/kmsan/kmsan_instr.c:469
    mb_cache_shrink+0x3b4/0xc50 fs/mbcache.c:287
    mb_cache_scan+0x67/0x80 fs/mbcache.c:321
    do_shrink_slab mm/vmscan.c:397 [inline]
    shrink_slab+0xc3d/0x12d0 mm/vmscan.c:500
    shrink_node+0x208f/0x2fd0 mm/vmscan.c:2603
    kswapd_shrink_node mm/vmscan.c:3172 [inline]
    balance_pgdat mm/vmscan.c:3289 [inline]
    kswapd+0x160f/0x2850 mm/vmscan.c:3478
    kthread+0x46c/0x5f0 kernel/kthread.c:230
    ret_from_fork+0x29/0x40 arch/x86/entry/entry_64.S:430
    chained origin:
    save_stack_trace+0x37/0x40 arch/x86/kernel/stacktrace.c:59
    kmsan_save_stack_with_flags mm/kmsan/kmsan.c:302 [inline]
    kmsan_save_stack mm/kmsan/kmsan.c:317 [inline]
    kmsan_internal_chain_origin+0x12a/0x1f0 mm/kmsan/kmsan.c:547
    __msan_store_shadow_origin_1+0xac/0x110 mm/kmsan/kmsan_instr.c:257
    mb_cache_entry_create+0x3b3/0xc60 fs/mbcache.c:95
    ext4_xattr_cache_insert fs/ext4/xattr.c:1647 [inline]
    ext4_xattr_block_set+0x4c82/0x5530 fs/ext4/xattr.c:1022
    ext4_xattr_set_handle+0x1332/0x20a0 fs/ext4/xattr.c:1252
    ext4_xattr_set+0x4d2/0x680 fs/ext4/xattr.c:1306
    ext4_xattr_trusted_set+0x8d/0xa0 fs/ext4/xattr_trusted.c:36
    __vfs_setxattr+0x703/0x790 fs/xattr.c:149
    __vfs_setxattr_noperm+0x27a/0x6f0 fs/xattr.c:180
    vfs_setxattr fs/xattr.c:223 [inline]
    setxattr+0x6ae/0x790 fs/xattr.c:449
    path_setxattr+0x1eb/0x380 fs/xattr.c:468
    SYSC_lsetxattr+0x8d/0xb0 fs/xattr.c:490
    SyS_lsetxattr+0x77/0xa0 fs/xattr.c:486
    entry_SYSCALL_64_fastpath+0x13/0x94
    origin:
    save_stack_trace+0x37/0x40 arch/x86/kernel/stacktrace.c:59
    kmsan_save_stack_with_flags mm/kmsan/kmsan.c:302 [inline]
    kmsan_internal_poison_shadow+0xb1/0x1a0 mm/kmsan/kmsan.c:198
    kmsan_kmalloc+0x7f/0xe0 mm/kmsan/kmsan.c:337
    kmem_cache_alloc+0x1c2/0x1e0 mm/slub.c:2766
    mb_cache_entry_create+0x283/0xc60 fs/mbcache.c:86
    ext4_xattr_cache_insert fs/ext4/xattr.c:1647 [inline]
    ext4_xattr_block_set+0x4c82/0x5530 fs/ext4/xattr.c:1022
    ext4_xattr_set_handle+0x1332/0x20a0 fs/ext4/xattr.c:1252
    ext4_xattr_set+0x4d2/0x680 fs/ext4/xattr.c:1306
    ext4_xattr_trusted_set+0x8d/0xa0 fs/ext4/xattr_trusted.c:36
    __vfs_setxattr+0x703/0x790 fs/xattr.c:149
    __vfs_setxattr_noperm+0x27a/0x6f0 fs/xattr.c:180
    vfs_setxattr fs/xattr.c:223 [inline]
    setxattr+0x6ae/0x790 fs/xattr.c:449
    path_setxattr+0x1eb/0x380 fs/xattr.c:468
    SYSC_lsetxattr+0x8d/0xb0 fs/xattr.c:490
    SyS_lsetxattr+0x77/0xa0 fs/xattr.c:486
    entry_SYSCALL_64_fastpath+0x13/0x94
    ==================================================================

    Signed-off-by: Alexander Potapenko
    Signed-off-by: Eric Biggers
    Cc: stable@vger.kernel.org # v4.6
    Signed-off-by: Greg Kroah-Hartman

    Alexander Potapenko
     

22 Jun, 2017

2 commits

  • Ext4 now supports xattr values that are up to 64k in size (vfs limit).
    Large xattr values are stored in external inodes each one holding a
    single value. Once written the data blocks of these inodes are immutable.

    The real world use cases are expected to have a lot of value duplication
    such as inherited acls etc. To reduce data duplication on disk, this patch
    implements a deduplicator that allows sharing of xattr inodes.

    The deduplication is based on an in-memory hash lookup that is a best
    effort sharing scheme. When a xattr inode is read from disk (i.e.
    getxattr() call), its crc32c hash is added to a hash table. Before
    creating a new xattr inode for a value being set, the hash table is
    checked to see if an existing inode holds an identical value. If such an
    inode is found, the ref count on that inode is incremented. On value
    removal the ref count is decremented and if it reaches zero the inode is
    deleted.

    The quota charging for such inodes is manually managed. Every reference
    holder is charged the full size as if there was no sharing happening.
    This is consistent with how xattr blocks are also charged.

    [ Fixed up journal credits calculation to handle inline data and the
    rare case where an shared xattr block can get freed when two thread
    race on breaking the xattr block sharing. --tytso ]

    Signed-off-by: Tahsin Erdogan
    Signed-off-by: Theodore Ts'o

    Tahsin Erdogan
     
  • Make names more generic so that mbcache usage is not limited to
    block sharing. In a subsequent patch in the series
    ("ext4: xattr inode deduplication"), we start using the mbcache code
    for sharing xattr inodes. With that patch, old mb_cache_entry.e_block
    field could be holding either a block number or an inode number.

    Signed-off-by: Tahsin Erdogan
    Signed-off-by: Theodore Ts'o

    Tahsin Erdogan
     

04 Dec, 2016

5 commits

  • mb_cache_entry_find_first() and mb_cache_entry_find_next() only return
    cache entries with the 'e_reusable' bit set. This should be documented.

    Signed-off-by: Eric Biggers
    Signed-off-by: Theodore Ts'o
    Reviewed-by: Jan Kara

    Eric Biggers
     
  • mbcache used several different types to represent the number of entries
    in the cache. For consistency within mbcache and with the shrinker API,
    always use unsigned long.

    This does not change behavior for current mbcache users (ext2 and ext4)
    since they limit the entry count to a value which easily fits in an int.

    Signed-off-by: Eric Biggers
    Signed-off-by: Theodore Ts'o
    Reviewed-by: Jan Kara

    Eric Biggers
     
  • When mbcache is built as a module, any modules that use it (ext2 and/or
    ext4) will depend on its symbols directly, incrementing its reference
    count. Therefore, there is no need to do module_get/module_put.

    Also note that since the module_get/module_put were in the mbcache
    module itself, executing those lines of code was already dependent on
    another reference to the mbcache module being held.

    Signed-off-by: Eric Biggers
    Signed-off-by: Theodore Ts'o
    Reviewed-by: Jan Kara

    Eric Biggers
     
  • mbcache can be a module that is loaded long after startup, when someone
    asks to mount an ext2 or ext4 filesystem. Therefore it should not BUG()
    if kmem_cache_create() fails, but rather just fail the module load.

    Signed-off-by: Eric Biggers
    Signed-off-by: Theodore Ts'o
    Reviewed-by: Jan Kara

    Eric Biggers
     
  • mbcache entries have an 'e_referenced' bit which users can set with
    mb_cache_entry_touch() to indicate that an entry should be given another
    pass through the LRU list before the shrinker can delete it. However,
    mb_cache_shrink() actually would, when seeing an e_referenced entry at
    the front of the list (the least-recently used end), place it right at
    the front of the list again. The next iteration would then remove the
    entry from the list and delete it. Consequently, e_referenced had
    essentially no effect, so ext2/ext4 xattr blocks would sometimes not be
    reused as often as expected.

    Fix this by making the shrinker move e_referenced entries to the back of
    the list rather than the front.

    Signed-off-by: Eric Biggers
    Signed-off-by: Theodore Ts'o
    Reviewed-by: Jan Kara

    Eric Biggers
     

31 Aug, 2016

1 commit

  • register_shrinker in mb_cache_create may fail due to no memory. This
    patch fixes to do the check of return value of register_shrinker and
    handle the error case, otherwise mb_cache_create may return with no
    error, but losing the inner shrinker.

    Signed-off-by: Chao Yu
    Reviewed-by: Jan Kara
    Signed-off-by: Theodore Ts'o

    Chao Yu
     

23 Feb, 2016

4 commits

  • To reduce amount of damage caused by single bad block, we limit number
    of inodes sharing an xattr block to 1024. Thus there can be more xattr
    blocks with the same contents when there are lots of files with the same
    extended attributes. These xattr blocks naturally result in hash
    collisions and can form long hash chains and we unnecessarily check each
    such block only to find out we cannot use it because it is already
    shared by too many inodes.

    Add a reusable flag to cache entries which is cleared when a cache entry
    has reached its maximum refcount. Cache entries which are not marked
    reusable are skipped by mb_cache_entry_find_{first,next}. This
    significantly speeds up mbcache when there are many same xattr blocks.
    For example for xattr-bench with 5 values and each process handling
    20000 files, the run for 64 processes is 25x faster with this patch.
    Even for 8 processes the speedup is almost 3x. We have also verified
    that for situations where there is only one xattr block of each kind,
    the patch doesn't have a measurable cost.

    [JK: Remove handling of setting the same value since it is not needed
    anymore, check for races in e_reusable setting, improve changelog,
    add measurements]

    Signed-off-by: Andreas Gruenbacher
    Signed-off-by: Jan Kara
    Signed-off-by: Theodore Ts'o

    Andreas Gruenbacher
     
  • Get rid of field _e_hash_list_head in cache entries and add bit field
    e_referenced instead.

    Signed-off-by: Andreas Gruenbacher
    Signed-off-by: Jan Kara
    Signed-off-by: Theodore Ts'o

    Andreas Gruenbacher
     
  • Since old mbcache code is gone, let's rename new code to mbcache since
    number 2 is now meaningless. This is just a mechanical replacement.

    Signed-off-by: Jan Kara
    Signed-off-by: Theodore Ts'o

    Jan Kara
     
  • Both ext2 and ext4 are now converted to mbcache2. Remove the old mbcache
    code.

    Signed-off-by: Jan Kara
    Signed-off-by: Theodore Ts'o

    Jan Kara
     

26 Jun, 2014

1 commit


19 Mar, 2014

3 commits

  • This patch adds new interfaces to create and destory cache,
    ext4_xattr_create_cache() and ext4_xattr_destroy_cache(), and remove
    the cache creation and destory calls from ex4_init_xattr() and
    ext4_exitxattr() in fs/ext4/xattr.c.

    fs/ext4/super.c has been changed so that when a filesystem is mounted
    a cache is allocated and attched to its ext4_sb_info structure.

    fs/mbcache.c has been changed so that only one slab allocator is
    allocated and used by all mbcache structures.

    Signed-off-by: T. Makphaibulchoke

    T Makphaibulchoke
     
  • The patch increases the parallelism of mbcache by using the built-in
    lock in the hlist_bl_node to protect the mb_cache's local block and
    index hash chains. The global data mb_cache_lru_list and
    mb_cache_list continue to be protected by the global
    mb_cache_spinlock.

    New block group spinlock, mb_cache_bg_lock is also added to serialize
    accesses to mb_cache_entry's local data.

    A new member e_refcnt is added to the mb_cache_entry structure to help
    preventing an mb_cache_entry from being deallocated by a free while it
    is being referenced by either mb_cache_entry_get() or
    mb_cache_entry_find().

    Signed-off-by: T. Makphaibulchoke
    Signed-off-by: "Theodore Ts'o"

    T Makphaibulchoke
     
  • This patch changes each mb_cache's both block and index hash chains to
    use a hlist_bl_node, which contains a built-in lock. This is the
    first step in decoupling of locks serializing accesses to mb_cache
    global data and each mb_cache_entry local data.

    Signed-off-by: T. Makphaibulchoke
    Signed-off-by: "Theodore Ts'o"

    T Makphaibulchoke
     

11 Sep, 2013

2 commits

  • Convert the filesystem shrinkers to use the new API, and standardise some
    of the behaviours of the shrinkers at the same time. For example,
    nr_to_scan means the number of objects to scan, not the number of objects
    to free.

    I refactored the CIFS idmap shrinker a little - it really needs to be
    broken up into a shrinker per tree and keep an item count with the tree
    root so that we don't need to walk the tree every time the shrinker needs
    to count the number of objects in the tree (i.e. all the time under
    memory pressure).

    [glommer@openvz.org: fixes for ext4, ubifs, nfs, cifs and glock. Fixes are needed mainly due to new code merged in the tree]
    [assorted fixes folded in]
    Signed-off-by: Dave Chinner
    Signed-off-by: Glauber Costa
    Acked-by: Mel Gorman
    Acked-by: Artem Bityutskiy
    Acked-by: Jan Kara
    Acked-by: Steven Whitehouse
    Cc: Adrian Hunter
    Cc: "Theodore Ts'o"
    Cc: Adrian Hunter
    Cc: Al Viro
    Cc: Artem Bityutskiy
    Cc: Arve Hjønnevåg
    Cc: Carlos Maiolino
    Cc: Christoph Hellwig
    Cc: Chuck Lever
    Cc: Daniel Vetter
    Cc: David Rientjes
    Cc: Gleb Natapov
    Cc: Greg Thelen
    Cc: J. Bruce Fields
    Cc: Jan Kara
    Cc: Jerome Glisse
    Cc: John Stultz
    Cc: KAMEZAWA Hiroyuki
    Cc: Kent Overstreet
    Cc: Kirill A. Shutemov
    Cc: Marcelo Tosatti
    Cc: Mel Gorman
    Cc: Steven Whitehouse
    Cc: Thomas Hellstrom
    Cc: Trond Myklebust
    Signed-off-by: Andrew Morton

    Signed-off-by: Al Viro

    Dave Chinner
     
  • The sysctl knob sysctl_vfs_cache_pressure is used to determine which
    percentage of the shrinkable objects in our cache we should actively try
    to shrink.

    It works great in situations in which we have many objects (at least more
    than 100), because the aproximation errors will be negligible. But if
    this is not the case, specially when total_objects < 100, we may end up
    concluding that we have no objects at all (total / 100 = 0, if total <
    100).

    This is certainly not the biggest killer in the world, but may matter in
    very low kernel memory situations.

    Signed-off-by: Glauber Costa
    Reviewed-by: Carlos Maiolino
    Acked-by: KAMEZAWA Hiroyuki
    Acked-by: Mel Gorman
    Cc: Dave Chinner
    Cc: Al Viro
    Cc: "Theodore Ts'o"
    Cc: Adrian Hunter
    Cc: Al Viro
    Cc: Artem Bityutskiy
    Cc: Arve Hjønnevåg
    Cc: Carlos Maiolino
    Cc: Christoph Hellwig
    Cc: Chuck Lever
    Cc: Daniel Vetter
    Cc: David Rientjes
    Cc: Gleb Natapov
    Cc: Greg Thelen
    Cc: J. Bruce Fields
    Cc: Jan Kara
    Cc: Jerome Glisse
    Cc: John Stultz
    Cc: KAMEZAWA Hiroyuki
    Cc: Kent Overstreet
    Cc: Kirill A. Shutemov
    Cc: Marcelo Tosatti
    Cc: Mel Gorman
    Cc: Steven Whitehouse
    Cc: Thomas Hellstrom
    Cc: Trond Myklebust
    Signed-off-by: Andrew Morton
    Signed-off-by: Al Viro

    Glauber Costa
     

25 May, 2011

1 commit

  • Change each shrinker's API by consolidating the existing parameters into
    shrink_control struct. This will simplify any further features added w/o
    touching each file of shrinker.

    [akpm@linux-foundation.org: fix build]
    [akpm@linux-foundation.org: fix warning]
    [kosaki.motohiro@jp.fujitsu.com: fix up new shrinker API]
    [akpm@linux-foundation.org: fix xfs warning]
    [akpm@linux-foundation.org: update gfs2]
    Signed-off-by: Ying Han
    Cc: KOSAKI Motohiro
    Cc: Minchan Kim
    Acked-by: Pavel Emelyanov
    Cc: KAMEZAWA Hiroyuki
    Cc: Mel Gorman
    Acked-by: Rik van Riel
    Cc: Johannes Weiner
    Cc: Hugh Dickins
    Cc: Dave Hansen
    Cc: Steven Whitehouse
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Ying Han
     

31 Mar, 2011

1 commit


11 Jan, 2011

1 commit

  • When I enable EXT2_XATTR_DEBUG in fs/ext2/xattr.c I get a build error stating
    the following:

    CC fs/ext2/xattr.o
    fs/ext2/xattr.c: In function 'ext2_xattr_cache_insert':
    fs/ext2/xattr.c:841: error: dereferencing pointer to incomplete type
    fs/ext2/xattr.c:846: error: dereferencing pointer to incomplete type
    make[2]: *** [fs/ext2/xattr.o] Error 1
    make[1]: *** [fs/ext2] Error 2
    make: *** [fs] Error 2

    These lines reference ext2_xattr_cache->c_entry_count which is defined
    in struct mb_cache. struct mb_cache is currently only defined in fs/mbcache.c.
    Moving struct mb_cache definition to include/linux/mbcache.h to resolve the
    issue.

    Signed-off-by: Josh Hunt
    Signed-off-by: Jan Kara

    Josh Hunt
     

18 Aug, 2010

1 commit

  • Limit the maximum number of mb_cache entries depending on the number of
    hash buckets: if the only limit to the number of cache entries is the
    available memory the hash chains can grow very long, taking a long time
    to search.

    At least partially solves https://bugzilla.lustre.org/show_bug.cgi?id=22771.

    Signed-off-by: Andreas Gruenbacher
    Signed-off-by: Al Viro

    Andreas Gruenbacher
     

10 Aug, 2010

2 commits

  • The shrinker function is supposed to return the number of cache
    entries after shrinking, not before shrinking. Fix that.

    Based on a patch from Wang Sheng-Hui .

    Signed-off-by: Andreas Gruenbacher
    Signed-off-by: Al Viro

    Andreas Gruenbacher
     
  • The mbcache code was written to support a variable number of indexes,
    but all the existing users use exactly one index. Simplify to code to
    support only that case.

    There are also no users of the cache entry free operation, and none of
    the users keep extra data in cache entries. Remove those features as
    well.

    Signed-off-by: Andreas Gruenbacher
    Signed-off-by: Al Viro

    Andreas Gruenbacher
     

19 Jul, 2010

1 commit

  • The current shrinker implementation requires the registered callback
    to have global state to work from. This makes it difficult to shrink
    caches that are not global (e.g. per-filesystem caches). Pass the shrinker
    structure to the callback so that users can embed the shrinker structure
    in the context the shrinker needs to operate on and get back to it in the
    callback via container_of().

    Signed-off-by: Dave Chinner
    Reviewed-by: Christoph Hellwig

    Dave Chinner
     

16 Apr, 2008

1 commit

  • mb_cache_entry_alloc() was allocating cache entries with GFP_KERNEL. But
    filesystems are calling this function while holding xattr_sem so possible
    recursion into the fs violates locking ordering of xattr_sem and transaction
    start / i_mutex for ext2-4. Change mb_cache_entry_alloc() so that filesystems
    can specify desired gfp mask and use GFP_NOFS from all of them.

    Signed-off-by: Jan Kara
    Reported-by: Dave Jones
    Cc:
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jan Kara
     

26 Oct, 2007

1 commit

  • This patch fixes the c_entry_count counter of the mbcache. Currently
    it increments the counter first & allocate the cache entry later. In
    case of failure to allocate the entry due to insufficient memory this
    counter is still left incremented. This patch fixes this anomaly.

    Signed-off-by: Ram Gupta
    Signed-off-by: Linus Torvalds

    Ram Gupta
     

20 Jul, 2007

1 commit

  • Slab destructors were no longer supported after Christoph's
    c59def9f222d44bb7e2f0a559f2906191a0862d7 change. They've been
    BUGs for both slab and slub, and slob never supported them
    either.

    This rips out support for the dtor pointer from kmem_cache_create()
    completely and fixes up every single callsite in the kernel (there were
    about 224, not including the slab allocator definitions themselves,
    or the documentation references).

    Signed-off-by: Paul Mundt

    Paul Mundt
     

18 Jul, 2007

1 commit

  • I can never remember what the function to register to receive VM pressure
    is called. I have to trace down from __alloc_pages() to find it.

    It's called "set_shrinker()", and it needs Your Help.

    1) Don't hide struct shrinker. It contains no magic.
    2) Don't allocate "struct shrinker". It's not helpful.
    3) Call them "register_shrinker" and "unregister_shrinker".
    4) Call the function "shrink" not "shrinker".
    5) Reduce the 17 lines of waffly comments to 13, but document it properly.

    Signed-off-by: Rusty Russell
    Cc: David Chinner
    Cc: Trond Myklebust
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Rusty Russell
     

08 Dec, 2006

1 commit

  • Replace all uses of kmem_cache_t with struct kmem_cache.

    The patch was generated using the following script:

    #!/bin/sh
    #
    # Replace one string by another in all the kernel sources.
    #

    set -e

    for file in `find * -name "*.c" -o -name "*.h"|xargs grep -l $1`; do
    quilt add $file
    sed -e "1,\$s/$1/$2/g" $file >/tmp/$$
    mv /tmp/$$ $file
    quilt refresh
    done

    The script was run like this

    sh replace kmem_cache_t "struct kmem_cache"

    Signed-off-by: Christoph Lameter
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Christoph Lameter
     

30 Sep, 2006

1 commit


29 Mar, 2006

1 commit


24 Mar, 2006

1 commit

  • 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
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Paul Jackson
     

15 Jan, 2006

1 commit


07 Nov, 2005

1 commit

  • 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
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jesper Juhl
     

28 Oct, 2005

1 commit

  • - ->releasepage() annotated (s/int/gfp_t), instances updated
    - missing gfp_t in fs/* added
    - fixed misannotation from the original sweep caught by bitwise checks:
    XFS used __nocast both for gfp_t and for flags used by XFS allocator.
    The latter left with unsigned int __nocast; we might want to add a
    different type for those but for now let's leave them alone. That,
    BTW, is a case when __nocast use had been actively confusing - it had
    been used in the same code for two different and similar types, with
    no way to catch misuses. Switch of gfp_t to bitwise had caught that
    immediately...

    One tricky bit is left alone to be dealt with later - mapping->flags is
    a mix of gfp_t and error indications. Left alone for now.

    Signed-off-by: Al Viro
    Signed-off-by: Linus Torvalds

    Al Viro
     

28 Jul, 2005

1 commit


06 May, 2005

1 commit


17 Apr, 2005

1 commit

  • Initial git repository build. I'm not bothering with the full history,
    even though we have it. We can create a separate "historical" git
    archive of that later if we want to, and in the meantime it's about
    3.2GB when imported into git - space that would just make the early
    git days unnecessarily complicated, when we don't have a lot of good
    infrastructure for it.

    Let it rip!

    Linus Torvalds