sl@0: // Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies). sl@0: // All rights reserved. sl@0: // This component and the accompanying materials are made available sl@0: // under the terms of the License "Eclipse Public License v1.0" sl@0: // which accompanies this distribution, and is available sl@0: // at the URL "http://www.eclipse.org/legal/epl-v10.html". sl@0: // sl@0: // Initial Contributors: sl@0: // Nokia Corporation - initial contribution. sl@0: // sl@0: // Contributors: sl@0: // sl@0: // Description: sl@0: // e32test\demandpaging\d_pagestress.h sl@0: // sl@0: // sl@0: sl@0: #ifndef __D_PAGESTRESS_H__ sl@0: #define __D_PAGESTRESS_H__ sl@0: sl@0: sl@0: #include sl@0: #ifndef __KERNEL_MODE__ sl@0: #include sl@0: #endif sl@0: sl@0: _LIT(KPageStressTestLddName,"D_PAGESTRESS"); sl@0: sl@0: class RPageStressTestLdd : public RBusLogicalChannel sl@0: { sl@0: public: sl@0: enum TControl sl@0: { sl@0: EDoConsumeRamSetup, sl@0: EDoConsumeRamFinish, sl@0: EDoConsumeSomeRam, sl@0: EDoReleaseSomeRam, sl@0: EDoSetDebugFlag, sl@0: }; sl@0: sl@0: #ifndef __KERNEL_MODE__ sl@0: public: sl@0: inline TInt Open() sl@0: { return DoCreate(KPageStressTestLddName,TVersion(),KNullUnit,NULL,NULL,EOwnerProcess,ETrue); } sl@0: inline TInt DoConsumeRamSetup(TInt aNumPagesLeft, TInt aPagesInBlock) sl@0: { return DoControl(EDoConsumeRamSetup,(TAny*)aNumPagesLeft, (TAny*)aPagesInBlock); } sl@0: inline TInt DoConsumeRamFinish(void) sl@0: { return DoControl(EDoConsumeRamFinish,(TAny*)NULL, (TAny*)NULL); } sl@0: inline TInt DoConsumeSomeRam(TInt aBlocks) sl@0: { return DoControl(EDoConsumeSomeRam,(TAny*)aBlocks, (TAny*)NULL); } sl@0: inline TInt DoReleaseSomeRam(TInt aBlocks) sl@0: { return DoControl(EDoReleaseSomeRam,(TAny*)aBlocks, (TAny*)NULL); } sl@0: inline TInt DoSetDebugFlag(TInt aState) sl@0: { return DoControl(EDoSetDebugFlag,(TAny*)aState, (TAny*)NULL); } sl@0: #endif sl@0: }; sl@0: sl@0: sl@0: #endif // __D_PAGESTRESS_H__