HNoPurge toolcall

This commit is contained in:
Kelvin Sherlock 2015-01-14 14:26:49 -05:00
parent d2bca7efe0
commit eca0516094
3 changed files with 35 additions and 0 deletions

View File

@ -1235,6 +1235,31 @@ namespace MM
return SetMemError(0);
}
uint16_t HNoPurge(uint16_t trap)
{
/*
* on entry:
* A0 Handle
*
* on exit:
* D0 Result code
*
*/
uint32_t hh = cpuGetAReg(0);
Log("%04x HNoPurge(%08x)\n", trap, hh);
auto iter = HandleMap.find(hh);
if (iter == HandleMap.end()) return SetMemError(MacOS::memWZErr);
iter->second.purgeable = false;
return SetMemError(0);
}
uint16_t HLock(uint16_t trap)
{
/*

View File

@ -68,7 +68,12 @@ namespace MM
uint16_t HUnlock(uint16_t trap);
uint16_t HPurge(uint16_t trap);
uint16_t HNoPurge(uint16_t trap);
uint16_t HSetRBit(uint16_t trap);
uint16_t HClrRBit(uint16_t trap);
uint16_t MoveHHi(uint16_t trap);
uint32_t StripAddress(uint16_t trap);

View File

@ -253,6 +253,11 @@ namespace ToolBox {
d0 = MM::HPurge(trap);
break;
case 0xa04a:
d0 = MM::HNoPurge(trap);
break;
case 0xA11D:
d0 = MM::MaxMem(trap);
break;