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.  
 
Please note that this RFC patch is currently in its initial phase and is
primarily intended for soliciting feedback and comments. As of now,
it has not undergone testing for build or functional issues.
 
Signed-off-by: Sivaprasad Tummala <sivaprasad.tumm...@amd.com>
---
  power: refactor core power management library
  power: refactor uncore power management library

 drivers/meson.build                           |   1 +
 drivers/power/core/acpi/meson.build           |   8 +
 .../power/core/acpi}/power_acpi_cpufreq.c     |  19 ++
 .../power/core/acpi}/power_acpi_cpufreq.h     |   0
 drivers/power/core/amd-pstate/meson.build     |   8 +
 .../amd-pstate}/power_amd_pstate_cpufreq.c    |  19 ++
 .../amd-pstate}/power_amd_pstate_cpufreq.h    |   0
 drivers/power/core/cppc/meson.build           |   8 +
 .../power/core/cppc}/power_cppc_cpufreq.c     |  19 ++
 .../power/core/cppc}/power_cppc_cpufreq.h     |   0
 .../power/core/kvm-vm}/guest_channel.c        |   0
 .../power/core/kvm-vm}/guest_channel.h        |   0
 drivers/power/core/kvm-vm/meson.build         |  20 ++
 .../power/core/kvm-vm}/power_kvm_vm.c         |  19 ++
 .../power/core/kvm-vm}/power_kvm_vm.h         |   0
 drivers/power/core/meson.build                |  12 +
 drivers/power/core/pstate/meson.build         |   8 +
 .../power/core/pstate}/power_pstate_cpufreq.c |  19 ++
 .../power/core/pstate}/power_pstate_cpufreq.h |   0
 drivers/power/meson.build                     |   9 +
 drivers/power/uncore/intel/meson.build        |   9 +
 .../power/uncore/intel}/power_intel_uncore.c  |  15 +
 .../power/uncore/intel}/power_intel_uncore.h  |   0
 drivers/power/uncore/meson.build              |   8 +
 lib/power/meson.build                         |   7 -
 lib/power/power_common.h                      |  11 +
 lib/power/rte_power.c                         | 305 ++++++++----------
 lib/power/rte_power.h                         | 207 ++++++++++--
 lib/power/rte_power_uncore.c                  | 163 ++++------
 lib/power/rte_power_uncore.h                  | 150 ++++++++-
 lib/power/version.map                         |  13 +
 31 files changed, 742 insertions(+), 315 deletions(-)
 create mode 100644 drivers/power/core/acpi/meson.build
 rename {lib/power => drivers/power/core/acpi}/power_acpi_cpufreq.c (95%)
 rename {lib/power => drivers/power/core/acpi}/power_acpi_cpufreq.h (100%)
 create mode 100644 drivers/power/core/amd-pstate/meson.build
 rename {lib/power => drivers/power/core/amd-pstate}/power_amd_pstate_cpufreq.c 
(95%)
 rename {lib/power => drivers/power/core/amd-pstate}/power_amd_pstate_cpufreq.h 
(100%)
 create mode 100644 drivers/power/core/cppc/meson.build
 rename {lib/power => drivers/power/core/cppc}/power_cppc_cpufreq.c (96%)
 rename {lib/power => drivers/power/core/cppc}/power_cppc_cpufreq.h (100%)
 rename {lib/power => drivers/power/core/kvm-vm}/guest_channel.c (100%)
 rename {lib/power => drivers/power/core/kvm-vm}/guest_channel.h (100%)
 create mode 100644 drivers/power/core/kvm-vm/meson.build
 rename {lib/power => drivers/power/core/kvm-vm}/power_kvm_vm.c (83%)
 rename {lib/power => drivers/power/core/kvm-vm}/power_kvm_vm.h (100%)
 create mode 100644 drivers/power/core/meson.build
 create mode 100644 drivers/power/core/pstate/meson.build
 rename {lib/power => drivers/power/core/pstate}/power_pstate_cpufreq.c (96%)
 rename {lib/power => drivers/power/core/pstate}/power_pstate_cpufreq.h (100%)
 create mode 100644 drivers/power/meson.build
 create mode 100644 drivers/power/uncore/intel/meson.build
 rename {lib/power => drivers/power/uncore/intel}/power_intel_uncore.c (95%)
 rename {lib/power => drivers/power/uncore/intel}/power_intel_uncore.h (100%)
 create mode 100644 drivers/power/uncore/meson.build

-- 
2.25.1

Reply via email to