Hello community,
here is the log from the commit of package device-mapper for openSUSE:Factory
checked in at Mon Apr 5 18:36:59 CEST 2010.
--------
--- device-mapper/device-mapper.changes 2009-12-20 18:12:57.000000000 +0100
+++ /mounts/work_src_done/STABLE/device-mapper/device-mapper.changes 2010-04-03 05:22:20.000000000 +0200
@@ -1,0 +2,9 @@
+Sat Apr 3 03:07:44 UTC 2010 - xwhu@novell.com
+
+- Upgrade to device-mapper 1.02.
+ - Add libdevmapper functions to support synchronisation with udev
+ - Check udev is running when processing cookies and retain state
+ internally.
+ - Add support for the "snapshot-merge" kernel target
+
+-------------------------------------------------------------------
--- device-mapper/lvm2-clvm.changes 2009-11-15 10:41:26.000000000 +0100
+++ /mounts/work_src_done/STABLE/device-mapper/lvm2-clvm.changes 2010-04-05 06:25:07.000000000 +0200
@@ -1,0 +2,14 @@
+Sat Apr 3 03:17:12 UTC 2010 - xwhu@novell.com
+
+- Upgrade to LVM2 2.02.58
+ - Rename liblvm.so to liblvm2app.so
+ - Introduce lvconvert --use_policies
+ - Add readonly locking type to replace implementation of
+ --ignorelockingfailure
+ - Add liblvm APIs to implement creation and deletion of VGs
+ - Add activation/udev_sync to lvm.conf
+ - Enable dmeventd monitoring section of config file by default
+ - Add --pvmetadatacopies for pvcreate, vgcreate, vgextend,
+ vgconvert.
+
+-------------------------------------------------------------------
--- device-mapper/lvm2.changes 2009-11-29 07:59:21.000000000 +0100
+++ /mounts/work_src_done/STABLE/device-mapper/lvm2.changes 2010-04-03 05:22:28.000000000 +0200
@@ -1,0 +2,14 @@
+Sat Apr 3 03:17:12 UTC 2010 - xwhu@novell.com
+
+- Upgrade to LVM2 2.02.58
+ - Rename liblvm.so to liblvm2app.so
+ - Introduce lvconvert --use_policies
+ - Add readonly locking type to replace implementation of
+ --ignorelockingfailure
+ - Add liblvm APIs to implement creation and deletion of VGs
+ - Add activation/udev_sync to lvm.conf
+ - Enable dmeventd monitoring section of config file by default
+ - Add --pvmetadatacopies for pvcreate, vgcreate, vgextend,
+ vgconvert.
+
+-------------------------------------------------------------------
calling whatdependson for head-i586
Old:
----
LVM2.2.02.45.tar.bz2
device-mapper-wait_udev.diff
New:
----
LVM2.2.02.58.tgz
fallback-major-number.diff
udev-rules_update.diff
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ device-mapper.spec ++++++
--- /var/tmp/diff_new_pack.5QB7ea/_old 2010-04-05 18:36:04.000000000 +0200
+++ /var/tmp/diff_new_pack.5QB7ea/_new 2010-04-05 18:36:04.000000000 +0200
@@ -1,7 +1,7 @@
#
-# spec file for package device-mapper (Version 1.02.31)
+# spec file for package device-mapper (Version 1.02.42)
#
-# Copyright (c) 2009 SUSE LINUX Products GmbH, Nuernberg, Germany.
+# Copyright (c) 2010 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -26,39 +26,25 @@
Obsoletes: device-mapper-64bit
%endif
#
-Version: 1.02.31
-Release: 11
+Version: 1.02.42
+Release: 1
Summary: Device Mapper Tools
-Source: LVM2.2.02.45.tar.bz2
+Source: LVM2.2.02.58.tgz
Source1: boot.device-mapper
Source2: mkinitrd-devmapper-setup.sh
Source3: mkinitrd-devmapper-boot.sh
-Patch: improve_probing.diff
-Patch2: no-inc-audit.diff
-Patch3: no_buildroot_shared.diff
-Patch4: sys_mount_instead_linux_fs.diff
-Patch5: pvscan_2TB_limit.diff
-Patch6: man_page_sectors.diff
-Patch10: lvm-no_chown.diff
-Patch11: cmdline_large_minor.diff
-Patch12: enable-clvmd.patch
-Patch13: pipe_buff-definition.diff
-Patch14: lvm-pv-create-link.diff
-#Patch15: dmeventd-link-libcmd.diff
-Patch16: clvmd-openais-use-dlm.diff
-Patch17: bug-486952_clvmd-check-returncode-of-dlmrelease.diff
-Patch18: sigterm_in_main_thread.diff
-Patch19: dont_ignore_tmp_device_file.diff
-Patch20: support-drbd-filter.diff
-Patch21: call_cpg_leave_before_shutdown.diff
+Source4: baselibs.conf
+
#Patches for device mapper
Patch60: k_dev_t.dif
Patch61: device-mapper-dmsetup-export.patch
Patch62: device-mapper-gcc-warning.diff
Patch63: device-mapper-static.diff
-Patch64: device-mapper-wait_udev.diff
Patch65: device-mapper-dmsetup-deps-export.patch
Patch66: device-mapper-type_punning.diff
+Patch67: udev-rules_update.diff
+#Patches applies to both LVM2 and device-mapper
+Patch80: lvm-no_chown.diff
BuildRoot: %{_tmppath}/%{name}-%{version}-build
BuildRequires: libselinux-devel
PreReq: %insserv_prereq %fillup_prereq
@@ -89,41 +75,27 @@
Joe Thornber
%prep
-%setup -n LVM2.2.02.45
-%patch
-%patch2
-%patch3
-%patch4
-%patch5
-%patch6
-%patch10
-%patch11
-%patch12
-%patch13
-%patch14 -p1
-#%patch15 -p1
-%patch16 -p1
-%patch17 -p1
-%patch18 -p1
-%patch19 -p1
-%patch20 -p1
-%patch21 -p1
+%setup -n LVM2.2.02.58
%patch60 -p1
%patch61 -p1
%patch62 -p1
%patch63 -p1
-%patch64 -p1
%patch65 -p1
%patch66 -p0
+%patch67 -p1
+%patch80 -p0
%build
CFLAGS="$RPM_OPT_FLAGS" \
%configure --bindir=/bin --libdir=/%_lib --with-usrlibdir=%_libdir \
--sbindir=/sbin --enable-dmeventd \
+ --with-udevdir=/lib/udev/rules.d \
--enable-selinux --enable-cmdlib \
--with-dmeventd-path=/sbin/dmeventd \
+ --with-user=root --with-group=root \
--with-device-uid=0 --with-device-gid=6 --with-device-mode=0640 \
- --enable-pkgconfig
+ --enable-udev_sync --enable-udev_rules --enable-compat \
+ --enable-pkgconfig --enable-realtime
make -j1 # symlinks are generated in parallel! %{?jobs:-j %jobs}
%install
@@ -135,10 +107,6 @@
ln -s /%_lib/libdevmapper-event.so.1.02 $RPM_BUILD_ROOT/%_libdir/libdevmapper-event.so
rm $RPM_BUILD_ROOT/%_lib/libdevmapper.so
rm $RPM_BUILD_ROOT/%_lib/libdevmapper-event.so
-rm $RPM_BUILD_ROOT/%_lib/libdevmapper-event-lvm2mirror.so
-rm $RPM_BUILD_ROOT/%_lib/libdevmapper-event-lvm2mirror.so.2.02
-rm $RPM_BUILD_ROOT/%_lib/libdevmapper-event-lvm2snapshot.so
-rm $RPM_BUILD_ROOT/%_lib/libdevmapper-event-lvm2snapshot.so.2.02
#install -m 744 scripts/devmap_mknod.sh $RPM_BUILD_ROOT/sbin/
mkdir -p $RPM_BUILD_ROOT/etc/init.d
install -m 744 %{SOURCE1} $RPM_BUILD_ROOT/etc/init.d
@@ -162,6 +130,12 @@
%config /etc/init.d/boot.device-mapper
/%_lib/libdevmapper.so.1.02
/%_lib/libdevmapper-event.so.1.02
+%dir /lib/udev/rules.d
+%dir /lib/udev
+/lib/udev/rules.d/10-dm.rules
+#/lib/udev/rules.d/12-dm-permissions.rules
+/lib/udev/rules.d/13-dm-disk.rules
+/lib/udev/rules.d/95-dm-notify.rules
/sbin/dmsetup
/sbin/dmeventd
#/sbin/devmap_mknod.sh
++++++ lvm2-clvm.spec ++++++
--- /var/tmp/diff_new_pack.5QB7ea/_old 2010-04-05 18:36:04.000000000 +0200
+++ /var/tmp/diff_new_pack.5QB7ea/_new 2010-04-05 18:36:04.000000000 +0200
@@ -1,7 +1,7 @@
#
-# spec file for package lvm2-clvm (Version 2.02.45)
+# spec file for package lvm2-clvm (Version 2.02.58)
#
-# Copyright (c) 2009 SUSE LINUX Products GmbH, Nuernberg, Germany.
+# Copyright (c) 2010 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -23,14 +23,14 @@
BuildRequires: libselinux-devel
License: GPLv2+ ; LGPLv2.1+
Group: System/Base
-Version: 2.02.45
-Release: 11
+Version: 2.02.58
+Release: 1
Requires: device-mapper >= 1.02.25 lvm2 = %{version} openais
Provides: clvm
PreReq: %fillup_prereq %insserv_prereq
AutoReqProv: on
Summary: Clustered LVM2
-Source: LVM2.%{version}.tar.bz2
+Source: LVM2.%{version}.tgz
Source1: lvm.conf
Source2: boot.lvm
Source3: sysconfig.lvm
@@ -57,6 +57,7 @@
Patch19: dont_ignore_tmp_device_file.diff
Patch20: support-drbd-filter.diff
Patch21: call_cpg_leave_before_shutdown.diff
+Patch67: fallback-major-number.diff
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%description
@@ -84,6 +85,7 @@
%patch19 -p1
%patch20 -p1
%patch21 -p1
+%patch67 -p1
%build
CFLAGS="$RPM_OPT_FLAGS" MODPROBE_CMD=/sbin/modprobe \
++++++ lvm2.spec ++++++
--- /var/tmp/diff_new_pack.5QB7ea/_old 2010-04-05 18:36:04.000000000 +0200
+++ /var/tmp/diff_new_pack.5QB7ea/_new 2010-04-05 18:36:04.000000000 +0200
@@ -1,7 +1,7 @@
#
-# spec file for package lvm2 (Version 2.02.45)
+# spec file for package lvm2 (Version 2.02.58)
#
-# Copyright (c) 2009 SUSE LINUX Products GmbH, Nuernberg, Germany.
+# Copyright (c) 2010 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -19,19 +19,18 @@
Url: http://sources.redhat.com/cluster/clvm/
Name: lvm2
-BuildRequires: device-mapper-devel libdlm-devel libopenais-devel readline-devel
+BuildRequires: readline-devel
BuildRequires: libselinux-devel
License: GPLv2+ ; LGPLv2.1+
Group: System/Base
Requires: device-mapper >= 1.02.25
Provides: lvm
-Obsoletes: lvm
PreReq: %fillup_prereq %insserv_prereq
AutoReqProv: on
-Version: 2.02.45
-Release: 11
+Version: 2.02.58
+Release: 1
Summary: LVM2 Tools
-Source: LVM2.%{version}.tar.bz2
+Source: LVM2.%{version}.tgz
Source1: lvm.conf
Source2: boot.lvm
Source3: sysconfig.lvm
@@ -46,18 +45,10 @@
Patch4: sys_mount_instead_linux_fs.diff
Patch5: pvscan_2TB_limit.diff
Patch6: man_page_sectors.diff
-Patch10: lvm-no_chown.diff
Patch11: cmdline_large_minor.diff
-Patch12: enable-clvmd.patch
Patch13: pipe_buff-definition.diff
Patch14: lvm-pv-create-link.diff
-#Patch15: dmeventd-link-libcmd.diff
-Patch16: clvmd-openais-use-dlm.diff
-Patch17: bug-486952_clvmd-check-returncode-of-dlmrelease.diff
-Patch18: sigterm_in_main_thread.diff
Patch19: dont_ignore_tmp_device_file.diff
-Patch20: support-drbd-filter.diff
-Patch21: call_cpg_leave_before_shutdown.diff
Patch22: handle_extended_devt.diff
Patch23: lvm2cmd-link-to-devmapper-event.diff
#Patches for device mapper
@@ -65,8 +56,11 @@
Patch61: device-mapper-dmsetup-export.patch
Patch62: device-mapper-gcc-warning.diff
Patch63: device-mapper-static.diff
-Patch64: device-mapper-wait_udev.diff
Patch65: device-mapper-dmsetup-deps-export.patch
+#Patches apply to both LVM2 and device-mapper
+Patch80: lvm-no_chown.diff
+Patch81: udev-rules_update.diff
+
BuildRoot: %{_tmppath}/%{name}-%{version}-build
# Not a real replacement but we drop evms
Provides: evms = 2.5.5 evms-gui = 2.5.5 evms-devel = 2.5.5 evms-ha = 2.5.5
@@ -86,18 +80,10 @@
%patch4
%patch5
%patch6
-%patch10
%patch11
-%patch12
%patch13
%patch14 -p1
-#%patch15 -p1
-%patch16 -p1
-%patch17 -p1
-%patch18 -p1
%patch19 -p1
-%patch20 -p1
-%patch21 -p1
%patch22 -p1
%patch23 -p1
# patch to device-mapper
@@ -105,30 +91,32 @@
%patch61 -p1
%patch62 -p1
%patch63 -p1
-%patch64 -p1
%patch65 -p1
+%patch80 -p0
+%patch81 -p1
%build
CFLAGS="$RPM_OPT_FLAGS" MODPROBE_CMD=/sbin/modprobe \
-LDFLAGS="-L /usr/%_lib/openais" \
./configure --prefix=/ \
+ --bindir=/bin --libdir=/%_lib --with-userlibdir=%_libdir \
+ --sbindir=/sbin --enable-dmeventd \
+ --with-udevdir=/lib/udev/rules.d \
+ --with-dmeventd_path=/sbin/dmeventd \
+ --with-user=root --with-group=root \
+ --enable-udev_sync --enable-udev_rules --enable-compat \
+ --enable-cmdlib --enable-dmeventd \
+ --enable-realtime --enable-pkgconfig \
--mandir=%{_mandir} \
- --includedir=/usr/include \
- --enable-selinux \
- --enable-cmdlib \
- --libdir=/%_lib --enable-dmeventd --enable-cmdlib \
- --with-clvmd=openais
+ --includedir=/usr/include
make
%install
-make install DESTDIR=$RPM_BUILD_ROOT
+make install_lvm2 DESTDIR=$RPM_BUILD_ROOT
install -d -m 755 $RPM_BUILD_ROOT/etc/lvm
install -d -m 755 $RPM_BUILD_ROOT/etc/lvm/backup
install -d -m 755 $RPM_BUILD_ROOT/etc/lvm/archive
install -d -m 755 $RPM_BUILD_ROOT/etc/lvm/metadata
install -d -m 755 $RPM_BUILD_ROOT/var/lock/lvm
-rm $RPM_BUILD_ROOT/sbin/clvmd
-rm $RPM_BUILD_ROOT/%{_mandir}/man8/clvmd*
install -m 644 %{SOURCE1} $RPM_BUILD_ROOT/etc/lvm
mkdir -p $RPM_BUILD_ROOT/etc/init.d
install -m 755 %{SOURCE2} $RPM_BUILD_ROOT/etc/init.d
@@ -139,16 +127,9 @@
install -m 644 %{SOURCE3} $RPM_BUILD_ROOT/var/adm/fillup-templates
rm $RPM_BUILD_ROOT/usr/include/lvm2cmd.h
# install 64-lvm2.rules and collect_lvm
-install -m644 -D %{S:6} $RPM_BUILD_ROOT/lib/udev/rules.d/64-lvm2.rules
+#install -m644 -D %{S:6} $RPM_BUILD_ROOT/lib/udev/rules.d/64-lvm2.rules
install -m755 -D %{S:7} $RPM_BUILD_ROOT/lib/udev/collect_lvm
# remove all device mapper files
-rm $RPM_BUILD_ROOT/%{_lib}/libdevmapper-event.so*
-rm $RPM_BUILD_ROOT/%{_lib}/libdevmapper.so*
-rm $RPM_BUILD_ROOT/sbin/dmeventd
-rm $RPM_BUILD_ROOT/sbin/dmsetup
-rm $RPM_BUILD_ROOT/usr/include/libdevmapper-event.h
-rm $RPM_BUILD_ROOT/usr/include/libdevmapper.h
-rm $RPM_BUILD_ROOT/%{_mandir}/man8/dmsetup.*
rm $RPM_BUILD_ROOT/%{_mandir}/man8/fsadm.*
%clean
@@ -181,7 +162,8 @@
%dir /lib/mkinitrd/scripts
%dir /lib/udev
%dir /lib/udev/rules.d
-/lib/udev/rules.d/64-lvm2.rules
+#/lib/udev/rules.d/64-lvm2.rules
+/lib/udev/rules.d/11-dm-lvm.rules
/lib/udev/collect_lvm
/lib/mkinitrd/scripts/setup-lvm2.sh
/lib/mkinitrd/scripts/boot-lvm2.sh
@@ -223,6 +205,7 @@
/sbin/vgexport
/sbin/vgextend
/sbin/vgimport
+/sbin/vgimportclone
/sbin/vgmerge
/sbin/vgmknodes
/sbin/vgreduce
@@ -272,6 +255,7 @@
%{_mandir}/man8/vgexport.8.gz
%{_mandir}/man8/vgextend.8.gz
%{_mandir}/man8/vgimport.8.gz
+%{_mandir}/man8/vgimportclone.8.gz
%{_mandir}/man8/vgmerge.8.gz
%{_mandir}/man8/vgmknodes.8.gz
%{_mandir}/man8/vgreduce.8.gz
++++++ cmdline_large_minor.diff ++++++
--- /var/tmp/diff_new_pack.5QB7ea/_old 2010-04-05 18:36:04.000000000 +0200
+++ /var/tmp/diff_new_pack.5QB7ea/_new 2010-04-05 18:36:04.000000000 +0200
@@ -1,8 +1,8 @@
Index: tools/lvmcmdline.c
===================================================================
---- tools/lvmcmdline.c.orig
-+++ tools/lvmcmdline.c
-@@ -357,8 +357,8 @@ int minor_arg(struct cmd_context *cmd __
+--- tools/lvmcmdline.c.orig 2010-01-12 03:19:17.000000000 +0800
++++ tools/lvmcmdline.c 2010-02-04 13:59:18.000000000 +0800
+@@ -371,8 +371,8 @@
if (!_get_int_arg(a, &ptr) || (*ptr) || (a->sign == SIGN_MINUS))
return 0;
++++++ device-mapper-dmsetup-deps-export.patch ++++++
--- /var/tmp/diff_new_pack.5QB7ea/_old 2010-04-05 18:36:04.000000000 +0200
+++ /var/tmp/diff_new_pack.5QB7ea/_new 2010-04-05 18:36:04.000000000 +0200
@@ -1,8 +1,8 @@
-Index: LVM2.2.02.45/tools/dmsetup.c
+Index: LVM2.2.02.58/tools/dmsetup.c
===================================================================
---- LVM2.2.02.45.orig/tools/dmsetup.c 2009-04-27 17:46:16.000000000 +0800
-+++ LVM2.2.02.45/tools/dmsetup.c 2009-04-27 17:58:50.000000000 +0800
-@@ -1087,6 +1087,7 @@
+--- LVM2.2.02.58.orig/tools/dmsetup.c 2010-02-04 14:01:40.000000000 +0800
++++ LVM2.2.02.58/tools/dmsetup.c 2010-02-04 14:02:41.000000000 +0800
+@@ -1469,6 +1469,7 @@
const char *name = NULL;
const char *uuid = NULL;
struct dm_info info;
@@ -10,7 +10,7 @@
if (data)
name = names->name;
-@@ -1156,6 +1157,22 @@
+@@ -1538,6 +1539,22 @@
printf("\n");
}
++++++ device-mapper-dmsetup-export.patch ++++++
--- /var/tmp/diff_new_pack.5QB7ea/_old 2010-04-05 18:36:04.000000000 +0200
+++ /var/tmp/diff_new_pack.5QB7ea/_new 2010-04-05 18:36:04.000000000 +0200
@@ -1,8 +1,8 @@
-Index: LVM2.2.02.45/tools/dmsetup.c
+Index: LVM2.2.02.58/tools/dmsetup.c
===================================================================
---- LVM2.2.02.45.orig/tools/dmsetup.c 2008-10-31 01:52:06.000000000 +0800
-+++ LVM2.2.02.45/tools/dmsetup.c 2009-04-27 17:46:16.000000000 +0800
-@@ -1075,6 +1075,94 @@
+--- LVM2.2.02.58.orig/tools/dmsetup.c 2010-01-14 18:15:23.000000000 +0800
++++ LVM2.2.02.58/tools/dmsetup.c 2010-02-04 11:23:23.000000000 +0800
+@@ -1457,6 +1457,94 @@
return r;
}
@@ -97,7 +97,7 @@
/* Show target names and their version numbers */
static int _targets(int argc __attribute((unused)), char **argv __attribute((unused)), void *data __attribute((unused)))
{
-@@ -2115,6 +2203,7 @@
+@@ -2556,6 +2644,7 @@
{"info", "[<device>]", 0, 1, _info},
{"deps", "[<device>]", 0, 1, _deps},
{"status", "[<device>] [--target ]", 0, 1, _status},
@@ -105,10 +105,10 @@
{"table", "[<device>] [--target ] [--showkeys]", 0, 1, _status},
{"wait", "<device> []", 0, 2, _wait},
{"mknodes", "[<device>]", 0, 1, _mknodes},
-Index: LVM2.2.02.45/man/dmsetup.8.in
+Index: LVM2.2.02.58/man/dmsetup.8.in
===================================================================
---- LVM2.2.02.45.orig/man/dmsetup.8.in 2007-12-28 23:13:38.000000000 +0800
-+++ LVM2.2.02.45/man/dmsetup.8.in 2009-04-27 17:48:53.000000000 +0800
+--- LVM2.2.02.58.orig/man/dmsetup.8.in 2010-01-08 03:45:12.000000000 +0800
++++ LVM2.2.02.58/man/dmsetup.8.in 2010-02-04 11:23:23.000000000 +0800
@@ -46,6 +46,9 @@
.I [--noheadings] [--separator separator] [-o fields] [-O|--sort sort_fields]
.I [device_name]
@@ -119,7 +119,7 @@
.B dmsetup deps
.I [device_name]
.br
-@@ -146,6 +149,10 @@
+@@ -174,6 +177,10 @@
If successful a device will appear as
/dev/device-mapper/<device-name>.
See below for information on the table format.
++++++ device-mapper-gcc-warning.diff ++++++
--- /var/tmp/diff_new_pack.5QB7ea/_old 2010-04-05 18:36:04.000000000 +0200
+++ /var/tmp/diff_new_pack.5QB7ea/_new 2010-04-05 18:36:04.000000000 +0200
@@ -1,7 +1,7 @@
-Index: LVM2.2.02.45/libdm/datastruct/hash.c
+Index: LVM2.2.02.58/libdm/datastruct/hash.c
===================================================================
---- LVM2.2.02.45.orig/libdm/datastruct/hash.c 2008-11-04 02:59:59.000000000 +0800
-+++ LVM2.2.02.45/libdm/datastruct/hash.c 2009-04-27 17:52:05.000000000 +0800
+--- LVM2.2.02.58.orig/libdm/datastruct/hash.c 2009-11-03 08:45:35.000000000 +0800
++++ LVM2.2.02.58/libdm/datastruct/hash.c 2010-02-04 11:24:39.000000000 +0800
@@ -19,7 +19,7 @@
struct dm_hash_node *next;
void *data;
@@ -19,8 +19,8 @@
+ unsigned h = _hash((unsigned char*)key, len) & (t->num_slots - 1);
struct dm_hash_node **c;
- for (c = &t->slots[h]; *c; c = &((*c)->next))
-@@ -235,7 +235,7 @@
+ for (c = &t->slots[h]; *c; c = &((*c)->next)) {
+@@ -239,7 +239,7 @@
char *dm_hash_get_key(struct dm_hash_table *t __attribute((unused)),
struct dm_hash_node *n)
{
@@ -29,16 +29,16 @@
}
void *dm_hash_get_data(struct dm_hash_table *t __attribute((unused)),
-Index: LVM2.2.02.45/libdm/ioctl/libdm-iface.c
+Index: LVM2.2.02.58/libdm/ioctl/libdm-iface.c
===================================================================
---- LVM2.2.02.45.orig/libdm/ioctl/libdm-iface.c 2009-02-13 04:42:07.000000000 +0800
-+++ LVM2.2.02.45/libdm/ioctl/libdm-iface.c 2009-04-27 17:53:30.000000000 +0800
-@@ -1668,7 +1668,8 @@
- dmt->no_open_count ? 'N' : 'O',
+--- LVM2.2.02.58.orig/libdm/ioctl/libdm-iface.c 2009-11-13 20:43:22.000000000 +0800
++++ LVM2.2.02.58/libdm/ioctl/libdm-iface.c 2010-02-04 11:24:53.000000000 +0800
+@@ -1751,7 +1751,8 @@
dmt->no_flush ? 'N' : 'F',
dmt->skip_lockfs ? "S " : "",
+ dmt->query_inactive_table ? "I " : "",
- dmt->sector, dmt->message ? dmt->message : "",
-+ (unsigned long long int)dmt->sector,
++ (unsigned long long int)dmt->sector,
+ dmt->message ? dmt->message : "",
dmi->data_size);
#ifdef DM_IOCTLS
++++++ device-mapper-static.diff ++++++
--- /var/tmp/diff_new_pack.5QB7ea/_old 2010-04-05 18:36:04.000000000 +0200
+++ /var/tmp/diff_new_pack.5QB7ea/_new 2010-04-05 18:36:04.000000000 +0200
@@ -1,19 +1,19 @@
-Index: LVM2.2.02.45/libdm/Makefile.in
+Index: LVM2.2.02.58/libdm/Makefile.in
===================================================================
---- LVM2.2.02.45.orig/libdm/Makefile.in 2009-04-27 17:41:57.000000000 +0800
-+++ LVM2.2.02.45/libdm/Makefile.in 2009-04-27 17:56:06.000000000 +0800
-@@ -78,7 +78,6 @@
+--- LVM2.2.02.58.orig/libdm/Makefile.in 2009-10-03 03:10:36.000000000 +0800
++++ LVM2.2.02.58/libdm/Makefile.in 2010-02-04 14:06:35.000000000 +0800
+@@ -81,7 +81,6 @@
$(libdir)/libdevmapper.$(LIB_SUFFIX)
install_static: install_@interface@_static
- $(LN_S) -f libdevmapper.a.$(LIB_VERSION_DM) $(libdir)/libdevmapper.a
install_ioctl: ioctl/libdevmapper.$(LIB_SUFFIX)
- $(INSTALL) -D -m 555 $(STRIP) $< \
-@@ -90,7 +89,7 @@
+ $(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< \
+@@ -93,7 +92,7 @@
install_ioctl_static: ioctl/libdevmapper.a
- $(INSTALL) -D -m 555 $(STRIP) $< \
+ $(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< \
- $(libdir)/libdevmapper.a.$(LIB_VERSION_DM)
+ $(libdir)/libdevmapper.a
++++++ device-mapper-type_punning.diff ++++++
--- /var/tmp/diff_new_pack.5QB7ea/_old 2010-04-05 18:36:04.000000000 +0200
+++ /var/tmp/diff_new_pack.5QB7ea/_new 2010-04-05 18:36:04.000000000 +0200
@@ -1,6 +1,8 @@
---- lib/device/device.c
-+++ lib/device/device.c
-@@ -37,7 +37,7 @@
+Index: lib/device/device.c
+===================================================================
+--- lib/device/device.c.orig 2009-08-02 01:14:52.000000000 +0800
++++ lib/device/device.c 2010-02-04 14:02:42.000000000 +0800
+@@ -38,7 +38,7 @@
uint8_t end_cyl;
uint32_t start_sect;
uint32_t nr_sects;
++++++ dont_ignore_tmp_device_file.diff ++++++
--- /var/tmp/diff_new_pack.5QB7ea/_old 2010-04-05 18:36:04.000000000 +0200
+++ /var/tmp/diff_new_pack.5QB7ea/_new 2010-04-05 18:36:04.000000000 +0200
@@ -1,8 +1,8 @@
-Index: LVM2.2.02.45/lib/device/dev-cache.c
+Index: LVM2.2.02.58/lib/device/dev-cache.c
===================================================================
---- LVM2.2.02.45.orig/lib/device/dev-cache.c 2009-06-25 00:36:22.000000000 +0800
-+++ LVM2.2.02.45/lib/device/dev-cache.c 2009-06-25 00:37:22.000000000 +0800
-@@ -356,7 +356,11 @@
+--- LVM2.2.02.58.orig/lib/device/dev-cache.c 2009-07-16 04:02:46.000000000 +0800
++++ LVM2.2.02.58/lib/device/dev-cache.c 2010-02-04 15:32:59.000000000 +0800
+@@ -358,7 +358,11 @@
dirent_count = scandir(dir, &dirent, NULL, alphasort);
if (dirent_count > 0) {
for (n = 0; n < dirent_count; n++) {
++++++ fallback-major-number.diff ++++++
commit f7c1e5f60d2f4f5de860e770792d62dac8da7e0e
Author: Milan Broz
Date: Wed Jun 17 20:55:24 2009 +0000
Fix backward compatibility for major:minor query.
Is an application uses query and set major:minor
to device, it should not fallback to default major by default.
Add new function whoich allows that (and use it in lvm2).
Index: LVM2.2.02.45/lib/activate/dev_manager.c
===================================================================
--- LVM2.2.02.45.orig/lib/activate/dev_manager.c 2009-03-01 04:04:24.000000000 +0800
+++ LVM2.2.02.45/lib/activate/dev_manager.c 2010-01-08 13:26:42.000000000 +0800
@@ -110,10 +110,8 @@
if (event_nr)
dm_task_set_event_nr(dmt, *event_nr);
- if (major) {
- dm_task_set_major(dmt, major);
- dm_task_set_minor(dmt, minor);
- }
+ if (major)
+ dm_task_set_major_minor(dmt, major, minor, 1);
return dmt;
}
@@ -170,7 +168,7 @@
return 0;
}
- if (!dm_task_set_major(dmt, MAJOR(dev)) || !dm_task_set_minor(dmt, MINOR(dev)))
+ if (!dm_task_set_major_minor(dmt, MAJOR(dev), MINOR(dev), 1))
goto_out;
if (!dm_task_run(dmt)) {
Index: LVM2.2.02.45/libdm/.exported_symbols
===================================================================
--- LVM2.2.02.45.orig/libdm/.exported_symbols 2008-11-04 04:03:00.000000000 +0800
+++ LVM2.2.02.45/libdm/.exported_symbols 2010-01-08 13:26:42.000000000 +0800
@@ -24,6 +24,7 @@
dm_task_set_event_nr
dm_task_set_major
dm_task_set_minor
+dm_task_set_major_minor
dm_task_set_sector
dm_task_set_message
dm_task_set_uid
Index: LVM2.2.02.45/libdm/ioctl/libdm-iface.c
===================================================================
--- LVM2.2.02.45.orig/libdm/ioctl/libdm-iface.c 2010-01-08 13:26:06.000000000 +0800
+++ LVM2.2.02.45/libdm/ioctl/libdm-iface.c 2010-01-08 13:26:42.000000000 +0800
@@ -1402,7 +1402,8 @@
goto bad;
}
- if (!_dm_multiple_major_support && dmt->major != _dm_device_major) {
+ if (!_dm_multiple_major_support && dmt->allow_default_major_fallback &&
+ dmt->major != _dm_device_major) {
log_verbose("Overriding major number of %" PRIu32
" with %" PRIu32 " for persistent device.",
dmt->major, _dm_device_major);
Index: LVM2.2.02.45/libdm/ioctl/libdm-targets.h
===================================================================
--- LVM2.2.02.45.orig/libdm/ioctl/libdm-targets.h 2008-09-19 02:34:53.000000000 +0800
+++ LVM2.2.02.45/libdm/ioctl/libdm-targets.h 2010-01-08 13:26:42.000000000 +0800
@@ -41,6 +41,7 @@
uint32_t event_nr;
int major;
int minor;
+ int allow_default_major_fallback;
uid_t uid;
gid_t gid;
mode_t mode;
Index: LVM2.2.02.45/libdm/libdevmapper.h
===================================================================
--- LVM2.2.02.45.orig/libdm/libdevmapper.h 2008-11-04 23:07:45.000000000 +0800
+++ LVM2.2.02.45/libdm/libdevmapper.h 2010-01-08 13:26:42.000000000 +0800
@@ -145,6 +145,7 @@
int dm_task_set_newname(struct dm_task *dmt, const char *newname);
int dm_task_set_minor(struct dm_task *dmt, int minor);
int dm_task_set_major(struct dm_task *dmt, int major);
+int dm_task_set_major_minor(struct dm_task *dmt, int major, int minor, int allow_default_major_fallback);
int dm_task_set_uid(struct dm_task *dmt, uid_t uid);
int dm_task_set_gid(struct dm_task *dmt, gid_t gid);
int dm_task_set_mode(struct dm_task *dmt, mode_t mode);
Index: LVM2.2.02.45/libdm/libdm-common.c
===================================================================
--- LVM2.2.02.45.orig/libdm/libdm-common.c 2009-01-07 20:17:40.000000000 +0800
+++ LVM2.2.02.45/libdm/libdm-common.c 2010-01-08 13:26:42.000000000 +0800
@@ -118,6 +118,7 @@
dmt->type = type;
dmt->minor = -1;
dmt->major = -1;
+ dmt->allow_default_major_fallback = 1;
dmt->uid = DM_DEVICE_UID;
dmt->gid = DM_DEVICE_GID;
dmt->mode = DM_DEVICE_MODE;
@@ -190,6 +191,7 @@
int dm_task_set_major(struct dm_task *dmt, int major)
{
dmt->major = major;
+ dmt->allow_default_major_fallback = 0;
return 1;
}
@@ -200,6 +202,16 @@
return 1;
}
+
+int dm_task_set_major_minor(struct dm_task *dmt, int major, int minor,
+ int allow_default_major_fallback)
+{
+ dmt->major = major;
+ dmt->minor = minor;
+ dmt->allow_default_major_fallback = allow_default_major_fallback;
+
+ return 1;
+}
int dm_task_set_uid(struct dm_task *dmt, uid_t uid)
{
++++++ improve_probing.diff ++++++
--- /var/tmp/diff_new_pack.5QB7ea/_old 2010-04-05 18:36:04.000000000 +0200
+++ /var/tmp/diff_new_pack.5QB7ea/_new 2010-04-05 18:36:04.000000000 +0200
@@ -1,7 +1,7 @@
Index: lib/filters/filter.c
===================================================================
---- lib/filters/filter.c.orig 2009-04-27 16:15:37.000000000 +0800
-+++ lib/filters/filter.c 2009-04-27 16:15:39.000000000 +0800
+--- lib/filters/filter.c.orig 2010-02-04 11:00:15.000000000 +0800
++++ lib/filters/filter.c 2010-02-04 11:00:18.000000000 +0800
@@ -13,6 +13,12 @@
* Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
@@ -15,7 +15,7 @@
#include "lib.h"
#include "dev-cache.h"
#include "filter.h"
-@@ -103,11 +109,18 @@
+@@ -138,11 +144,18 @@
}
/* Check it's accessible */
++++++ lvm-no_chown.diff ++++++
--- /var/tmp/diff_new_pack.5QB7ea/_old 2010-04-05 18:36:04.000000000 +0200
+++ /var/tmp/diff_new_pack.5QB7ea/_new 2010-04-05 18:36:04.000000000 +0200
@@ -1,8 +1,8 @@
Index: daemons/clvmd/Makefile.in
===================================================================
---- daemons/clvmd/Makefile.in.orig 2009-04-27 16:51:29.000000000 +0800
-+++ daemons/clvmd/Makefile.in 2009-04-27 16:51:32.000000000 +0800
-@@ -107,7 +107,7 @@
+--- daemons/clvmd/Makefile.in.orig 2010-02-04 16:31:38.000000000 +0800
++++ daemons/clvmd/Makefile.in 2010-02-04 16:31:42.000000000 +0800
+@@ -98,7 +98,7 @@
.PHONY: install_clvmd
install_clvmd: $(TARGETS)
@@ -13,23 +13,23 @@
install: $(INSTALL_TARGETS)
Index: doc/Makefile.in
===================================================================
---- doc/Makefile.in.orig 2009-04-27 16:51:29.000000000 +0800
-+++ doc/Makefile.in 2009-04-27 16:51:32.000000000 +0800
-@@ -23,7 +23,7 @@
- install:
+--- doc/Makefile.in.orig 2010-02-04 16:31:38.000000000 +0800
++++ doc/Makefile.in 2010-02-04 16:31:42.000000000 +0800
+@@ -24,7 +24,7 @@
+ install_lvm2: $(CONFSRC)
@if [ ! -e $(confdir)/$(CONFDEST) ]; then \
echo "Installing $(CONFSRC) as $(confdir)/$(CONFDEST)"; \
-- @INSTALL@ -D $(OWNER) $(GROUP) -m 644 $(CONFSRC) \
-+ @INSTALL@ -D -m 644 $(CONFSRC) \
+- @INSTALL@ -D $(OWNER) $(GROUP) -m 644 $< \
++ @INSTALL@ -D -m 644 $< \
$(confdir)/$(CONFDEST); \
fi
Index: lib/format1/Makefile.in
===================================================================
---- lib/format1/Makefile.in.orig 2009-04-27 16:51:29.000000000 +0800
-+++ lib/format1/Makefile.in 2009-04-27 16:51:32.000000000 +0800
-@@ -31,7 +31,7 @@
- include $(top_srcdir)/make.tmpl
+--- lib/format1/Makefile.in.orig 2010-02-04 16:31:38.000000000 +0800
++++ lib/format1/Makefile.in 2010-02-04 16:31:42.000000000 +0800
+@@ -32,7 +32,7 @@
+ include ../../make.tmpl
install: liblvm2format1.so
- $(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< \
@@ -39,10 +39,10 @@
Index: lib/format_pool/Makefile.in
===================================================================
---- lib/format_pool/Makefile.in.orig 2009-04-27 16:51:29.000000000 +0800
-+++ lib/format_pool/Makefile.in 2009-04-27 16:51:32.000000000 +0800
-@@ -28,7 +28,7 @@
- include $(top_srcdir)/make.tmpl
+--- lib/format_pool/Makefile.in.orig 2010-02-04 16:31:38.000000000 +0800
++++ lib/format_pool/Makefile.in 2010-02-04 16:31:42.000000000 +0800
+@@ -29,7 +29,7 @@
+ include ../../make.tmpl
install: liblvm2formatpool.so
- $(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< \
@@ -52,10 +52,10 @@
$(libdir)/liblvm2formatpool.so
Index: lib/locking/Makefile.in
===================================================================
---- lib/locking/Makefile.in.orig 2009-04-27 16:51:29.000000000 +0800
-+++ lib/locking/Makefile.in 2009-04-27 16:51:32.000000000 +0800
-@@ -24,7 +24,7 @@
- include $(top_srcdir)/make.tmpl
+--- lib/locking/Makefile.in.orig 2010-02-04 16:31:38.000000000 +0800
++++ lib/locking/Makefile.in 2010-02-04 16:31:42.000000000 +0800
+@@ -25,7 +25,7 @@
+ include ../../make.tmpl
install install_cluster: liblvm2clusterlock.so
- $(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< \
@@ -65,10 +65,10 @@
$(libdir)/liblvm2clusterlock.so
Index: lib/mirror/Makefile.in
===================================================================
---- lib/mirror/Makefile.in.orig 2009-04-27 16:51:29.000000000 +0800
-+++ lib/mirror/Makefile.in 2009-04-27 16:51:32.000000000 +0800
-@@ -24,7 +24,7 @@
- include $(top_srcdir)/make.tmpl
+--- lib/mirror/Makefile.in.orig 2010-02-04 16:31:38.000000000 +0800
++++ lib/mirror/Makefile.in 2010-02-04 16:31:42.000000000 +0800
+@@ -25,7 +25,7 @@
+ include ../../make.tmpl
install: liblvm2mirror.so
- $(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< \
@@ -78,10 +78,10 @@
Index: lib/snapshot/Makefile.in
===================================================================
---- lib/snapshot/Makefile.in.orig 2009-04-27 16:51:29.000000000 +0800
-+++ lib/snapshot/Makefile.in 2009-04-27 16:51:32.000000000 +0800
-@@ -24,7 +24,7 @@
- include $(top_srcdir)/make.tmpl
+--- lib/snapshot/Makefile.in.orig 2010-02-04 16:31:38.000000000 +0800
++++ lib/snapshot/Makefile.in 2010-02-04 16:31:42.000000000 +0800
+@@ -25,7 +25,7 @@
+ include ../../make.tmpl
install: liblvm2snapshot.so
- $(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< \
@@ -91,9 +91,9 @@
$(libdir)/liblvm2snapshot.so
Index: man/Makefile.in
===================================================================
---- man/Makefile.in.orig 2009-04-27 16:51:29.000000000 +0800
-+++ man/Makefile.in 2009-04-27 16:52:20.000000000 +0800
-@@ -62,14 +62,14 @@
+--- man/Makefile.in.orig 2010-02-04 16:31:38.000000000 +0800
++++ man/Makefile.in 2010-02-04 16:31:42.000000000 +0800
+@@ -63,14 +63,14 @@
@for f in $(MAN8); \
do \
$(RM) $(MAN8DIR)/$$f; \
@@ -110,7 +110,7 @@
done
install_cluster:
-@@ -77,7 +77,7 @@
+@@ -78,7 +78,7 @@
@for f in $(MAN8CLUSTER); \
do \
$(RM) $(MAN8DIR)/$$f; \
@@ -119,18 +119,20 @@
done
install_device-mapper:
-@@ -85,5 +85,5 @@
+@@ -86,7 +86,7 @@
@for f in $(MAN8DM); \
do \
$(RM) $(MAN8DIR)/$$f; \
- @INSTALL@ -D $(OWNER) $(GROUP) -m 444 $$f $(MAN8DIR)/$$f; \
+ @INSTALL@ -D -m 444 $$f $(MAN8DIR)/$$f; \
done
+
+ install: install_lvm2 install_device-mapper
Index: po/Makefile.in
===================================================================
---- po/Makefile.in.orig 2009-04-27 16:51:29.000000000 +0800
-+++ po/Makefile.in 2009-04-27 16:51:32.000000000 +0800
-@@ -53,13 +53,13 @@
+--- po/Makefile.in.orig 2010-02-04 16:31:38.000000000 +0800
++++ po/Makefile.in 2010-02-04 16:31:42.000000000 +0800
+@@ -54,13 +54,13 @@
@echo Installing translation files in $(localedir)
@( \
for lang in $(LANGS); do \
@@ -148,43 +150,47 @@
)
Index: scripts/Makefile.in
===================================================================
---- scripts/Makefile.in.orig 2009-04-27 16:51:29.000000000 +0800
-+++ scripts/Makefile.in 2009-04-27 16:51:32.000000000 +0800
-@@ -18,9 +18,9 @@
- include $(top_srcdir)/make.tmpl
+--- scripts/Makefile.in.orig 2010-02-04 16:31:38.000000000 +0800
++++ scripts/Makefile.in 2010-02-04 16:31:42.000000000 +0800
+@@ -19,12 +19,12 @@
+ include ../make.tmpl
install:
-- $(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) lvm_dump.sh \
-+ $(INSTALL) -D -m 555 $(STRIP) lvm_dump.sh \
+- $(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(srcdir)/lvm_dump.sh \
++ $(INSTALL) -D -m 555 $(srcdir)/lvm_dump.sh \
$(sbindir)/lvmdump
+- $(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(srcdir)/vgimportclone.sh \
++ $(INSTALL) -D -m 555 $(srcdir)/vgimportclone.sh \
+ $(sbindir)/vgimportclone
ifeq ("@FSADM@", "yes")
-- $(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) fsadm.sh \
-+ $(INSTALL) -D -m 555 $(STRIP) fsadm.sh \
+- $(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(srcdir)/fsadm.sh \
++ $(INSTALL) -D -m 555 $(srcdir)/fsadm.sh \
$(sbindir)/fsadm
endif
+
Index: tools/Makefile.in
===================================================================
---- tools/Makefile.in.orig 2009-04-27 16:51:29.000000000 +0800
-+++ tools/Makefile.in 2009-04-27 16:51:32.000000000 +0800
-@@ -156,21 +156,21 @@
+--- tools/Makefile.in.orig 2010-02-04 16:31:38.000000000 +0800
++++ tools/Makefile.in 2010-02-04 16:31:42.000000000 +0800
+@@ -166,21 +166,21 @@
endif
install_cmdlib_dynamic: liblvm2cmd.$(LIB_SUFFIX)
-- $(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) liblvm2cmd.$(LIB_SUFFIX) \
-+ $(INSTALL) -D -m 555 $(STRIP) liblvm2cmd.$(LIB_SUFFIX) \
- $(libdir)/liblvm2cmd.$(LIB_SUFFIX).$(LIB_VERSION_LVM)
- $(LN_S) -f liblvm2cmd.$(LIB_SUFFIX).$(LIB_VERSION_LVM) $(libdir)/liblvm2cmd.$(LIB_SUFFIX)
-- $(INSTALL) -D $(OWNER) $(GROUP) -m 444 lvm2cmd.h \
-+ $(INSTALL) -D -m 444 lvm2cmd.h \
+- $(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< \
++ $(INSTALL) -D -m 555 $(STRIP) $< \
+ $(libdir)/liblvm2cmd.$(LIB_SUFFIX).$(LIB_VERSION)
+ $(LN_S) -f liblvm2cmd.$(LIB_SUFFIX).$(LIB_VERSION) $(libdir)/liblvm2cmd.$(LIB_SUFFIX)
+- $(INSTALL) -D $(OWNER) $(GROUP) -m 444 $(srcdir)/lvm2cmd.h \
++ $(INSTALL) -D -m 444 $(srcdir)/lvm2cmd.h \
$(includedir)/lvm2cmd.h
install_cmdlib_static: liblvm2cmd-static.a
-- $(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) liblvm2cmd-static.a \
-+ $(INSTALL) -D -m 555 $(STRIP) liblvm2cmd-static.a \
- $(libdir)/liblvm2cmd.a.$(LIB_VERSION_LVM)
- $(LN_S) -f liblvm2cmd.a.$(LIB_VERSION_LVM) $(libdir)/liblvm2cmd.a
-- $(INSTALL) -D $(OWNER) $(GROUP) -m 444 lvm2cmd.h \
-+ $(INSTALL) -D -m 444 lvm2cmd.h \
+- $(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< \
++ $(INSTALL) -D -m 555 $(STRIP) $< \
+ $(libdir)/liblvm2cmd.a.$(LIB_VERSION)
+ $(LN_S) -f liblvm2cmd.a.$(LIB_VERSION) $(libdir)/liblvm2cmd.a
+- $(INSTALL) -D $(OWNER) $(GROUP) -m 444 $(srcdir)/lvm2cmd.h \
++ $(INSTALL) -D -m 444 $(srcdir)/lvm2cmd.h \
$(includedir)/lvm2cmd.h
install_tools_dynamic: lvm .commands
@@ -193,12 +199,12 @@
$(sbindir)/lvm
@echo Creating symbolic links for individual commands in $(sbindir)
@( \
-@@ -181,14 +181,14 @@
+@@ -191,14 +191,14 @@
)
install_tools_static: lvm.static
-- $(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) lvm.static \
-+ $(INSTALL) -D -m 555 $(STRIP) lvm.static \
+- $(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< \
++ $(INSTALL) -D -m 555 $(STRIP) $< \
$(staticdir)/lvm.static
install_dmsetup_dynamic: dmsetup
@@ -213,77 +219,87 @@
Index: daemons/dmeventd/Makefile.in
===================================================================
---- daemons/dmeventd/Makefile.in.orig 2008-11-05 01:25:32.000000000 +0800
-+++ daemons/dmeventd/Makefile.in 2009-04-27 16:57:01.000000000 +0800
-@@ -64,24 +64,24 @@
- install_device-mapper: install
+--- daemons/dmeventd/Makefile.in.orig 2010-02-04 16:31:38.000000000 +0800
++++ daemons/dmeventd/Makefile.in 2010-02-04 16:31:42.000000000 +0800
+@@ -73,31 +73,31 @@
+ endif
install_include:
-- $(INSTALL) -D $(OWNER) $(GROUP) -m 444 libdevmapper-event.h \
-+ $(INSTALL) -D -m 444 libdevmapper-event.h \
+- $(INSTALL) -D $(OWNER) $(GROUP) -m 444 $(srcdir)/libdevmapper-event.h \
++ $(INSTALL) -D -m 444 $(srcdir)/libdevmapper-event.h \
$(includedir)/libdevmapper-event.h
- install_dynamic: libdevmapper-event.$(LIB_SUFFIX)
+ install_pkgconfig:
+- $(INSTALL) -D $(OWNER) $(GROUP) -m 444 libdevmapper-event.pc \
++ $(INSTALL) -D -m 444 libdevmapper-event.pc \
+ $(usrlibdir)/pkgconfig/devmapper-event.pc
+
+ install_lib_dynamic: libdevmapper-event.$(LIB_SUFFIX)
- $(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< \
+ $(INSTALL) -D -m 555 $(STRIP) $< \
$(libdir)/libdevmapper-event.$(LIB_SUFFIX).$(LIB_VERSION)
$(LN_S) -f libdevmapper-event.$(LIB_SUFFIX).$(LIB_VERSION) \
$(libdir)/libdevmapper-event.$(LIB_SUFFIX)
- install_dmeventd: dmeventd
-- $(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< $(sbindir)/$<
-+ $(INSTALL) -D -m 555 $(STRIP) $< $(sbindir)/$<
-
- install_pkgconfig:
-- $(INSTALL) -D $(OWNER) $(GROUP) -m 444 libdevmapper-event.pc \
-+ $(INSTALL) -D -m 444 libdevmapper-event.pc \
- $(usrlibdir)/pkgconfig/devmapper-event.pc
-
- install_static: libdevmapper-event.a
+ install_lib_static: libdevmapper-event.a
- $(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< \
+ $(INSTALL) -D -m 555 $(STRIP) $< \
$(libdir)/libdevmapper-event.a.$(LIB_VERSION)
$(LN_S) -f libdevmapper-event.a.$(LIB_VERSION) $(libdir)/libdevmapper-event.a
+ install_lib: $(INSTALL_LIB_TARGETS)
+
+ install_dmeventd_dynamic: dmeventd
+- $(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< $(sbindir)/$<
++ $(INSTALL) -D -m 555 $(STRIP) $< $(sbindir)/$<
+
+ install_dmeventd_static: dmeventd.static
+- $(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< $(sbindir)/$<
++ $(INSTALL) -D -m 555 $(STRIP) $< $(sbindir)/$<
+
+ install_dmeventd: $(INSTALL_DMEVENTD_TARGETS)
+
Index: daemons/dmeventd/plugins/mirror/Makefile.in
===================================================================
---- daemons/dmeventd/plugins/mirror/Makefile.in.orig 2008-11-04 06:14:26.000000000 +0800
-+++ daemons/dmeventd/plugins/mirror/Makefile.in 2009-04-27 16:55:45.000000000 +0800
-@@ -32,6 +32,6 @@
- include $(top_srcdir)/make.tmpl
+--- daemons/dmeventd/plugins/mirror/Makefile.in.orig 2010-02-04 16:31:38.000000000 +0800
++++ daemons/dmeventd/plugins/mirror/Makefile.in 2010-02-04 16:31:42.000000000 +0800
+@@ -35,7 +35,7 @@
+ LIBS += -ldevmapper @LIB_PTHREAD@ @LVM2CMD_LIB@
- install: libdevmapper-event-lvm2mirror.$(LIB_SUFFIX)
+ install_lvm2: libdevmapper-event-lvm2mirror.$(LIB_SUFFIX)
- $(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< \
+ $(INSTALL) -D -m 555 $(STRIP) $< \
$(libdir)/$<.$(LIB_VERSION)
$(LN_S) -f $<.$(LIB_VERSION) $(libdir)/$<
+
Index: daemons/dmeventd/plugins/snapshot/Makefile.in
===================================================================
---- daemons/dmeventd/plugins/snapshot/Makefile.in.orig 2008-11-04 06:14:27.000000000 +0800
-+++ daemons/dmeventd/plugins/snapshot/Makefile.in 2009-04-27 16:56:00.000000000 +0800
-@@ -32,6 +32,6 @@
- include $(top_srcdir)/make.tmpl
+--- daemons/dmeventd/plugins/snapshot/Makefile.in.orig 2010-02-04 16:31:38.000000000 +0800
++++ daemons/dmeventd/plugins/snapshot/Makefile.in 2010-02-04 16:31:42.000000000 +0800
+@@ -35,7 +35,7 @@
+ LIBS += -ldevmapper @LIB_PTHREAD@ @LVM2CMD_LIB@
- install: libdevmapper-event-lvm2snapshot.$(LIB_SUFFIX)
+ install_lvm2: libdevmapper-event-lvm2snapshot.$(LIB_SUFFIX)
- $(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< \
+ $(INSTALL) -D -m 555 $(STRIP) $< \
$(libdir)/$<.$(LIB_VERSION)
$(LN_S) -f $<.$(LIB_VERSION) $(libdir)/$<
+
Index: libdm/Makefile.in
===================================================================
---- libdm/Makefile.in.orig 2008-11-15 04:59:56.000000000 +0800
-+++ libdm/Makefile.in 2009-04-27 16:57:28.000000000 +0800
-@@ -70,7 +70,7 @@
+--- libdm/Makefile.in.orig 2010-02-04 16:31:38.000000000 +0800
++++ libdm/Makefile.in 2010-02-04 16:31:42.000000000 +0800
+@@ -73,7 +73,7 @@
install_device-mapper: install
install_include:
-- $(INSTALL) -D $(OWNER) $(GROUP) -m 444 libdevmapper.h \
-+ $(INSTALL) -D -m 444 libdevmapper.h \
+- $(INSTALL) -D $(OWNER) $(GROUP) -m 444 $(srcdir)/libdevmapper.h \
++ $(INSTALL) -D -m 444 $(srcdir)/libdevmapper.h \
$(includedir)/libdevmapper.h
install_dynamic: install_@interface@
-@@ -81,15 +81,15 @@
- $(LN_S) -f libdevmapper.a.$(LIB_VERSION_DM) $(libdir)/libdevmapper.a
+@@ -83,15 +83,15 @@
+ install_static: install_@interface@_static
install_ioctl: ioctl/libdevmapper.$(LIB_SUFFIX)
- $(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< \
@@ -298,6 +314,28 @@
install_ioctl_static: ioctl/libdevmapper.a
- $(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< \
+ $(INSTALL) -D -m 555 $(STRIP) $< \
- $(libdir)/libdevmapper.a.$(LIB_VERSION_DM)
+ $(libdir)/libdevmapper.a
$(VERSIONED_SHLIB): %.$(LIB_SUFFIX).$(LIB_VERSION_DM): $(interface)/%.$(LIB_SUFFIX)
+Index: udev/Makefile.in
+===================================================================
+--- udev/Makefile.in.orig 2010-02-04 16:31:38.000000000 +0800
++++ udev/Makefile.in 2010-02-04 16:31:59.000000000 +0800
+@@ -32,7 +32,7 @@
+ @for f in $(LVM_RULES); \
+ do \
+ $(RM) $(udevdir)/$$f; \
+- $(INSTALL) -c -D $(OWNER) $(GROUP) -m 644 $(srcdir)/$$f $(udevdir)/$$f; \
++ $(INSTALL) -c -D -m 644 $(srcdir)/$$f $(udevdir)/$$f; \
+ done
+
+ install_device-mapper: $(DM_RULES)
+@@ -40,7 +40,7 @@
+ @for f in $(DM_RULES); \
+ do \
+ $(RM) $(udevdir)/$$f; \
+- $(INSTALL) -c -D $(OWNER) $(GROUP) -m 644 $(srcdir)/$$f $(udevdir)/$$f; \
++ $(INSTALL) -c -D -m 644 $(srcdir)/$$f $(udevdir)/$$f; \
+ done
+
+ install: install_lvm2 install_device-mapper
++++++ lvm-pv-create-link.diff ++++++
--- /var/tmp/diff_new_pack.5QB7ea/_old 2010-04-05 18:36:04.000000000 +0200
+++ /var/tmp/diff_new_pack.5QB7ea/_new 2010-04-05 18:36:04.000000000 +0200
@@ -1,7 +1,7 @@
-Index: LVM2.2.02.45/tools/pvremove.c
+Index: LVM2.2.02.58/tools/pvremove.c
===================================================================
---- LVM2.2.02.45.orig/tools/pvremove.c 2009-04-27 16:35:32.000000000 +0800
-+++ LVM2.2.02.45/tools/pvremove.c 2009-04-27 16:49:48.000000000 +0800
+--- LVM2.2.02.58.orig/tools/pvremove.c 2009-12-04 03:18:34.000000000 +0800
++++ LVM2.2.02.58/tools/pvremove.c 2010-02-04 15:24:32.000000000 +0800
@@ -18,6 +18,30 @@
const char _really_wipe[] =
"Really WIPE LABELS from physical volume \"%s\" of volume group \"%s\" [y/n]? ";
@@ -42,26 +42,26 @@
ret = ECMD_PROCESSED;
error:
-Index: LVM2.2.02.45/tools/pvcreate.c
+Index: LVM2.2.02.58/tools/pvchange.c
===================================================================
---- LVM2.2.02.45.orig/tools/pvcreate.c 2009-04-27 16:35:32.000000000 +0800
-+++ LVM2.2.02.45/tools/pvcreate.c 2009-04-27 16:45:34.000000000 +0800
-@@ -36,6 +36,89 @@
- const char _really_init[] =
- "Really INITIALIZE physical volume \"%s\" of volume group \"%s\" [y/n]? ";
+--- LVM2.2.02.58.orig/tools/pvchange.c 2009-09-15 06:47:49.000000000 +0800
++++ LVM2.2.02.58/tools/pvchange.c 2010-02-04 15:24:32.000000000 +0800
+@@ -15,6 +15,90 @@
+
+ #include "tools.h"
+static const char* pv_follow_if_link (const char* path)
+{
-+ int r;
-+ int len = 60;
-+ char *fpath = NULL;
-+ char *npath = NULL;
-+ struct stat st;
++ int r;
++ int len = 60;
++ char *fpath = NULL;
++ char *npath = NULL;
++ struct stat st;
+
-+ r = lstat(path, &st);
-+ if (r == -1) return NULL; //shouldn't happen
++ r = lstat(path, &st);
++ if (r == -1) return NULL; //shouldn't happen
+
-+ if (S_ISLNK(st.st_mode)) {
++ if (S_ISLNK(st.st_mode)) {
+ while (1) {
+ npath = realloc(fpath, sizeof(char)*len);
+ if (npath == NULL) {
@@ -87,30 +87,30 @@
+ return fpath;
+}
+
-+
+static const char* pv_symlink_handle(struct cmd_context* cmd, const char* name, int create)
+{
-+ struct physical_volume *pv;
-+ char *pvuuid;
-+ char *pvuuid_link;
++ struct physical_volume *pv;
++ char *pvuuid;
++ char *pvuuid_link;
+
+ pvuuid_link = malloc(70);
+ if (pvuuid_link == NULL) return NULL;
+
-+ if (!(pv = pv_read(cmd, name, NULL, NULL, 0, 0))) {
++
++ if (!(pv = pv_read(cmd, name, NULL, NULL, 0, 0))) {
+ free(pvuuid_link);
+ return NULL;
+ }
+
-+ pvuuid = malloc(sizeof(char)*40);
-+ if (pvuuid == NULL) {
++ pvuuid = malloc(sizeof(char)*40);
++ if (pvuuid == NULL) {
+ free(pvuuid_link);
+ return NULL;
+ }
+
-+ id_write_format(&pv->id, pvuuid, 40);
++ id_write_format(&pv->id, pvuuid, 40);
+
-+ snprintf(pvuuid_link, 70, "/dev/disk/by-id/lvm2-pvuuid-%s", pvuuid);
++ snprintf(pvuuid_link, 70, "/dev/disk/by-id/lvm2-pvuuid-%s", pvuuid);
+
+ //we really don't care if it successed or not.
+ if (create) {
@@ -129,52 +129,21 @@
+ //unlink(pvuuid_link);
+ }
+
-+ free(pvuuid);
-+ return pvuuid_link;
++ free(pvuuid);
++ return pvuuid_link;
+}
+
- /*
- * See if we may pvcreate on this device.
- * 0 indicates we may not.
-@@ -150,6 +233,8 @@
- void *pv;
- struct device *dev;
- struct dm_list mdas;
-+ const char *oldsymlink;
-+
-
- if (pp->idp) {
- if ((dev = device_from_pvid(cmd, pp->idp)) &&
-@@ -213,12 +298,22 @@
-
- log_very_verbose("Writing physical volume data to disk \"%s\"",
- pv_name);
-+
-+ oldsymlink = pv_symlink_handle(cmd, pv_name, 0);
+
- if (!(pv_write(cmd, (struct physical_volume *)pv, &mdas,
- pp->labelsector))) {
- log_error("Failed to write physical volume \"%s\"", pv_name);
-+ if (oldsymlink) free(oldsymlink);
- goto error;
- }
-
-+ pv_symlink_handle(cmd, pv_name, 1);
-+ if (oldsymlink) {
-+ unlink(oldsymlink);
-+ free(oldsymlink);
-+ }
-+
- log_print("Physical volume \"%s\" successfully created", pv_name);
+ /* FIXME Locking. PVs in VG. */
- unlock_vg(cmd, VG_ORPHANS);
-Index: LVM2.2.02.45/tools/pvchange.c
+ static int _pvchange_single(struct cmd_context *cmd, struct physical_volume *pv,
+Index: LVM2.2.02.58/lib/metadata/metadata.c
===================================================================
---- LVM2.2.02.45.orig/tools/pvchange.c 2009-04-27 16:35:32.000000000 +0800
-+++ LVM2.2.02.45/tools/pvchange.c 2009-04-27 16:45:18.000000000 +0800
-@@ -15,6 +15,90 @@
-
- #include "tools.h"
+--- LVM2.2.02.58.orig/lib/metadata/metadata.c 2010-01-07 22:29:53.000000000 +0800
++++ LVM2.2.02.58/lib/metadata/metadata.c 2010-02-04 15:31:58.000000000 +0800
+@@ -1333,6 +1333,88 @@
+ pp->yes = 0;
+ }
+static const char* pv_follow_if_link (const char* path)
+{
@@ -206,13 +175,13 @@
+ len = len * 2;
+ }
+ }
-+ }
-+ else {
++ } else {
+ fpath = strdup(path);
+ }
+ return fpath;
+}
+
++
+static const char* pv_symlink_handle(struct cmd_context* cmd, const char* name, int create)
+{
+ struct physical_volume *pv;
@@ -222,7 +191,6 @@
+ pvuuid_link = malloc(70);
+ if (pvuuid_link == NULL) return NULL;
+
-+
+ if (!(pv = pv_read(cmd, name, NULL, NULL, 0, 0))) {
+ free(pvuuid_link);
+ return NULL;
@@ -235,7 +203,6 @@
+ }
+
+ id_write_format(&pv->id, pvuuid, 40);
-+
+ snprintf(pvuuid_link, 70, "/dev/disk/by-id/lvm2-pvuuid-%s", pvuuid);
+
+ //we really don't care if it successed or not.
@@ -246,8 +213,7 @@
+ if (tname != NULL) {
+ r = symlink(tname, pvuuid_link);
+ free(tname);
-+ }
-+ else {
++ } else {
+ symlink(name, pvuuid_link);
+ }
+ } else {
@@ -260,35 +226,37 @@
+}
+
+
- /* FIXME Locking. PVs in VG. */
-
- static int _pvchange_single(struct cmd_context *cmd, struct physical_volume *pv,
-@@ -202,11 +286,23 @@
- return 0;
- }
- backup(vg);
-- } else if (!(pv_write(cmd, pv, NULL, INT64_C(-1)))) {
-- unlock_vg(cmd, vg_name);
-- log_error("Failed to store physical volume \"%s\"",
-- pv_name);
-- return 0;
-+ } else {
-+ const char* oldsymlink;
-+ oldsymlink = pv_symlink_handle(cmd, pv_name, 0);
+
-+ if (!(pv_write(cmd, pv, NULL, INT64_C(-1)))) {
-+ unlock_vg(cmd, vg_name);
-+ log_error("Failed to store physical volume \"%s\"",
-+ pv_name);
-+ if (oldsymlink) free(oldsymlink);
-+ return 0;
-+ }
-+ pv_symlink_handle(cmd, pv_name, 1);
-+ if (oldsymlink) {
-+ unlink(oldsymlink);
-+ free(oldsymlink);
-+ }
+ /*
+ * pvcreate_single() - initialize a device with PV label and metadata area
+ *
+@@ -1353,6 +1435,7 @@
+ struct dm_list mdas;
+ struct pvcreate_params default_pp;
+ char buffer[64] __attribute((aligned(8)));
++ const char *oldsymlink;
+
+ pvcreate_params_set_defaults(&default_pp);
+ if (!pp)
+@@ -1418,12 +1501,21 @@
+
+ log_very_verbose("Writing physical volume data to disk \"%s\"",
+ pv_name);
++ oldsymlink = pv_symlink_handle(cmd, pv_name, 0);
+
+ if (!(pv_write(cmd, (struct physical_volume *)pv, &mdas,
+ pp->labelsector))) {
+ log_error("Failed to write physical volume \"%s\"", pv_name);
++ if (oldsymlink) free(oldsymlink);
+ goto error;
}
- unlock_vg(cmd, vg_name);
++ pv_symlink_handle(cmd, pv_name, 1);
++ if (oldsymlink) {
++ unlink(oldsymlink);
++ free(oldsymlink);
++ }
++
+ log_print("Physical volume \"%s\" successfully created", pv_name);
+
+ return pv;
++++++ lvm2cmd-link-to-devmapper-event.diff ++++++
--- /var/tmp/diff_new_pack.5QB7ea/_old 2010-04-05 18:36:04.000000000 +0200
+++ /var/tmp/diff_new_pack.5QB7ea/_new 2010-04-05 18:36:04.000000000 +0200
@@ -1,12 +1,12 @@
-Index: LVM2.2.02.45/tools/Makefile.in
+Index: LVM2.2.02.58/tools/Makefile.in
===================================================================
---- LVM2.2.02.45.orig/tools/Makefile.in 2009-11-27 20:35:17.000000000 +0800
-+++ LVM2.2.02.45/tools/Makefile.in 2009-11-27 20:36:34.000000000 +0800
-@@ -130,6 +130,7 @@
+--- LVM2.2.02.58.orig/tools/Makefile.in 2010-02-04 15:51:32.000000000 +0800
++++ LVM2.2.02.58/tools/Makefile.in 2010-02-04 15:51:37.000000000 +0800
+@@ -139,6 +139,7 @@
$(AR) rs $@ $(OBJECTS) lvmcmdlib.o lvm2cmd-static.o
liblvm2cmd.$(LIB_SUFFIX): liblvm2cmd.a $(LDDEPS)
+ $(CC) -shared -o $@ $(CFLAGS) $(OBJECTS) lvmcmdlib.o lvm2cmd.o $(LDFLAGS) $(LVMLIBS) $(LIBS) $(LIB_PTHREAD)
.commands: commands.h cmdnames.h Makefile
- $(CC) -E -P cmdnames.h 2> /dev/null | \
+ $(CC) -E -P $(srcdir)/cmdnames.h 2> /dev/null | \
++++++ man_page_sectors.diff ++++++
--- /var/tmp/diff_new_pack.5QB7ea/_old 2010-04-05 18:36:04.000000000 +0200
+++ /var/tmp/diff_new_pack.5QB7ea/_new 2010-04-05 18:36:04.000000000 +0200
@@ -1,8 +1,8 @@
Index: man/pvdisplay.8.in
===================================================================
---- man/pvdisplay.8.in.orig 2009-04-27 16:17:35.000000000 +0800
-+++ man/pvdisplay.8.in 2009-04-27 16:17:50.000000000 +0800
-@@ -25,7 +25,7 @@
+--- man/pvdisplay.8.in.orig 2009-10-26 22:37:09.000000000 +0800
++++ man/pvdisplay.8.in 2010-02-04 11:00:40.000000000 +0800
+@@ -51,7 +51,7 @@
* physical volume device name
* volume group name
++++++ no-inc-audit.diff ++++++
--- /var/tmp/diff_new_pack.5QB7ea/_old 2010-04-05 18:36:04.000000000 +0200
+++ /var/tmp/diff_new_pack.5QB7ea/_new 2010-04-05 18:36:04.000000000 +0200
@@ -1,7 +1,7 @@
Index: lib/device/dev-io.c
===================================================================
---- lib/device/dev-io.c.orig 2009-04-27 16:15:36.000000000 +0800
-+++ lib/device/dev-io.c 2009-04-27 16:15:42.000000000 +0800
+--- lib/device/dev-io.c.orig 2009-05-20 19:09:49.000000000 +0800
++++ lib/device/dev-io.c 2010-02-04 11:00:22.000000000 +0800
@@ -31,6 +31,7 @@
# define u64 uint64_t /* Missing without __KERNEL__ */
# undef WNOHANG /* Avoid redefinition */
@@ -12,8 +12,8 @@
# ifndef BLKGETSIZE64 /* fs.h out-of-date */
Index: lib/filters/filter.c
===================================================================
---- lib/filters/filter.c.orig 2009-04-27 16:15:39.000000000 +0800
-+++ lib/filters/filter.c 2009-04-27 16:15:42.000000000 +0800
+--- lib/filters/filter.c.orig 2010-02-04 11:00:18.000000000 +0800
++++ lib/filters/filter.c 2010-02-04 11:00:22.000000000 +0800
@@ -14,6 +14,7 @@
*/
++++++ no_buildroot_shared.diff ++++++
--- /var/tmp/diff_new_pack.5QB7ea/_old 2010-04-05 18:36:04.000000000 +0200
+++ /var/tmp/diff_new_pack.5QB7ea/_new 2010-04-05 18:36:04.000000000 +0200
@@ -1,13 +1,13 @@
Index: tools/Makefile.in
===================================================================
---- tools/Makefile.in.orig 2009-04-27 16:15:35.000000000 +0800
-+++ tools/Makefile.in 2009-04-27 16:15:46.000000000 +0800
-@@ -95,7 +95,7 @@
+--- tools/Makefile.in.orig 2009-10-13 09:31:10.000000000 +0800
++++ tools/Makefile.in 2010-02-04 11:00:25.000000000 +0800
+@@ -105,7 +105,7 @@
LVMLIBS += -ldevmapper
-DEFS += -DLVM_SHARED_PATH=\"$(exec_prefix)/sbin/lvm\"
+DEFS += -DLVM_SHARED_PATH=\"/sbin/lvm\"
- include $(top_srcdir)/make.tmpl
+ include ../make.tmpl
++++++ support-drbd-filter.diff ++++++
--- /var/tmp/diff_new_pack.5QB7ea/_old 2010-04-05 18:36:04.000000000 +0200
+++ /var/tmp/diff_new_pack.5QB7ea/_new 2010-04-05 18:36:04.000000000 +0200
@@ -1,24 +1,10 @@
This is still very primitive support of drbd in lvm2.
Can we use some /sys information for this ?
-Index: LVM2.2.02.45/lib/cache/lvmcache.c
+Index: LVM2.2.02.58/lib/cache/lvmcache.c
===================================================================
---- LVM2.2.02.45.orig/lib/cache/lvmcache.c
-+++ LVM2.2.02.45/lib/cache/lvmcache.c
-@@ -1136,6 +1136,13 @@ struct lvmcache_info *lvmcache_add(struc
- pvid, dev_name(dev),
- dev_name(existing->dev));
- return NULL;
-+ } else if (MAJOR(existing->dev->dev) == drbd_major() &&
-+ MAJOR(dev->dev) != drbd_major()) {
-+ log_very_verbose("Ignoring duplicate PV %s on "
-+ "%s - using drbd %s",
-+ pvid, dev_name(dev),
-+ dev_name(existing->dev));
-+ return NULL;
- } else if (MAJOR(existing->dev->dev) != md_major() &&
- MAJOR(dev->dev) == md_major())
- log_very_verbose("Duplicate PV %s on %s - "
-@@ -1148,6 +1155,12 @@ struct lvmcache_info *lvmcache_add(struc
+--- LVM2.2.02.58.orig/lib/cache/lvmcache.c 2010-01-12 03:12:25.000000000 +0800
++++ LVM2.2.02.58/lib/cache/lvmcache.c 2010-02-04 16:03:13.000000000 +0800
+@@ -1242,6 +1242,12 @@
"using dm %s", pvid,
dev_name(existing->dev),
dev_name(dev));
@@ -31,38 +17,3 @@
/* FIXME If both dm, check dependencies */
//else if (dm_is_dm_major(MAJOR(existing->dev->dev)) &&
//dm_is_dm_major(MAJOR(dev->dev)))
-Index: LVM2.2.02.45/lib/filters/filter.c
-===================================================================
---- LVM2.2.02.45.orig/lib/filters/filter.c
-+++ LVM2.2.02.45/lib/filters/filter.c
-@@ -46,12 +46,20 @@ typedef struct {
-
- static int _md_major = -1;
- static int _device_mapper_major = -1;
-+static int _drbd_major = -1;
-
- int md_major(void)
- {
- return _md_major;
- }
-
-+/* FIXME: Should we consider filter out non-primary
-+ drbd resource ?? */
-+int drbd_major(void)
-+{
-+ return _drbd_major;
-+}
-+
- /*
- * Devices are only checked for partition tables if their minor number
- * is a multiple of the number corresponding to their type below
-@@ -208,6 +216,9 @@ static int _scan_proc_dev(const char *pr
- if (!strncmp("md", line + i, 2) && isspace(*(line + i + 2)))
- _md_major = line_maj;
-
-+ if (!strncmp("drbd", line + i, 4) && isspace(*(line + i + 4)))
-+ _drbd_major = line_maj;
-+
- /* Look for device-mapper device */
- /* FIXME Cope with multiple majors */
- if (!strncmp("device-mapper", line + i, 13) && isspace(*(line + i + 13)))
++++++ udev-rules_update.diff ++++++
Index: LVM2.2.02.58/udev/10-dm.rules.in
===================================================================
--- LVM2.2.02.58.orig/udev/10-dm.rules.in 2009-12-07 20:03:47.000000000 +0800
+++ LVM2.2.02.58/udev/10-dm.rules.in 2010-02-04 14:55:45.000000000 +0800
@@ -62,6 +62,10 @@
TEST!="dm", IMPORT{program}="$env{DM_SBIN_PATH}/dmsetup info -j %M -m %m -c --nameprefixes --noheadings --rows -o name,uuid,suspended"
ENV{DM_SUSPENDED}!="?*", IMPORT{program}="$env{DM_SBIN_PATH}/dmsetup info -j %M -m %m -c --nameprefixes --noheadings --rows -o suspended"
+# dmsetup export is a SUSE extension to dmsetup
+# it is required by some other udev rules in SUSE distro.
+IMPORT{program}="$env{DM_SBIN_PATH}/dmsetup export -j %M -m %m"
+
# dmsetup tool provides suspended state information in textual
# form with values "Suspended"/"Active". We translate it to
# 0/1 respectively to be consistent with sysfs values.
Index: LVM2.2.02.58/udev/13-dm-disk.rules
===================================================================
--- LVM2.2.02.58.orig/udev/13-dm-disk.rules 2009-11-13 20:33:27.000000000 +0800
+++ LVM2.2.02.58/udev/13-dm-disk.rules 2010-02-04 14:59:09.000000000 +0800
@@ -14,13 +14,16 @@
ENV{DM_UDEV_RULES_VSN}!="?*", GOTO="dm_end"
ENV{DM_UDEV_DISABLE_DISK_RULES_FLAG}=="1", GOTO="dm_end"
-SYMLINK+="disk/by-id/dm-name-$env{DM_NAME}"
-ENV{DM_UUID}=="?*", SYMLINK+="disk/by-id/dm-uuid-$env{DM_UUID}"
+SYMLINK+="disk/by-id/dm-name-$env{DM_NAME}", OPTIONS+="string_escape=replace"
+ENV{DM_UUID}=="?*", SYMLINK+="disk/by-id/dm-uuid-$env{DM_UUID}", OPTIONS+="string_escape=replace"
ENV{DM_SUSPENDED}=="1", GOTO="dm_end"
+ENV{DM_TARGET_TYPES}=="|*error*", GOTO="dm_end"
IMPORT{program}="$env{DM_SBIN_PATH}/blkid -o udev -p $tempnode"
-ENV{DM_UDEV_LOW_PRIORITY_FLAG}=="1", OPTIONS="link_priority=-100"
+ENV{DM_UDEV_LOW_PRIORITY_FLAG}=="1", OPTIONS+="link_priority=-100"
+OPTIONS+="watch"
+ENV{DM_TARGET_TYPES}=="*snapshot-origin*", OPTIONS+="link_priority=-90"
ENV{ID_FS_USAGE}=="filesystem|other|crypto", ENV{ID_FS_UUID_ENC}=="?*", SYMLINK+="disk/by-uuid/$env{ID_FS_UUID_ENC}"
ENV{ID_FS_USAGE}=="filesystem|other", ENV{ID_FS_LABEL_ENC}=="?*", SYMLINK+="disk/by-label/$env{ID_FS_LABEL_ENC}"
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Remember to have fun...
--
To unsubscribe, e-mail: opensuse-commit+unsubscribe@opensuse.org
For additional commands, e-mail: opensuse-commit+help@opensuse.org