Skip to content

Commit

Permalink
Ignore test_disable_enable_perf_events and `test_get_set_thp_disabl…
Browse files Browse the repository at this point in the history
…e` on Loongarch64 QEMU
  • Loading branch information
Fearyncess committed Sep 22, 2024
1 parent d4a765e commit 6e1dfcc
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions test/sys/test_prctl.rs
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,10 @@ mod test_prctl {
prctl::set_timerslack(original).unwrap();
}

// Loongarch need to use a newer QEMU that disabled these PRCTL subcodes/methods.
// https://github.com/qemu/qemu/commit/220717a6f46a99031a5b1af964bbf4dec1310440
// So we should ignore them when testing in QEMU environments.
#[cfg_attr(all(qemu, target_arch = "loongarch64"), ignore)]
#[test]
fn test_disable_enable_perf_events() {
prctl::task_perf_events_disable().unwrap();
Expand All @@ -112,6 +116,10 @@ mod test_prctl {
assert!(no_new_privs);
}

// Loongarch need to use a newer QEMU that disabled these PRCTL subcodes/methods
// https://github.com/qemu/qemu/commit/220717a6f46a99031a5b1af964bbf4dec1310440
// So we should ignore them when testing in QEMU environments.
#[cfg_attr(all(qemu, target_arch = "loongarch64"), ignore)]
#[test]
fn test_get_set_thp_disable() {
let original = prctl::get_thp_disable().unwrap();
Expand Down

0 comments on commit 6e1dfcc

Please sign in to comment.