* [ndctl PATCH v2 3/4] ndctl, lib: implement ndctl_dimm_get_cmd_family()
@ 2019-02-20 5:11 Dexuan Cui
2019-03-21 1:41 ` Verma, Vishal L
0 siblings, 1 reply; 3+ messages in thread
From: Dexuan Cui @ 2019-02-20 5:11 UTC (permalink / raw)
To: Dave Jiang, Vishal Verma, Dan Williams,
linux-nvdimm-hn68Rpc1hR1g9hUCZPvPmw, Michael Kelley,
qi.fuli-LMvhtfratI1BDgjK7y7TUQ, Johannes Thumshirn
Let's export the family info so we can do some family-specific
handling in ndctl/monitor.c for Hyper-V NVDIMM.
Signed-off-by: Dexuan Cui <decui-0li6OtcxBFHby3iVrkZq2A@public.gmane.org>
---
ndctl/lib/libndctl.c | 5 +++++
ndctl/lib/libndctl.sym | 1 +
ndctl/libndctl.h | 1 +
3 files changed, 7 insertions(+)
diff --git a/ndctl/lib/libndctl.c b/ndctl/lib/libndctl.c
index 48bdb27..1186579 100644
--- a/ndctl/lib/libndctl.c
+++ b/ndctl/lib/libndctl.c
@@ -1550,6 +1550,11 @@ NDCTL_EXPORT struct ndctl_dimm *ndctl_dimm_get_next(struct ndctl_dimm *dimm)
return list_next(&bus->dimms, dimm, list);
}
+NDCTL_EXPORT unsigned long ndctl_dimm_get_cmd_family(struct ndctl_dimm *dimm)
+{
+ return dimm->cmd_family;
+}
+
NDCTL_EXPORT unsigned int ndctl_dimm_get_handle(struct ndctl_dimm *dimm)
{
return dimm->handle;
diff --git a/ndctl/lib/libndctl.sym b/ndctl/lib/libndctl.sym
index cb9f769..470e895 100644
--- a/ndctl/lib/libndctl.sym
+++ b/ndctl/lib/libndctl.sym
@@ -38,6 +38,7 @@ global:
ndctl_bus_wait_probe;
ndctl_dimm_get_first;
ndctl_dimm_get_next;
+ ndctl_dimm_get_cmd_family;
ndctl_dimm_get_handle;
ndctl_dimm_get_phys_id;
ndctl_dimm_get_vendor;
diff --git a/ndctl/libndctl.h b/ndctl/libndctl.h
index 0debdb6..cb5a8fc 100644
--- a/ndctl/libndctl.h
+++ b/ndctl/libndctl.h
@@ -145,6 +145,7 @@ struct ndctl_dimm *ndctl_dimm_get_next(struct ndctl_dimm *dimm);
for (dimm = ndctl_dimm_get_first(bus); \
dimm != NULL; \
dimm = ndctl_dimm_get_next(dimm))
+unsigned long ndctl_dimm_get_cmd_family(struct ndctl_dimm *dimm);
unsigned int ndctl_dimm_get_handle(struct ndctl_dimm *dimm);
unsigned short ndctl_dimm_get_phys_id(struct ndctl_dimm *dimm);
unsigned short ndctl_dimm_get_vendor(struct ndctl_dimm *dimm);
--
2.19.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [ndctl PATCH v2 3/4] ndctl, lib: implement ndctl_dimm_get_cmd_family()
2019-02-20 5:11 [ndctl PATCH v2 3/4] ndctl, lib: implement ndctl_dimm_get_cmd_family() Dexuan Cui
@ 2019-03-21 1:41 ` Verma, Vishal L
[not found] ` <221ceaa03f0a46d020da7a1c7fcd4d521bf5e09e.camel-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
0 siblings, 1 reply; 3+ messages in thread
From: Verma, Vishal L @ 2019-03-21 1:41 UTC (permalink / raw)
To: Williams, Dan J, decui, Jiang, Dave, linux-nvdimm, jthumshirn,
mikelley, qi.fuli
On Wed, 2019-02-20 at 05:11 +0000, Dexuan Cui wrote:
> Let's export the family info so we can do some family-specific
> handling in ndctl/monitor.c for Hyper-V NVDIMM.
s/Let's//
>
> Signed-off-by: Dexuan Cui <decui@microsoft.com>
> ---
> ndctl/lib/libndctl.c | 5 +++++
> ndctl/lib/libndctl.sym | 1 +
> ndctl/libndctl.h | 1 +
> 3 files changed, 7 insertions(+)
>
> diff --git a/ndctl/lib/libndctl.c b/ndctl/lib/libndctl.c
> index 48bdb27..1186579 100644
> --- a/ndctl/lib/libndctl.c
> +++ b/ndctl/lib/libndctl.c
> @@ -1550,6 +1550,11 @@ NDCTL_EXPORT struct ndctl_dimm *ndctl_dimm_get_next(struct ndctl_dimm *dimm)
> return list_next(&bus->dimms, dimm, list);
> }
>
> +NDCTL_EXPORT unsigned long ndctl_dimm_get_cmd_family(struct ndctl_dimm *dimm)
> +{
> + return dimm->cmd_family;
> +}
> +
> NDCTL_EXPORT unsigned int ndctl_dimm_get_handle(struct ndctl_dimm *dimm)
> {
> return dimm->handle;
> diff --git a/ndctl/lib/libndctl.sym b/ndctl/lib/libndctl.sym
> index cb9f769..470e895 100644
> --- a/ndctl/lib/libndctl.sym
> +++ b/ndctl/lib/libndctl.sym
> @@ -38,6 +38,7 @@ global:
> ndctl_bus_wait_probe;
> ndctl_dimm_get_first;
> ndctl_dimm_get_next;
> + ndctl_dimm_get_cmd_family;
Any new APIs need to go in a new LIBNDCTL_XX section (for this release
that would be LIBNDCTL_20).
If you rebase to the current 'pending' branch on github, the section has
already been created at the bottom, and you can just add to that.
> ndctl_dimm_get_handle;
> ndctl_dimm_get_phys_id;
> ndctl_dimm_get_vendor;
> diff --git a/ndctl/libndctl.h b/ndctl/libndctl.h
> index 0debdb6..cb5a8fc 100644
> --- a/ndctl/libndctl.h
> +++ b/ndctl/libndctl.h
> @@ -145,6 +145,7 @@ struct ndctl_dimm *ndctl_dimm_get_next(struct ndctl_dimm *dimm);
> for (dimm = ndctl_dimm_get_first(bus); \
> dimm != NULL; \
> dimm = ndctl_dimm_get_next(dimm))
> +unsigned long ndctl_dimm_get_cmd_family(struct ndctl_dimm *dimm);
> unsigned int ndctl_dimm_get_handle(struct ndctl_dimm *dimm);
> unsigned short ndctl_dimm_get_phys_id(struct ndctl_dimm *dimm);
> unsigned short ndctl_dimm_get_vendor(struct ndctl_dimm *dimm);
_______________________________________________
Linux-nvdimm mailing list
Linux-nvdimm@lists.01.org
https://lists.01.org/mailman/listinfo/linux-nvdimm
^ permalink raw reply [flat|nested] 3+ messages in thread
* RE: [ndctl PATCH v2 3/4] ndctl, lib: implement ndctl_dimm_get_cmd_family()
[not found] ` <221ceaa03f0a46d020da7a1c7fcd4d521bf5e09e.camel-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
@ 2019-03-22 1:33 ` Dexuan Cui
0 siblings, 0 replies; 3+ messages in thread
From: Dexuan Cui @ 2019-03-22 1:33 UTC (permalink / raw)
To: Verma, Vishal L, Williams, Dan J, Jiang, Dave,
linux-nvdimm-hn68Rpc1hR1g9hUCZPvPmw, jthumshirn-l3A5Bk7waGM,
Michael Kelley, qi.fuli-LMvhtfratI1BDgjK7y7TUQ
> From: Verma, Vishal L <vishal.l.verma-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
> Sent: Wednesday, March 20, 2019 6:42 PM
> On Wed, 2019-02-20 at 05:11 +0000, Dexuan Cui wrote:
> > Let's export the family info so we can do some family-specific
> > handling in ndctl/monitor.c for Hyper-V NVDIMM.
>
> s/Let's//
Will fix it.
> > ndctl/lib/libndctl.c | 5 +++++
> > ndctl/lib/libndctl.sym | 1 +
> > ndctl/libndctl.h | 1 +
> > 3 files changed, 7 insertions(+)
> >
> > diff --git a/ndctl/lib/libndctl.c b/ndctl/lib/libndctl.c
> > index 48bdb27..1186579 100644
> > --- a/ndctl/lib/libndctl.c
> > +++ b/ndctl/lib/libndctl.c
> > @@ -1550,6 +1550,11 @@ NDCTL_EXPORT struct ndctl_dimm
> *ndctl_dimm_get_next(struct ndctl_dimm *dimm)
> > return list_next(&bus->dimms, dimm, list);
> > }
> >
> > +NDCTL_EXPORT unsigned long ndctl_dimm_get_cmd_family(struct
> ndctl_dimm *dimm)
> > +{
> > + return dimm->cmd_family;
> > +}
> > +
> > NDCTL_EXPORT unsigned int ndctl_dimm_get_handle(struct ndctl_dimm
> *dimm)
> > {
> > return dimm->handle;
> > diff --git a/ndctl/lib/libndctl.sym b/ndctl/lib/libndctl.sym
> > index cb9f769..470e895 100644
> > --- a/ndctl/lib/libndctl.sym
> > +++ b/ndctl/lib/libndctl.sym
> > @@ -38,6 +38,7 @@ global:
> > ndctl_bus_wait_probe;
> > ndctl_dimm_get_first;
> > ndctl_dimm_get_next;
> > + ndctl_dimm_get_cmd_family;
>
> Any new APIs need to go in a new LIBNDCTL_XX section (for this release
> that would be LIBNDCTL_20).
> If you rebase to the current 'pending' branch on github, the section has
> already been created at the bottom, and you can just add to that.
Will fix it
Thanks,
-- Dexuan
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2019-03-22 1:33 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-02-20 5:11 [ndctl PATCH v2 3/4] ndctl, lib: implement ndctl_dimm_get_cmd_family() Dexuan Cui
2019-03-21 1:41 ` Verma, Vishal L
[not found] ` <221ceaa03f0a46d020da7a1c7fcd4d521bf5e09e.camel-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
2019-03-22 1:33 ` Dexuan Cui
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).