On Fri, Jun 7, 2019 at 12:54 PM Dave Hansen <dave.hansen(a)intel.com> wrote:
On 6/7/19 12:27 PM, Dan Williams wrote:
> @@ -848,15 +848,16 @@ char * __init efi_md_typeattr_format(char *buf, size_t size,
> if (attr & ~(EFI_MEMORY_UC | EFI_MEMORY_WC | EFI_MEMORY_WT |
> EFI_MEMORY_WB | EFI_MEMORY_UCE | EFI_MEMORY_RO |
> EFI_MEMORY_WP | EFI_MEMORY_RP | EFI_MEMORY_XP |
> - EFI_MEMORY_NV |
> + EFI_MEMORY_NV | EFI_MEMORY_SP |
> EFI_MEMORY_RUNTIME | EFI_MEMORY_MORE_RELIABLE))
> snprintf(pos, size, "|attr=0x%016llx]",
> (unsigned long long)attr);
> snprintf(pos, size,
> attr & EFI_MEMORY_RUNTIME ? "RUN" :
> attr & EFI_MEMORY_MORE_RELIABLE ? "MR" :
> + attr & EFI_MEMORY_SP ? "SP" :
> attr & EFI_MEMORY_NV ? "NV" :
> attr & EFI_MEMORY_XP ? "XP" :
> attr & EFI_MEMORY_RP ? "RP" :
Haha, I went digging in sysfs to find out where this gets dumped out.
The joke was on me because it seems to only go to dmesg.
Separate from these patches, should we have a runtime file that dumps
out the same info? dmesg isn't always available, and hotplug could
change this too, I'd imagine.
Perhaps, but I thought /proc/iomem was that runtime file. Given that
x86/Linux only seems to care about the the EFI to E820 translation of
the map and the E820 map is directly reflected in /proc/iomem, do we
need another file?