kernel/eka/memmodel/epoc/moving/arm/xmmu.cpp
changeset 45 329ab0095843
parent 43 96e5fb8b040d
child 87 2f92ad2dc5db
equal deleted inserted replaced
44:36bfc973b146 45:329ab0095843
   757 // Replace the mapping at address aAddr in page table aId.
   757 // Replace the mapping at address aAddr in page table aId.
   758 // Update the page information array for both the old and new pages.
   758 // Update the page information array for both the old and new pages.
   759 // Call this with the system locked.
   759 // Call this with the system locked.
   760 //
   760 //
   761 	{
   761 	{
   762 	__KTRACE_OPT(KMMU,Kern::Printf("ArmMmu::RemapPages() id=%d addr=%08x old=%08x new=%08x perm=%08x", aId, aAddr, aOldAddr, aNewAddr, aPtePerm));
   762 	__KTRACE_OPT(KMMU,Kern::Printf("ArmMmu::RemapPage() id=%d addr=%08x old=%08x new=%08x perm=%08x", aId, aAddr, aOldAddr, aNewAddr, aPtePerm));
   763 
   763 
   764 	TInt ptOffset=(aAddr&KChunkMask)>>KPageShift;			// entry number in page table
   764 	TInt ptOffset=(aAddr&KChunkMask)>>KPageShift;			// entry number in page table
   765 	TPte* pPte=PageTable(aId)+ptOffset;						// address of PTE
   765 	TPte* pPte=PageTable(aId)+ptOffset;						// address of PTE
   766 	TPte pte=*pPte;
   766 	TPte pte=*pPte;
   767 
   767 
   783 		pi->Set(oldpi->Type(),oldpi->Owner(),oldpi->Offset());
   783 		pi->Set(oldpi->Type(),oldpi->Owner(),oldpi->Offset());
   784 		oldpi->SetUnused();
   784 		oldpi->SetUnused();
   785 		}
   785 		}
   786 	else
   786 	else
   787 		{
   787 		{
   788 		__KTRACE_OPT(KMMU,Kern::Printf("ArmMmu::RemapPages() called on a non-4K page!"));
   788 		__KTRACE_OPT(KMMU,Kern::Printf("ArmMmu::RemapPage() called on a non-4K page!"));
   789 		Panic(ERemapPageFailed);
   789 		Panic(ERemapPageFailed);
   790 		}
   790 		}
   791 	}
   791 	}
   792 
   792 
   793 void ArmMmu::RemapKernelPage(TInt aId, TLinAddr aSrc, TLinAddr aDest, TPhysAddr aNewPhys, TPte aPtePerm)
   793 void ArmMmu::RemapKernelPage(TInt aId, TLinAddr aSrc, TLinAddr aDest, TPhysAddr aNewPhys, TPte aPtePerm)