mm: add show num_poisoned_pages when oom
Subsystems (2)
PATCH v2 1/1 mm: add show num_poisoned_pages when oom
Show num_poisoned_pages when oom, it is a little helpful to find the reason. Also it will be emitted anytime show_mem() is called.
--- lib/show_mem.c | 3 +++ 1 files changed, 3 insertions(+), 0 deletions(-)
lib/show_mem.c +3 -0
@@ -46,4 +46,7 @@ void show_mem(unsigned int filter)printk ("%lu pages in pagetable cache\n" ,quicklist_total_size ());#endif +#ifdef CONFIG_MEMORY_FAILURE +printk ("%lu pages hwpoisoned\n" ,atomic_long_read (&num_poisoned_pages)); +#endif }
Signature · 8 lines
1.7.1 -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to [email protected]. For more info on Linux MM, see: http://www.linux-mm.org/ . Don't email: <a href=mailto:"[email protected]"> [email protected] </a>
Quoted 7 lines · Xishi Qiu
Show
num_poisoned_pageswhen oom, it is a little helpful to find the reason. Also it will be emitted anytimeshow_mem()is called.Signed-off-by Xishi Qiu <[email protected]>Suggested-by Naoya Horiguchi <[email protected]>Acked-by Michal Hocko <[email protected]>Acked-by David Rientjes <[email protected]>
Quoted 25 lines
---
lib/show_mem.c| 3 +++1 files changed, 3 insertions(+), 0 deletions(-)lib/show_mem.c +3
-0@@ -46,4 +46,7 @@ void show_mem(unsigned int filter)printk ("%lu pages in pagetable cache\n" ,quicklist_total_size ());#endif +#ifdef CONFIG_MEMORY_FAILURE +printk ("%lu pages hwpoisoned\n" ,atomic_long_read (&num_poisoned_pages)); +#endif }Signature · 8 lines
1.7.1 -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to [email protected]. For more info on Linux MM, see: http://www.linux-mm.org/ . Don't email: <a href=mailto:"[email protected]"> [email protected] </a>
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to [email protected]. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"[email protected]"> [email protected] </a>
Quoted 16 lines · Xishi Qiu
Show
num_poisoned_pageswhen oom, it is a little helpful to find the reason. Also it will be emitted anytimeshow_mem()is called.Signed-off-by Xishi Qiu <[email protected]>Suggested-by Naoya Horiguchi <[email protected]>Acked-by Michal Hocko <[email protected]>Acked-by David Rientjes <[email protected]>--- lib/show_mem.c | 3 +++ 1 files changed, 3 insertions(+), 0 deletions(-)lib/show_mem.c +0
-0
lib/show_mem.c void show_mem(unsigned int filter) · line 52
Quoted 7 lines
lib/show_mem.c +3
-0@@ -46,4 +46,7 @@ void show_mem(unsigned int filter)printk ("%lu pages in pagetable cache\n" ,quicklist_total_size ());#endif +#ifdef CONFIG_MEMORY_FAILURE +printk ("%lu pages hwpoisoned\n" ,atomic_long_read (&num_poisoned_pages)); +#endif }
Looks ok.