os/kernelhwsrv/kernel/eka/memmodel/epoc/direct/x86/xinit.cpp
changeset 0 bde4ae8d615e
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/os/kernelhwsrv/kernel/eka/memmodel/epoc/direct/x86/xinit.cpp	Fri Jun 15 03:10:57 2012 +0200
     1.3 @@ -0,0 +1,64 @@
     1.4 +// Copyright (c) 1996-2009 Nokia Corporation and/or its subsidiary(-ies).
     1.5 +// All rights reserved.
     1.6 +// This component and the accompanying materials are made available
     1.7 +// under the terms of the License "Eclipse Public License v1.0"
     1.8 +// which accompanies this distribution, and is available
     1.9 +// at the URL "http://www.eclipse.org/legal/epl-v10.html".
    1.10 +//
    1.11 +// Initial Contributors:
    1.12 +// Nokia Corporation - initial contribution.
    1.13 +//
    1.14 +// Contributors:
    1.15 +//
    1.16 +// Description:
    1.17 +// e32\memmodel\epoc\direct\x86\xinit.cpp
    1.18 +// 
    1.19 +//
    1.20 +
    1.21 +#include <x86_mem.h>
    1.22 +#include <e32uid.h>
    1.23 +#include <kernel/cache.h>
    1.24 +
    1.25 +void MM::Init1()
    1.26 +	{
    1.27 +	__KTRACE_OPT(KBOOT,Kern::Printf("MM::Init1()"));
    1.28 +
    1.29 +	MM::RamBlockSize=0x1000;
    1.30 +	MM::RamBlockShift=12;
    1.31 +
    1.32 +	PP::MaxUserThreadStack=0x14000;			// 80K - STDLIB asks for 64K for PosixServer!!!!
    1.33 +	PP::UserThreadStackGuard=0x2000;		// 8K
    1.34 +	PP::MaxStackSpacePerProcess=0x200000;	// 2Mb
    1.35 +	K::SupervisorThreadStackSize=0x1000;	// 4K
    1.36 +	PP::SupervisorThreadStackGuard=0x1000;	// 4K
    1.37 +
    1.38 +	K::MachineConfig=(TMachineConfig*)(((TUint8*)SuperPageAddress)+0x800);	// HACK!!
    1.39 +
    1.40 +	K::MaxMemCopyInOneGo = KDefaultMaxMemCopyInOneGo;
    1.41 +
    1.42 +	PP::RamDriveStartAddress = TheSuperPage().iKernelLimit;
    1.43 +	PP::RamDriveMaxSize = TheRomHeader().iUserDataAddress - PP::RamDriveStartAddress;
    1.44 +	__KTRACE_OPT(KBOOT,Kern::Printf("RamDriveBase %08x RamDriveMaxSize %08x",PP::RamDriveStartAddress,PP::RamDriveMaxSize));
    1.45 +	__KTRACE_OPT(KBOOT,Kern::Printf("K::MaxMemCopyInOneGo=0x%x",K::MaxMemCopyInOneGo));
    1.46 +
    1.47 +	K::MemModelAttributes=EMemModelTypeDirect|EMemModelAttrNonExProt|EMemModelAttrKernProt|EMemModelAttrWriteProt;
    1.48 +	}
    1.49 +
    1.50 +#ifdef __CPU_HAS_CACHE
    1.51 +// Set up virtual addresses used for cache flushing if this is
    1.52 +// done by data read or line allocate
    1.53 +void M::SetupCacheFlushPtr(TInt aCache, SCacheInfo& aInfo)
    1.54 +	{
    1.55 +	}
    1.56 +#endif
    1.57 +
    1.58 +#ifdef __SMP__
    1.59 +void M::GetAPBootInfo(TInt /*aCpu*/, volatile SAPBootInfo* /*aInfo*/)
    1.60 +	{
    1.61 +	}
    1.62 +
    1.63 +void M::Init2AP()
    1.64 +	{
    1.65 +	__KTRACE_OPT(KBOOT,Kern::Printf("M::Init2AP()"));
    1.66 +	}
    1.67 +#endif