Skip to content

Commit

Permalink
Merge branch 'storaged-project:master' into master
Browse files Browse the repository at this point in the history
  • Loading branch information
xyakimo1 authored Jul 11, 2024
2 parents 433ed08 + 894c324 commit 83fc115
Show file tree
Hide file tree
Showing 34 changed files with 3,839 additions and 2,203 deletions.
10 changes: 10 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
version: 2
updates:

# Set update schedule for GitHub actions.
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "weekly"
commit-message:
prefix: "infra"
2 changes: 1 addition & 1 deletion .github/workflows/csmock.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ jobs:
- name: Upload the csmock logs
if: always()
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: csmock_logs
path: csmock_*/*
10 changes: 10 additions & 0 deletions .packit.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,16 @@ jobs:
additional_repos:
- "copr://@storage/udisks-daily"

- job: tests
trigger: pull_request
targets:
- fedora-latest-stable
tf_extra_params:
environments:
- artifacts:
- type: repository-file
id: https://copr.fedorainfracloud.org/coprs/g/storage/udisks-daily/repo/fedora-$releasever/group_storage-udisks-daily-fedora-$releasever.repo

# run tests for udisks consumers, see plans/ with `revdeps == yes`
- job: tests
identifier: revdeps
Expand Down
28 changes: 24 additions & 4 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -170,10 +170,6 @@ if test "x$enable_daemon" = "xyes"; then
AC_SUBST(BLOCKDEV_CFLAGS)
AC_SUBST(BLOCKDEV_LIBS)

PKG_CHECK_MODULES(LIBATASMART, [libatasmart >= 0.17])
AC_SUBST(LIBATASMART_CFLAGS)
AC_SUBST(LIBATASMART_LIBS)

PKG_CHECK_MODULES(LIBBLKID, [blkid])
AC_SUBST(LIBBLKID_CFLAGS)
AC_SUBST(LIBBLKID_LIBS)
Expand Down Expand Up @@ -215,6 +211,7 @@ if test "x$enable_daemon" = "xyes"; then
else
have_libsystemd_login=no
have_libelogind=no
AM_CONDITIONAL(HAVE_SMART, [0])
fi
AM_CONDITIONAL(HAVE_LIBSYSTEMD_LOGIN, test x$have_libsystemd_login = xyes)
AM_CONDITIONAL(HAVE_LIBELOGIND, test x$have_libelogind = xyes)
Expand Down Expand Up @@ -544,6 +541,28 @@ if test "x$enable_daemon" = "xyes"; then
if test "x$have_nvme" = "xno"; then
AC_MSG_ERROR([BLOCKDEV NVMe support requested but header or library not found])
fi

# libblockdev smart
have_smart=no
AC_ARG_ENABLE(smart, AS_HELP_STRING([--disable-smart], [disable ATA SMART support]))
if test "x$enable_smart" != "xno"; then
SAVE_CFLAGS=$CFLAGS
SAVE_LDFLAGS=$LDFLAGS

CFLAGS="$GLIB_CFLAGS"
LDFLAGS="$GLIB_LIBS"
AC_MSG_CHECKING([libblockdev-smart presence])
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <blockdev/smart.h>]], [[]])],
[AC_MSG_RESULT([yes])
AC_DEFINE(HAVE_SMART, 1, [Define, if libblockdev-smart is available])
have_smart=yes],
[AC_MSG_RESULT([no])
AC_MSG_ERROR([libblockdev-smart requested but not found.])
have_smart=no])
CFLAGS=$SAVE_CFLAGS
LDFLAGS=$SAVE_LDFLAGS
fi
AM_CONDITIONAL(HAVE_SMART, [test "$have_smart" = "yes"])
fi


Expand Down Expand Up @@ -674,6 +693,7 @@ echo "
Enable daemon: ${enable_daemon}
Enable modules: ${enable_modules_info}

ATA SMART support: ${have_smart}
BTRFS module: ${have_btrfs}
iSCSI module: ${have_iscsi}${have_libiscsi_session_info_msg}
LVM2 module: ${have_lvm2}
Expand Down
26 changes: 21 additions & 5 deletions data/org.freedesktop.UDisks2.xml
Original file line number Diff line number Diff line change
Expand Up @@ -896,10 +896,13 @@
<literal>org.freedesktop.UDisks2.Error.WouldWakeup</literal> is
returned.
The option @atasmart_blob can be used to inject libatasmart
compatible blobs for testing how clients react to different
kinds of SMART data. This option may be removed in the future
without it being considered an ABI break.
The option @atasmart_blob (of type 's' representing a path to
the blob file) can be used to inject libatasmart-compatible
blobs for testing how clients react to different kinds of SMART
data. Only valid when backed with the
<literal>libblockdev_libatasmat</literal> plugin. This option
may be removed in the future without it being considered an ABI
break. Deprecated since 2.11.0.
-->
<method name="SmartUpdate">
<arg name="options" direction="in" type="a{sv}"/>
Expand Down Expand Up @@ -946,7 +949,8 @@
Starts a SMART selftest. The @type parameter is for the type
of test to start - valid values are <literal>short</literal>,
<literal>extended</literal> and <literal>conveyance</literal>.
<literal>extended</literal>, <literal>conveyance</literal> and
<literal>offline</literal> (since 2.11.0).
Note that the method returns immediately after the test has
been started successfully.
Expand Down Expand Up @@ -3156,6 +3160,18 @@
-->
<property name="Degraded" type="u" access="read"/>

<!-- ConsistencyPolicy:
@since: 2.11.0
The consistency policy of the array.
If the RAID array does not support consistency policies (for
example RAID-0 arrays), this is empty.
This property corresponds to the
<literal>consistency_policy</literal> sysfs file.
-->
<property name="ConsistencyPolicy" type="s" access="read"/>

<!-- BitmapLocation:
The location of a write-intent bitmap (empty if the array is not running), if any.
Expand Down
2 changes: 2 additions & 0 deletions doc/udisks2-sections.txt.daemon.sections.in
Original file line number Diff line number Diff line change
Expand Up @@ -283,6 +283,8 @@ udisks_linux_device_read_sysfs_attr_as_int
udisks_linux_device_read_sysfs_attr_as_uint64
udisks_linux_device_subsystem_is_nvme
udisks_linux_device_nvme_is_fabrics
udisks_linux_device_is_dm_multipath
udisks_linux_device_is_mpath_device_path
<SUBSECTION Standard>
UDISKS_TYPE_LINUX_DEVICE
UDISKS_LINUX_DEVICE
Expand Down
7 changes: 6 additions & 1 deletion misc/install-test-dependencies.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,10 @@
package: name=libblockdev-nvme-devel state=present
when: ansible_distribution == 'Fedora'

- name: Install libblockdev SMART plugin (Fedora)
package: name=libblockdev-smart-devel state=present
when: ansible_distribution == 'Fedora'

- name: Install test dependencies (Fedora)
package: name={{item}} state=present
with_items:
Expand All @@ -59,5 +63,6 @@
- python-systemd
- python3-systemd
- python3-monotonic
- python3-monotonic
- cryptsetup
- vdo
when: ansible_distribution == 'Fedora'
4 changes: 2 additions & 2 deletions modules/btrfs/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ SUBDIRS = data

NULL =

CPPFLAGS = \
AM_CPPFLAGS = \
-I$(top_builddir) -I$(top_srcdir) \
-DPACKAGE_LIBEXEC_DIR=\""$(libexecdir)"\" \
-DPACKAGE_SYSCONF_DIR=\""$(sysconfdir)"\" \
Expand Down Expand Up @@ -51,7 +51,7 @@ libudisks2_btrfs_la_SOURCES = \
$(NULL)

libudisks2_btrfs_la_CPPFLAGS = \
$(CPPFLAGS) \
$(AM_CPPFLAGS) \
-DG_LOG_DOMAIN=\"libudisks2-btrfs\" \
$(NULL)

Expand Down
4 changes: 2 additions & 2 deletions modules/iscsi/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ SUBDIRS = data

NULL =

CPPFLAGS = \
AM_CPPFLAGS = \
-I$(top_builddir) -I$(top_srcdir) \
-DPACKAGE_LIBEXEC_DIR=\""$(libexecdir)"\" \
-DPACKAGE_SYSCONF_DIR=\""$(sysconfdir)"\" \
Expand Down Expand Up @@ -56,7 +56,7 @@ libudisks2_iscsi_la_SOURCES += \
endif # BUILD_ISCSI_SESSION_OBJECT

libudisks2_iscsi_la_CPPFLAGS = \
$(CPPFLAGS) \
$(AM_CPPFLAGS) \
-DG_LOG_DOMAIN=\"libudisks2-iscsi\" \
$(NULL)

Expand Down
4 changes: 2 additions & 2 deletions modules/lsm/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ SUBDIRS = data

NULL =

CPPFLAGS = \
AM_CPPFLAGS = \
-I$(top_builddir) -I$(top_srcdir) \
-DPACKAGE_LIBEXEC_DIR=\""$(libexecdir)"\" \
-DPACKAGE_SYSCONF_DIR=\""$(sysconfdir)"\" \
Expand Down Expand Up @@ -48,7 +48,7 @@ libudisks2_lsm_la_SOURCES = \
$(NULL)

libudisks2_lsm_la_CPPFLAGS = \
$(CPPFLAGS) \
$(AM_CPPFLAGS) \
-DG_LOG_DOMAIN=\"libudisks2-lsm\" \
$(NULL)

Expand Down
4 changes: 2 additions & 2 deletions modules/lvm2/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ SUBDIRS = data

NULL =

CPPFLAGS = \
AM_CPPFLAGS = \
-I$(top_builddir) -I$(top_srcdir) \
-DPACKAGE_LIBEXEC_DIR=\""$(libexecdir)"\" \
-DPACKAGE_SYSCONF_DIR=\""$(sysconfdir)"\" \
Expand Down Expand Up @@ -55,7 +55,7 @@ libudisks2_lvm2_la_SOURCES = \
$(NULL)

libudisks2_lvm2_la_CPPFLAGS = \
$(CPPFLAGS) \
$(AM_CPPFLAGS) \
-DG_LOG_DOMAIN=\"libudisks2-lvm2\" \
$(NULL)

Expand Down
Loading

0 comments on commit 83fc115

Please sign in to comment.