Subversion Repositories HelenOS-historic

Compare Revisions

Ignore whitespace Rev 1765 → Rev 1766

/kernel/trunk/generic/src/mm/slab.c
161,11 → 161,10
slab_t *slab;
size_t fsize;
int i;
int status;
int zone=0;
data = frame_alloc_rc_zone(cache->order, FRAME_KA | flags, &status, &zone);
if (status != FRAME_OK) {
data = frame_alloc_generic(cache->order, FRAME_KA | flags, &zone);
if (!data) {
return NULL;
}
if (! (cache->flags & SLAB_CACHE_SLINSIDE)) {
/kernel/trunk/generic/src/mm/frame.c
931,7 → 931,7
* @return Physical address of the allocated frame.
*
*/
void * frame_alloc_generic(__u8 order, int flags, int *status, int *pzone)
void * frame_alloc_generic(__u8 order, int flags, int *pzone)
{
ipl_t ipl;
int freed;
967,12 → 967,8
*/
interrupts_restore(ipl);
 
if (flags & FRAME_ATOMIC) {
ASSERT(status != NULL);
if (status)
*status = FRAME_NO_MEMORY;
if (flags & FRAME_ATOMIC)
return 0;
}
panic("Sleep not implemented.\n");
goto loop;
984,9 → 980,6
spinlock_unlock(&zone->lock);
interrupts_restore(ipl);
 
if (status)
*status = FRAME_OK;
 
if (flags & FRAME_KA)
return (void *)PA2KA(PFN2ADDR(v));
return (void *)PFN2ADDR(v);