/Linux-v5.4/lib/ |
D | test_ida.c | 16 void ida_dump(struct ida *ida) { } in ida_dump() argument 18 #define IDA_BUG_ON(ida, x) do { \ argument 21 ida_dump(ida); \ 31 static void ida_check_alloc(struct ida *ida) in ida_check_alloc() argument 36 IDA_BUG_ON(ida, ida_alloc(ida, GFP_KERNEL) != i); in ida_check_alloc() 38 ida_free(ida, 20); in ida_check_alloc() 39 ida_free(ida, 21); in ida_check_alloc() 41 id = ida_alloc(ida, GFP_KERNEL); in ida_check_alloc() 42 IDA_BUG_ON(ida, id < 0); in ida_check_alloc() 44 IDA_BUG_ON(ida, id != 10000); in ida_check_alloc() [all …]
|
D | idr.c | 379 int ida_alloc_range(struct ida *ida, unsigned int min, unsigned int max, in ida_alloc_range() argument 382 XA_STATE(xas, &ida->xa, min / IDA_BITMAP_BITS); in ida_alloc_range() 484 void ida_free(struct ida *ida, unsigned int id) in ida_free() argument 486 XA_STATE(xas, &ida->xa, id / IDA_BITMAP_BITS); in ida_free() 536 void ida_destroy(struct ida *ida) in ida_destroy() argument 538 XA_STATE(xas, &ida->xa, 0); in ida_destroy() 587 static void ida_dump(struct ida *ida) in ida_dump() argument 589 struct xarray *xa = &ida->xa; in ida_dump() 590 pr_debug("ida: %p node %p free %d\n", ida, xa->xa_head, in ida_dump()
|
/Linux-v5.4/include/linux/ |
D | idr.h | 244 struct ida { struct 253 #define DEFINE_IDA(name) struct ida name = IDA_INIT(name) argument 255 int ida_alloc_range(struct ida *, unsigned int min, unsigned int max, gfp_t); 256 void ida_free(struct ida *, unsigned int id); 257 void ida_destroy(struct ida *ida); 270 static inline int ida_alloc(struct ida *ida, gfp_t gfp) in ida_alloc() argument 272 return ida_alloc_range(ida, 0, ~0, gfp); in ida_alloc() 287 static inline int ida_alloc_min(struct ida *ida, unsigned int min, gfp_t gfp) in ida_alloc_min() argument 289 return ida_alloc_range(ida, min, ~0, gfp); in ida_alloc_min() 304 static inline int ida_alloc_max(struct ida *ida, unsigned int max, gfp_t gfp) in ida_alloc_max() argument [all …]
|
D | nfs_fs_sb.h | 218 struct ida openowner_id; 219 struct ida lockowner_id;
|
D | thermal.h | 217 struct ida ida; member
|
D | thunderbolt.h | 233 struct ida service_ids; 450 struct ida msix_ida;
|
/Linux-v5.4/tools/testing/radix-tree/ |
D | idr-test.c | 416 void ida_dump(struct ida *); 428 DEFINE_IDA(ida); in ida_check_nomem() 431 id = ida_alloc_min(&ida, 256, GFP_NOWAIT); in ida_check_nomem() 432 IDA_BUG_ON(&ida, id != -ENOMEM); in ida_check_nomem() 433 id = ida_alloc_min(&ida, 1UL << 30, GFP_NOWAIT); in ida_check_nomem() 434 IDA_BUG_ON(&ida, id != -ENOMEM); in ida_check_nomem() 435 IDA_BUG_ON(&ida, !ida_is_empty(&ida)); in ida_check_nomem() 443 DEFINE_IDA(ida); in ida_check_conv_user() 447 int id = ida_alloc(&ida, GFP_NOWAIT); in ida_check_conv_user() 449 IDA_BUG_ON(&ida, ((i % IDA_BITMAP_BITS) != in ida_check_conv_user() [all …]
|
/Linux-v5.4/drivers/net/ethernet/mellanox/mlx5/core/lib/ |
D | gid.c | 43 ida_init(&dev->roce.reserved_gids.ida); in mlx5_init_reserved_gids() 50 WARN_ON(!ida_is_empty(&dev->roce.reserved_gids.ida)); in mlx5_cleanup_reserved_gids() 53 ida_destroy(&dev->roce.reserved_gids.ida); in mlx5_cleanup_reserved_gids() 99 index = ida_simple_get(&dev->roce.reserved_gids.ida, in mlx5_core_reserved_gid_alloc() 113 ida_simple_remove(&dev->roce.reserved_gids.ida, gid_index); in mlx5_core_reserved_gid_free()
|
/Linux-v5.4/drivers/greybus/ |
D | hd.c | 22 static struct ida gb_hd_bus_id_map; 50 struct ida *id_map = &hd->cport_id_map; in gb_hd_cport_reserve() 65 struct ida *id_map = &hd->cport_id_map; in gb_hd_cport_release_reserved() 75 struct ida *id_map = &hd->cport_id_map; in gb_hd_cport_allocate()
|
/Linux-v5.4/include/media/ |
D | media-device.h | 20 struct ida; 158 struct ida entity_internal_idx;
|
/Linux-v5.4/drivers/pnp/ |
D | driver.c | 16 static int compare_func(const char *ida, const char *idb) in compare_func() argument 22 if (ida[i] != 'X' && in compare_func() 23 idb[i] != 'X' && toupper(ida[i]) != toupper(idb[i])) in compare_func()
|
/Linux-v5.4/drivers/nvdimm/ |
D | nd.h | 140 struct ida ns_ida; 141 struct ida btt_ida; 142 struct ida pfn_ida; 143 struct ida dax_ida;
|
/Linux-v5.4/arch/powerpc/platforms/powernv/ |
D | vas-window.c | 504 static void vas_release_window_id(struct ida *ida, int winid) in vas_release_window_id() argument 506 ida_free(ida, winid); in vas_release_window_id() 509 static int vas_assign_window_id(struct ida *ida) in vas_assign_window_id() argument 511 int winid = ida_alloc_max(ida, VAS_WINDOWS_PER_CHIP - 1, GFP_KERNEL); in vas_assign_window_id() 532 vas_release_window_id(&vinst->ida, winid); in vas_window_free() 540 winid = vas_assign_window_id(&vinst->ida); in vas_window_alloc() 560 vas_release_window_id(&vinst->ida, winid); in vas_window_alloc()
|
D | vas.h | 307 struct ida ida; member
|
D | vas.c | 50 ida_init(&vinst->ida); in init_vas_instance()
|
/Linux-v5.4/drivers/net/ipvlan/ |
D | ipvlan.h | 100 struct ida ida; member
|
D | ipvlan_main.c | 77 ida_init(&port->ida); in ipvlan_port_create() 105 ida_destroy(&port->ida); in ipvlan_port_destroy() 587 err = ida_simple_get(&port->ida, port->dev_id_start, 0xFFFE, in ipvlan_link_new() 590 err = ida_simple_get(&port->ida, 0x1, port->dev_id_start, in ipvlan_link_new() 623 ida_simple_remove(&port->ida, dev->dev_id); in ipvlan_link_new() 643 ida_simple_remove(&ipvlan->port->ida, dev->dev_id); in ipvlan_link_delete()
|
/Linux-v5.4/drivers/target/iscsi/ |
D | iscsi_target.h | 58 extern struct ida sess_ida;
|
/Linux-v5.4/drivers/misc/mic/host/ |
D | mic_intr.h | 74 struct ida cb_ida;
|
/Linux-v5.4/drivers/gpu/drm/ |
D | drm_connector.c | 69 struct ida ida; member 103 ida_init(&drm_connector_enum_list[i].ida); in drm_connector_ida_init() 111 ida_destroy(&drm_connector_enum_list[i].ida); in drm_connector_ida_destroy() 201 struct ida *connector_ida = in drm_connector_init() 202 &drm_connector_enum_list[connector_type].ida; in drm_connector_init() 453 ida_simple_remove(&drm_connector_enum_list[connector->connector_type].ida, in drm_connector_cleanup()
|
/Linux-v5.4/drivers/net/ethernet/netronome/nfp/flower/ |
D | main.h | 77 struct ida mac_off_ids; 114 struct ida ida_handle;
|
/Linux-v5.4/drivers/net/ethernet/mellanox/mlx5/core/en_accel/ |
D | ipsec.h | 83 struct ida halloc;
|
/Linux-v5.4/drivers/media/platform/coda/ |
D | coda.h | 94 struct ida ida; member
|
/Linux-v5.4/include/linux/greybus/ |
D | hd.h | 51 struct ida cport_id_map;
|
/Linux-v5.4/drivers/gpu/drm/vmwgfx/ |
D | vmwgfx_gmrid_manager.c | 41 struct ida gmr_ida;
|