Skip to content

Commit b64816b

Browse files
committed
Ignore test_disable_enable_perf_events and test_get_set_thp_disable on Loongarch64 QEMU
1 parent 5fca3eb commit b64816b

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

test/sys/test_prctl.rs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -99,6 +99,9 @@ mod test_prctl {
9999
prctl::set_timerslack(original).unwrap();
100100
}
101101

102+
// Loongarch need to use a newer QEMU that disabled these PRCTL subcodes/methods.
103+
// So we should ignore them when testing in QEMU environments.
104+
#[cfg_attr(all(qemu, target_arch = "loongarch64"), ignore)]
102105
#[test]
103106
fn test_disable_enable_perf_events() {
104107
prctl::task_perf_events_disable().unwrap();
@@ -112,6 +115,9 @@ mod test_prctl {
112115
assert!(no_new_privs);
113116
}
114117

118+
// Loongarch need to use a newer QEMU that disabled these PRCTL subcodes/methods
119+
// So we should ignore them when testing in QEMU environments.
120+
#[cfg_attr(all(qemu, target_arch = "loongarch64"), ignore)]
115121
#[test]
116122
fn test_get_set_thp_disable() {
117123
let original = prctl::get_thp_disable().unwrap();

0 commit comments

Comments
 (0)