|
|
@ -167,12 +167,12 @@ ck_hs_map_create(struct ck_hs *hs, unsigned long entries)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
bool
|
|
|
|
bool
|
|
|
|
ck_hs_reset(struct ck_hs *hs)
|
|
|
|
ck_hs_reset_size(struct ck_hs *hs, unsigned long capacity)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
struct ck_hs_map *map, *previous;
|
|
|
|
struct ck_hs_map *map, *previous;
|
|
|
|
|
|
|
|
|
|
|
|
previous = hs->map;
|
|
|
|
previous = hs->map;
|
|
|
|
map = ck_hs_map_create(hs, previous->capacity);
|
|
|
|
map = ck_hs_map_create(hs, capacity);
|
|
|
|
if (map == NULL)
|
|
|
|
if (map == NULL)
|
|
|
|
return false;
|
|
|
|
return false;
|
|
|
|
|
|
|
|
|
|
|
@ -181,6 +181,15 @@ ck_hs_reset(struct ck_hs *hs)
|
|
|
|
return true;
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
bool
|
|
|
|
|
|
|
|
ck_hs_reset(struct ck_hs *hs)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
struct ck_hs_map *previous;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
previous = hs->map;
|
|
|
|
|
|
|
|
return ck_hs_reset_size(hs, previous->capacity);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
static inline unsigned long
|
|
|
|
static inline unsigned long
|
|
|
|
ck_hs_map_probe_next(struct ck_hs_map *map,
|
|
|
|
ck_hs_map_probe_next(struct ck_hs_map *map,
|
|
|
|
unsigned long offset,
|
|
|
|
unsigned long offset,
|
|
|
|