On Mon, Oct 1, 2018 at 8:38 PM Vishal Verma <[email protected]> wrote:
>
> When ndctl list --media-errors is invoked, we rely upon the 'region'
> badblocks provided by the kernel, and reference them against the
> namespace start to report namespace badblocks. This can fail for
> non-root users, as the region and namespace resource information is
> root-only. However the kernel also provides block-device badblocks
> information in sysfs, and that is world readable. Provide a new helper
> to retrieve this information, and use it as a fallback when the region
> based badblocks are unavailable.
>
> Note that when falling back to the namespace based badblocks, we are
> unable to retrieve the DIMM on which the badblocks are present, since we
> still need root privileges for both getting the resource information,
> and for the address translation command.
>
> Cc: Dan Williams <[email protected]>
> Signed-off-by: Vishal Verma <[email protected]>

Reviewed-by: Dan Williams <[email protected]>
_______________________________________________
Linux-nvdimm mailing list
[email protected]
https://lists.01.org/mailman/listinfo/linux-nvdimm

Reply via email to