UPSTREAM: lib/memrange: Introduce method to clone memrange

Add a new method to clone an existing memrange with all of its entries.
Required for new bootmem type LB_MEM_RAM_DONT_OVERLAP.

BUG=none
BRANCH=none
TEST=none

Change-Id: I20b7bbe1b0c0366938cacded87999a76d47fa462
Signed-off-by: Martin Roth <martinroth@chromium.org>
Original-Commit-Id: d67a4bd5a7f2270294a83a15ba4bc58d16e67180
Original-Change-Id: I64b27bf2611ca310385ef680f030a3e4aa0c2680
Original-Signed-off-by: Patrick Rudolph <patrick.rudolph@9elements.com>
Original-Reviewed-on: https://review.coreboot.org/25582
Original-Reviewed-by: Aaron Durbin <adurbin@chromium.org>
Original-Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-on: https://chromium-review.googlesource.com/1007441
2 files changed