On Fri, Apr 21, 2017 at 12:12 AM, Oliver O'Halloran <[email protected]> wrote:
> Print the alignment for dax namespaces creation. It's good to be explicit 
> about
> it since about the selected region alignment dictates the type of faults
> we allow on the namespace.
>
> Signed-off-by: Oliver O'Halloran <[email protected]>
> ---
>  util/json.c | 5 +++++
>  1 file changed, 5 insertions(+)
>
> diff --git a/util/json.c b/util/json.c
> index d6a8d4c899ed..720d22559df0 100644
> --- a/util/json.c
> +++ b/util/json.c
> @@ -299,6 +299,11 @@ struct json_object *util_namespace_to_json(struct 
> ndctl_namespace *ndns,
>                 if (!jobj)
>                         goto err;
>                 json_object_object_add(jndns, "uuid", jobj);
> +               jobj = json_object_new_int64(ndctl_dax_get_align(dax));
> +               if (!jobj)
> +                       goto err;
> +               json_object_object_add(jndns, "align", jobj);
> +

Yes, we need this, but lets hide this attribute when the 'align' is
zero. That helps with ndctl running on older kernels that do not have
an align attribute available.
_______________________________________________
Linux-nvdimm mailing list
[email protected]
https://lists.01.org/mailman/listinfo/linux-nvdimm

Reply via email to