BaseTools/CommonLib: drop the use of MAX_ADDRESS
authorArd Biesheuvel <ard.biesheuvel@linaro.org>
Wed, 5 Dec 2018 08:15:48 +0000 (09:15 +0100)
committerArd Biesheuvel <ard.biesheuvel@linaro.org>
Thu, 6 Dec 2018 07:32:00 +0000 (08:32 +0100)
commit67938bcc9d9ed7b1867d29e47f3547bdf299f8c6
tree423f764c0324121b0484cf6576ea3b02dc2a26fc
parent6e8cad49a09db38c309b19b930ba568d2953a901
BaseTools/CommonLib: drop the use of MAX_ADDRESS

The macro MAX_ADDRESS represents the largest virtual address that
is valid for a certain architecture. For the BaseTools, this quantity
is irrelevant, since the same tools can be used to build for different
targets.

Since we only refer to it in a single place, which is an ASSERT() that
doesn't seem particularly useful (it ensures that memcpy() will not
be called with arguments that will make it read beyond the end of the
address space and wrap around), let's drop the ASSERT and all references
to MAX_ADDRESS.

Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>
BaseTools/Source/C/Common/CommonLib.c
BaseTools/Source/C/Include/AArch64/ProcessorBind.h
BaseTools/Source/C/Include/Arm/ProcessorBind.h
BaseTools/Source/C/Include/Common/UefiBaseTypes.h
BaseTools/Source/C/Include/Ia32/ProcessorBind.h
BaseTools/Source/C/Include/X64/ProcessorBind.h