Skip to content

Commit

Permalink
selftests/powerpc: Update PROT_SAO test to skip ISA 3.1
Browse files Browse the repository at this point in the history
Since SAO support was removed from ISA 3.1, skip the
prot_sao test if PPC_FEATURE2_ARCH_3_1 is set.

Signed-off-by: Shawn Anastasio <[email protected]>
Signed-off-by: Michael Ellerman <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
  • Loading branch information
shawnanastasio authored and mpe committed Aug 24, 2020
1 parent 9b725a9 commit 24ded46
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions tools/testing/selftests/powerpc/mm/prot_sao.c
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,9 @@ int test_prot_sao(void)
{
char *p;

/* 2.06 or later should support SAO */
SKIP_IF(!have_hwcap(PPC_FEATURE_ARCH_2_06));
/* SAO was introduced in 2.06 and removed in 3.1 */
SKIP_IF(!have_hwcap(PPC_FEATURE_ARCH_2_06) ||
have_hwcap2(PPC_FEATURE2_ARCH_3_1));

/*
* Ensure we can ask for PROT_SAO.
Expand Down

0 comments on commit 24ded46

Please sign in to comment.