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

DEVFS - Factor out recursive code into iterate_topology


From: Alex Hornung <alexh@xxxxxxxxxxxxxxxxxxxxxxx>
Date: Sat, 8 Aug 2009 10:01:19 -0700 (PDT)

commit 66abefa5a42a0b63ca3bb1fbb1601c3955401681
Author: Alex Hornung <ahornung@gmail.com>
Date:   Sat Aug 8 17:42:02 2009 +0100

    DEVFS - Factor out recursive code into iterate_topology
    
    * Factor out the recursive code which scans through all nodes in
      the topology into a function, devfs_iterate_topology, which takes
      a callback as argument, which is called for every node.
    
    * Create new callback functions for all functions that were recursive
      before, containing the code that was executed for each node.
    
    * Change all callers of recursive functions to call
      devfs_iterate_topology with the respective callback function
      instead of having their own recursive functions.

Summary of changes:
 sys/vfs/devfs/devfs.h       |    8 ++-
 sys/vfs/devfs/devfs_core.c  |  201 +++++++++++++++---------------------------
 sys/vfs/devfs/devfs_rules.c |   14 ++--
 sys/vfs/devfs/devfs_rules.h |    6 +-
 4 files changed, 88 insertions(+), 141 deletions(-)

http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/66abefa5a42a0b63ca3bb1fbb1601c3955401681


-- 
DragonFly BSD source repository



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