equal
deleted
inserted
replaced
|
1 // Copyright (c) 1998-2009 Nokia Corporation and/or its subsidiary(-ies). |
|
2 // All rights reserved. |
|
3 // This component and the accompanying materials are made available |
|
4 // under the terms of the License "Eclipse Public License v1.0" |
|
5 // which accompanies this distribution, and is available |
|
6 // at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
7 // |
|
8 // Initial Contributors: |
|
9 // Nokia Corporation - initial contribution. |
|
10 // |
|
11 // Contributors: |
|
12 // |
|
13 // Description: |
|
14 // e32test\mmu\freeram.h |
|
15 // |
|
16 // |
|
17 |
|
18 #ifndef __FREERAM_H__ |
|
19 #define __FREERAM_H__ |
|
20 |
|
21 // |
|
22 // returns the free RAM in bytes |
|
23 // |
|
24 inline TInt FreeRam() |
|
25 { |
|
26 // wait for any async cleanup in the supervisor to finish first... |
|
27 UserSvr::HalFunction(EHalGroupKernel, EKernelHalSupervisorBarrier, 0, 0); |
|
28 |
|
29 TMemoryInfoV1Buf meminfo; |
|
30 UserHal::MemoryInfo(meminfo); |
|
31 return meminfo().iFreeRamInBytes; |
|
32 } |
|
33 |
|
34 #endif |