MINORBITS
#define BSG_MAX_DEVS (1 << MINORBITS)
#define NR_EXT_DEVT (1 << MINORBITS)
#define BINDERFS_MAX_MINOR (1U << MINORBITS)
#define BINDERFS_MAX_MINOR (1U << MINORBITS)
#define N_DEVS ((1U<<MINORBITS)/AOE_PARTITIONS)
if ((1U << MINORBITS) % max_part != 0)
if (max_loop > 1UL << (MINORBITS - part_shift)) {
if (nbds_max > 1UL << (MINORBITS - part_shift))
minor_to_rbd_dev_id(1 << MINORBITS) - 1,
(1 << (MINORBITS - RNBD_PART_BITS)) - 1,
#define UBLK_MINORS (1U << MINORBITS)
minor_to_index(1 << MINORBITS) - 1, GFP_KERNEL);
if (minor >> MINORBITS) {
static_assert(FWCTL_MAX_DEVICES < (1U << MINORBITS));
#define DRM_EXTENDED_MINOR_LIMIT XA_LIMIT(192, (1 << MINORBITS) - 1)
#define BCACHE_DEVICE_IDX_MAX ((1U << MINORBITS)/BCACHE_MINORS)
dev->dmi.dev >= (1 << MINORBITS))
if (minor >= (1 << MINORBITS))
r = idr_alloc(&_minor_idr, MINOR_ALLOCED, 0, 1 << MINORBITS, GFP_NOWAIT);
if (MAJOR(dev) != _major || minor >= (1 << MINORBITS))
max_devices = min(MAX_DEVICES, (1 << MINORBITS) / perdev_minors);
ret = __register_chrdev(MTD_CHAR_MAJOR, 0, 1 << MINORBITS,
__unregister_chrdev(MTD_CHAR_MAJOR, 0, 1 << MINORBITS, "mtd");
#define TAP_NUM_DEVS (1U << MINORBITS)
#define WWAN_MAX_MINORS (1 << MINORBITS)
#define NVME_MINORS (1U << MINORBITS)
#define DASD_PER_MAJOR (1U << (MINORBITS - DASD_PARTN_BITS))
for (minor = 0; minor < (1<<MINORBITS); minor++) {
#define SG_MAX_DEVS (1 << MINORBITS)
#define UIO_MAX_DEVICES (1U << MINORBITS)
#define VDUSE_DEV_MAX (1U << MINORBITS)
#define VHOST_VDPA_DEV_MAX (1U << MINORBITS)
static unsigned long pseudo_lock_minor_avail = GENMASK(MINORBITS, 0);
first_bit = find_first_bit(&pseudo_lock_minor_avail, MINORBITS);
if (first_bit == MINORBITS)
dev = ida_alloc_range(&unnamed_dev_ida, 1, (1 << MINORBITS) - 1,
#define MAJOR(dev) ((unsigned int) ((dev) >> MINORBITS))
#define MKDEV(ma,mi) (((ma) << MINORBITS) | (mi))
#define MINORMASK ((1U << MINORBITS) - 1)
#define NR_UNIX98_PTY_MAX (1 << MINORBITS) /* Absolute limit */
#define MINORMASK ((1U << MINORBITS) - 1)
#define MAJOR(dev) ((unsigned int) ((dev) >> MINORBITS))