git: DragonFly_RELEASE_3_6 idr : Fix logic error in binary tree allocation

Francois Tigeot ftigeot at crater.dragonflybsd.org
Thu Dec 5 07:16:00 PST 2013


commit a25082ce00c361fc5714e1eeabb274554abec5ab
Author: Joris Giovannangeli <joris at dragonflybsd.org>
Date:   Tue Dec 3 01:55:27 2013 +0100

    idr : Fix logic error in binary tree allocation
    
     * A complete binary tree has 2^n - 1 nodes, not 2^n. Changes default size
       to be 2^n - 1.
    
     * While here, also add proper locking directives to idr_grow and idr_remove_all

Summary of changes:
 sys/libkern/linux_idr.c | 34 +++++++++++++++++++++++++++++-----
 1 file changed, 29 insertions(+), 5 deletions(-)

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


-- 
DragonFly BSD source repository



More information about the Commits mailing list