equal
deleted
inserted
replaced
70 TInt ZoneAllocToMany(TInt aZoneIndex, TInt aNumPages); |
70 TInt ZoneAllocToMany(TInt aZoneIndex, TInt aNumPages); |
71 TInt ZoneAllocToManyArray(TInt aZoneIndex, TInt aNumPages); |
71 TInt ZoneAllocToManyArray(TInt aZoneIndex, TInt aNumPages); |
72 TInt ZoneAllocToMany2(TInt aZoneIndex, TInt aNumPages); |
72 TInt ZoneAllocToMany2(TInt aZoneIndex, TInt aNumPages); |
73 TInt AllocContiguous(TUint aNumBytes); |
73 TInt AllocContiguous(TUint aNumBytes); |
74 TInt FreeZone(TInt aNumPages); |
74 TInt FreeZone(TInt aNumPages); |
|
75 TInt FreeZoneId(TUint aZoneId); |
75 TInt FreeFromAllZones(); |
76 TInt FreeFromAllZones(); |
76 TInt FreeFromAddr(TInt aNumPages, TUint32 aAddr); |
77 TInt FreeFromAddr(TInt aNumPages, TUint32 aAddr); |
77 TInt PageCount(TUint aId, STestUserSidePageCount* aPageData); |
78 TInt PageCount(TUint aId, STestUserSidePageCount* aPageData); |
78 TInt CancelDefrag(); |
79 TInt CancelDefrag(); |
79 TInt CheckCancel(STestParameters* aParams); |
80 TInt CheckCancel(STestParameters* aParams); |
385 retVal = DRamDefragFuncTestChannel::AllocContiguous((TUint)a1); |
386 retVal = DRamDefragFuncTestChannel::AllocContiguous((TUint)a1); |
386 break; |
387 break; |
387 |
388 |
388 case RRamDefragFuncTestLdd::EFreeZone: |
389 case RRamDefragFuncTestLdd::EFreeZone: |
389 retVal = DRamDefragFuncTestChannel::FreeZone((TInt)a1); |
390 retVal = DRamDefragFuncTestChannel::FreeZone((TInt)a1); |
|
391 break; |
|
392 |
|
393 case RRamDefragFuncTestLdd::EFreeZoneId: |
|
394 retVal = DRamDefragFuncTestChannel::FreeZoneId((TUint)a1); |
390 break; |
395 break; |
391 |
396 |
392 case RRamDefragFuncTestLdd::EFreeFromAllZones: |
397 case RRamDefragFuncTestLdd::EFreeFromAllZones: |
393 retVal = DRamDefragFuncTestChannel::FreeFromAllZones(); |
398 retVal = DRamDefragFuncTestChannel::FreeFromAllZones(); |
394 break; |
399 break; |
1510 NKern::ThreadLeaveCS(); |
1515 NKern::ThreadLeaveCS(); |
1511 return returnValue; |
1516 return returnValue; |
1512 } |
1517 } |
1513 |
1518 |
1514 // |
1519 // |
|
1520 // FreeZoneId |
|
1521 // |
|
1522 // Call Epoc::FreeRamZone() |
|
1523 // |
|
1524 TInt DRamDefragFuncTestChannel::FreeZoneId(TUint aZoneId) |
|
1525 { |
|
1526 NKern::ThreadEnterCS(); |
|
1527 |
|
1528 TInt r = Epoc::FreeRamZone(aZoneId); |
|
1529 if (r == KErrNone) |
|
1530 { |
|
1531 if (iContigAddr == KPhysAddrInvalid) |
|
1532 { |
|
1533 Kern::Printf("Error some how freed a RAM zone that wasn't previously claimed"); |
|
1534 NKern::ThreadLeaveCS(); |
|
1535 return KErrGeneral; |
|
1536 } |
|
1537 iContigAddr = KPhysAddrInvalid; |
|
1538 } |
|
1539 NKern::ThreadLeaveCS(); |
|
1540 return r; |
|
1541 } |
|
1542 |
|
1543 // |
1515 // FreeFromAllZones |
1544 // FreeFromAllZones |
1516 // |
1545 // |
1517 // Call the overloaded Epoc::FreePhysicalRam function |
1546 // Call the overloaded Epoc::FreePhysicalRam function |
1518 // |
1547 // |
1519 TInt DRamDefragFuncTestChannel::FreeFromAllZones() |
1548 TInt DRamDefragFuncTestChannel::FreeFromAllZones() |