diff options
author | Petr Rockai <prockai@redhat.com> | 2011-08-30 14:55:15 +0000 |
---|---|---|
committer | Petr Rockai <prockai@redhat.com> | 2011-08-30 14:55:15 +0000 |
commit | e59e2f7c3c1e2fa170dfca2ee0c29cca2d4f55c1 (patch) | |
tree | 197a579049ddab74d8944939a45f8e0d46b6c3cf /lib/striped/striped.c | |
parent | d35188058be01bd29128dcf1f5b79220fbcb135b (diff) | |
download | lvm2-e59e2f7c3c1e2fa170dfca2ee0c29cca2d4f55c1.tar.gz lvm2-e59e2f7c3c1e2fa170dfca2ee0c29cca2d4f55c1.tar.xz lvm2-e59e2f7c3c1e2fa170dfca2ee0c29cca2d4f55c1.zip |
Move the core of the lib/config/config.c functionality into libdevmapper,
leaving behind the LVM-specific parts of the code (convenience wrappers that
handle `struct device` and `struct cmd_context`, basically). A number of
functions have been renamed (in addition to getting a dm_ prefix) -- namely,
all of the config interface now has a dm_config_ prefix.
Diffstat (limited to 'lib/striped/striped.c')
-rw-r--r-- | lib/striped/striped.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/lib/striped/striped.c b/lib/striped/striped.c index 6fa49e32..fee2a962 100644 --- a/lib/striped/striped.c +++ b/lib/striped/striped.c @@ -57,32 +57,32 @@ static void _striped_display(const struct lv_segment *seg) log_print(" "); } -static int _striped_text_import_area_count(const struct config_node *sn, uint32_t *area_count) +static int _striped_text_import_area_count(const struct dm_config_node *sn, uint32_t *area_count) { - if (!get_config_uint32(sn, "stripe_count", area_count)) { + if (!dm_config_get_uint32(sn, "stripe_count", area_count)) { log_error("Couldn't read 'stripe_count' for " - "segment '%s'.", config_parent_name(sn)); + "segment '%s'.", dm_config_parent_name(sn)); return 0; } return 1; } -static int _striped_text_import(struct lv_segment *seg, const struct config_node *sn, +static int _striped_text_import(struct lv_segment *seg, const struct dm_config_node *sn, struct dm_hash_table *pv_hash) { - const struct config_node *cn; + const struct dm_config_node *cn; if ((seg->area_count != 1) && - !get_config_uint32(sn, "stripe_size", &seg->stripe_size)) { + !dm_config_get_uint32(sn, "stripe_size", &seg->stripe_size)) { log_error("Couldn't read stripe_size for segment %s " - "of logical volume %s.", config_parent_name(sn), seg->lv->name); + "of logical volume %s.", dm_config_parent_name(sn), seg->lv->name); return 0; } - if (!(cn = find_config_node(sn, "stripes"))) { + if (!(cn = dm_config_find_node(sn, "stripes"))) { log_error("Couldn't find stripes array for segment %s " - "of logical volume %s.", config_parent_name(sn), seg->lv->name); + "of logical volume %s.", dm_config_parent_name(sn), seg->lv->name); return 0; } |