]> git.ipfire.org Git - thirdparty/mdadm.git/blobdiff - sysfs.c
mdadm: define DEV_MD_DIR
[thirdparty/mdadm.git] / sysfs.c
diff --git a/sysfs.c b/sysfs.c
index ca1d888f21ced33c8772a9a468cd04668f953b86..94d02f53a768e64b883ab76f07d1ee9729ea54af 100644 (file)
--- a/sysfs.c
+++ b/sysfs.c
@@ -1114,7 +1114,7 @@ void sysfsline(char *line)
                if (strncasecmp(w, "name=", 5) == 0) {
                        char *devname = w + 5;
 
-                       if (strncmp(devname, "/dev/md/", 8) == 0) {
+                       if (strncmp(devname, DEV_MD_DIR, DEV_MD_DIR_LEN) == 0) {
                                if (sr->devname)
                                        pr_err("Only give one device per SYSFS line: %s\n",
                                                devname);