Linux 6.10-rc3
[linux-2.6-block.git] / drivers / dax / bus.c
index f24b67c64d5eccf7ab65b6eeef77c3195d2aa3f8..3ef9550bd2ca78c1da754bb22b2ecd8a6ed64f3d 100644 (file)
@@ -792,7 +792,7 @@ static const struct attribute_group *dax_mapping_attribute_groups[] = {
        NULL,
 };
 
-static struct device_type dax_mapping_type = {
+static const struct device_type dax_mapping_type = {
        .release = dax_mapping_release,
        .groups = dax_mapping_attribute_groups,
 };
@@ -1178,7 +1178,6 @@ static ssize_t mapping_store(struct device *dev, struct device_attribute *attr,
        if (rc)
                return rc;
 
-       rc = -ENXIO;
        rc = down_write_killable(&dax_region_rwsem);
        if (rc)
                return rc;