mirror of
https://github.com/systemd/systemd
synced 2024-07-01 07:34:28 +00:00
Compare commits
15 Commits
6b9c98e825
...
2921e1cf98
Author | SHA1 | Date | |
---|---|---|---|
|
2921e1cf98 | ||
|
713e68b13c | ||
|
0e445aaa85 | ||
|
1c74db68e4 | ||
|
436474dd43 | ||
|
f392be9e77 | ||
|
3cf38516bb | ||
|
7c04137a6f | ||
|
98f2a332cb | ||
|
24284098a4 | ||
|
72d121b601 | ||
|
3cdc8da5ad | ||
|
32f3617fd7 | ||
|
4e469c0af2 | ||
|
7f07f9c8cd |
|
@ -57,6 +57,7 @@ Packages=
|
|||
opensc
|
||||
openssl
|
||||
p11-kit
|
||||
pciutils
|
||||
python3
|
||||
qrencode
|
||||
radvd
|
||||
|
|
|
@ -2574,8 +2574,10 @@ static int context_load_partition_table(Context *context) {
|
|||
/* If we found the sector size and we're operating on a block device, use it as the file
|
||||
* system sector size as well, as we know its the sector size of the actual block device and
|
||||
* not just the offset at which we found the GPT header. */
|
||||
if (r > 0 && S_ISBLK(st.st_mode))
|
||||
if (r > 0 && S_ISBLK(st.st_mode)) {
|
||||
log_debug("Probed sector size of %s is %" PRIu32 " bytes.", context->node, ssz);
|
||||
fs_secsz = ssz;
|
||||
}
|
||||
}
|
||||
|
||||
r = fdisk_save_user_sector_size(c, /* phy= */ 0, ssz);
|
||||
|
@ -2639,7 +2641,7 @@ static int context_load_partition_table(Context *context) {
|
|||
* larger */
|
||||
grainsz = secsz < 4096 ? 4096 : secsz;
|
||||
|
||||
log_debug("Sector size of device is %lu bytes. Using grain size of %" PRIu64 ".", secsz, grainsz);
|
||||
log_debug("Sector size of device is %lu bytes. Using filesystem sector size of %" PRIu64 " and grain size of %" PRIu64 ".", secsz, fs_secsz, grainsz);
|
||||
|
||||
switch (arg_empty) {
|
||||
|
||||
|
|
|
@ -33,11 +33,7 @@ int read_smbios11_field(unsigned i, size_t max_size, char **ret_data, size_t *re
|
|||
|
||||
assert_cc(offsetof(struct dmi_field_header, contents) == 5);
|
||||
|
||||
r = read_virtual_file(
|
||||
p,
|
||||
max_size >= SIZE_MAX - offsetof(struct dmi_field_header, contents) ? SIZE_MAX :
|
||||
sizeof(dmi_field_header) + max_size,
|
||||
(char**) &data, &size);
|
||||
r = read_full_file_full(AT_FDCWD, p, /* offset = */ 0, max_size, /* flags = */ 0, NULL, (char**) &data, &size);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
integration_tests += [
|
||||
integration_test_template + {
|
||||
'name' : fs.name(meson.current_source_dir()),
|
||||
'cmdline' : integration_test_template['cmdline'] + ['selinux=1', 'lsm=selinux'],
|
||||
'cmdline' : integration_test_template['cmdline'] + ['systemd.wants=autorelabel.service', 'selinux=1', 'lsm=selinux'],
|
||||
# FIXME; Figure out why reboot sometimes hangs with 'linux' firmware.
|
||||
# Use 'auto' to automatically fallback on non-uefi architectures.
|
||||
'firmware' : 'auto',
|
||||
|
|
|
@ -4,5 +4,8 @@ integration_tests += [
|
|||
integration_test_template + {
|
||||
'name' : fs.name(meson.current_source_dir()),
|
||||
'storage' : 'persistent',
|
||||
# FIXME: Figure out why reboot sometimes hangs with 'linux' firmware.
|
||||
# Use 'auto' to automatically fallback on non-uefi architectures.
|
||||
'firmware' : 'auto',
|
||||
},
|
||||
]
|
||||
|
|
|
@ -3,5 +3,8 @@
|
|||
integration_tests += [
|
||||
integration_test_template + {
|
||||
'name' : fs.name(meson.current_source_dir()),
|
||||
# FIXME: Figure out why reboot sometimes hangs with 'linux' firmware.
|
||||
# Use 'auto' to automatically fallback on non-uefi architectures.
|
||||
'firmware' : 'auto',
|
||||
},
|
||||
]
|
||||
|
|
|
@ -27,5 +27,6 @@ integration_tests += [
|
|||
'-smbios', 'type=11,value=io.systemd.credential.binary:fstab.extra=aW5qZWN0ZWQgL2luamVjdGVkIHRtcGZzIFgtbW91bnQubWtkaXIgMCAwCg==',
|
||||
'-smbios', 'type=11,value=io.systemd.credential:getty.ttys.container=idontexist',
|
||||
],
|
||||
'firmware' : 'auto',
|
||||
},
|
||||
]
|
||||
|
|
|
@ -23,10 +23,9 @@ config["QemuArgs"] += ["-device", "pci-bridge,id=pci_bridge0,chassis_nr=64"]
|
|||
for bridge in range(1, 26):
|
||||
config["QemuArgs"] += [
|
||||
"-device",
|
||||
f"pci-bridge,id=pci_bridge{bridge},bus=pci_bridge{bridge - 1},"
|
||||
f"chassis_nr={64 + bridge}"
|
||||
f"pci-bridge,id=pci_bridge{bridge},bus=pci_bridge{bridge - 1},chassis_nr={64 + bridge},addr=1",
|
||||
]
|
||||
|
||||
config["QemuArgs"] += ["-device", f"virtio-blk-pci,drive=drive0,scsi=off,bus=pci_bridge25"]
|
||||
config["QemuArgs"] += ["-device", f"virtio-blk-pci,drive=drive0,scsi=off,bus=pci_bridge25,addr=1"]
|
||||
|
||||
json.dump(config, sys.stdout)
|
||||
|
|
|
@ -9,8 +9,8 @@ import sys
|
|||
|
||||
config = json.load(sys.stdin)
|
||||
|
||||
qemu = f"qemu-system-{os.environ["QEMU_ARCHITECTURE"]}"
|
||||
result = subprocess.run([qemu, '-device', 'help'], check=True, text=True, stdout=subprocess.PIPE)
|
||||
qemu = f"qemu-system-{os.environ['QEMU_ARCHITECTURE']}"
|
||||
result = subprocess.run([qemu, "-device", "help"], check=True, text=True, stdout=subprocess.PIPE)
|
||||
if 'name "nvme"' not in result.stdout:
|
||||
print("nvme device driver is not available, skipping test...", file=sys.stderr)
|
||||
exit(77)
|
||||
|
|
|
@ -9,8 +9,8 @@ import sys
|
|||
|
||||
config = json.load(sys.stdin)
|
||||
|
||||
qemu = f"qemu-system-{os.environ["QEMU_ARCHITECTURE"]}"
|
||||
result = subprocess.run([qemu, '-device', 'help'], check=True, text=True, stdout=subprocess.PIPE)
|
||||
qemu = f"qemu-system-{os.environ['QEMU_ARCHITECTURE']}"
|
||||
result = subprocess.run([qemu, "-device", "help"], check=True, text=True, stdout=subprocess.PIPE)
|
||||
if 'name "nvme"' not in result.stdout:
|
||||
print("nvme device driver is not available, skipping test...", file=sys.stderr)
|
||||
exit(77)
|
||||
|
|
|
@ -9,8 +9,8 @@ import sys
|
|||
|
||||
config = json.load(sys.stdin)
|
||||
|
||||
qemu = f"qemu-system-{os.environ["QEMU_ARCHITECTURE"]}"
|
||||
result = subprocess.run([qemu, '-device', 'help'], check=True, text=True, stdout=subprocess.PIPE)
|
||||
qemu = f"qemu-system-{os.environ['QEMU_ARCHITECTURE']}"
|
||||
result = subprocess.run([qemu, "-device", "help"], check=True, text=True, stdout=subprocess.PIPE)
|
||||
if 'name "virtio-scsi-pci"' not in result.stdout:
|
||||
print("virtio-scsi-pci device driver is not available, skipping test...", file=sys.stderr)
|
||||
exit(77)
|
||||
|
|
|
@ -8,5 +8,6 @@ integration_tests += [
|
|||
'after' : '@0@ tpm2.target'.format(integration_test_template['configuration']['after']),
|
||||
},
|
||||
'vm' : true,
|
||||
'firmware' : 'auto',
|
||||
},
|
||||
]
|
||||
|
|
|
@ -103,6 +103,12 @@ def main():
|
|||
journal_file = (args.meson_build_dir / (f"test/journal/{name}.journal")).absolute()
|
||||
journal_file.unlink(missing_ok=True)
|
||||
else:
|
||||
dropin += textwrap.dedent(
|
||||
"""
|
||||
[Unit]
|
||||
Wants=multi-user.target
|
||||
"""
|
||||
)
|
||||
journal_file = None
|
||||
|
||||
cmd = [
|
||||
|
|
|
@ -218,7 +218,7 @@ assert_ntp() {
|
|||
assert_timedated_signal() {
|
||||
local timestamp="${1:?}"
|
||||
local value="${2:?}"
|
||||
local args=(-q -n 1 --since="$timestamp" -p info _SYSTEMD_UNIT="busctl-monitor.service")
|
||||
local args=(-q -n 1 --since="$timestamp" -p info -t busctl)
|
||||
|
||||
journalctl --sync
|
||||
|
||||
|
@ -298,7 +298,7 @@ assert_timesyncd_signal() {
|
|||
local timestamp="${1:?}"
|
||||
local property="${2:?}"
|
||||
local value="${3:?}"
|
||||
local args=(-q --since="$timestamp" -p info _SYSTEMD_UNIT="busctl-monitor.service")
|
||||
local args=(-q --since="$timestamp" -p info -t busctl)
|
||||
|
||||
journalctl --sync
|
||||
|
||||
|
|
|
@ -231,8 +231,8 @@ testcase_nvme_subsystem() {
|
|||
/dev/disk/by-id/nvme-QEMU_NVMe_Ctrl_deadbeef_16
|
||||
/dev/disk/by-id/nvme-QEMU_NVMe_Ctrl_deadbeef_17
|
||||
# Shared namespaces
|
||||
/dev/disk/by-path/pci-*-nvme-16
|
||||
/dev/disk/by-path/pci-*-nvme-17
|
||||
/dev/disk/by-path/*pci*-nvme-16
|
||||
/dev/disk/by-path/*pci*-nvme-17
|
||||
)
|
||||
|
||||
udevadm wait --settle --timeout=30 "${expected_symlinks[@]}"
|
||||
|
|
Loading…
Reference in New Issue
Block a user