[libvirt] [PATCH 0/2] build: bump minimum udev version to 219

Inspired-by: Pavel Hrdina <phardina@redhat.com> Ján Tomko (2): build: bump minimum udev version to 219 build: drop check for udev_monitor_set_receive_buffer_size m4/virt-udev.m4 | 14 ++------------ src/node_device/node_device_udev.c | 2 -- 2 files changed, 2 insertions(+), 14 deletions(-) -- 2.19.2

This is the version of systemd RHEL/CentOS 7 uses: https://repology.org/project/systemd/versions Oldest tracked openSUSE distros have 228, Ubuntu 16.04 has 229 and Gentoo's alternative eudev has bumped the version to 219 back in 2015. Signed-off-by: Ján Tomko <jtomko@redhat.com> --- m4/virt-udev.m4 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/m4/virt-udev.m4 b/m4/virt-udev.m4 index cf977c650b..5bb9cd5c5f 100644 --- a/m4/virt-udev.m4 +++ b/m4/virt-udev.m4 @@ -18,12 +18,12 @@ dnl <http://www.gnu.org/licenses/>. dnl AC_DEFUN([LIBVIRT_ARG_UDEV],[ - LIBVIRT_ARG_WITH_FEATURE([UDEV], [libudev], [check], [145]) + LIBVIRT_ARG_WITH_FEATURE([UDEV], [libudev], [check], [219]) ]) AC_DEFUN([LIBVIRT_CHECK_UDEV],[ AC_REQUIRE([LIBVIRT_CHECK_PCIACCESS]) - LIBVIRT_CHECK_PKG([UDEV], [libudev], [145]) + LIBVIRT_CHECK_PKG([UDEV], [libudev], [219]) if test "$with_udev" = "yes" && test "$with_pciaccess" != "yes" ; then AC_MSG_ERROR([You must install the pciaccess module to build with udev]) -- 2.19.2

It has been exported by systemd commit commit a571c23e954cb88cdd5faa28593b19bd7c340130 libudev: export udev_monitor_set_receive_buffer_size() released in v183. Signed-off-by: Ján Tomko <jtomko@redhat.com> --- m4/virt-udev.m4 | 10 ---------- src/node_device/node_device_udev.c | 2 -- 2 files changed, 12 deletions(-) diff --git a/m4/virt-udev.m4 b/m4/virt-udev.m4 index 5bb9cd5c5f..2e0f993e33 100644 --- a/m4/virt-udev.m4 +++ b/m4/virt-udev.m4 @@ -28,16 +28,6 @@ AC_DEFUN([LIBVIRT_CHECK_UDEV],[ if test "$with_udev" = "yes" && test "$with_pciaccess" != "yes" ; then AC_MSG_ERROR([You must install the pciaccess module to build with udev]) fi - - if test "$with_udev" = "yes" ; then - old_CFLAGS="$CFLAGS" - old_LIBS="$LIBS" - CFLAGS="$CFLAGS $UDEV_CFLAGS" - LIBS="$CFLAGS $UDEV_LIBS" - AC_CHECK_FUNCS([udev_monitor_set_receive_buffer_size]) - CFLAGS="$old_CFLAGS" - LIBS="$old_LIBS" - fi ]) AC_DEFUN([LIBVIRT_RESULT_UDEV],[ diff --git a/src/node_device/node_device_udev.c b/src/node_device/node_device_udev.c index 5df2fd72f3..276bf3dd99 100644 --- a/src/node_device/node_device_udev.c +++ b/src/node_device/node_device_udev.c @@ -1847,14 +1847,12 @@ nodeStateInitialize(bool privileged, udev_monitor_enable_receiving(priv->udev_monitor); -#if HAVE_UDEV_MONITOR_SET_RECEIVE_BUFFER_SIZE /* mimic udevd's behaviour and override the systems rmem_max limit in case * there's a significant number of device 'add' events */ if (geteuid() == 0) udev_monitor_set_receive_buffer_size(priv->udev_monitor, 128 * 1024 * 1024); -#endif if (virThreadCreate(&priv->th, true, udevEventHandleThread, NULL) < 0) { virReportSystemError(errno, "%s", -- 2.19.2
participants (2)
-
Ján Tomko
-
Pavel Hrdina