mirror of https://github.com/acidanthera/audk.git
Correct ASSERT to more cases.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@7847 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
parent
07d97279a3
commit
351d6e7fcc
|
@ -68,7 +68,11 @@ InvalidateInstructionCacheRange (
|
|||
IN UINTN Length
|
||||
)
|
||||
{
|
||||
ASSERT (Length <= MAX_ADDRESS - (UINTN)Address + 1);
|
||||
if (Length == 0) {
|
||||
return Address;
|
||||
}
|
||||
|
||||
ASSERT ((Length - 1) <= (MAX_ADDRESS - (UINTN)Address));
|
||||
return Address;
|
||||
}
|
||||
|
||||
|
@ -127,12 +131,12 @@ WriteBackInvalidateDataCacheRange (
|
|||
UINTN Start;
|
||||
UINTN End;
|
||||
|
||||
ASSERT (Length <= MAX_ADDRESS - (UINTN)Address + 1);
|
||||
|
||||
if (Length == 0) {
|
||||
return Address;
|
||||
}
|
||||
|
||||
ASSERT ((Length - 1) <= (MAX_ADDRESS - (UINTN)Address));
|
||||
|
||||
Start = (UINTN)Address;
|
||||
//
|
||||
// Calculate the cache line alignment
|
||||
|
|
Loading…
Reference in New Issue