]> Git Repo - linux.git/commitdiff
mm: cma: print region name on failure
authorPatrick Daly <[email protected]>
Fri, 26 Feb 2021 01:16:44 +0000 (17:16 -0800)
committerLinus Torvalds <[email protected]>
Fri, 26 Feb 2021 17:41:00 +0000 (09:41 -0800)
Print the name of the CMA region for convenience.  This is useful
information to have when cma_alloc() fails.

[[email protected]: print the "count" variable]
Link: https://lkml.kernel.org/r/[email protected]
Link: https://lkml.kernel.org/r/[email protected]
Signed-off-by: Patrick Daly <[email protected]>
Signed-off-by: Georgi Djakov <[email protected]>
Acked-by: Minchan Kim <[email protected]>
Reviewed-by: David Hildenbrand <[email protected]>
Reviewed-by: Randy Dunlap <[email protected]>
Cc: Minchan Kim <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
mm/cma.c

index 23d4a97c834a5312635b918cc5cd56fe5a265059..54eee2119822026fe08a2c24329c5f5b8ee3516a 100644 (file)
--- a/mm/cma.c
+++ b/mm/cma.c
@@ -500,8 +500,8 @@ struct page *cma_alloc(struct cma *cma, size_t count, unsigned int align,
        }
 
        if (ret && !no_warn) {
-               pr_err("%s: alloc failed, req-size: %zu pages, ret: %d\n",
-                       __func__, count, ret);
+               pr_err("%s: %s: alloc failed, req-size: %zu pages, ret: %d\n",
+                      __func__, cma->name, count, ret);
                cma_debug_show_areas(cma);
        }
 
This page took 0.064697 seconds and 4 git commands to generate.