mirror of
https://git.rtems.org/rtems-libbsd/
synced 2025-10-16 16:39:49 +08:00
Added in uma_find_refcnt() and vtoslab()
The vtoslab returns NULL for now which will cause a fault when the code runs.
This commit is contained in:
@@ -3043,7 +3043,6 @@ uma_prealloc(uma_zone_t zone, int items)
|
|||||||
ZONE_UNLOCK(zone);
|
ZONE_UNLOCK(zone);
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifndef __rtems__
|
|
||||||
/* See uma.h */
|
/* See uma.h */
|
||||||
u_int32_t *
|
u_int32_t *
|
||||||
uma_find_refcnt(uma_zone_t zone, void *item)
|
uma_find_refcnt(uma_zone_t zone, void *item)
|
||||||
@@ -3063,7 +3062,6 @@ uma_find_refcnt(uma_zone_t zone, void *item)
|
|||||||
refcnt = &slabref->us_freelist[idx].us_refcnt;
|
refcnt = &slabref->us_freelist[idx].us_refcnt;
|
||||||
return refcnt;
|
return refcnt;
|
||||||
}
|
}
|
||||||
#endif /* __rtems__ */
|
|
||||||
|
|
||||||
/* See uma.h */
|
/* See uma.h */
|
||||||
void
|
void
|
||||||
|
@@ -391,10 +391,10 @@ hash_sfind(struct uma_hash *hash, u_int8_t *data)
|
|||||||
return (NULL);
|
return (NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifndef __rtems__
|
|
||||||
static __inline uma_slab_t
|
static __inline uma_slab_t
|
||||||
vtoslab(vm_offset_t va)
|
vtoslab(vm_offset_t va)
|
||||||
{
|
{
|
||||||
|
#ifndef __rtems__
|
||||||
vm_page_t p;
|
vm_page_t p;
|
||||||
uma_slab_t slab;
|
uma_slab_t slab;
|
||||||
|
|
||||||
@@ -405,8 +405,12 @@ vtoslab(vm_offset_t va)
|
|||||||
return (slab);
|
return (slab);
|
||||||
else
|
else
|
||||||
return (NULL);
|
return (NULL);
|
||||||
|
#else /* __rtems__ */
|
||||||
|
return (NULL); /* XXX - FIX THIS!!! */
|
||||||
|
#endif /* __rtems__ */
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifndef __rtems__
|
||||||
static __inline void
|
static __inline void
|
||||||
vsetslab(vm_offset_t va, uma_slab_t slab)
|
vsetslab(vm_offset_t va, uma_slab_t slab)
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user