mirror of
https://gitlab.freedesktop.org/wayland/wayland.git
synced 2025-10-31 22:25:25 -04:00
wayland-util: do not export the wl_map_* API
Used only internally and explicitly marked as such with commit
cf04b0a18f ("Move private definitions and prototypes to new
zwayland-private.h")
Signed-off-by: Emil Velikov <emil.velikov@collabora.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
This commit is contained in:
parent
9b78be6bb0
commit
654dee85c6
1 changed files with 9 additions and 9 deletions
|
|
@ -177,21 +177,21 @@ union map_entry {
|
||||||
#define map_entry_get_data(entry) ((void *)((entry).next & ~(uintptr_t)0x3))
|
#define map_entry_get_data(entry) ((void *)((entry).next & ~(uintptr_t)0x3))
|
||||||
#define map_entry_get_flags(entry) (((entry).next >> 1) & 0x1)
|
#define map_entry_get_flags(entry) (((entry).next >> 1) & 0x1)
|
||||||
|
|
||||||
WL_EXPORT void
|
void
|
||||||
wl_map_init(struct wl_map *map, uint32_t side)
|
wl_map_init(struct wl_map *map, uint32_t side)
|
||||||
{
|
{
|
||||||
memset(map, 0, sizeof *map);
|
memset(map, 0, sizeof *map);
|
||||||
map->side = side;
|
map->side = side;
|
||||||
}
|
}
|
||||||
|
|
||||||
WL_EXPORT void
|
void
|
||||||
wl_map_release(struct wl_map *map)
|
wl_map_release(struct wl_map *map)
|
||||||
{
|
{
|
||||||
wl_array_release(&map->client_entries);
|
wl_array_release(&map->client_entries);
|
||||||
wl_array_release(&map->server_entries);
|
wl_array_release(&map->server_entries);
|
||||||
}
|
}
|
||||||
|
|
||||||
WL_EXPORT uint32_t
|
uint32_t
|
||||||
wl_map_insert_new(struct wl_map *map, uint32_t flags, void *data)
|
wl_map_insert_new(struct wl_map *map, uint32_t flags, void *data)
|
||||||
{
|
{
|
||||||
union map_entry *start, *entry;
|
union map_entry *start, *entry;
|
||||||
|
|
@ -223,7 +223,7 @@ wl_map_insert_new(struct wl_map *map, uint32_t flags, void *data)
|
||||||
return (entry - start) + base;
|
return (entry - start) + base;
|
||||||
}
|
}
|
||||||
|
|
||||||
WL_EXPORT int
|
int
|
||||||
wl_map_insert_at(struct wl_map *map, uint32_t flags, uint32_t i, void *data)
|
wl_map_insert_at(struct wl_map *map, uint32_t flags, uint32_t i, void *data)
|
||||||
{
|
{
|
||||||
union map_entry *start;
|
union map_entry *start;
|
||||||
|
|
@ -251,7 +251,7 @@ wl_map_insert_at(struct wl_map *map, uint32_t flags, uint32_t i, void *data)
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
WL_EXPORT int
|
int
|
||||||
wl_map_reserve_new(struct wl_map *map, uint32_t i)
|
wl_map_reserve_new(struct wl_map *map, uint32_t i)
|
||||||
{
|
{
|
||||||
union map_entry *start;
|
union map_entry *start;
|
||||||
|
|
@ -290,7 +290,7 @@ wl_map_reserve_new(struct wl_map *map, uint32_t i)
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
WL_EXPORT void
|
void
|
||||||
wl_map_remove(struct wl_map *map, uint32_t i)
|
wl_map_remove(struct wl_map *map, uint32_t i)
|
||||||
{
|
{
|
||||||
union map_entry *start;
|
union map_entry *start;
|
||||||
|
|
@ -314,7 +314,7 @@ wl_map_remove(struct wl_map *map, uint32_t i)
|
||||||
map->free_list = (i << 1) | 1;
|
map->free_list = (i << 1) | 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
WL_EXPORT void *
|
void *
|
||||||
wl_map_lookup(struct wl_map *map, uint32_t i)
|
wl_map_lookup(struct wl_map *map, uint32_t i)
|
||||||
{
|
{
|
||||||
union map_entry *start;
|
union map_entry *start;
|
||||||
|
|
@ -337,7 +337,7 @@ wl_map_lookup(struct wl_map *map, uint32_t i)
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
WL_EXPORT uint32_t
|
uint32_t
|
||||||
wl_map_lookup_flags(struct wl_map *map, uint32_t i)
|
wl_map_lookup_flags(struct wl_map *map, uint32_t i)
|
||||||
{
|
{
|
||||||
union map_entry *start;
|
union map_entry *start;
|
||||||
|
|
@ -379,7 +379,7 @@ for_each_helper(struct wl_array *entries, wl_iterator_func_t func, void *data)
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
WL_EXPORT void
|
void
|
||||||
wl_map_for_each(struct wl_map *map, wl_iterator_func_t func, void *data)
|
wl_map_for_each(struct wl_map *map, wl_iterator_func_t func, void *data)
|
||||||
{
|
{
|
||||||
enum wl_iterator_result ret;
|
enum wl_iterator_result ret;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue