Skip to content
  • Andi Kleen's avatar
    brlocks/lglocks: turn into functions · eea62f83
    Andi Kleen authored
    
    
    lglocks and brlocks are currently generated with some complicated macros
    in lglock.h.  But there's no reason to not just use common utility
    functions and put all the data into a common data structure.
    
    Since there are at least two users it makes sense to share this code in a
    library.  This is also easier maintainable than a macro forest.
    
    This will also make it later possible to dynamically allocate lglocks and
    also use them in modules (this would both still need some additional, but
    now straightforward, code)
    
    [akpm@linux-foundation.org: checkpatch fixes]
    Signed-off-by: default avatarAndi Kleen <ak@linux.intel.com>
    Cc: Al Viro <viro@zeniv.linux.org.uk>
    Cc: Rusty Russell <rusty@rustcorp.com.au>
    Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
    Signed-off-by: default avatarRusty Russell <rusty@rustcorp.com.au>
    Signed-off-by: default avatarAl Viro <viro@zeniv.linux.org.uk>
    eea62f83