diff options
author | Vishal Verma <vishal.l.verma@intel.com> | 2016-07-24 00:51:42 -0400 |
---|---|---|
committer | Dan Williams <dan.j.williams@intel.com> | 2016-07-24 00:51:42 -0400 |
commit | 37b137ff8c833385b75ff2baf4bace25e52247d2 (patch) | |
tree | 7bf79dcc785820ed90a02874c4c9119e528da3c4 /drivers/nvdimm | |
parent | 18515942d61bdfd4b31ea13f9fbb9c18650c6818 (diff) |
nfit, libnvdimm: allow an ARS scrub to be triggered on demand
Normally, an ARS (Address Range Scrub) only happens at
boot/initialization time. There can however arise situations where a
bus-wide rescan is needed - notably, in the case of discovering a latent
media error, we should do a full rescan to figure out what other sectors
are bad, and thus potentially avoid triggering an mce on them in the
future. Also provide a sysfs trigger to start a bus-wide scrub.
Cc: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Signed-off-by: Vishal Verma <vishal.l.verma@intel.com>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Diffstat (limited to 'drivers/nvdimm')
-rw-r--r-- | drivers/nvdimm/core.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/nvdimm/core.c b/drivers/nvdimm/core.c index 2c98f958fabb..715583f69d28 100644 --- a/drivers/nvdimm/core.c +++ b/drivers/nvdimm/core.c | |||
@@ -201,6 +201,13 @@ struct nvdimm_bus_descriptor *to_nd_desc(struct nvdimm_bus *nvdimm_bus) | |||
201 | } | 201 | } |
202 | EXPORT_SYMBOL_GPL(to_nd_desc); | 202 | EXPORT_SYMBOL_GPL(to_nd_desc); |
203 | 203 | ||
204 | struct device *to_nvdimm_bus_dev(struct nvdimm_bus *nvdimm_bus) | ||
205 | { | ||
206 | /* struct nvdimm_bus definition is private to libnvdimm */ | ||
207 | return &nvdimm_bus->dev; | ||
208 | } | ||
209 | EXPORT_SYMBOL_GPL(to_nvdimm_bus_dev); | ||
210 | |||
204 | static bool is_uuid_sep(char sep) | 211 | static bool is_uuid_sep(char sep) |
205 | { | 212 | { |
206 | if (sep == '\n' || sep == '-' || sep == ':' || sep == '\0') | 213 | if (sep == '\n' || sep == '-' || sep == ':' || sep == '\0') |