On Tue, 2015-09-15 at 09:46 -0700, Lee Duncan wrote: > Clients of the ida and idr index-management routines > tend to use the same calling sequences much of the time, > so this change adds helper functions for allocating and > releasing indexes of either flavor, i.e. with or > without pointer management. > > Inline functions added for idr: > idr_get_index_in_range > idr_get_index (in range 0,0) > idr_put_index > And for ida: > ida_get_index > ida_put_index Every consumer of this I've seen seems to have the pattern of allocating the ida and the protecting spinlock together. If that's the case, why not move the spinlock into struct ida so it doesn't have to be separately allocated and passed in to all the helpers? Also, you need a cc of Tejun (added on this one) because he's the one who last did significant work in ida/idr. James -- To unsubscribe from this list: send the line "unsubscribe linux-scsi" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html