[patch 007/124] memblock: let memblock_type_name know about physmem type

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Heiko Carstens <heiko.carstens@xxxxxxxxxx>
Subject: memblock: let memblock_type_name know about physmem type

Since commit 70210ed950b5 ("mm/memblock: add physical memory list")
the memblock structure knows about a physical memory list.

memblock_type_name() should return "physmem" instead of "unknown" if
the name of the physmem memblock_type is being asked for.

Link: http://lkml.kernel.org/r/20170120123456.46508-2-heiko.carstens@xxxxxxxxxx
Signed-off-by: Heiko Carstens <heiko.carstens@xxxxxxxxxx>
Cc: Philipp Hachtmann <phacht@xxxxxxxxxxxxxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
---

 mm/memblock.c |    4 ++++
 1 file changed, 4 insertions(+)

diff -puN mm/memblock.c~memblock-let-memblock_type_name-know-about-physmem-type mm/memblock.c
--- a/mm/memblock.c~memblock-let-memblock_type_name-know-about-physmem-type
+++ a/mm/memblock.c
@@ -72,6 +72,10 @@ memblock_type_name(struct memblock_type
 		return "memory";
 	else if (type == &memblock.reserved)
 		return "reserved";
+#ifdef CONFIG_HAVE_MEMBLOCK_PHYS_MAP
+	else if (type == &memblock.physmem)
+		return "physmem";
+#endif
 	else
 		return "unknown";
 }
_
--
To unsubscribe from this list: send the line "unsubscribe mm-commits" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Kernel Archive]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]

  Powered by Linux