lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <87mt80g2fp.ffs@tglx>
Date:   Tue, 06 Dec 2022 13:08:10 +0100
From:   Thomas Gleixner <tglx@...utronix.de>
To:     "Rafael J. Wysocki" <rafael@...nel.org>, lirongqing@...du.com
Cc:     mingo@...hat.com, bp@...en8.de, dave.hansen@...ux.intel.com,
        x86@...nel.org, rafael@...nel.org, daniel.lezcano@...aro.org,
        peterz@...radead.org, akpm@...ux-foundation.org,
        tony.luck@...el.com, jpoimboe@...nel.org,
        linux-kernel@...r.kernel.org, linux-pm@...r.kernel.org
Subject: Re: [PATCH] cpuidle-haltpoll: Disable kvm guest polling when
 mwait_idle is used

On Tue, Dec 06 2022 at 12:59, Rafael J. Wysocki wrote:
> On Tue, Dec 6, 2022 at 7:43 AM <lirongqing@...du.com> wrote:
>>
>> +bool is_mwait_idle(void)
>> +{
>> +       return x86_idle == mwait_idle;
>> +}
>> +EXPORT_SYMBOL_GPL(is_mwait_idle);

No, this is just another adhoc check, which scratches ONE particular itch.

>> @@ -111,6 +112,9 @@ static int __init haltpoll_init(void)
>>         if (!kvm_para_available() || !haltpoll_want())
>>                 return -ENODEV;
>>
>> +       if (is_mwait_idle())
>> +               return -ENODEV;
>> +
>
> So perhaps you could make default_enter_idle() be a bit more careful
> about what it calls as the "default idle" routine?

Correct. arch_cpu_idle() is the one which should be called.

Thanks,

        tglx

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ