On Wed, Dec 28, 2022 at 6:36 PM Jim Mattson <jmattson@xxxxxxxxxx> wrote: > > On Tue, Dec 27, 2022 at 2:05 PM Aaron Lewis <aaronlewis@xxxxxxxxxx> wrote: > > > > The check in amx_test that ensures that XSAVE supports XTILE, doesn't > > actually check anything. It simply returns a bool which the test does > > nothing with. > > Additionally, the check ensures that at least one of the XTILE bits are > > set, XTILECFG or XTILEDATA, when it really should be checking that both > > are set. > > > > Change both behaviors to: > > 1) Asserting if the check fails. > > 2) Fail if both XTILECFG and XTILEDATA aren't set. > > For (1), why not simply undo the damage caused by commit 5dc19f1c7dd3 > ("KVM: selftests: Convert AMX test to use X86_PROPRETY_XXX"), and > restore the GUEST_ASSERT() at the call site? I opted to add the assert in the check call to be consistent with the others. I thought it would look odd to have 3 check calls being called one after the other, where 2 of them made the call and did nothing with the result and 1 was wrapped in an assert. > Should this be two separate changes, since there are two separate bug fixes? Sure, splitting this into two commits SGTM.