On Sunday 13 June 2010 16:43:42 Avi Kivity wrote:
> On 06/13/2010 11:32 AM, Sheng Yang wrote:
> > Based on IDT test framework.
> > +
> > +int main(void)
> > +{
> > +    setup_idt();
> > +    if (check_cpuid_1_ecx(CPUID_1_ECX_XSAVE)) {
> > +        printf("CPU has XSAVE feature\n");
> > +        test_xsave();
> > +    } else {
> > +        printf("CPU don't has XSAVE feature\n");
> > +        test_no_xsave();
> > +    }
> > +    printf("Total test: %d\n", total_tests);
> > +    if (fail_tests == 0)
> > +        printf("ALL PASS!\n");
> > +    else {
> > +        printf("Fail %d tests.\n", fail_tests);
> > +        return 0;
> > +    }
> > +    return 1;
> > +}
> 
> Wrong way, 0 = success, !0 = fail (just like shell exit codes).

Indeed oops. Finally checked your first comment to this test case patch, and 
found 
I completely misread it...

--
regards
Yang, Sheng
--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to