diff mbox

[ndctl,1/2] ndctl: s/memory/fsdax/ in some user visible places

Message ID 20180409200920.20177-1-ross.zwisler@linux.intel.com (mailing list archive)
State New, archived
Headers show

Commit Message

Ross Zwisler April 9, 2018, 8:09 p.m. UTC
Adding on to the work started by:

commit ebb4fb605e68 ("ndctl, create-namespace: introduce "fsdax" and "devdax" modes")

Signed-off-by: Ross Zwisler <ross.zwisler@linux.intel.com>
---
 Documentation/ndctl/ndctl-inject-error.txt | 2 +-
 ndctl/namespace.c                          | 8 ++++----
 2 files changed, 5 insertions(+), 5 deletions(-)

Comments

Dan Williams April 9, 2018, 10:10 p.m. UTC | #1
On Mon, Apr 9, 2018 at 1:09 PM, Ross Zwisler
<ross.zwisler@linux.intel.com> wrote:
> Adding on to the work started by:
>
> commit ebb4fb605e68 ("ndctl, create-namespace: introduce "fsdax" and "devdax" modes")

I'd say "why" here.

Also, might as well also convert util_namespace_to_json() to emit
"fsdax" in all cases. I had initially thought there were compat
concerns with removing the "memory" designation, but it will just
cause ongoing confusion. Lets kill its output everywhere, but of
course still accept it as a command input.
Ross Zwisler April 9, 2018, 11:07 p.m. UTC | #2
On Mon, Apr 09, 2018 at 03:10:26PM -0700, Dan Williams wrote:
> On Mon, Apr 9, 2018 at 1:09 PM, Ross Zwisler
> <ross.zwisler@linux.intel.com> wrote:
> > Adding on to the work started by:
> >
> > commit ebb4fb605e68 ("ndctl, create-namespace: introduce "fsdax" and "devdax" modes")
> 
> I'd say "why" here.

Because having both "memory" and "fsdax" and having to know that they are
aliases is confusing.  It'd be great if we could just choose one term and
stick with it, and I thought the term we had decided on was "fsdax".

> Also, might as well also convert util_namespace_to_json() to emit
> "fsdax" in all cases. I had initially thought there were compat
> concerns with removing the "memory" designation, but it will just
> cause ongoing confusion. Lets kill its output everywhere, but of
> course still accept it as a command input.

Cool, I think that'd be best.
diff mbox

Patch

diff --git a/Documentation/ndctl/ndctl-inject-error.txt b/Documentation/ndctl/ndctl-inject-error.txt
index 01f6c22..94c4e69 100644
--- a/Documentation/ndctl/ndctl-inject-error.txt
+++ b/Documentation/ndctl/ndctl-inject-error.txt
@@ -45,7 +45,7 @@  OPTIONS
 
 	NOTE: The offset is interpreted in different ways based on the "mode"
 	of the namespace. For "raw" mode, the offset is the base namespace
-	offset. For "memory" mode (i.e. a "pfn" namespace), the offset is
+	offset. For "fsdax" mode (i.e. a "pfn" namespace), the offset is
 	relative to the user-visible part of the namespace, and the offset
 	introduced by the kernel's metadata will be accounted for. For a
 	"sector" mode namespace (i.e. a "BTT" namespace), the offset is
diff --git a/ndctl/namespace.c b/ndctl/namespace.c
index f2c5644..e619dc1 100644
--- a/ndctl/namespace.c
+++ b/ndctl/namespace.c
@@ -103,7 +103,7 @@  OPT_STRING('n', "name", &param.name, "name", \
 OPT_STRING('s', "size", &param.size, "size", \
 	"specify the namespace size in bytes (default: available capacity)"), \
 OPT_STRING('m', "mode", &param.mode, "operation-mode", \
-	"specify a mode for the namespace, 'sector', 'memory', or 'raw'"), \
+	"specify a mode for the namespace, 'sector', 'fsdax', or 'raw'"), \
 OPT_STRING('M', "map", &param.map, "memmap-location", \
 	"specify 'mem' or 'dev' for the location of the memmap"), \
 OPT_STRING('l', "sector-size", &param.sector_size, "lba-size", \
@@ -696,7 +696,7 @@  static int validate_namespace_options(struct ndctl_region *region,
 
 		if (ndns && p->mode != NDCTL_NS_MODE_MEMORY
 			&& p->mode != NDCTL_NS_MODE_DAX) {
-			debug("%s: --map= only valid for memory mode namespace\n",
+			debug("%s: --map= only valid for fsdax mode namespace\n",
 				ndctl_namespace_get_devname(ndns));
 			return -EINVAL;
 		}
@@ -709,10 +709,10 @@  static int validate_namespace_options(struct ndctl_region *region,
 		struct ndctl_pfn *pfn = ndctl_region_get_pfn_seed(region);
 
 		if (!pfn && param.mode_default) {
-			debug("%s memory mode not available\n", region_name);
+			debug("%s fsdax mode not available\n", region_name);
 			p->mode = NDCTL_NS_MODE_RAW;
 		} else if (!pfn) {
-			error("operation failed, %s memory mode not available\n",
+			error("operation failed, %s fsdax mode not available\n",
 					region_name);
 			return -EINVAL;
 		}