DragonFly BSD
DragonFly commits List (threaded) for 2013-02
[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]

git: kernel - Fix kernel panic caused by rename race


From: Matthew Dillon <dillon@xxxxxxxxxxxxxxxxxxxxxxx>
Date: Fri, 1 Feb 2013 13:50:05 -0800 (PST)

commit e2a099cf1b1188b60aecc18de449444f7dca0f6a
Author: Matthew Dillon <dillon@apollo.backplane.com>
Date:   Fri Feb 1 13:47:37 2013 -0800

    kernel - Fix kernel panic caused by rename race
    
    * kern_rename() must temporarily unlock the source ncp when resolving the
      target ncp, and will sometimes have to temporarily unlock the target ncp
      when relocking both.  This can race against a topological removal of one
      or both ncp's, resulting in incorrect operation or a panic due to a
      NULL vp.
    
    * Detect the case and return EAGAIN if the ncp's have been marked NCF_DESTROYED
      or if fromncp loses its vp resolution.  Callers detect the EAGAIN and retry
      the operation.
    
    Reported-by: ftigeot

Summary of changes:
 sys/emulation/linux/linux_file.c | 18 +++++++------
 sys/kern/vfs_syscalls.c          | 58 +++++++++++++++++++++++++++-------------
 2 files changed, 50 insertions(+), 26 deletions(-)

http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/e2a099cf1b1188b60aecc18de449444f7dca0f6a


-- 
DragonFly BSD source repository



[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]