From patchwork Mon Feb 8 11:52:00 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Georgi Djakov X-Patchwork-Id: 12075233 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-16.6 required=3.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id F2D32C433E6 for ; Mon, 8 Feb 2021 11:52:07 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 4FC8A64E6E for ; Mon, 8 Feb 2021 11:52:07 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 4FC8A64E6E Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=linaro.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 453426B0006; Mon, 8 Feb 2021 06:52:05 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 404D56B006C; Mon, 8 Feb 2021 06:52:05 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 2F2D86B0071; Mon, 8 Feb 2021 06:52:05 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0056.hostedemail.com [216.40.44.56]) by kanga.kvack.org (Postfix) with ESMTP id 195996B0006 for ; Mon, 8 Feb 2021 06:52:05 -0500 (EST) Received: from smtpin03.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay01.hostedemail.com (Postfix) with ESMTP id D6A20180AD815 for ; Mon, 8 Feb 2021 11:52:04 +0000 (UTC) X-FDA: 77794936968.03.9876A94 Received: from mail-wr1-f46.google.com (mail-wr1-f46.google.com [209.85.221.46]) by imf02.hostedemail.com (Postfix) with ESMTP id 3949440001DE for ; Mon, 8 Feb 2021 11:52:04 +0000 (UTC) Received: by mail-wr1-f46.google.com with SMTP id g10so16748953wrx.1 for ; Mon, 08 Feb 2021 03:52:04 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=P8sbwZJksTHY0g7J4gwBmmOhoWBgz9PyjuC/t9xFYc4=; b=og8oHOy20CdNUnjmh4a5BFlhL/JHUeymZ5PBKhTZik+VO6CHT9e4mzp6yRIxNsehQi lLgV4cA6iFbCSbj7MWBsHZb7U5E+7zrVNvU5G+vTy01ehcqCOlRCJLgTt4Rakjr3BQyw cClxPHXYeybfWlhEO5T7kBUyQz2FECUYiP6HniQrwSCOxHsgz/zwHMWtLwTyS5YvRZSG 3fYc5hhoMYi/dyx32MIWyX/0QSgUbqsR3m0NQPjhYDkk4q36DIR5OpO2vBy6LuPyzeTh UitCbPqf8+JO3n/9/nigR47F77IFqqSVupxZEqR24a3CejkjYVWST919IEjUvYod9dcW 2ScQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=P8sbwZJksTHY0g7J4gwBmmOhoWBgz9PyjuC/t9xFYc4=; b=O6dFPh+q1V7KFuxIU2mAL/oOZVMlsLzVxZ4mglgSTlOqqlx8bdF2+ufqyRRTlT1b4J OagmI9ttThwInA/nOmMEHF/Jba8UUKEktZwF54Hpw6hR/pwoEOP2XpmJCEdt1tR/8ZSg uhQOc/BubAZfUbcwsboSw3O3bWaqCi6ytmZaOlEJvAO5pS9+15/84lEw7/mvYjO21M14 EDq49/TUjshRS5wKWFnhNOTdhbsQfm9A2jjzucVWWVoeBv3j7ygqSNnyTa0jLZLPzr6M WauxASDCuHOkmp0GR5WZ9Clm9ER0lfSIlMZ2cb7Lf2crWDk2txtl/M2yEx4PGyv4ODUW 3SSg== X-Gm-Message-State: AOAM533+cn/enQSNq2QgYJQkuq1x/X3FHIKnk1o652YyHMgTNenpNes/ a7Zp8rhzBy/PYGv7G6AER2PLkg== X-Google-Smtp-Source: ABdhPJzbVPAxOaCpXmvkC8F2ttifA1FDEkebSqYL4jke6VNrz9r29Gom+z/dOybf4mUE2YoHLnkVmg== X-Received: by 2002:a5d:50d2:: with SMTP id f18mr20356764wrt.338.1612785123105; Mon, 08 Feb 2021 03:52:03 -0800 (PST) Received: from localhost.localdomain ([212.45.67.2]) by smtp.googlemail.com with ESMTPSA id f7sm27980549wre.78.2021.02.08.03.52.02 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Mon, 08 Feb 2021 03:52:02 -0800 (PST) From: Georgi Djakov To: akpm@linux-foundation.org, linux-mm@kvack.org Cc: linux-kernel@vger.kernel.org, pdaly@codeaurora.org, georgi.djakov@linaro.org Subject: [PATCH] mm: cma: Print region name on failure Date: Mon, 8 Feb 2021 13:52:00 +0200 Message-Id: <20210208115200.20286-1-georgi.djakov@linaro.org> X-Mailer: git-send-email 2.29.0 MIME-Version: 1.0 X-Stat-Signature: 3uz3gz9hqniynkxknwozhunkwcqyxrye X-Rspamd-Server: rspam05 X-Rspamd-Queue-Id: 3949440001DE Received-SPF: none (linaro.org>: No applicable sender policy available) receiver=imf02; identity=mailfrom; envelope-from=""; helo=mail-wr1-f46.google.com; client-ip=209.85.221.46 X-HE-DKIM-Result: pass/pass X-HE-Tag: 1612785124-395704 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: From: Patrick Daly Print the name of the cma region for convienience. This is useful information to have when cma_alloc() fails. Signed-off-by: Patrick Daly Signed-off-by: Georgi Djakov --- mm/cma.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mm/cma.c b/mm/cma.c index 23d4a97c834a..9ca6eaa0e52e 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, cma->count, ret); cma_debug_show_areas(cma); }