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 498E845BA6; Wed, 23 Oct 2024 03:40:44 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 001234026C; Wed, 23 Oct 2024 03:40:43 +0200 (CEST) Received: from mail-pj1-f46.google.com (mail-pj1-f46.google.com [209.85.216.46]) by mails.dpdk.org (Postfix) with ESMTP id 03AB240151 for ; Wed, 23 Oct 2024 03:40:42 +0200 (CEST) Received: by mail-pj1-f46.google.com with SMTP id 98e67ed59e1d1-2e3fca72a41so4283714a91.1 for ; Tue, 22 Oct 2024 18:40:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20230601.gappssmtp.com; s=20230601; t=1729647642; x=1730252442; 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=eSO92wNfU0HBdVIKrN8lNvyOpOmLLHL3mf120jE6Ma8=; b=pUflc+v3coWeGXznHGep4vEsKpdkn9AOxiRD27KpgI0ND9JUB+TqUX1PRT0wptbV+0 86VKW69i+RqC4jWzyJZcnVYjM9IZANB+sBRZIQrNaj6CaFSt0LMuAdtrvUHIegfcIVWD hl2QuaulGJ+sh1p3YkTDkY3EdH3X3cAaEfFRM1wAv9Icba1288VbrgaXpHE45SOsAI8G mUKvadpsnyrnYosF7BR/stHMNluytJI7Eb/gUdLIGJ9z2fxeuFSiB65uCcUw/z0su7Dj iWAe+X2LtMkTDeucyf+oOahd/hbUAtW1VewUBwZvDSSP8zOy45rMcoq73OHBEIekYDvX 2OQQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1729647642; x=1730252442; 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=eSO92wNfU0HBdVIKrN8lNvyOpOmLLHL3mf120jE6Ma8=; b=kMYAChuEA9RXPNph3mkxnubbyNbppd1aFajX7IAcJkS7b9zbHzppnWYB4EQDZhUvtF VrSVaAx8OhjSJSXREcw5Ds3Xipp8aZTFz7L6ow3r1P6SY6+05iuWWSY6gV47+faYLVnE lUpfUvD0kmm8eDl5W7werSWr79+yjsrHsVI+1Vl4EOIbdsxQX+F5l4NooYpCO5dM3Rfb 9LqryHxWE9MHy0CZqWXDsvn95+K6TXkbj7MDu8OdHVpNzbNvyBFJPxD5+eKfdSAaAxVt 1v/t5S5Pg+1eVKlUaWMnE4iUtfyBoXoVjP2sZN/z4q1UVIUQCDJyN24pEdO76Xx5FY7d BDuQ== X-Forwarded-Encrypted: i=1; AJvYcCW950jP2q3xh3GVPC4h8m8MRcw0c7MXr4qatt38vnapZf3RyBcMco6n9CH8YZJJMI5n1jc=@dpdk.org X-Gm-Message-State: AOJu0YwOLVIA4yYO+M5HCpX3tSVwMT7QKg7nRbPxVnXC8KepoKndmNU+ BsM0AGgQnbcx/k+rnxeUl7Jv4k8hOQPj5A6OoYXGhKAR7YLWvvwMMh9Bs9KK34w= X-Google-Smtp-Source: AGHT+IFnJk9sojxfLRIeYv+a/rBp4eNSIhxDyG/rc/Uq1XLfkMLSg82gkuqIv79qYMByty2lcusO6w== X-Received: by 2002:a17:90a:17ec:b0:2e2:8f39:98d9 with SMTP id 98e67ed59e1d1-2e76b60d989mr1058457a91.18.1729647642030; Tue, 22 Oct 2024 18:40:42 -0700 (PDT) Received: from hermes.local (204-195-96-226.wavecable.com. [204.195.96.226]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-2e76dfdfb4asm147732a91.50.2024.10.22.18.40.41 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 22 Oct 2024 18:40:41 -0700 (PDT) Date: Tue, 22 Oct 2024 18:40:39 -0700 From: Stephen Hemminger To: Sivaprasad Tummala Cc: , , , , , , , , , Subject: Re: [PATCH v8 0/6] power: refactor power management library Message-ID: <20241022184039.1250a5bf@hermes.local> In-Reply-To: <20241022184133.700367-1-sivaprasad.tummala@amd.com> References: <20241021040724.3325876-1-sivaprasad.tummala@amd.com> <20241022184133.700367-1-sivaprasad.tummala@amd.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 Tue, 22 Oct 2024 18:41:26 +0000 Sivaprasad Tummala wrote: > This patchset refactors the power management library, addressing both > core and uncore power management. The primary changes involve the > creation of dedicated directories for each driver within > 'drivers/power/core/*' and 'drivers/power/uncore/*'. > > This refactor significantly improves code organization, enhances > clarity, and boosts maintainability. It lays the foundation for more > focused development on individual drivers and facilitates seamless > integration of future enhancements, particularly the AMD uncore driver. > > Furthermore, this effort aims to streamline code maintenance by > consolidating common functions for cpufreq and cppc across various > core drivers, thus reducing code duplication. > > Sivaprasad Tummala (6): > power: refactor core power management library > power: refactor uncore power management library > test/power: removed function pointer validations > drivers/power: uncore support for AMD EPYC processors > maintainers: update for drivers/power > power: rename library sources for cpu frequency management > > MAINTAINERS | 1 + > app/test/test_power.c | 97 +----- > app/test/test_power_cpufreq.c | 54 +-- > app/test/test_power_kvm_vm.c | 38 +- > drivers/meson.build | 1 + > .../power/acpi/acpi_cpufreq.c | 22 +- > .../power/acpi/acpi_cpufreq.h | 6 +- > drivers/power/acpi/meson.build | 10 + > .../power/amd_pstate/amd_pstate_cpufreq.c | 24 +- > .../power/amd_pstate/amd_pstate_cpufreq.h | 10 +- > drivers/power/amd_pstate/meson.build | 10 + > drivers/power/amd_uncore/amd_uncore.c | 329 ++++++++++++++++++ > drivers/power/amd_uncore/amd_uncore.h | 225 ++++++++++++ > drivers/power/amd_uncore/meson.build | 20 ++ > .../power/cppc/cppc_cpufreq.c | 22 +- > .../power/cppc/cppc_cpufreq.h | 8 +- > drivers/power/cppc/meson.build | 10 + > .../power/intel_uncore/intel_uncore.c | 18 +- > .../power/intel_uncore/intel_uncore.h | 9 +- > drivers/power/intel_uncore/meson.build | 6 + > .../power/kvm_vm}/guest_channel.c | 2 +- > .../power/kvm_vm}/guest_channel.h | 0 > .../power/kvm_vm/kvm_vm.c | 22 +- > .../power/kvm_vm/kvm_vm.h | 6 +- > drivers/power/kvm_vm/meson.build | 14 + > drivers/power/meson.build | 14 + > drivers/power/pstate/meson.build | 10 + > .../power/pstate/pstate_cpufreq.c | 22 +- > .../power/pstate/pstate_cpufreq.h | 6 +- > examples/distributor/main.c | 2 +- > examples/l3fwd-power/main.c | 14 +- > examples/l3fwd-power/perf_core.c | 2 +- > examples/vm_power_manager/channel_monitor.c | 2 +- > examples/vm_power_manager/channel_monitor.h | 2 +- > examples/vm_power_manager/guest_cli/main.c | 2 +- > .../guest_cli/vm_power_cli_guest.c | 2 +- > examples/vm_power_manager/power_manager.c | 2 +- > lib/power/meson.build | 13 +- > lib/power/power_common.c | 2 +- > lib/power/power_common.h | 18 +- > lib/power/power_cpufreq.h | 191 ++++++++++ > lib/power/power_uncore_ops.h | 244 +++++++++++++ > lib/power/rte_power.c | 257 -------------- > lib/power/rte_power_cpufreq.c | 230 ++++++++++++ > .../{rte_power.h => rte_power_cpufreq.h} | 120 ++++--- > lib/power/rte_power_pmd_mgmt.h | 2 +- > lib/power/rte_power_uncore.c | 256 +++++++------- > lib/power/rte_power_uncore.h | 61 ++-- > lib/power/version.map | 15 + > 49 files changed, 1746 insertions(+), 707 deletions(-) > rename lib/power/power_acpi_cpufreq.c => drivers/power/acpi/acpi_cpufreq.c (95%) > rename lib/power/power_acpi_cpufreq.h => drivers/power/acpi/acpi_cpufreq.h (98%) > create mode 100644 drivers/power/acpi/meson.build > rename lib/power/power_amd_pstate_cpufreq.c => drivers/power/amd_pstate/amd_pstate_cpufreq.c (95%) > rename lib/power/power_amd_pstate_cpufreq.h => drivers/power/amd_pstate/amd_pstate_cpufreq.h (96%) > create mode 100644 drivers/power/amd_pstate/meson.build > create mode 100644 drivers/power/amd_uncore/amd_uncore.c > create mode 100644 drivers/power/amd_uncore/amd_uncore.h > create mode 100644 drivers/power/amd_uncore/meson.build > rename lib/power/power_cppc_cpufreq.c => drivers/power/cppc/cppc_cpufreq.c (95%) > rename lib/power/power_cppc_cpufreq.h => drivers/power/cppc/cppc_cpufreq.h (97%) > create mode 100644 drivers/power/cppc/meson.build > rename lib/power/power_intel_uncore.c => drivers/power/intel_uncore/intel_uncore.c (95%) > rename lib/power/power_intel_uncore.h => drivers/power/intel_uncore/intel_uncore.h (97%) > create mode 100644 drivers/power/intel_uncore/meson.build > rename {lib/power => drivers/power/kvm_vm}/guest_channel.c (99%) > rename {lib/power => drivers/power/kvm_vm}/guest_channel.h (100%) > rename lib/power/power_kvm_vm.c => drivers/power/kvm_vm/kvm_vm.c (82%) > rename lib/power/power_kvm_vm.h => drivers/power/kvm_vm/kvm_vm.h (98%) > create mode 100644 drivers/power/kvm_vm/meson.build > create mode 100644 drivers/power/meson.build > create mode 100644 drivers/power/pstate/meson.build > rename lib/power/power_pstate_cpufreq.c => drivers/power/pstate/pstate_cpufreq.c (96%) > rename lib/power/power_pstate_cpufreq.h => drivers/power/pstate/pstate_cpufreq.h (98%) > create mode 100644 lib/power/power_cpufreq.h > create mode 100644 lib/power/power_uncore_ops.h > delete mode 100644 lib/power/rte_power.c > create mode 100644 lib/power/rte_power_cpufreq.c > rename lib/power/{rte_power.h => rte_power_cpufreq.h} (73%) > This has some issues with documentation. $ ninja -C build doc ninja: Entering directory `build' [3/6] Generating doc/api/doxygen-html with a custom command /home/shemminger/DPDK/power/doc/api/doxy-api-index.md:105: warning: unable to resolve reference to 'rte_power.h' for \ref command [5/6] Running external command doc (wrapped by meson to set env) Building docs: Doxygen_API(HTML) Doxygen_API(Manpage) DTS_API_HTML HTML_Guides