Home
last modified time | relevance | path

Searched refs:BITS_PER_PAGE (Results 1 – 6 of 6) sorted by relevance

/linux-4.1.27/include/linux/
Dpid_namespace.h18 #define BITS_PER_PAGE (PAGE_SIZE * 8) macro
19 #define BITS_PER_PAGE_MASK (BITS_PER_PAGE-1)
20 #define PIDMAP_ENTRIES ((PID_MAX_LIMIT+BITS_PER_PAGE-1)/BITS_PER_PAGE)
/linux-4.1.27/kernel/
Dpid.c58 return (map - pid_ns->pidmap)*BITS_PER_PAGE + off; in mk_pid()
62 find_next_zero_bit((map)->page, BITS_PER_PAGE, off)
75 [ 0 ... PIDMAP_ENTRIES-1] = { ATOMIC_INIT(BITS_PER_PAGE), NULL }
108 struct pidmap *map = upid->ns->pidmap + nr / BITS_PER_PAGE; in free_pidmap()
163 map = &pid_ns->pidmap[pid/BITS_PER_PAGE]; in alloc_pidmap()
169 max_scan = DIV_ROUND_UP(pid_max, BITS_PER_PAGE) - !offset; in alloc_pidmap()
195 if (offset >= BITS_PER_PAGE) in alloc_pidmap()
202 if (map < &pid_ns->pidmap[(pid_max-1)/BITS_PER_PAGE]) { in alloc_pidmap()
225 map = &pid_ns->pidmap[(last + 1)/BITS_PER_PAGE]; in next_pidmap()
230 offset = find_next_bit((map)->page, BITS_PER_PAGE, offset); in next_pidmap()
[all …]
Dpid_namespace.c121 atomic_set(&ns->pidmap[0].nr_free, BITS_PER_PAGE - 1); in create_pid_namespace()
124 atomic_set(&ns->pidmap[i].nr_free, BITS_PER_PAGE); in create_pid_namespace()
/linux-4.1.27/drivers/infiniband/hw/ipath/
Dipath_qp.c42 #define BITS_PER_PAGE (PAGE_SIZE*BITS_PER_BYTE) macro
43 #define BITS_PER_PAGE_MASK (BITS_PER_PAGE-1)
44 #define mk_qpn(qpt, map, off) (((map) - (qpt)->map) * BITS_PER_PAGE + \
47 BITS_PER_PAGE, off)
136 map = &qpt->map[qpn / BITS_PER_PAGE]; in alloc_qpn()
162 } while (offset < BITS_PER_PAGE && qpn < QPN_MAX); in alloc_qpn()
194 map = qpt->map + qpn / BITS_PER_PAGE; in free_qpn()
1038 atomic_set(&idev->qp_table.map[i].n_free, BITS_PER_PAGE); in ipath_init_qp_table()
/linux-4.1.27/drivers/infiniband/hw/qib/
Dqib_qp.c44 #define BITS_PER_PAGE (PAGE_SIZE*BITS_PER_BYTE) macro
45 #define BITS_PER_PAGE_MASK (BITS_PER_PAGE-1)
50 return (map - qpt->map) * BITS_PER_PAGE + off; in mk_qpn()
62 off = find_next_zero_bit(map->page, BITS_PER_PAGE, off); in find_next_offset()
151 map = &qpt->map[qpn / BITS_PER_PAGE]; in alloc_qpn()
176 } while (offset < BITS_PER_PAGE && qpn < QPN_MAX); in alloc_qpn()
207 map = qpt->map + qpn / BITS_PER_PAGE; in free_qpn()
/linux-4.1.27/drivers/block/drbd/
Ddrbd_bitmap.c482 #define BITS_PER_PAGE (1UL << (PAGE_SHIFT + 3)) macro
483 #define BITS_PER_PAGE_MASK (BITS_PER_PAGE - 1)