All of lore.kernel.org
 help / color / mirror / Atom feed
From: Minwoo Im <minwoo.im.dev@gmail.com>
To: linux-cxl@vger.kernel.org, nvdimm@lists.linux.dev
Cc: Dave Jiang <dave.jiang@intel.com>,
	Dan Williams <dan.j.williams@intel.com>,
	Vishal Verma <vishal.l.verma@intel.com>,
	Minwoo Im <minwoo.im.dev@gmail.com>
Subject: [ndctl PATCH 2/3] cxl: region: remove redundant func name from error
Date: Wed, 10 May 2023 00:24:26 +0900	[thread overview]
Message-ID: <20230509152427.6920-3-minwoo.im.dev@gmail.com> (raw)
In-Reply-To: <20230509152427.6920-1-minwoo.im.dev@gmail.com>

If user does not provide `-s, --size` option and there's no ep_min_size
configured, it prints error log like the following.  This patch removes
redundant repeated function name from the log.

Before:

  root@vm:~/work# cxl create-region -m -d decoder0.0 -w 1 -g 1024 mem0
  cxl region: create_region: create_region: unable to determine region size
  cxl region: cmd_create_region: created 0 regions

After:
  root@vm:~/work# cxl create-region -m -d decoder0.0 -w 1 -g 1024 mem0
  cxl region: create_region: unable to determine region size
  cxl region: cmd_create_region: created 0 regions

Signed-off-by: Minwoo Im <minwoo.im.dev@gmail.com>
---
 cxl/region.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/cxl/region.c b/cxl/region.c
index 07ce4a319fd0..71f152d9e5a5 100644
--- a/cxl/region.c
+++ b/cxl/region.c
@@ -607,7 +607,8 @@ static int create_region(struct cxl_ctx *ctx, int *count,
 	} else if (p->ep_min_size) {
 		size = p->ep_min_size * p->ways;
 	} else {
-		log_err(&rl, "%s: unable to determine region size\n", __func__);
+		log_err(&rl, "unable to determine region size\n");
+
 		return -ENXIO;
 	}
 	max_extent = cxl_decoder_get_max_available_extent(p->root_decoder);
-- 
2.34.1


  parent reply	other threads:[~2023-05-09 15:25 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-05-09 15:24 [ndctl PATCH 0/3] cxl: clean up and fix typos Minwoo Im
2023-05-09 15:24 ` [ndctl PATCH 1/3] cxl/list: Fix typo in cxl-list documentation Minwoo Im
2023-05-09 17:31   ` Dave Jiang
2023-05-09 15:24 ` Minwoo Im [this message]
2023-05-09 17:32   ` [ndctl PATCH 2/3] cxl: region: remove redundant func name from error Dave Jiang
2023-05-09 15:24 ` [ndctl PATCH 3/3] cxl: fix changed function name in a comment Minwoo Im
2023-05-09 17:33   ` Dave Jiang

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=20230509152427.6920-3-minwoo.im.dev@gmail.com \
    --to=minwoo.im.dev@gmail.com \
    --cc=dan.j.williams@intel.com \
    --cc=dave.jiang@intel.com \
    --cc=linux-cxl@vger.kernel.org \
    --cc=nvdimm@lists.linux.dev \
    --cc=vishal.l.verma@intel.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.