util: convert slab macros to inline functions