[PATCH 1/2] common: memtop: add logic to detect ram_top