]> sourceware.org Git - lvm2.git/commitdiff
cleanup: rename function
authorZdenek Kabelac <zkabelac@redhat.com>
Sun, 2 Nov 2014 19:59:57 +0000 (20:59 +0100)
committerZdenek Kabelac <zkabelac@redhat.com>
Mon, 3 Nov 2014 13:19:34 +0000 (14:19 +0100)
Make more clear dm_info type.

lib/activate/dev_manager.c

index 7b43e09c721f5e3ae2ecd87d74adfbca9dc81e86..266c80a28d82ac5d338797a957b582006e2c8672 100644 (file)
@@ -543,10 +543,10 @@ out:
        return r;
 }
 
-static const struct dm_info *_cached_info(struct dm_pool *mem,
-                                         struct dm_tree *dtree,
-                                         const struct logical_volume *lv,
-                                         const char *layer)
+static const struct dm_info *_cached_dm_info(struct dm_pool *mem,
+                                            struct dm_tree *dtree,
+                                            const struct logical_volume *lv,
+                                            const char *layer)
 {
        char *dlid;
        const struct dm_tree_node *dnode;
@@ -1925,7 +1925,7 @@ static int _add_lv_to_dtree(struct dev_manager *dm, struct dm_tree *dtree,
                if (!dm->activation) {
                        /* Setup callback for non-activation partial tree */
                        /* Activation gets own callback when needed */
-                       /* TODO: extend _cached_info() to return dnode */
+                       /* TODO: extend _cached_dm_info() to return dnode */
                        if (!(uuid = build_dm_uuid(dm->mem, lv, lv_layer(lv))))
                                return_0;
                        if ((node = dm_tree_find_node_by_uuid(dtree, uuid)) &&
@@ -1938,7 +1938,7 @@ static int _add_lv_to_dtree(struct dev_manager *dm, struct dm_tree *dtree,
                if (!dm->activation) {
                        /* Setup callback for non-activation partial tree */
                        /* Activation gets own callback when needed */
-                       /* TODO: extend _cached_info() to return dnode */
+                       /* TODO: extend _cached_dm_info() to return dnode */
                        if (!(uuid = build_dm_uuid(dm->mem, lv, lv_layer(lv))))
                                return_0;
                        if ((node = dm_tree_find_node_by_uuid(dtree, uuid)) &&
@@ -2409,8 +2409,8 @@ static int _add_new_external_lv_to_dtree(struct dev_manager *dm,
        dm_list_iterate_items(sl, &external_lv->segs_using_this_lv)
                if ((sl->seg->external_lv == external_lv) &&
                    /* Add only active layered devices (also avoids loop) */
-                   _cached_info(dm->mem, dtree, sl->seg->lv,
-                                lv_layer(sl->seg->lv)) &&
+                   _cached_dm_info(dm->mem, dtree, sl->seg->lv,
+                                   lv_layer(sl->seg->lv)) &&
                    !_add_new_lv_to_dtree(dm, dtree, sl->seg->lv,
                                          laopts, lv_layer(sl->seg->lv)))
                        return_0;
@@ -2585,11 +2585,11 @@ static int _add_new_lv_to_dtree(struct dev_manager *dm, struct dm_tree *dtree,
                 *   so just use the tree's existing nodes' info
                 */
                /* An activating merging origin won't have a node in the tree yet */
-               if (((dinfo = _cached_info(dm->mem, dtree, lv, NULL)) &&
+               if (((dinfo = _cached_dm_info(dm->mem, dtree, lv, NULL)) &&
                     dinfo->open_count) ||
-                   ((dinfo = _cached_info(dm->mem, dtree,
-                                          seg_is_thin_volume(seg) ?
-                                          seg->lv : seg->cow, NULL)) &&
+                   ((dinfo = _cached_dm_info(dm->mem, dtree,
+                                             seg_is_thin_volume(seg) ?
+                                             seg->lv : seg->cow, NULL)) &&
                     dinfo->open_count)) {
                        if (seg_is_thin_volume(seg) ||
                            /* FIXME Is there anything simpler to check for instead? */
This page took 0.038282 seconds and 5 git commands to generate.