]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
libnvdimm, pfn: fix uuid validation
authorDan Williams <dan.j.williams@intel.com>
Fri, 8 Apr 2016 02:59:27 +0000 (19:59 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 20 Apr 2016 06:45:08 +0000 (15:45 +0900)
commit90ad05df5acc44fda7c8c315fdf9d758791ed376
tree48c2251c3f035454e0ab9055c6ae04c606263769
parent333b72e9252332c72ed5c5dbcf1dd8145c1856c6
libnvdimm, pfn: fix uuid validation

commit e5670563f588ed1c0603819350c0f02cec23f5c5 upstream.

If we detect a namespace has a stale info block in the init path, we
should overwrite with the latest configuration.  In fact, we already
return -ENODEV when the parent uuid is invalid, the same should be done
for the 'self' uuid.  Otherwise we can get into a condition where
userspace is unable to reconfigure the pfn-device without directly /
manually invalidating the info block.

Reported-by: Jeff Moyer <jmoyer@redhat.com>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/nvdimm/pfn_devs.c