From 78c81cc89a40114d09a5ec0693cfd97831ffbe79 Mon Sep 17 00:00:00 2001 From: Dan Williams Date: Wed, 6 Nov 2019 19:56:41 -0800 Subject: libnvdimm: Move attribute groups to device type Statically initialize the attribute groups for each libnvdimm device_type. This is a preparation step for removing unnecessary exports of attributes that can be included in the device_type by default. Also take the opportunity to mark 'struct device_type' instances const. Cc: Ira Weiny Cc: Vishal Verma Signed-off-by: Dan Williams Reviewed-by: Aneesh Kumar K.V Link: https://lore.kernel.org/r/157309900111.1582359.2445687530383470348.stgit@dwillia2-desk3.amr.corp.intel.com --- drivers/nvdimm/nd.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'drivers/nvdimm/nd.h') diff --git a/drivers/nvdimm/nd.h b/drivers/nvdimm/nd.h index a9f338d01a55..d83dd34cd169 100644 --- a/drivers/nvdimm/nd.h +++ b/drivers/nvdimm/nd.h @@ -302,7 +302,7 @@ struct device *nd_pfn_create(struct nd_region *nd_region); struct device *nd_pfn_devinit(struct nd_pfn *nd_pfn, struct nd_namespace_common *ndns); int nd_pfn_validate(struct nd_pfn *nd_pfn, const char *sig); -extern struct attribute_group nd_pfn_attribute_group; +extern const struct attribute_group *nd_pfn_attribute_groups[]; #else static inline int nd_pfn_probe(struct device *dev, struct nd_namespace_common *ndns) -- cgit v1.2.3