1
0
mirror of git://sourceware.org/git/lvm2.git synced 2024-12-21 13:34:40 +03:00
lvm2/libdm/.exported_symbols.Base
Bryn M. Reeves 82a27a85b5 macros: fix default symbol export control
Fix the version export macros to make it possible to export two
different DM_* versions of a symbol: currently it is only possible for a
DM_* symbol to override a symbol in Base. Attempting to export two
symbols at different DM_* version levels (e.g. DM_1_02_104 and
DM_1_02_106) leads to a linker error due to a duplicate symbol
definition.

This is because the DM_EXPORTED_SYMBOL macro makes each exported symbol
the default (@@VERSION):

       __asm__(".symver " #func "_v" #ver ", " #func "@@DM_" #ver )

Fix the macro to use a single '@' for a symbols exported in multiple
versions and rename the macros to DM_EXPORT_*:

  DM_EXPORT_SYMBOL(func,ver)
  DM_EXPORT_SYMBOL_BASE(func,ver)

For functions that have multiple implementations these macros control
symbol export and versioning.

Function definitions that exist in only one version never need to use
these macros.

Backwards compatible implementations must include a version tag of
the form "_v1_02_104" as a suffix to the function name and use the
macro DM_EXPORT_SYMBOL to export the function and bind it to the
specified version string.

Since versioning is only available when compiling with GCC the entire
compatibility version should be enclosed in '#if defined(__GNUC__)',
for example:

  int dm_foo(int bar)
  {
    return bar;
  }

  #if defined(__GNUC__)
  // Backward compatible dm_foo() version 1.02.104
  int dm_foo_v1_02_104(void);
  int dm_foo_v1_02_104(void)
  {
    return 0;
  }
  DM_EXPORT_SYMBOL(dm_foo,1_02_104)
  #endif

A prototype for the compatibility version is required as these
functions must not be declared static.

The DM_EXPORT_SYMBOL_BASE macro is only used to export the base
versions of library symbols prior to the introduction of symbol
versioning: it must never be used for new symbols.
2015-08-24 20:03:21 +01:00

287 lines
5.9 KiB
Plaintext

dm_asprintf
dm_basename
dm_bit_and
dm_bit_get_first
dm_bit_get_next
dm_bitset_create
dm_bitset_destroy
dm_bitset_equal
dm_bit_union
dm_bounds_check_debug
dm_build_dm_name
dm_build_dm_uuid
dm_config_clone_node
dm_config_clone_node_with_mem
dm_config_create
dm_config_create_node
dm_config_create_value
dm_config_destroy
dm_config_find_bool
dm_config_find_float
dm_config_find_int
dm_config_find_int64
dm_config_find_node
dm_config_find_str
dm_config_find_str_allow_empty
dm_config_flatten
dm_config_from_string
dm_config_get_custom
dm_config_get_list
dm_config_get_section
dm_config_get_str
dm_config_get_uint32
dm_config_get_uint64
dm_config_has_node
dm_config_insert_cascaded_tree
dm_config_maybe_section
dm_config_memory
dm_config_parent_name
dm_config_parse
dm_config_remove_cascaded_tree
dm_config_remove_node
dm_config_set_custom
dm_config_tree_find_bool
dm_config_tree_find_float
dm_config_tree_find_int
dm_config_tree_find_int64
dm_config_tree_find_node
dm_config_tree_find_str
dm_config_tree_find_str_allow_empty
dm_config_value_is_bool
dm_config_write_node
dm_config_write_node_out
dm_config_write_one_node
dm_config_write_one_node_out
dm_cookie_supported
dm_count_chars
dm_create_dir
dm_create_lockfile
dm_daemon_is_running
dm_device_get_name
dm_device_has_holders
dm_device_has_mounted_fs
dm_dir
dm_driver_version
dm_dump_memory_debug
dm_escaped_len
dm_escape_double_quotes
dm_fclose
dm_format_dev
dm_free_aux
dm_get_library_version
dm_get_name_mangling_mode
dm_get_next_target
dm_get_status_cache
dm_get_status_raid
dm_get_status_snapshot
dm_get_status_thin
dm_get_status_thin_pool
dm_get_suspended_counter
dm_hash_create
dm_hash_destroy
dm_hash_get_data
dm_hash_get_first
dm_hash_get_key
dm_hash_get_next
dm_hash_get_num_entries
dm_hash_insert
dm_hash_insert_binary
dm_hash_iter
dm_hash_lookup
dm_hash_lookup_binary
dm_hash_remove
dm_hash_remove_binary
dm_hash_wipe
dm_is_dm_major
dm_is_empty_dir
dm_lib_exit
dm_lib_init
dm_lib_release
dm_list_add
dm_list_add_h
dm_list_del
dm_list_empty
dm_list_end
dm_list_first
dm_list_init
dm_list_last
dm_list_move
dm_list_next
dm_list_prev
dm_list_size
dm_list_splice
dm_list_start
dm_log
dm_log_init
dm_log_init_verbose
dm_log_is_non_default
dm_log_with_errno
dm_log_with_errno_init
dm_make_percent
dm_malloc_aux
dm_malloc_aux_debug
dm_mknodes
dm_mountinfo_read
dm_percent_to_float
dm_pool_abandon_object
dm_pool_alloc
dm_pool_alloc_aligned
dm_pool_begin_object
dm_pool_create
dm_pool_destroy
dm_pool_empty
dm_pool_end_object
dm_pool_free
dm_pool_grow_object
dm_pool_lock
dm_pool_locked
dm_pool_strdup
dm_pool_strndup
dm_pool_unlock
dm_pool_zalloc
dm_prepare_selinux_context
dm_realloc_aux
dm_regex_create
dm_regex_fingerprint
dm_regex_match
dm_report_compact_fields
dm_report_field_int
dm_report_field_int32
dm_report_field_percent
dm_report_field_set_value
dm_report_field_string
dm_report_field_string_list
dm_report_field_string_list_unsorted
dm_report_field_uint32
dm_report_field_uint64
dm_report_free
dm_report_init
dm_report_init_with_selection
dm_report_object
dm_report_object_is_selected
dm_report_output
dm_report_set_output_field_name_prefix
dm_set_dev_dir
dm_set_name_mangling_mode
dm_set_selinux_context
dm_set_sysfs_dir
dm_set_uuid_prefix
dm_snprintf
dm_split_lvm_name
dm_split_words
dm_strdup_aux
dm_strncpy
dm_sysfs_dir
dm_task_add_target
dm_task_create
dm_task_deferred_remove
dm_task_destroy
dm_task_enable_checks
dm_task_get_deps
dm_task_get_driver_version
dm_task_get_info_with_deferred_remove
dm_task_get_message_response
dm_task_get_name
dm_task_get_name_mangled
dm_task_get_names
dm_task_get_name_unmangled
dm_task_get_read_ahead
dm_task_get_uuid
dm_task_get_uuid_mangled
dm_task_get_uuid_unmangled
dm_task_get_versions
dm_task_no_flush
dm_task_no_open_count
dm_task_query_inactive_table
dm_task_retry_remove
dm_task_run
dm_task_secure_data
dm_task_set_add_node
dm_task_set_cookie
dm_task_set_event_nr
dm_task_set_geometry
dm_task_set_gid
dm_task_set_major
dm_task_set_major_minor
dm_task_set_message
dm_task_set_minor
dm_task_set_mode
dm_task_set_name
dm_task_set_newname
dm_task_set_newuuid
dm_task_set_read_ahead
dm_task_set_ro
dm_task_set_sector
dm_task_set_uid
dm_task_set_uuid
dm_task_skip_lockfs
dm_task_suppress_identical_reload
dm_task_update_nodes
dm_tree_activate_children
dm_tree_add_dev
dm_tree_add_dev_with_udev_flags
dm_tree_add_new_dev
dm_tree_add_new_dev_with_udev_flags
dm_tree_create
dm_tree_deactivate_children
dm_tree_find_node
dm_tree_find_node_by_uuid
dm_tree_free
dm_tree_get_cookie
dm_tree_children_use_uuid
dm_tree_next_child
dm_tree_node_add_cache_target
dm_tree_node_add_crypt_target
dm_tree_node_add_error_target
dm_tree_node_add_linear_target
dm_tree_node_add_mirror_target
dm_tree_node_add_mirror_target_log
dm_tree_node_add_null_area
dm_tree_node_add_raid_target
dm_tree_node_add_raid_target_with_params
dm_tree_node_add_replicator_dev_target
dm_tree_node_add_replicator_target
dm_tree_node_add_snapshot_merge_target
dm_tree_node_add_snapshot_origin_target
dm_tree_node_add_snapshot_target
dm_tree_node_add_striped_target
dm_tree_node_add_target_area
dm_tree_node_add_thin_pool_message
dm_tree_node_add_thin_pool_target
dm_tree_node_add_thin_target
dm_tree_node_add_zero_target
dm_tree_node_get_context
dm_tree_node_get_info
dm_tree_node_get_name
dm_tree_node_get_uuid
dm_tree_node_num_children
dm_tree_node_set_callback
dm_tree_node_set_presuspend_node
dm_tree_node_set_read_ahead
dm_tree_node_set_thin_external_origin
dm_tree_node_set_thin_pool_discard
dm_tree_node_set_thin_pool_error_if_no_space
dm_tree_node_set_udev_flags
dm_tree_node_size_changed
dm_tree_preload_children
dm_tree_retry_remove
dm_tree_set_cookie
dm_tree_set_optional_uuid_suffixes
dm_tree_skip_lockfs
dm_tree_suspend_children
dm_tree_use_no_flush_suspend
dm_udev_complete
dm_udev_create_cookie
dm_udev_get_checking
dm_udev_get_sync_support
dm_udev_set_checking
dm_udev_set_sync_support
dm_udev_wait
dm_unescape_colons_and_at_signs
dm_unescape_double_quotes
dm_units_to_factor
dm_uuid_prefix
dm_vasprintf
dm_zalloc_aux
dm_zalloc_aux_debug