Re: [PATCH] xen-blkfront: Use the bitmap API when applicable

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

 



On Sat, 2021-12-04 at 07:57 +0100, Christophe JAILLET wrote:
> So, maybe adding an "official" 'bitmap_size()' (which is already 
> existing and duplicated in a few places) would ease things.
> 
> It would replace the 'nr_minors = BITS_TO_LONGS(end) * BITS_PER_LONG;' 
> and hide the implementation details of the bitmap API.
> 
> Something like:
> static __always_inline size_t bitmap_size(unsigned long nr_bits)
> {
> 	return BITS_TO_LONGS(nr_bits) * sizeof(long);
> }

Or maybe a bitmap_realloc




[Index of Archives]     [Linux RAID]     [Linux SCSI]     [Linux ATA RAID]     [IDE]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Device Mapper]

  Powered by Linux