mirror of
git://sourceware.org/git/lvm2.git
synced 2024-12-21 13:34:40 +03:00
device_mapper: remove unused lines
No need for versioning history in internal version.
This commit is contained in:
parent
1cedbaf137
commit
f1e8437c59
@ -242,18 +242,3 @@ bad:
|
|||||||
}
|
}
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
#if defined(__GNUC__)
|
|
||||||
/*
|
|
||||||
* Maintain backward compatibility with older versions that did not
|
|
||||||
* accept a 'min_num_bits' argument to dm_bitset_parse_list().
|
|
||||||
*/
|
|
||||||
dm_bitset_t dm_bitset_parse_list_v1_02_129(const char *str, struct dm_pool *mem);
|
|
||||||
dm_bitset_t dm_bitset_parse_list_v1_02_129(const char *str, struct dm_pool *mem)
|
|
||||||
{
|
|
||||||
return dm_bitset_parse_list(str, mem, 0);
|
|
||||||
}
|
|
||||||
|
|
||||||
#else /* if defined(__GNUC__) */
|
|
||||||
|
|
||||||
#endif
|
|
||||||
|
@ -2209,52 +2209,3 @@ void dm_lib_exit(void)
|
|||||||
_version_ok = 1;
|
_version_ok = 1;
|
||||||
_version_checked = 0;
|
_version_checked = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
#if defined(__GNUC__)
|
|
||||||
/*
|
|
||||||
* Maintain binary backward compatibility.
|
|
||||||
* Version script mechanism works with 'gcc' compatible compilers only.
|
|
||||||
*/
|
|
||||||
|
|
||||||
/*
|
|
||||||
* This following code is here to retain ABI compatibility after adding
|
|
||||||
* the field deferred_remove to struct dm_info in version 1.02.89.
|
|
||||||
*
|
|
||||||
* Binaries linked against version 1.02.88 of libdevmapper or earlier
|
|
||||||
* will use this function that returns dm_info without the
|
|
||||||
* deferred_remove field.
|
|
||||||
*
|
|
||||||
* Binaries compiled against version 1.02.89 onwards will use
|
|
||||||
* the new function dm_task_get_info_with_deferred_remove due to the
|
|
||||||
* #define.
|
|
||||||
*
|
|
||||||
* N.B. Keep this function at the end of the file to make sure that
|
|
||||||
* no code in this file accidentally calls it.
|
|
||||||
*/
|
|
||||||
|
|
||||||
int dm_task_get_info_base(struct dm_task *dmt, struct dm_info *info);
|
|
||||||
int dm_task_get_info_base(struct dm_task *dmt, struct dm_info *info)
|
|
||||||
{
|
|
||||||
struct dm_info new_info;
|
|
||||||
|
|
||||||
if (!dm_task_get_info(dmt, &new_info))
|
|
||||||
return 0;
|
|
||||||
|
|
||||||
memcpy(info, &new_info, offsetof(struct dm_info, deferred_remove));
|
|
||||||
|
|
||||||
return 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
int dm_task_get_info_with_deferred_remove(struct dm_task *dmt, struct dm_info *info);
|
|
||||||
int dm_task_get_info_with_deferred_remove(struct dm_task *dmt, struct dm_info *info)
|
|
||||||
{
|
|
||||||
struct dm_info new_info;
|
|
||||||
|
|
||||||
if (!dm_task_get_info(dmt, &new_info))
|
|
||||||
return 0;
|
|
||||||
|
|
||||||
memcpy(info, &new_info, offsetof(struct dm_info, internal_suspend));
|
|
||||||
|
|
||||||
return 1;
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
@ -4328,61 +4328,6 @@ void dm_tree_node_set_callback(struct dm_tree_node *dnode,
|
|||||||
dnode->callback_data = data;
|
dnode->callback_data = data;
|
||||||
}
|
}
|
||||||
|
|
||||||
#if defined(__GNUC__)
|
|
||||||
/*
|
|
||||||
* Backward compatible implementations.
|
|
||||||
*
|
|
||||||
* Keep these at the end of the file to make sure that
|
|
||||||
* no code in this file accidentally calls it.
|
|
||||||
*/
|
|
||||||
|
|
||||||
/* Backward compatible dm_tree_node_size_changed() implementations. */
|
|
||||||
int dm_tree_node_size_changed_base(const struct dm_tree_node *dnode);
|
|
||||||
int dm_tree_node_size_changed_base(const struct dm_tree_node *dnode)
|
|
||||||
{
|
|
||||||
/* Base does not make difference between smaller and bigger */
|
|
||||||
return dm_tree_node_size_changed(dnode) ? 1 : 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Retain ABI compatibility after adding the DM_CACHE_FEATURE_METADATA2
|
|
||||||
* in version 1.02.138.
|
|
||||||
*
|
|
||||||
* Binaries compiled against version 1.02.138 onwards will use
|
|
||||||
* the new function dm_tree_node_add_cache_target which detects unknown
|
|
||||||
* feature flags and returns error for them.
|
|
||||||
*/
|
|
||||||
int dm_tree_node_add_cache_target_base(struct dm_tree_node *node,
|
|
||||||
uint64_t size,
|
|
||||||
uint64_t feature_flags, /* DM_CACHE_FEATURE_* */
|
|
||||||
const char *metadata_uuid,
|
|
||||||
const char *data_uuid,
|
|
||||||
const char *origin_uuid,
|
|
||||||
const char *policy_name,
|
|
||||||
const struct dm_config_node *policy_settings,
|
|
||||||
uint32_t data_block_size);
|
|
||||||
int dm_tree_node_add_cache_target_base(struct dm_tree_node *node,
|
|
||||||
uint64_t size,
|
|
||||||
uint64_t feature_flags,
|
|
||||||
const char *metadata_uuid,
|
|
||||||
const char *data_uuid,
|
|
||||||
const char *origin_uuid,
|
|
||||||
const char *policy_name,
|
|
||||||
const struct dm_config_node *policy_settings,
|
|
||||||
uint32_t data_block_size)
|
|
||||||
{
|
|
||||||
/* Old version supported only these FEATURE bits, others were ignored so masked them */
|
|
||||||
static const uint64_t _mask =
|
|
||||||
DM_CACHE_FEATURE_WRITEBACK |
|
|
||||||
DM_CACHE_FEATURE_WRITETHROUGH |
|
|
||||||
DM_CACHE_FEATURE_PASSTHROUGH;
|
|
||||||
|
|
||||||
return dm_tree_node_add_cache_target(node, size, feature_flags & _mask,
|
|
||||||
metadata_uuid, data_uuid, origin_uuid,
|
|
||||||
policy_name, policy_settings, 0, 0, 0, 0, data_block_size);
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
int dm_tree_node_add_vdo_target(struct dm_tree_node *node,
|
int dm_tree_node_add_vdo_target(struct dm_tree_node *node,
|
||||||
uint64_t size,
|
uint64_t size,
|
||||||
const char *vdo_pool_name,
|
const char *vdo_pool_name,
|
||||||
|
Loading…
Reference in New Issue
Block a user