1
0
mirror of git://sourceware.org/git/lvm2.git synced 2024-12-21 13:34:40 +03:00
Commit Graph

25 Commits

Author SHA1 Message Date
Zdenek Kabelac
77aa055e8a cov: index off by one
Basically apply stable patch fdb6ef8a85 to internal libdm version.
2018-10-15 17:49:44 +02:00
Zdenek Kabelac
d8a41f22e9 device_mapper: basic support for vdo dm target 2018-07-09 15:28:35 +02:00
Zdenek Kabelac
0d9a4c6989 lib: new vdo segment configurable options
Configurable for vdo segment with their default values.
Also specify their ranges with minimal and maximal values.
2018-07-09 15:28:35 +02:00
Zdenek Kabelac
4a90b0c4c9 build: add vdo configuration option --with-vdo=
Checks whether VDO support is enabled.
Detects presence of 'vdoformat' tool which is required for to format VDO pool.

ATM build of VDO is NOT automatically enabled (None is default).
To enable build of LVM with VDO support use:

configure --with-vdo=internal

TODO: Maybe future version may switch to link some small VDO library for formating
(would require linking and package dependency).
2018-07-09 15:28:35 +02:00
Zdenek Kabelac
9b6b4f14d8 device_mapper: convert vdo to use dm_ prefix
Keep using DM_/dm_ prefixes for device_mapper code.
2018-07-09 10:30:34 +02:00
Zdenek Kabelac
5cf0923e18 vdo: fix parsing vdo status
Recent updates relay on zerod status structure memory (device ptr is
NULL) and also dm_strncpy need to count with '\0'.
2018-07-09 10:30:34 +02:00
Zdenek Kabelac
c96400b6c7 vdo: enhance status parser
Add support for using mempool for allocations inside status parser.
Convert some string pointers to arrays.
Reindent tabs.
2018-07-02 10:25:35 +02:00
Zdenek Kabelac
c1a6b10d09 device_mapper: relocate code for sending messages
To be able to send messages for recently resumed devices,
move code into inner loop.
2018-07-02 10:25:35 +02:00
Zdenek Kabelac
d56e400d44 device_mapper: deactive new nodes when load fails
When node loading fails, there is not much the caller can do,
since there is 'unknown' set of devices preloaded.

Only suspend during preload knows future precommitted 'metadata',
so it's non-trivial to drop 'preloaded' entries with any later call.

However dm tree tracks newly loaded entries - so in this case it
may simplify the recovery path by dropping preloaded entries so
they are not leaked in the DM table.
2018-07-02 10:25:35 +02:00
Zdenek Kabelac
52b07672f8 build: avoid rebuild deps for top-level makefiles 2018-07-02 10:21:42 +02:00
Zdenek Kabelac
4194fc9bbd device_mapper: add new _dm_task_create_device_status
Introduce new function _dm_task_create_device_status for grabbing
status of device for better code sharing.
2018-06-25 15:07:55 +02:00
Zdenek Kabelac
739a213d2e device_mapper: split code for sending message
Move message sending from _thin_pool_node_message to
new _node_message for possible better code sharing.
2018-06-25 15:07:55 +02:00
Zdenek Kabelac
a1c81c009a device_mapper: split _node_send_message
For better code reuse split _node_send_messages into commont
messaging part and separate _thin_pool_node_send_messages.

Patch makes it possible to better reuse common code for messaging
other targets.
2018-06-25 15:07:55 +02:00
Zdenek Kabelac
c728d88e11 build: include configure.h
It's important to consistenly include  configure.h as the 1st. header.
It containts #defines influencing behavior of other included header
files.
2018-06-22 23:11:44 +02:00
Zdenek Kabelac
3eff3aa4f8 device_mapper: drop unneeded function
Subdir without stats.
2018-06-14 22:02:01 +02:00
Joe Thornber
e84e9cd115 device_mapper: remove libdm-stats.c
We don't use it in lvm.
2018-06-14 14:32:17 +01:00
Zdenek Kabelac
1c79cf9830 build: ensure configure.h comes first
Fix header order so configure.h is 1st. included header.
2018-06-11 22:38:51 +02:00
Joe Thornber
61e67e51e1 device_mapper: move hash.[hc] to base/data-struct 2018-06-08 13:54:19 +01:00
Joe Thornber
962a3eb3fa device_mapper: remove c++ guards from the header
This isn't a public header anymore, so not needed.
2018-06-08 13:44:43 +01:00
Joe Thornber
d5da55ed85 device_mapper: remove dbg_malloc.
I wrote dbg_malloc before we had valgrind.  These days there's just
no need.
2018-06-08 13:40:53 +01:00
Joe Thornber
286c1ba336 device_mapper: rename libdevmapper.h -> all.h
I'm paranoid a file will include the global one in /usr/include
by accident.
2018-06-08 12:31:45 +01:00
Joe Thornber
88ae928ca3 base: Move list to base/data-struct 2018-06-08 11:24:18 +01:00
Joe Thornber
74460cd009 device_mapper: fixup a couple of includes
"libdevmapper.h" -> "device_mapper/libdevmapper.h"
2018-06-06 14:45:16 +01:00
Joe Thornber
29abba3785 build: get separate builddir working again 2018-06-04 13:22:14 +01:00
Joe Thornber
ccc35e2647 device-mapper: Fork libdm internally.
The device-mapper directory now holds a copy of libdm source.  At
the moment this code is identical to libdm.  Over time code will
migrate out to appropriate places (see doc/refactoring.txt).

The libdm directory still exists, and contains the source for the
libdevmapper shared library, which we will continue to ship (though
not neccessarily update).

All code using libdm should now use the version in device-mapper.
2018-05-16 13:00:50 +01:00