git: tmpfs - Use atomic_fetchadd_long() to allocate inode numbers

Matthew Dillon dillon at crater.dragonflybsd.org
Tue Oct 30 18:52:57 PDT 2018


commit 5af112ab74684a87cb5fe9e8e313d7f5187bde86
Author: Matthew Dillon <dillon at apollo.backplane.com>
Date:   Tue Oct 30 18:50:03 2018 -0700

    tmpfs - Use atomic_fetchadd_long() to allocate inode numbers
    
    * Since DFly inode numbers are 64 bits wide, tmpfs just increments a
      per-mount counter to allocate a new inode.
    
    * We had some old code in tmpfs to allocate inode numbers which wrapped
      a tmpfs mount lock around the increment.  This is totally unnecessary.
      Use atomic_fetchadd_long() instead.
    
    Reported-by: mjg

Summary of changes:
 sys/vfs/tmpfs/tmpfs_subr.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/5af112ab74684a87cb5fe9e8e313d7f5187bde86


-- 
DragonFly BSD source repository


More information about the Commits mailing list