I don't have RPi4, I tested following cases on qemu
On 3/31/2022 12:40 AM, Kefeng Wang wrote:
ARM64 enable ZONE_DMA by default, and with ZONE_DMA crash kernel
memory reservation is delayed until DMA zone memory range size
initilazation performed in zone_sizes_init(), but for most platforms
use 32bit dma_zone_bits, so add dma_force_32bit kernel parameter
if ZONE_DMA enabled, and initialize arm64_dma_phys_limit to
dma32_phys_limit in arm64_memblock_init() if dma_force_32bit
is setup, this could let the crash kernel reservation earlier,
and allows linear creation with block mapping.
Signed-off-by: Kefeng Wang <wangkefeng.wang@xxxxxxxxxx>
I don't see any problem with the approach. Hope you or someone can test to make sure no surprises on RPi4 with the proposed change. I do understand on RPi4 --
- both ZONE_DMA and ZONE_DMA32 are enabled
- one wouldn't use dma_force_32bit kernel parameter
- crashkernel_could_early_reserve() would return false to preserve late reserve of crash kernel memory
nit --Sure.
- consider renaming crashkernel_could_early_reserve() => crashkernel_early_reserve()
Reviewed-by: Vijay Balakrishna <vijayb@xxxxxxxxxxxxxxxxxxx>Thanks.