lkml.org 
[lkml]   [2021]   [Feb]   [9]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH v2] mm: cma: Print region name on failure
From
Date
On 09.02.21 15:24, Georgi Djakov wrote:
> From: Patrick Daly <pdaly@codeaurora.org>
>
> Print the name of the CMA region for convenience. This is useful
> information to have when cma_alloc() fails.
>
> Signed-off-by: Patrick Daly <pdaly@codeaurora.org>
> Signed-off-by: Georgi Djakov <georgi.djakov@linaro.org>
> ---
> v2:
> * Print the "count" variable, as it was originally in the code. (Randy)
> * Fix spelling s/convienience/convenience/ in the commit text (Randy)
>
> v1: https://lore.kernel.org/r/20210208115200.20286-1-georgi.djakov@linaro.org/
>
> mm/cma.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/mm/cma.c b/mm/cma.c
> index 23d4a97c834a..54eee2119822 100644
> --- 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);
> }
>
>

Reviewed-by: David Hildenbrand <david@redhat.com>

--
Thanks,

David / dhildenb

\
 
 \ /
  Last update: 2021-02-09 17:09    [W:0.078 / U:0.748 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site