mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Christian Loehle <christian.loehle@arm.com>
To: Zhongqiu Han <quic_zhonhan@quicinc.com>,
	rafael@kernel.org, pavel@kernel.org, len.brown@intel.com
Cc: linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] PM: QoS: Add support for CPU affinity mask-based CPUs latency QoS
Date: Thu, 24 Apr 2025 11:25:19 +0100	[thread overview]
Message-ID: <31742ec7-c1c5-4cb9-8c13-a30b7a6033be@arm.com> (raw)
In-Reply-To: <20250424095228.1112558-1-quic_zhonhan@quicinc.com>

On 4/24/25 10:52, Zhongqiu Han wrote:
> Currently, the PM QoS framework supports global CPU latency QoS and
> per-device CPU latency QoS requests. An example of using global CPU
> latency QoS is a commit 2777e73fc154 ("scsi: ufs: core: Add CPU latency
> QoS support for UFS driver") that improved random io performance by 15%
> for ufs on specific device platform.
> 
> However, this prevents all CPUs in the system from entering C states.
> Typically, some threads or drivers know which specific CPUs they are
> interested in. For example, drivers with IRQ affinity only want interrupts
> to wake up and be handled on specific CPUs. Similarly, kernel thread bound
> to specific CPUs through affinity only care about the latency of those
> particular CPUs.
> 
> This patch introduces support for partial CPUs PM QoS using a CPU affinity
> mask, allowing flexible and more precise latency QoS settings for specific
> CPUs. This can help save power, especially on heterogeneous platforms with
> big and little cores, as well as some power-conscious embedded systems for
> example:
> 
>                   driver A       rt kthread B      module C
> QoS cpu mask:       0-3              2-5              6-7
> target latency:     20               30               50
>                     |                |                |
>                     v                v                v
>                     +---------------------------------+
>                     |        PM  QoS  Framework       |
>                     +---------------------------------+
>                     |                |                |
>                     v                v                v
> cpu mask:          0-3            2-3,4-5            6-7
> actual latency:    20             20, 30             50
> 
> Implement this support based on per-device CPU latency PM QoS.
> 
> Signed-off-by: Zhongqiu Han <quic_zhonhan@quicinc.com>

I like the idea!
The interface does need an in-tree user, why not convert the UFS driver?


  reply	other threads:[~2025-04-24 10:25 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-04-24  9:52 Zhongqiu Han
2025-04-24 10:25 ` Christian Loehle [this message]
2025-04-25 11:20   ` Zhongqiu Han
2025-04-25 10:17 ` kernel test robot
2025-04-25 11:10 ` kernel test robot
2025-04-25 11:10 ` kernel test robot

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=31742ec7-c1c5-4cb9-8c13-a30b7a6033be@arm.com \
    --to=christian.loehle@arm.com \
    --cc=len.brown@intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=pavel@kernel.org \
    --cc=quic_zhonhan@quicinc.com \
    --cc=rafael@kernel.org \
    /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

all inboxes | Powered by JetHome®