From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 39F9645B38; Mon, 14 Oct 2024 17:27:30 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id C8DA64027F; Mon, 14 Oct 2024 17:27:29 +0200 (CEST) Received: from mail-pl1-f177.google.com (mail-pl1-f177.google.com [209.85.214.177]) by mails.dpdk.org (Postfix) with ESMTP id 1877840151 for ; Mon, 14 Oct 2024 17:27:28 +0200 (CEST) Received: by mail-pl1-f177.google.com with SMTP id d9443c01a7336-20cdda5cfb6so12889465ad.3 for ; Mon, 14 Oct 2024 08:27:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20230601.gappssmtp.com; s=20230601; t=1728919647; x=1729524447; darn=dpdk.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:subject:cc:to:from:date:from:to:cc:subject:date :message-id:reply-to; bh=95tBa4tlYYuoTJZAOtOjbHC2K+r8hqAZyhDpzcRUTZk=; b=jAhTrAJ8q9x95srPjb6hHustG8leqevz4Cc4X/oOByVQEI0yeLQx0zLsvmHoTx0F1d /pcUohrfOR+y1hWTTqhpBWngNSTH5a1K1Dq69pcOG8lnY/0tMCkncbzwJfyfMCsWEbAj Zus6KrKwOvAYZPU4XMF8sGXptEj6dFxiBNd5oZqtwrjpjjj7DJ/HE4a850ZEedny8Ppn 3YWujGL3+pKw6c7DdYrIwAPI3uIn0AOu/vWIT4SR+uCJBXvXLsrh4US9J5ioErj+aZBU zPcwh76PNr6fE5/SgsZMvelZOVNylCQ1UaB3e9VYPtfvbjY36ubjJoM96S+XJhgzf3fc 2s9g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1728919647; x=1729524447; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:subject:cc:to:from:date:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=95tBa4tlYYuoTJZAOtOjbHC2K+r8hqAZyhDpzcRUTZk=; b=T9kGJ61q9Lj7ZU0/EfGSHz3DDOkywvgnnIx8wMDirFwjopqWtK9eue5Cx8tT811ePD FWSgSPPPmQ+in1my37g1VwIfEcecav5KeGJ8abXmB/HaIxtoNSGuPG0Jb0IWICYuhysg /PnDuFm2KpzmYqmer9hrlDtGmTOwppgD9cuMFqyfqhAni2DgZMvFugYyS4af9RIDoteq ArdzIn10Utsmp/MV8Ri43k1P0R24SdYAtqf7F1j9tlm/KkCqqhuTsLN6sboo8tVvFBPx gXieEEJhXNQHfqOyBamRa/fvPsU0fkwmPF31EUz58bM8BtIS8QKaBwLbZv/pd6zsNWdu mUnA== X-Gm-Message-State: AOJu0YzNN/Sacvqe7eFHQDth3Qal1aCwL4okzl/DHbqr5ZLjuuZxN98Y Hy7x0hW7LL2/+iobysN4sGY6jboJcdsPsvXz9oqrgFBilR5tMpbkJpWJ5mhELhU= X-Google-Smtp-Source: AGHT+IH9MzZRmKCAZwLemgq7sG61dehCyQYTH5ge1ABlk9zvwLL+Gtf+oTt11vmQawqsdp15+x5UxQ== X-Received: by 2002:a17:903:244e:b0:20c:bbac:2013 with SMTP id d9443c01a7336-20cbbac21bamr146043935ad.48.1728919647286; Mon, 14 Oct 2024 08:27:27 -0700 (PDT) Received: from hermes.local (204-195-96-226.wavecable.com. [204.195.96.226]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-20c8bad324csm67322115ad.1.2024.10.14.08.27.26 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 14 Oct 2024 08:27:27 -0700 (PDT) Date: Mon, 14 Oct 2024 08:27:25 -0700 From: Stephen Hemminger To: Huisong Li Cc: , , , , , , , , , Subject: Re: [PATCH v10 0/2] power: introduce PM QoS interface Message-ID: <20241014082725.325b327e@hermes.local> In-Reply-To: <20240912023812.30885-1-lihuisong@huawei.com> References: <20240320105529.5626-1-lihuisong@huawei.com> <20240912023812.30885-1-lihuisong@huawei.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org On Thu, 12 Sep 2024 10:38:10 +0800 Huisong Li wrote: > The deeper the idle state, the lower the power consumption, but the longer > the resume time. Some service are delay sensitive and very except the low > resume time, like interrupt packet receiving mode. > > And the "/sys/devices/system/cpu/cpuX/power/pm_qos_resume_latency_us" sysfs > interface is used to set and get the resume latency limit on the cpuX for > userspace. Please see the description in kernel document[1]. > Each cpuidle governor in Linux select which idle state to enter based on > this CPU resume latency in their idle task. > > The per-CPU PM QoS API can be used to control this CPU's idle state > selection and limit just enter the shallowest idle state to low the delay > after sleep by setting strict resume latency (zero value). > > [1] https://www.kernel.org/doc/html/latest/admin-guide/abi-testing.html?highlight=pm_qos_resume_latency_us#abi-sys-devices-power-pm-qos-resume-latency-us This is not a direct critique of this patch. The power library should have been designed to take a single configuration structure specifying CPU frequencies, wake up latency, and all the parameters from the kernel. And there would be a simple API with: rte_power_config_set() and rte_power_config_get().