Subversion Repositories HelenOS-historic

Compare Revisions

Ignore whitespace Rev 813 → Rev 814

/kernel/trunk/test/mm/falloc1/test.c
29,7 → 29,7
#include <test.h>
#include <mm/page.h>
#include <mm/frame.h>
#include <mm/heap.h>
#include <mm/slab.h>
#include <arch/mm/page.h>
#include <arch/types.h>
#include <debug.h>
55,7 → 55,7
printf("Allocating %d frames blocks ... ", 1 << order);
allocated = 0;
for (i = 0; i < MAX_FRAMES >> order; i++) {
frames[allocated] = frame_alloc_rc(order, FRAME_ATOMIC | FRAME_KA, &status);
frames[allocated] = PA2KA(PFN2ADDR(frame_alloc_rc(order, FRAME_ATOMIC | FRAME_KA, &status)));
if (ALIGN_UP(frames[allocated], FRAME_SIZE << order) != frames[allocated]) {
panic("Test failed. Block at address %X (size %dK) is not aligned\n", frames[allocated], (FRAME_SIZE << order) >> 10);
80,7 → 80,7
printf("Deallocating ... ");
for (i = 0; i < allocated; i++) {
frame_free(frames[i]);
frame_free(ADDR2PFN(KA2PA(frames[i])));
}
printf("done.\n");
}