201019_04
authorhgs
Wed, 12 May 2010 10:34:10 +0100
changeset 133 2a0ada0a1bf8
parent 132 e4a7b1cbe40c
child 134 95847726fe57
201019_04
kernel/eka/drivers/medmmc/medmmc.cpp
kernel/eka/include/e32math.h
kernel/eka/include/e32ver.h
kernel/eka/release.txt
kerneltest/e32test/benchmark/bm_rapu_pdd.cpp
kerneltest/e32test/cppexceptions/second_excp.h
kerneltest/e32test/eabi/d_second_excp2_40u.def
kerneltest/e32test/eabi/d_second_excp_40u.def
kerneltest/e32test/group/bm_pdd.mmp
kerneltest/e32test/group/d_cache.mmp
kerneltest/e32test/group/d_second_excp.mmp
kerneltest/e32test/group/d_second_excp2.mmp
kerneltest/e32test/group/t_suser.mmp
kerneltest/e32test/multimedia/t_sound2.cpp
kerneltest/e32test/power/t_domain.cpp
kerneltest/e32test/prime/t_timer.cpp
kerneltest/e32test/realtime/d_latncy.cpp
kerneltest/e32test/secure/t_suser.cpp
kerneltest/e32test/system/d_mstim.cpp
kerneltest/e32test/system/d_tick.cpp
kerneltest/f32test/server/t_dlocl.cpp
--- a/kernel/eka/drivers/medmmc/medmmc.cpp	Mon May 10 11:40:53 2010 +0100
+++ b/kernel/eka/drivers/medmmc/medmmc.cpp	Wed May 12 10:34:10 2010 +0100
@@ -1485,7 +1485,8 @@
 					}
 				}
 			}
-	
+
+#ifdef _ENABLE_EMMC_RELIABLE_WRITE_		
 			//Reliable Write only supported by v4.3+ MMC media
 			if (iCard->ExtendedCSD().ExtendedCSDRev() >= 3)
 				{
@@ -1497,6 +1498,7 @@
 					iSession->Command().iFlags|= KMMCCmdFlagReliableWrite;
 					}
 				}
+#endif //_ENABLE_EMMC_RELIABLE_WRITE_			
 		
 			// Engage the data transfer session...
 			r = EngageAndSetWriteRequest(aMedReq);
--- a/kernel/eka/include/e32math.h	Mon May 10 11:40:53 2010 +0100
+++ b/kernel/eka/include/e32math.h	Wed May 12 10:34:10 2010 +0100
@@ -456,11 +456,6 @@
 	IMPORT_C static TInt ATan(TReal &aTrg,const TReal &aSrc);
 	IMPORT_C static TInt ATan(TReal &aTrg,const TReal &aSrcY,const TReal &aSrcX);
 	IMPORT_C static TInt Cos(TReal &aTrg,const TReal &aSrc);
-	
-	/**
-	This function is not implemented by Symbian OS.
-	*/
-	IMPORT_C static TInt DtoR(TReal &aTrg,const TDesC &aSrc,TInt &aPos,const TChar aPoint);
 	IMPORT_C static TInt Exp(TReal &aTrg,const TReal &aSrc);
 	IMPORT_C static TInt Frac(TReal &aTrg,const TReal &aSrc);
 	IMPORT_C static TInt Int(TReal &aTrg,const TReal &aSrc);
--- a/kernel/eka/include/e32ver.h	Mon May 10 11:40:53 2010 +0100
+++ b/kernel/eka/include/e32ver.h	Wed May 12 10:34:10 2010 +0100
@@ -28,7 +28,7 @@
 
 const TInt KE32MajorVersionNumber=2;
 const TInt KE32MinorVersionNumber=0;
-const TInt KE32BuildVersionNumber=3079;
+const TInt KE32BuildVersionNumber=3081;
 
 const TInt KMachineConfigurationMajorVersionNumber=1;
 const TInt KMachineConfigurationMinorVersionNumber=0;
--- a/kernel/eka/release.txt	Mon May 10 11:40:53 2010 +0100
+++ b/kernel/eka/release.txt	Wed May 12 10:34:10 2010 +0100
@@ -1,3 +1,32 @@
+Version 2.00.3081
+=================
+(Made by vfebvre 11/05/2010)
+
+1.	jimhofe
+	1.	ou1cimx1#367892 Changing MedSD3c PolicyId from 2 to 1461
+
+2.	martai
+	1.	PDEF145025 Support rapu variant specific e32tests 
+
+3.	kmetherm
+	1.	PR457093 RVCT 4 compatible software codebase (SSS)
+
+
+Version 2.00.3080
+=================
+(Made by vfebvre 10/05/2010)
+
+1.	necliffo
+	1.	ou1cimx1#378256 eMMC reliable Write can increase wear of eMMC devices
+
+2.	jessiezh
+	1.	MINOR_CHANGE Re-enable T_SOUND2 test
+	2.	ou1cimx1#367177 E32TEST T_DOMAIN test failure investigation
+
+3.	gcochran
+	1.	ou1cimx1#367939 MCL: Undefined Symbol error with the header "e32math.h"
+
+
 Version 2.00.3079
 =================
 (Made by vfebvre 07/05/2010)
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/kerneltest/e32test/benchmark/bm_rapu_pdd.cpp	Wed May 12 10:34:10 2010 +0100
@@ -0,0 +1,262 @@
+// Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies).
+// All rights reserved.
+// This component and the accompanying materials are made available
+// under the terms of the License "Eclipse Public License v1.0"
+// which accompanies this distribution, and is available
+// at the URL "http://www.eclipse.org/legal/epl-v10.html".
+//
+// Initial Contributors:
+// Nokia Corporation - initial contribution.
+//
+// Contributors:
+//
+// Description:
+//
+/*
+Change History:
+VERSION     : 2     26-01-2010     Ruixing Yang
+REASON      : 
+REFERENCE   : 
+DESCRIPTION : The timer resolution is modified for better interrupt latency calculation
+
+Change History:
+VERSION     : 1     25-01-2010     Ruixing Yang
+REASON      : 
+REFERENCE   : 
+DESCRIPTION : Initial implementation of BM_SUITE PDD for Rapu platform
+
+*/
+
+
+#include <kernel/kernel.h>
+#include <internal/rap_hw.h>
+#include <internal/rap.h>
+#include "k32bm.h"
+
+
+
+
+	
+
+class DBMRapuDevice : public DPhysicalDevice
+	{
+public:
+	DBMRapuDevice();
+	virtual TInt Install();
+	virtual void GetCaps(TDes8& aDes) const;
+	virtual TInt Create(DBase*& aChannel, TInt aUnit, const TDesC8* anInfo, const TVersion& aVer);
+	virtual TInt Validate(TInt aUnit, const TDesC8* anInfo, const TVersion& aVer);
+	};
+
+class DBMRapuChannel : public DBMPChannel
+	{
+public:
+	DBMRapuChannel();
+	~DBMRapuChannel();
+	virtual TBMTicks TimerPeriod();
+	virtual TBMTicks TimerStamp();
+	virtual TBMNs TimerTicksToNs(TBMTicks);
+	virtual TBMTicks TimerNsToTicks(TBMNs);
+	virtual TInt BindInterrupt(MBMIsr*);
+	virtual TInt BindInterrupt(MBMInterruptLatencyIsr*);
+	virtual void RequestInterrupt();
+	virtual void CancelInterrupt();
+
+private:
+	
+	static const TBMTicks	KBMRapuPeriod = (((TBMTicks) 1) << 32);
+	// Ticks at 1000Hz, input clock to timer @ 32.768 MHz.
+	static const TInt KHighResTimerFrequency = 32768000;   // 32.768 MHz
+	
+	static const TBMNs		KBMRapuNsPerTick = (1000*1000*1000) / KHighResTimerFrequency;	
+	static const TInt KRTC_Freq = 32768;
+	static const TInt KRTC_Ratio = 1172;
+	
+
+		
+	static void Isr(TAny*);
+	
+	MBMIsr*								iIsr;
+	MBMInterruptLatencyIsr*		iInterruptLatencyIsr;	
+	TUint									iTmpStartCount;
+	TUint									iTmpLongCount;	
+	NTimer								iTimer;
+	volatile TUint				iStartCount;
+	volatile TUint				iRunCount;
+	volatile TUint				iCancelCount;
+	};
+	
+	RTC001_STR& RTC001 = *reinterpret_cast<RTC001_STR*>(KRapRegRTC001);
+	GPT003_STR& GPT003 = *reinterpret_cast<GPT003_STR*>(KRapRegGPT003A0);
+	
+	
+DECLARE_STANDARD_PDD()
+//
+// Create a new device
+//
+	{
+	__ASSERT_CRITICAL;
+	return new DBMRapuDevice;
+	}
+	
+DBMRapuDevice::DBMRapuDevice()
+//
+// Constructor
+//
+	{
+	
+	iVersion = TVersion(1,0,1);
+	}
+	
+TInt DBMRapuDevice::Install()
+//
+// Install the device driver.
+//
+	{
+		
+	TInt r = SetName(&KBMPdName);
+	return r;
+	}
+	
+void DBMRapuDevice::GetCaps(TDes8& aDes) const
+//
+// Return the Comm capabilities.
+//
+	{
+	
+	}
+	
+TInt DBMRapuDevice::Create(DBase*& aChannel, TInt /*aUnit*/, const TDesC8* /*aInfo*/, const TVersion& /*aVer*/)
+//
+// Create a channel on the device.
+//
+	{
+		
+	__ASSERT_CRITICAL;
+	aChannel = new DBMRapuChannel;
+	return aChannel?KErrNone:KErrNoMemory;
+	}
+
+TInt DBMRapuDevice::Validate(TInt /*aUnit*/, const TDesC8* /*anInfo*/, const TVersion& aVer)
+	{
+		
+	if (!Kern::QueryVersionSupported(iVersion,aVer))
+		{
+		return KErrNotSupported;
+		}
+	return KErrNone;
+	}
+	
+DBMRapuChannel::DBMRapuChannel()
+	: iTimer(&Isr, this)
+	{
+	iTmpStartCount = 0;
+	iTmpLongCount = 0;
+	}
+	
+DBMRapuChannel::~DBMRapuChannel()
+	{
+	//Kern::Printf(("DBMRapuChannel::~DBMRapuChannel()"));	
+	CancelInterrupt();
+	}
+
+TBMTicks DBMRapuChannel::TimerPeriod()
+	{
+		//Kern::Printf(("DBMRapuChannel::TimerPeriod()"));
+	return KBMRapuPeriod;
+	}
+
+TBMTicks DBMRapuChannel::TimerStamp()
+	{
+	//Kern::Printf(("DBMRapuChannel::TimerStamp(), iTimerCount = %u"), RPTimer1::Timer().iTimerCount);	
+	TUint tmpTimeStamp;
+	RTC001.TRIGGER = 0;	
+	tmpTimeStamp = RTC001.LONGCOUNT;
+	tmpTimeStamp *= KRTC_Ratio;
+	tmpTimeStamp += RTC001.SHORTCOUNT;		
+	return tmpTimeStamp;	
+	}	
+
+
+TBMNs DBMRapuChannel::TimerTicksToNs(TBMTicks ticks)
+	{
+	//Kern::Printf(("DBMRapuChannel::TimerTIcksToNs(), iNsPerTick = %u"), (TBMTicks)iNsPerTick);
+	return ticks * KBMRapuNsPerTick;
+	}
+
+TBMTicks DBMRapuChannel::TimerNsToTicks(TBMNs ns)
+	{
+	//Kern::Printf(("DBMRapuChannel::TimerNsToTicks()"));
+	return ns / KBMRapuNsPerTick;	
+	}
+	
+void DBMRapuChannel::Isr(TAny* ptr)
+	{
+	//Kern::Printf(("DBMRapuChannel::Isr()"));
+	// Read RTC001	
+	RTC001.TRIGGER = 0;
+	TUint x = RTC001.LONGCOUNT;
+	x *= KRTC_Ratio;
+	x += RTC001.SHORTCOUNT;
+	TUint wasteTime = 1000000/KBMRapuNsPerTick; //NTimer's resolution is 1 ms = 1000000 ns	
+			
+	DBMRapuChannel* mCh = (DBMRapuChannel*) ptr;
+	BM_ASSERT(mCh->iIsr || mCh->iInterruptLatencyIsr);
+	if (mCh->iIsr)
+		{				
+		mCh->iIsr->Isr( x);	
+		}
+	else
+		{				
+		TUint y = (TUint)( x - mCh->iTmpLongCount - wasteTime);
+		//Kern::Printf(("DBMRapuChannel::Isr(), latency = %u"), y);	
+		mCh->iInterruptLatencyIsr->InterruptLatencyIsr(y);
+		}
+	__e32_atomic_add_ord32(&mCh->iRunCount, 1);
+	}	
+
+TInt DBMRapuChannel::BindInterrupt(MBMIsr* aIsr)
+	{
+	//Kern::Printf(("DBMRapuChannel::BindInterrupt(MBMIsr* aIsr)"));
+	BM_ASSERT(!iIsr);
+	BM_ASSERT(!iInterruptLatencyIsr);
+	iIsr = aIsr;
+	return KErrNone;
+	}
+
+TInt DBMRapuChannel::BindInterrupt(MBMInterruptLatencyIsr* aIsr)
+	{
+	//Kern::Printf(("DBMRapuChannel::BindInterrupt(MBMInterruptLatencyIsr* aIsr)"));
+	BM_ASSERT(!iIsr);
+	BM_ASSERT(!iInterruptLatencyIsr);
+	iInterruptLatencyIsr = aIsr;
+	return KErrNone;
+	}
+
+
+void DBMRapuChannel::RequestInterrupt()
+	{
+	//Kern::Printf(("DBMRapuChannel::RequestInterrupt()"));	
+	BM_ASSERT(iIsr || iInterruptLatencyIsr);		
+	// Read RTC001
+	RTC001.TRIGGER = 0;	
+	iTmpLongCount = RTC001.LONGCOUNT;
+	iTmpLongCount *= KRTC_Ratio;
+	iTmpLongCount += RTC001.SHORTCOUNT;					
+	if (iTimer.OneShot(1)==KErrNone)
+		__e32_atomic_add_ord32(&iStartCount, 1);
+	
+	}
+
+void DBMRapuChannel::CancelInterrupt()
+	{
+	iTmpStartCount = 0;
+	//Kern::Printf(("DBMRapuChannel::CancelInterrupt()"));		
+	if (iTimer.Cancel())
+		__e32_atomic_add_ord32(&iCancelCount, 1);
+	while (iStartCount != iCancelCount + iRunCount)
+		{}
+	}
+	
+	
+		
\ No newline at end of file
--- a/kerneltest/e32test/cppexceptions/second_excp.h	Mon May 10 11:40:53 2010 +0100
+++ b/kerneltest/e32test/cppexceptions/second_excp.h	Wed May 12 10:34:10 2010 +0100
@@ -41,7 +41,11 @@
 
 class MyFourthException : public VB1 , public VB2 {
 public:
+#if defined(__ARMCC__) && __ARMCC_VERSION >= 400000
+  EXPORT_C MyFourthException(int x) { iVal = x; iVal2=x+2;};
+#else
   MyFourthException(int x) { iVal = x; iVal2=x+2;};
+#endif
   int iVal2;
 };
 
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/kerneltest/e32test/eabi/d_second_excp2_40u.def	Wed May 12 10:34:10 2010 +0100
@@ -0,0 +1,12 @@
+EXPORTS
+	_Z8thrower2i @ 1 NONAME
+	_Z8thrower3i @ 2 NONAME
+	_Z8thrower4i @ 3 NONAME
+	_Z8thrower5i @ 4 NONAME
+	_ZN14UncaughtTesterC1ERi @ 5 NONAME
+	_ZN14UncaughtTesterC2ERi @ 6 NONAME
+	_ZN14UncaughtTesterD1Ev @ 7 NONAME
+	_ZN14UncaughtTesterD2Ev @ 8 NONAME
+	_ZN17MyFourthExceptionC1Ei @ 9 NONAME
+	_ZN17MyFourthExceptionC2Ei @ 10 NONAME
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/kerneltest/e32test/eabi/d_second_excp_40u.def	Wed May 12 10:34:10 2010 +0100
@@ -0,0 +1,12 @@
+EXPORTS
+	_Z8thrower2i @ 1 NONAME
+	_Z8thrower3i @ 2 NONAME
+	_Z8thrower4i @ 3 NONAME
+	_Z8thrower5i @ 4 NONAME
+	_ZN14UncaughtTesterC1ERi @ 5 NONAME
+	_ZN14UncaughtTesterC2ERi @ 6 NONAME
+	_ZN14UncaughtTesterD1Ev @ 7 NONAME
+	_ZN14UncaughtTesterD2Ev @ 8 NONAME
+	_ZN17MyFourthExceptionC1Ei @ 9 NONAME
+	_ZN17MyFourthExceptionC2Ei @ 10 NONAME
+
--- a/kerneltest/e32test/group/bm_pdd.mmp	Mon May 10 11:40:53 2010 +0100
+++ b/kerneltest/e32test/group/bm_pdd.mmp	Wed May 12 10:34:10 2010 +0100
@@ -68,6 +68,10 @@
 source			bm_ne1_pdd.cpp
 #endif
 
+#if defined(NCP_COMMON_RAPU_FAMILY)
+SYMBIAN_BASE_SYSTEMINCLUDE(assp/rapu)
+source			bm_rapu_pdd.cpp
+#endif
 start wins
 win32_library	kernel32.lib
 end
--- a/kerneltest/e32test/group/d_cache.mmp	Mon May 10 11:40:53 2010 +0100
+++ b/kerneltest/e32test/group/d_cache.mmp	Wed May 12 10:34:10 2010 +0100
@@ -15,7 +15,9 @@
 // 
 //
 
-#include            <../variant.mmh>
+#include		<variant_test.mmh>
+
+
 #include            "kernel/kern_ext.mmh"
 
 target              VariantTarget(d_cache,ldd)
--- a/kerneltest/e32test/group/d_second_excp.mmp	Mon May 10 11:40:53 2010 +0100
+++ b/kerneltest/e32test/group/d_second_excp.mmp	Wed May 12 10:34:10 2010 +0100
@@ -40,5 +40,10 @@
 capability		all
 vendorid		0x70000001
 
+#if defined ARMCC_4_0
+deffile		d_second_excp_40.def
+#else
+deffile		d_second_excp.def
+#endif
 
 SMPSAFE
--- a/kerneltest/e32test/group/d_second_excp2.mmp	Mon May 10 11:40:53 2010 +0100
+++ b/kerneltest/e32test/group/d_second_excp2.mmp	Wed May 12 10:34:10 2010 +0100
@@ -28,6 +28,10 @@
 capability		all
 vendorid		0x70000001
 
-
+#if defined ARMCC_4_0
+deffile		d_second_excp2_40.def
+#else
+deffile		d_second_excp2.def
+#endif
 
 SMPSAFE
--- a/kerneltest/e32test/group/t_suser.mmp	Mon May 10 11:40:53 2010 +0100
+++ b/kerneltest/e32test/group/t_suser.mmp	Wed May 12 10:34:10 2010 +0100
@@ -19,7 +19,7 @@
 targettype		exe
 sourcepath		../secure
 source			t_suser.cpp
-library			euser.lib
+library			euser.lib hal.lib
 OS_LAYER_SYSTEMINCLUDE_SYMBIAN
 ROMTARGET
 RAMTARGET 	    \sys\bin\	//
--- a/kerneltest/e32test/multimedia/t_sound2.cpp	Mon May 10 11:40:53 2010 +0100
+++ b/kerneltest/e32test/multimedia/t_sound2.cpp	Wed May 12 10:34:10 2010 +0100
@@ -2379,10 +2379,6 @@
 	Test.Title();
 
 	Test.Start(_L("Load"));
-	// --- TEMPORARILY DISABLING T_SOUND2
-	Test.Printf(_L("T_SOUND2 DISABLED UNTIL DEF144934 IS FIXED\n"));
-	CHECK(0);
-	// --- TEMPORARILY DISABLING T_SOUND2
 	if (Load()==KErrNotFound)
 		{
 		Test.Printf(_L("Shared chunk sound driver not supported - test skipped\r\n"));
--- a/kerneltest/e32test/power/t_domain.cpp	Mon May 10 11:40:53 2010 +0100
+++ b/kerneltest/e32test/power/t_domain.cpp	Wed May 12 10:34:10 2010 +0100
@@ -2050,7 +2050,6 @@
 	TInt r = manager.Connect(KDmHierarchyIdTest);
 	test (r == KErrNone);
 	manager.RequestDomainTransition(KDmIdRoot, EStartupCriticalStatic, ETraverseDefault, status);
-	test(status.Int() == KRequestPending);
 	User::WaitForRequest(status);
 	test(status.Int() == KErrNone);
 	manager.Close();
--- a/kerneltest/e32test/prime/t_timer.cpp	Mon May 10 11:40:53 2010 +0100
+++ b/kerneltest/e32test/prime/t_timer.cpp	Wed May 12 10:34:10 2010 +0100
@@ -606,7 +606,7 @@
 #if !(defined(__EPOC32__) && defined(__X86__))
 	TInt muid = 0;
 	HAL::Get(HAL::EMachineUid, muid);
-	if(muid!=HAL::EMachineUid_Lubbock && muid!=HAL::EMachineUid_NE1_TB && muid!=HAL::EMachineUid_STE8500)
+	if(muid==HAL::EMachineUid_OmapH2 || muid==HAL::EMachineUid_OmapH4 || muid==HAL::EMachineUid_OmapH6)
 		{
 		test.Next(_L("Test sequential locks fail over on/off"));
 		RTimer tat;
--- a/kerneltest/e32test/realtime/d_latncy.cpp	Mon May 10 11:40:53 2010 +0100
+++ b/kerneltest/e32test/realtime/d_latncy.cpp	Wed May 12 10:34:10 2010 +0100
@@ -87,6 +87,9 @@
 #elif defined(__NE1_TB__)
 const TInt KTickPeriodMs=1;
 const TInt KTicksPerMillisecond=66667;
+#elif defined(__MRAP__)
+const TInt KTickPeriodMs=1;
+const TInt KTicksPerMillisecond=1000;
 #endif
 
 #ifdef _DEBUG
--- a/kerneltest/e32test/secure/t_suser.cpp	Mon May 10 11:40:53 2010 +0100
+++ b/kerneltest/e32test/secure/t_suser.cpp	Wed May 12 10:34:10 2010 +0100
@@ -42,6 +42,8 @@
 #include <e32test.h>
 #include <e32svr.h>
 #include <nkern/nk_trace.h>
+#include <e32hal.h>
+#include <hal.h>
 
 LOCAL_D RTest test(_L("T_SUSER"));
 
@@ -946,21 +948,26 @@
 	test(logonStatus==KErrPermissionDenied);
 	CLOSE_AND_WAIT(process);
 
-	test.Next(_L("Calling UserSvr::AddEvent(ESwitchOff) with ECapabilityPowerMgmt & ECapabilitySwEvent"));
-	TRequestStatus absstatus;
-	RTimer abstimer;
-	TInt r = abstimer.CreateLocal();
-	test (r == KErrNone);
-	SetAbsoluteTimeout(abstimer, 5000000, absstatus); // 5 sec
-	process.Create((1u<<ECapabilitySwEvent)|(1u<<ECapabilityPowerMgmt),ETestProcessAddEventESwitchOff);
-	process.Logon(logonStatus);
-	process.Resume();
-	User::WaitForRequest(absstatus);
-	abstimer.Close();
-	User::WaitForRequest(logonStatus);
-	test(process.ExitType()==EExitKill);
-	test(logonStatus==KErrNone);
-	CLOSE_AND_WAIT(process);
+	TInt muid = 0;
+	HAL::Get(HAL::EMachineUid, muid);
+	if(muid==HAL::EMachineUid_OmapH2 || muid==HAL::EMachineUid_OmapH4 || muid==HAL::EMachineUid_OmapH6 || muid==HAL::EMachineUid_NE1_TB || muid==HAL::EMachineUid_X86PC || muid==HAL::EMachineUid_Win32Emulator)
+		{
+		test.Next(_L("Calling UserSvr::AddEvent(ESwitchOff) with ECapabilityPowerMgmt & ECapabilitySwEvent"));
+		TRequestStatus absstatus;
+		RTimer abstimer;
+		TInt r = abstimer.CreateLocal();
+		test (r == KErrNone);
+		SetAbsoluteTimeout(abstimer, 5000000, absstatus); // 5 sec
+		process.Create((1u<<ECapabilitySwEvent)|(1u<<ECapabilityPowerMgmt),ETestProcessAddEventESwitchOff);
+		process.Logon(logonStatus);
+		process.Resume();
+		User::WaitForRequest(absstatus);
+		abstimer.Close();
+		User::WaitForRequest(logonStatus);
+		test(process.ExitType()==EExitKill);
+		test(logonStatus==KErrNone);
+		CLOSE_AND_WAIT(process);
+		}
 
 	test.End();
 	}
--- a/kerneltest/e32test/system/d_mstim.cpp	Mon May 10 11:40:53 2010 +0100
+++ b/kerneltest/e32test/system/d_mstim.cpp	Wed May 12 10:34:10 2010 +0100
@@ -41,6 +41,8 @@
 #include <rvemuboard.h>
 #elif defined(__NE1_TB__)
 #include <upd35001_timer.h>
+#elif defined(__MRAP__)
+#include <rap.h>
 #endif
 #include "d_mstim.h"
 #include "../misc/prbs.h"
@@ -93,6 +95,11 @@
 inline TCounter TIMER()
 	{ return NETimer::Timer(5).iTimerCount; }
 #endif
+#ifdef __MRAP__
+inline TCounter TIMER()
+	{ TRap::SetRegister32(1, KRapRegRTC001_TRIGGER);
+	return  TRap::Register32(KRapRegRTC001_LONGCOUNT); }
+#endif
 #if defined(__EPOC32__) && defined(__CPU_X86)
 TCounter TIMER();
 void SetUpTimerChannel2();
@@ -137,6 +144,10 @@
 inline TDelta TimeDelta(TCounter initial, TCounter final)
 	{ return final - initial; }
 #endif
+#if defined(__MRAP__)
+inline TDelta TimeDelta(TCounter initial, TCounter final)
+	{ return final-initial; }				// RAP RTC timer counts up
+#endif
 #ifdef __WINS__
 inline TDelta TimeDelta(TCounter initial, TCounter final)
 	{ return final-initial; }		// counts up
@@ -197,6 +208,15 @@
 	x /= TInt64(f);
 	return (TInt)x;
 #endif
+#if defined(__MRAP__)
+    // RTC runs with 32.768 kHz -> one tick is 
+    const TUint KRTCClockHz = 32768;
+    Int64 ticks(aTicks);
+    ticks*=(1000000);
+	ticks+=KRTCClockHz/2;		// 32.768 kHz tick
+	ticks/=KRTCClockHz;
+	return (TInt)ticks;
+#endif
 #if defined(__EPOC32__) && defined(__CPU_X86)
 	TInt x = aTicks;
 	TInt y = x;
--- a/kerneltest/e32test/system/d_tick.cpp	Mon May 10 11:40:53 2010 +0100
+++ b/kerneltest/e32test/system/d_tick.cpp	Wed May 12 10:34:10 2010 +0100
@@ -37,6 +37,8 @@
 #include <rvemuboard.h>
 #elif defined(__NE1_TB__)
 #include <upd35001_timer.h>
+#elif defined(__MRAP__)
+#include <rap.h>
 #endif
 #include <kernel/kern_priv.h>
 #include "d_tick.h"
@@ -78,6 +80,11 @@
 inline TCounter TIMER()
 	{ return NETimer::Timer(2).iTimerCount; }
 #endif
+#ifdef __MRAP__
+inline TCounter TIMER()
+	{ TRap::SetRegister32(1, KRapRegRTC001_TRIGGER);
+	return  TRap::Register32(KRapRegRTC001_LONGCOUNT); }
+#endif
 #if defined(__EPOC32__) && defined(__CPU_X86)
 TCounter TIMER();
 void SetUpTimerChannel2();
@@ -90,6 +97,12 @@
 	return c.QuadPart;
 	}
 #endif
+#if defined(__MRAP__)
+inline TDelta TimeDelta(TCounter initial, TCounter final)
+	{ return final-initial; }				// RAP RTC timer counts up
+inline TInt LongTimeDelta(TCounter initial, TCounter final, TUint, TUint)
+	{ return final-initial; }				// RAP RTC timer counts up
+#endif
 
 #if defined(__MISA__) || defined(__MCOT__)
 inline TDelta TimeDelta(TCounter initial, TCounter final)
@@ -211,6 +224,15 @@
 	x /= TUint64(f);
 	return (TUint)x;
 #endif
+#if defined(__MRAP__)
+    // RTC runs with 32.768 kHz -> one tick is 
+    const TUint KRTCClockHz = 32768;
+    Int64 ticks(aTicks);
+    ticks*=(1000000);
+	ticks+=KRTCClockHz/2;		// 32.768 kHz tick
+	ticks/=KRTCClockHz;
+	return (TInt)ticks;
+#endif
 #if defined(__MAWD__) || defined(__MEIG__)
 	return aTicks*500;					// 2kHz tick
 #endif
@@ -589,6 +611,9 @@
 #if defined(__NE1_TB__)
 	// nothing to do since we use fast counter
 #endif
+#if defined(__MRAP__)
+	// nothing to do here RTC runs with 32.768 kHz
+#endif
 #ifdef __MAWD__
 	// Set up timer 1 as free running 2kHz clock
 	TWind::SetBuzzerControl(0);		// disable buzzer
--- a/kerneltest/f32test/server/t_dlocl.cpp	Mon May 10 11:40:53 2010 +0100
+++ b/kerneltest/f32test/server/t_dlocl.cpp	Wed May 12 10:34:10 2010 +0100
@@ -73,7 +73,7 @@
 
     RLibrary testLib;
     TInt res=testLib.Load(EKDATA);
-    test(res==KErrNone);
+    test_KErrNone(res);
     THandleInfo handleInfo;
     testLib.HandleInfo(&handleInfo);
     test(handleInfo.iNumOpenInThread==2);
@@ -81,16 +81,16 @@
 
     test.Printf(_L("Change to unknown dll \n"));                // Test with non keydata type dll
     res=KeyTranslator->ChangeKeyData(DUMMYDLL);
-    test(res==KErrArgument);
+    test_Value(res, res == KErrArgument);
     
     res=testLib.Load(EKDATA);
-    test(res==KErrNone);
+    test_KErrNone(res);
     testLib.HandleInfo(&handleInfo);
     test(handleInfo.iNumOpenInThread==2);
     testLib.Close();
 
     res=testLib.Load(DUMMYDLL);
-    test(res==KErrNone);
+    test_KErrNone(res);
     testLib.HandleInfo(&handleInfo);
     test(handleInfo.iNumOpenInThread==1);
     testLib.Close();
@@ -106,15 +106,15 @@
     //
     test.Printf(_L("Change to EKDATA.dll\n"));
     res=KeyTranslator->ChangeKeyData(EKDATA);
-    test(res==KErrNone);
+    test_KErrNone(res);
     
     res=testLib.Load(EKDATA);
-    test(res==KErrNone);
+    test_KErrNone(res);
     testLib.HandleInfo(&handleInfo);
     test(handleInfo.iNumOpenInThread==2);
     testLib.Close();
     res=testLib.Load(DUMMYDLL);
-    test(res==KErrNone);
+    test_KErrNone(res);
     testLib.HandleInfo(&handleInfo);
     test(handleInfo.iNumOpenInThread==1);
     testLib.Close();
@@ -134,16 +134,16 @@
 
     test.Printf(_L("Change back to Default KeyData\n"));
     res=KeyTranslator->ChangeKeyData(_L(""));
-    test(res==KErrNone);
+    test_KErrNone(res);
     
     res=testLib.Load(EKDATA);
-    test(res==KErrNone);
+    test_KErrNone(res);
     testLib.HandleInfo(&handleInfo);
     test(handleInfo.iNumOpenInThread==2);
     testLib.Close();
 
     res=testLib.Load(DUMMYDLL);
-    test(res==KErrNone);
+    test_KErrNone(res);
     testLib.HandleInfo(&handleInfo);
     test(handleInfo.iNumOpenInThread==1);
     testLib.Close();
@@ -280,7 +280,7 @@
         test.Printf(_L("SubscribeToSystemChangeNotification(0x%x), attempt:%d\n"), aEventMask, i);   
 
         TInt nRes = aNotifier.Logon(aStatus);
-        test(nRes==KErrNone);
+        test_KErrNone(nRes);
 
         if(aStatus.Int() == KRequestPending)
             break;
@@ -322,11 +322,11 @@
     
     RChangeNotifier notifier;
     TInt res=notifier.Create();
-    test(res==KErrNone);
+    test_KErrNone(res);
     TRequestStatus stat;
     
     res=notifier.Logon(stat);
-    test(res==KErrNone);
+    test_KErrNone(res);
 	// initial value of stat already tested by t_chnot
 
     SubscribeToSystemChangeNotification(notifier, stat, EChangesLocale);
@@ -334,7 +334,7 @@
         test.Printf(_L("Change to US Locale\n"));   
         res=UserSvr::ChangeLocale(ELOCLUS);
         test.Printf(_L("res=%d\n"),res);
-        test(res==KErrNone);
+        test_KErrNone(res);
 
     WaitForSystemChange(notifier, stat, EChangesLocale);
     test(stat.Int() & EChangesLocale);
@@ -350,7 +350,7 @@
         test.Printf(_L("Change to GE Locale\n"));
         res=UserSvr::ChangeLocale(ELOCLGE);
         test.Printf(_L("res=%d\n"),res);
-        test(res==KErrNone);
+        test_KErrNone(res);
 
     WaitForSystemChange(notifier, stat, EChangesLocale);
     test(stat.Int() & EChangesLocale);
@@ -367,7 +367,7 @@
         test.Printf(_L("Load non ELOCL type DLL\n"));    
         res=UserSvr::ChangeLocale(DUMMYDLL);
         test.Printf(_L("res=%d\n"),res);
-        test(res == KErrNotSupported);
+        test_Value(res, res == KErrNotSupported);
     
     //-- ensure that there wasn't locale change
     const TInt KMaxAttempts = 100;
@@ -396,7 +396,7 @@
         test.Printf(_L("Change to US1 Locale\n"));  
         res=UserSvr::ChangeLocale(ELOCLUS1);
         test.Printf(_L("res=%d\n"),res);
-        test(res==KErrNone);
+        test_KErrNone(res);
     
     WaitForSystemChange(notifier, stat, EChangesLocale);
     test(stat.Int() & EChangesLocale);
@@ -437,7 +437,7 @@
         test.Printf(_L("Back to default UK Locale\n"));
         res=UserSvr::ChangeLocale(ELOCL_DEFAULT);
         test.Printf(_L("res=%d\n"),res);
-        test(res==KErrNone);
+        test_KErrNone(res);
     
     WaitForSystemChange(notifier, stat, EChangesLocale);
     test(stat.Int() & EChangesLocale);
@@ -459,12 +459,12 @@
         _LIT(KTestFile, "TEST.TXT");
         RFile file;
         res = file.Replace(TheFs, KTestFile, 0);
-        test(res == KErrNone);
+        test_KErrNone(res);
 
 
         res=UserSvr::ChangeLocale(ELOCLUS);
         test.Printf(_L("res=%d\n"),res);
-        test(res==KErrNone);
+        test_KErrNone(res);
 
 
     WaitForSystemChange(notifier, stat, EChangesLocale);
@@ -477,14 +477,14 @@
 
         _LIT8(KTestData, "Arsenal");
         res = file.Write(KTestData);
-        test(res==KErrNone);
+        test_KErrNone(res);
         file.Close();
 
         res = file.Open(TheFs, KTestFile, 0);
-        test(res == KErrNone);
+        test_KErrNone(res);
         file.Close();
         res = TheFs.Delete(KTestFile);
-        test(res==KErrNone);
+        test_KErrNone(res);
 
     //************************************************
 
@@ -650,11 +650,11 @@
     TExtendedLocale locale;
     locale.LoadLocale(ELOCLUS);
     TInt r = locale.SaveSystemSettings();
-    test(r == KErrNone);
+    test_KErrNone(r);
     testExtendedUS(ELocaleLanguageSettings | ELocaleCollateSetting | ELocaleLocaleSettings | ELocaleTimeDateSettings, locale);
 
     r = locale.SetCurrencySymbol(TPtrC(_S("Leu")));
-    test(r == KErrNone);
+    test_KErrNone(r);
     TCurrencySymbol symbol;
     symbol.Set();
     test(symbol.Compare(TPtrC(_S("Leu"))) == 0);
@@ -668,35 +668,39 @@
     eloclus.Copy(ELOCLUS);
     eloclus.Append(TPtrC(KDLLExtension));
     r = locale.GetLocaleDllName(ELocaleLanguageSettings, dllName);
-    test(r == KErrNone);
+    test_KErrNone(r);
+	dllName.UpperCase();
     test.Printf(_L("dllName looking for %s (%s)\n"), dllName.Ptr(), eloclus.Ptr());
     test(dllName.Find(eloclus) != KErrNotFound);
     
     dllName.FillZ();
 
     r = locale.GetLocaleDllName(ELocaleCollateSetting, dllName);
-    test(r == KErrNone);
+    test_KErrNone(r);
+	dllName.UpperCase();
     test(dllName.Find(eloclus) != KErrNotFound);
     
     dllName.FillZ();
 
     r = locale.GetLocaleDllName(ELocaleLocaleSettings, dllName);
-    test(r == KErrNone);
+    test_KErrNone(r);
+	dllName.UpperCase();
     test(dllName.Find(eloclus) != KErrNotFound);
     
     dllName.FillZ();
 
     r = locale.GetLocaleDllName(ELocaleTimeDateSettings, dllName);
-    test(r == KErrNone);
+    test_KErrNone(r);
+	dllName.UpperCase();
     test(dllName.Find(eloclus) != KErrNotFound);
     
     dllName.FillZ();
 
     r = locale.LoadLocaleAspect(ELocaleLocaleSettings | ELocaleTimeDateSettings, ELOCLGE);
-    test(r == KErrNone);
+    test_KErrNone(r);
 
     r = locale.SaveSystemSettings();
-    test(r == KErrNone);
+    test_KErrNone(r);
 
     testExtendedUS(ELocaleLanguageSettings | ELocaleCollateSetting, locale);
 
@@ -719,25 +723,29 @@
     eloclge.Copy(ELOCLGE);
     eloclge.Append(KDLLExtension);
     r = locale.GetLocaleDllName(ELocaleLanguageSettings, dllName);
-    test(r == KErrNone);
+    test_KErrNone(r);
+	dllName.UpperCase();
     test(dllName.Find(eloclus) != KErrNotFound);
     
     dllName.FillZ();
 
     r = locale.GetLocaleDllName(ELocaleCollateSetting, dllName);
-    test(r == KErrNone);
+    test_KErrNone(r);
+	dllName.UpperCase();
     test(dllName.Find(eloclus) != KErrNotFound);
     
     dllName.FillZ();
 
     r = locale.GetLocaleDllName(ELocaleLocaleSettings, dllName);
-    test(r == KErrNone);
+    test_KErrNone(r);
+	dllName.UpperCase();
     test(dllName.Find(eloclge) != KErrNotFound);
     
     dllName.FillZ();
 
     r = locale.GetLocaleDllName(ELocaleTimeDateSettings, dllName);
-    test(r == KErrNone);
+    test_KErrNone(r);
+	dllName.UpperCase();
     test(dllName.Find(eloclge) != KErrNotFound);
     
     dllName.FillZ();