Skip to contentSkip to conversation

memory_hotplug: add missing newlines to debugging output

PATCH In review Michal Hocko 3 participants 3 messages Dec 18, 2018

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 memory_hotplug: add missing newlines to debugging output

From: Michal Hocko <[email protected]>

pages_correctly_probed is missing new lines which means that the line is not printed rightaway but it rather waits for additional printks.

Add \n to all three messages in pages_correctly_probed.

Fixes b77eab7079d9 ("mm/memory_hotplug: optimize probe routine")
---
 drivers/base/memory.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/base/memory.c +3 -3
index 0e5985682642..b5ff45ab7967 100644
@@ -207,15 +207,15 @@ static bool pages_correctly_probed(unsigned long start_pfn)
 			return false;
 
 		if (!present_section_nr(section_nr)) {
-			pr_warn("section %ld pfn[%lx, %lx) not present",
+			pr_warn("section %ld pfn[%lx, %lx) not present\n",
 				section_nr, pfn, pfn + PAGES_PER_SECTION);
 			return false;
 		} else if (!valid_section_nr(section_nr)) {
-			pr_warn("section %ld pfn[%lx, %lx) no valid memmap",
+			pr_warn("section %ld pfn[%lx, %lx) no valid memmap\n",
 				section_nr, pfn, pfn + PAGES_PER_SECTION);
 			return false;
 		} else if (online_section_nr(section_nr)) {
-			pr_warn("section %ld pfn[%lx, %lx) is already online",
+			pr_warn("section %ld pfn[%lx, %lx) is already online\n",
 				section_nr, pfn, pfn + PAGES_PER_SECTION);
 			return false;
 		}
Signature · 1 line
2.19.2
maintainer Reviewed-by on v1 1/1
#1 lore raw
Quoted 4 lines · Michal Hocko

From: Michal Hocko <[email protected]>

Fixes b77eab7079d9 ("mm/memory_hotplug: optimize probe routine")
Quoted 30 lines
---
 drivers/base/memory.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/base/memory.c +3 -3
index 0e5985682642..b5ff45ab7967 100644
@@ -207,15 +207,15 @@ static bool pages_correctly_probed(unsigned long start_pfn)
 			return false;
 
 		if (!present_section_nr(section_nr)) {
-			pr_warn("section %ld pfn[%lx, %lx) not present",
+			pr_warn("section %ld pfn[%lx, %lx) not present\n",
 				section_nr, pfn, pfn + PAGES_PER_SECTION);
 			return false;
 		} else if (!valid_section_nr(section_nr)) {
-			pr_warn("section %ld pfn[%lx, %lx) no valid memmap",
+			pr_warn("section %ld pfn[%lx, %lx) no valid memmap\n",
 				section_nr, pfn, pfn + PAGES_PER_SECTION);
 			return false;
 		} else if (online_section_nr(section_nr)) {
-			pr_warn("section %ld pfn[%lx, %lx) is already online",
+			pr_warn("section %ld pfn[%lx, %lx) is already online\n",
 				section_nr, pfn, pfn + PAGES_PER_SECTION);
 			return false;
 		}
Signature · 1 line
2.19.2
Signature · 2 lines
Oscar Salvador
SUSE L3
Reviewed-by on v1 1/1
#2 lore raw
In reply to Michal Hocko
Quoted 9 lines · Michal Hocko

From: Michal Hocko <[email protected]>

pages_correctly_probed is missing new lines which means that the line is not printed rightaway but it rather waits for additional printks.

Add \n to all three messages in pages_correctly_probed.

Fixes b77eab7079d9 ("mm/memory_hotplug: optimize probe routine")
Quoted 29 lines

---
drivers/base/memory.c | 6 +++---

1 file changed, 3 insertions(+), 3 deletions(-)
drivers/base/memory.c +3 -3
index 0e5985682642..b5ff45ab7967 100644
@@ -207,15 +207,15 @@ static bool pages_correctly_probed(unsigned long start_pfn)
 			return false;
 
 		if (!present_section_nr(section_nr)) {
-			pr_warn("section %ld pfn[%lx, %lx) not present",
+			pr_warn("section %ld pfn[%lx, %lx) not present\n",
 				section_nr, pfn, pfn + PAGES_PER_SECTION);
 			return false;
 		} else if (!valid_section_nr(section_nr)) {
-			pr_warn("section %ld pfn[%lx, %lx) no valid memmap",
+			pr_warn("section %ld pfn[%lx, %lx) no valid memmap\n",
 				section_nr, pfn, pfn + PAGES_PER_SECTION);
 			return false;
 		} else if (online_section_nr(section_nr)) {
-			pr_warn("section %ld pfn[%lx, %lx) is already online",
+			pr_warn("section %ld pfn[%lx, %lx) is already online\n",
 				section_nr, pfn, pfn + PAGES_PER_SECTION);
 			return false;
 		}
Signature · 1 line
2.19.2
Signature · 2 lines
Wei Yang
Help you, Help me