public inbox for linux-pm@vger.kernel.org
 help / color / mirror / Atom feed
From: David Arcari <darcari@redhat.com>
To: dedekind1@gmail.com, kernel test robot <lkp@intel.com>,
	linux-pm@vger.kernel.org
Cc: oe-kbuild-all@lists.linux.dev, Jonathan Corbet <corbet@lwn.net>,
	Jacob Pan <jacob.jun.pan@linux.intel.com>,
	Len Brown <lenb@kernel.org>, Prarit Bhargava <prarit@redhat.com>,
	linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v3] intel_idle: introduce 'no_native' module parameter
Date: Wed, 12 Feb 2025 07:53:40 -0500	[thread overview]
Message-ID: <1d2c943f-9521-4dc8-b798-06cbb84bb7dc@redhat.com> (raw)
In-Reply-To: <b7ed8d0b07e82a637bfc8a3f4d592f0f15ba9688.camel@gmail.com>



On 2/12/25 7:46 AM, Artem Bityutskiy wrote:
> On Wed, 2025-02-12 at 07:41 -0500, David Arcari wrote:
>> - #ifdef the code that doesn't compile
>> - default no_acpi=true in the !CONFIG_ACPI_PROCESSOR_CSTATE case
>>
>> I sort of like the second option better, but I worry about the
>> documentation.  Specifically:
>>
>> "In the case that ACPI is not configured these flags have no impact
>> +on functionality."
>>
>> I guess that is still true.
>>
>> Perhaps there is a better option.  What do you think?
> 
> I've not been involved into kernel that much for long time. In old days
> sprinkling #ifdefs around was an anti-pattern. Most probably nowadays too. So
> the second option sounds better to me.

Another option would be to change the offending code to a function call:

if (ignore_native()) {

And have ignore_native() always return false when ACPI is not configured.

And yes I should have built and tested the kernel with ACPI disabled. 
My apologies.

I will do that for v4.

-DA

> 
> Artem.
> 


  reply	other threads:[~2025-02-12 12:53 UTC|newest]

Thread overview: 32+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-01-28 14:11 [PATCH] intel_idle: introduce 'use_acpi_cst' module parameter David Arcari
2025-02-04 12:23 ` Artem Bityutskiy
2025-02-04 12:52   ` David Arcari
2025-02-04 13:04     ` Prarit Bhargava
2025-02-04 15:21     ` Rafael J. Wysocki
2025-02-04 16:30       ` Artem Bityutskiy
2025-02-04 17:33         ` Rafael J. Wysocki
2025-02-05 12:09           ` David Arcari
2025-02-04 16:26     ` Artem Bityutskiy
2025-02-06 16:40 ` [PATCH v2] intel_idle: introduce 'no_native' " David Arcari
2025-02-07 15:55   ` Artem Bityutskiy
2025-02-07 17:13     ` David Arcari
2025-02-08 10:37       ` Artem Bityutskiy
2025-02-08 19:56         ` David Arcari
2025-02-09  9:08           ` Artem Bityutskiy
2025-02-11 13:27 ` [PATCH v3] " David Arcari
2025-02-12  7:04   ` Artem Bityutskiy
2025-02-12 10:09   ` kernel test robot
2025-02-12 11:32     ` Artem Bityutskiy
2025-02-12 12:41       ` David Arcari
2025-02-12 12:46         ` Artem Bityutskiy
2025-02-12 12:53           ` David Arcari [this message]
2025-02-12 12:49         ` Artem Bityutskiy
2025-02-13 11:49   ` kernel test robot
2025-02-13 16:07 ` [PATCH v4] " David Arcari
2025-02-18 19:57   ` Rafael J. Wysocki
2025-02-20 12:50     ` Artem Bityutskiy
2025-02-19 21:27   ` Rafael J. Wysocki
2025-02-20 12:21     ` David Arcari
2025-02-20 12:23       ` Rafael J. Wysocki
2025-02-20 15:11 ` [PATCH v5] " David Arcari
2025-02-20 20:02   ` Rafael J. Wysocki

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1d2c943f-9521-4dc8-b798-06cbb84bb7dc@redhat.com \
    --to=darcari@redhat.com \
    --cc=corbet@lwn.net \
    --cc=dedekind1@gmail.com \
    --cc=jacob.jun.pan@linux.intel.com \
    --cc=lenb@kernel.org \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=lkp@intel.com \
    --cc=oe-kbuild-all@lists.linux.dev \
    --cc=prarit@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox