summaryrefslogtreecommitdiff
path: root/src/shared/loop-util.h
diff options
context:
space:
mode:
authorYu Watanabe <watanabe.yu+github@gmail.com>2022-09-06 04:35:54 +0900
committerYu Watanabe <watanabe.yu+github@gmail.com>2022-09-06 11:26:00 +0900
commitcc5bae6cc27ba85a6efa5331fabb4c7447186e52 (patch)
tree74c1f9e90017b1dd4b895b1aae393f57373c12c1 /src/shared/loop-util.h
parent802e7f72341a8c7a2e4c9a50d3853d5c64c7ecec (diff)
downloadsystemd-cc5bae6cc27ba85a6efa5331fabb4c7447186e52.tar.gz
loop-util: store sd_device object for the loop device
It will be used in later commits.
Diffstat (limited to 'src/shared/loop-util.h')
-rw-r--r--src/shared/loop-util.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/shared/loop-util.h b/src/shared/loop-util.h
index 89fcbc00a0..43bd25d445 100644
--- a/src/shared/loop-util.h
+++ b/src/shared/loop-util.h
@@ -1,6 +1,8 @@
/* SPDX-License-Identifier: LGPL-2.1-or-later */
#pragma once
+#include "sd-device.h"
+
#include "macro.h"
#include "time-util.h"
@@ -14,6 +16,7 @@ struct LoopDevice {
int nr; /* The loopback device index (i.e. 4 for /dev/loop4); if this object encapsulates a non-loopback block device, set to -1 */
dev_t devno;
char *node;
+ sd_device *dev;
bool relinquished;
uint64_t diskseq; /* Block device sequence number, monothonically incremented by the kernel on create/attach, or 0 if we don't know */
uint64_t uevent_seqnum_not_before; /* uevent sequm right before we attached the loopback device, or UINT64_MAX if we don't know */