- cleanups
- disable tracing mmu - make scratch buffer 8k as it's declared as such... that makes things much better indeed :) git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26537 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -29,7 +29,7 @@ extern uint8 gBootDriveID;
|
||||
extern uint32 gBootPartitionOffset;
|
||||
|
||||
#define SCRATCH_SIZE (2*4096)
|
||||
static uint8 gScratchBuffer[4096];
|
||||
static uint8 gScratchBuffer[SCRATCH_SIZE];
|
||||
|
||||
static const uint16 kParametersSizeVersion1 = sizeof(struct tos_bpb);
|
||||
static const uint16 kParametersSizeVersion2 = 0x1e;
|
||||
@@ -584,8 +584,8 @@ BlockHandle::ReadAt(void *cookie, off_t pos, void *buffer, size_t bufferSize)
|
||||
uint32 blocksLeft = (bufferSize + offset + fBlockSize - 1) / fBlockSize;
|
||||
int32 totalBytesRead = 0;
|
||||
|
||||
//TRACE(("BIOS reads %lu bytes from %Ld (offset = %lu), drive %u\n",
|
||||
// blocksLeft * fBlockSize, pos * fBlockSize, offset, fDriveID));
|
||||
//TRACE(("BIOS reads %lu bytes from %Ld (offset = %lu)\n",
|
||||
// blocksLeft * fBlockSize, pos * fBlockSize, offset));
|
||||
|
||||
// read partial block
|
||||
if (offset) {
|
||||
@@ -622,6 +622,7 @@ BlockHandle::ReadAt(void *cookie, off_t pos, void *buffer, size_t bufferSize)
|
||||
totalBytesRead += bytesRead;
|
||||
}
|
||||
|
||||
//TRACE(("BlockHandle::%s: %d bytes read\n", __FUNCTION__, totalBytesRead));
|
||||
return totalBytesRead;
|
||||
}
|
||||
|
||||
@@ -893,7 +894,7 @@ XHDIDrive::FillIdentifier()
|
||||
ssize_t
|
||||
XHDIDrive::ReadBlocks(void *buffer, off_t first, int32 count)
|
||||
{
|
||||
int sectorsPerBlocks = (fBlockSize / 256);
|
||||
int sectorsPerBlock = (fBlockSize / 256);
|
||||
int32 ret;
|
||||
uint16 flags = RW_READ;
|
||||
TRACE(("XHDIDrive::%s(%Ld, %d) (%d,%d)\n", __FUNCTION__, first, count, fMajor, fMinor));
|
||||
|
||||
@@ -68,7 +68,7 @@
|
||||
*/
|
||||
#warning M68K: check for Physbase() < ST_RAM_TOP
|
||||
|
||||
#define TRACE_MMU
|
||||
//#define TRACE_MMU
|
||||
#ifdef TRACE_MMU
|
||||
# define TRACE(x) dprintf x
|
||||
#else
|
||||
@@ -355,6 +355,7 @@ mmu_allocate(void *virtualAddress, size_t size)
|
||||
address += B_PAGE_SIZE;
|
||||
}
|
||||
|
||||
TRACE(("mmu_allocate(KERNEL, %d): done\n", size));
|
||||
return virtualAddress;
|
||||
}
|
||||
|
||||
@@ -364,6 +365,7 @@ mmu_allocate(void *virtualAddress, size_t size)
|
||||
map_page(get_next_virtual_page(), get_next_physical_page(), kDefaultPageFlags);
|
||||
}
|
||||
|
||||
TRACE(("mmu_allocate(NULL, %d): %p\n", size, address));
|
||||
return address;
|
||||
}
|
||||
|
||||
|
||||
@@ -23,7 +23,7 @@
|
||||
#include "arch_040_mmu.h"
|
||||
|
||||
|
||||
#define TRACE_MMU
|
||||
//#define TRACE_MMU
|
||||
#ifdef TRACE_MMU
|
||||
# define TRACE(x) dprintf x
|
||||
#else
|
||||
|
||||
@@ -77,6 +77,8 @@ platform_start_kernel(void)
|
||||
mmu_init_for_kernel();
|
||||
//smp_boot_other_cpus();
|
||||
|
||||
#warning M68K: stop ints
|
||||
|
||||
dprintf("kernel entry at %lx\n", gKernelArgs.kernel_image.elf_header.e_entry);
|
||||
|
||||
asm("move.l %0, %%sp; " // move stack out of way
|
||||
|
||||
Reference in New Issue
Block a user