forked from Minki/linux
b617c5266e
UEFI 2.8 defines an EFI_MEMORY_SP attribute bit to augment the interpretation of the EFI Memory Types as "reserved for a specific purpose". The proposed Linux behavior for specific purpose memory is that it is reserved for direct-access (device-dax) by default and not available for any kernel usage, not even as an OOM fallback. Later, through udev scripts or another init mechanism, these device-dax claimed ranges can be reconfigured and hot-added to the available System-RAM with a unique node identifier. This device-dax management scheme implements "soft" in the "soft reserved" designation by allowing some or all of the reservation to be recovered as typical memory. This policy can be disabled at compile-time with CONFIG_EFI_SOFT_RESERVE=n, or runtime with efi=nosoftreserve. As for this patch, define the common helpers to determine if the EFI_MEMORY_SP attribute should be honored. The determination needs to be made early to prevent the kernel from being loaded into soft-reserved memory, or otherwise allowing early allocations to land there. Follow-on changes are needed per architecture to leverage these helpers in their respective mem-init paths. Reviewed-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Dan Williams <dan.j.williams@intel.com> Acked-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> |
||
---|---|---|
.. | ||
arm_scmi | ||
broadcom | ||
efi | ||
imx | ||
meson | ||
psci | ||
tegra | ||
xilinx | ||
arm_scpi.c | ||
arm_sdei.c | ||
dmi_scan.c | ||
dmi-id.c | ||
dmi-sysfs.c | ||
edd.c | ||
iscsi_ibft_find.c | ||
iscsi_ibft.c | ||
Kconfig | ||
Makefile | ||
memmap.c | ||
pcdp.c | ||
pcdp.h | ||
qcom_scm-32.c | ||
qcom_scm-64.c | ||
qcom_scm.c | ||
qcom_scm.h | ||
qemu_fw_cfg.c | ||
raspberrypi.c | ||
scpi_pm_domain.c | ||
stratix10-rsu.c | ||
stratix10-svc.c | ||
ti_sci.c | ||
ti_sci.h | ||
trusted_foundations.c | ||
turris-mox-rwtm.c |