this better not be it.
This commit is contained in:
parent
5069e4cefc
commit
ec629f31e2
@ -161,18 +161,26 @@
|
|||||||
void print_memory(node *umem_head, node *hole_head) {
|
void print_memory(node *umem_head, node *hole_head) {
|
||||||
|
|
||||||
u32 total_memory = 0x3FFFF;
|
u32 total_memory = 0x3FFFF;
|
||||||
// u32 free_memory = total_memory;
|
u32 free_memory = total_memory;
|
||||||
// u32 total_allocated = total_memory - free_memory;
|
u32 total_allocated = total_memory - free_memory;
|
||||||
//
|
|
||||||
// int num_of_gaps = 0;
|
int num_of_gaps = 0;
|
||||||
// int num_of_nodes = 0;
|
int num_of_nodes = 0;
|
||||||
// while (umem_head
|
while (umem_head != NULL) {
|
||||||
|
num_of_nodes++;
|
||||||
|
free_memory = free_memory - umem_head->limit_register;
|
||||||
|
umem_head = umem_head->next;
|
||||||
|
}
|
||||||
|
|
||||||
|
while (hole_head != NULL) {
|
||||||
|
num_of_gaps++;
|
||||||
|
}
|
||||||
|
|
||||||
char c[16];
|
char c[16];
|
||||||
hex_to_ascii( total_memory, c, 16);
|
hex_to_ascii( total_memory/1024, c, 16);
|
||||||
kprint("Total Physical Memory: ");
|
kprint("Total Physical Memory: ");
|
||||||
kprint(c);
|
kprint(c);
|
||||||
kprint("\n");
|
kprint("kb\n");
|
||||||
|
|
||||||
print_list(umem_head, false);
|
print_list(umem_head, false);
|
||||||
print_list(hole_head, false);
|
print_list(hole_head, false);
|
||||||
|
Reference in New Issue
Block a user