linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Randy Dunlap <rdunlap@infradead.org>
To: Georgi Djakov <georgi.djakov@linaro.org>,
	akpm@linux-foundation.org, linux-mm@kvack.org
Cc: pdaly@codeaurora.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2] mm: cma: Print region name on failure
Date: Tue, 9 Feb 2021 09:36:00 -0800	[thread overview]
Message-ID: <7caf3642-4283-4288-45c1-fcbd17d8c84b@infradead.org> (raw)
In-Reply-To: <20210209142414.12768-1-georgi.djakov@linaro.org>

On 2/9/21 6:24 AM, 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>

Reviewed-by: Randy Dunlap <rdunlap@infradead.org>

Thanks.

> ---
> 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);
>  	}
>  
> 


-- 
~Randy


      parent reply	other threads:[~2021-02-09 17:39 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-02-09 14:24 [PATCH v2] mm: cma: Print region name on failure Georgi Djakov
2021-02-09 16:03 ` Minchan Kim
2021-02-09 16:06 ` David Hildenbrand
2021-02-09 17:36 ` Randy Dunlap [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=7caf3642-4283-4288-45c1-fcbd17d8c84b@infradead.org \
    --to=rdunlap@infradead.org \
    --cc=akpm@linux-foundation.org \
    --cc=georgi.djakov@linaro.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=pdaly@codeaurora.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).