Open m-joon-ixix opened 5 months ago
Block size should be a multiple of 32 so that the last 4 degrees of size is 0000 as a binary number.
If the status is free: the last 4 degree of header/footer -> 0000 If the status is allocated: the last 4 degree of header/footer -> 0001
So it's no matter to set STATUS_MASK as 1111, 0111, 0011, or 0001. ( respectively equal to 0xf, 0x7, 0x3, 0x1)
There exists a pre-defined macro as below, on the given
memmgr.c
file.Shouldn't this be
0x1
, not0x7
?