代码拉取完成,页面将自动刷新
同步操作将从 src-openEuler/systemd 强制同步,此操作会覆盖自 Fork 仓库以来所做的任何修改,且无法恢复!!!
确定后同步将在后台操作,完成时将刷新页面,请耐心等待。
diff --git a/src/basic/virt.c b/src/basic/virt.c
index 7e88f09..de1acf1 100644
--- a/src/basic/virt.c
+++ b/src/basic/virt.c
@@ -140,7 +140,7 @@ static int detect_vm_device_tree(void) {
#endif
}
-#if defined(__i386__) || defined(__x86_64__) || defined(__arm__) || defined(__aarch64__)
+#if defined(__i386__) || defined(__x86_64__) || defined(__arm__) || defined(__aarch64__) || defined(__loongarch64)
static int detect_vm_dmi_vendor(void) {
static const char *const dmi_vendors[] = {
"/sys/class/dmi/id/product_name", /* Test this before sys_vendor to detect KVM over QEMU */
@@ -225,10 +225,10 @@ static int detect_vm_smbios(void) {
log_debug("DMI BIOS Extension table does not indicate virtualization.");
return SMBIOS_VM_BIT_UNSET;
}
-#endif /* defined(__i386__) || defined(__x86_64__) || defined(__arm__) || defined(__aarch64__) */
+#endif /* defined(__i386__) || defined(__x86_64__) || defined(__arm__) || defined(__aarch64__) || defined(__loongarch64) */
static int detect_vm_dmi(void) {
-#if defined(__i386__) || defined(__x86_64__) || defined(__arm__) || defined(__aarch64__)
+#if defined(__i386__) || defined(__x86_64__) || defined(__arm__) || defined(__aarch64__) || defined(__loongarch64)
int r;
r = detect_vm_dmi_vendor();
diff --git a/src/test/test-execute.c b/src/test/test-execute.c
index 125e0bb..6e168d3 100644
--- a/src/test/test-execute.c
+++ b/src/test/test-execute.c
@@ -284,6 +284,8 @@ static void test_exec_personality(Manager *m) {
#elif defined(__i386__)
test(m, "exec-personality-x86.service", 0, CLD_EXITED);
+#elif defined(__loongarch64)
+ test(m, "exec-personality-loongarch64.service", 0, CLD_EXITED);
#else
log_notice("Unknown personality, skipping %s", __func__);
#endif
diff --git a/src/udev/meson.build b/src/udev/meson.build
index 4e80f9b..f2eb0b2 100644
--- a/src/udev/meson.build
+++ b/src/udev/meson.build
@@ -129,7 +129,7 @@ udev_id_progs = [['ata_id/ata_id.c'],
'mtd_probe/mtd_probe.h',
'mtd_probe/probe_smartmedia.c']]
-dmi_arches = ['x86', 'x86_64', 'aarch64', 'arm', 'ia64', 'mips']
+dmi_arches = ['x86', 'x86_64', 'aarch64', 'arm', 'ia64', 'loongarch64', 'mips']
if dmi_arches.contains(host_machine.cpu_family())
udev_id_progs += [['dmi_memory_id/dmi_memory_id.c']]
endif
diff --git a/test/test-execute/exec-personality-loongarch64.service b/test/test-execute/exec-personality-loongarch64.service
new file mode 100644
index 0000000..0531ad1
--- /dev/null
+++ b/test/test-execute/exec-personality-loongarch64.service
@@ -0,0 +1,7 @@
+[Unit]
+Description=Test for Personality=loongarch64
+
+[Service]
+ExecStart=/bin/sh -c 'echo $(uname -m); exit $(test $(uname -m) = "loongarch64")'
+Type=oneshot
+Personality=loongarch64
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。