Use startPage, not start, to calculate initial bitmapIndex and bitmapOffset

This commit is contained in:
Eryn Wells 2016-04-14 00:10:48 -04:00
parent 051dc27006
commit eb7997c037

View file

@ -59,8 +59,8 @@ FrameAllocator::reserveRange(u32 start,
// Iterators
u32 page = startPage;
u32 bitmapIndex = start / pagesPerBitmap;
u8 bitmapOffset = start % pagesPerBitmap;
u32 bitmapIndex = startPage / pagesPerBitmap;
u8 bitmapOffset = startPage % pagesPerBitmap;
kstd::printFormat("Reserving %ld pages for memory addresses between 0x%08lX and 0x%08lX\n", endPage - startPage, start, start + length);