public inbox for linux-rt-users@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH v3 0/2] Add cpupower idle-state functionality
@ 2025-03-07 18:07 John B. Wyatt IV
  2025-03-07 18:07 ` [PATCH v3 1/2] tuna: extract common cpu and nics determination code into a utils.py file John B. Wyatt IV
  2025-03-07 18:07 ` [PATCH v3 2/2] tuna: Add idle_state control functionality John B. Wyatt IV
  0 siblings, 2 replies; 3+ messages in thread
From: John B. Wyatt IV @ 2025-03-07 18:07 UTC (permalink / raw)
  To: Clark Williams, John Kacur, Crystal Wood
  Cc: John B. Wyatt IV, linux-rt-users, kernel-rts-sst,
	John B. Wyatt IV

This patch series adds idle-state functionality to control cpu power
usage and to test idle states.

The number of cpus was needed in the cpupower file; I extracted out the
previously local to tuna-cli.py functionality to a separate file so the
cpu code can be used in any file in Tuna and reduce duplications. The
nics code was similar so it was also extracted to reduce the number of
global variables.

Sincerely,
John Wyatt
Software Engineer, Core Kernel
Red Hat

Changes v2 -> v3:
- Several small improvements suggested by John Kacur off list including
  removing unnecessary string interpolation, renaming idle-set to idle_set,
  and correct placement of docstrings.

Changes v1 -> v2:
- Numerous improvements suggested by Crystal Wood including message
  text, output, error handling, moving a function to utils.py and
  structure of the code.
- Fixed a libcpupower bindings detection error that did not show on
  my local machine but did on a fresh install of Fedora GNOME 40
  reported by John Kacur.

John B. Wyatt IV (2):
  tuna: extract common cpu and nics determination code into a utils.py
    file
  tuna: Add idle_state control functionality

 tuna-cmd.py      |  64 +++++++++--------
 tuna/cpupower.py | 184 +++++++++++++++++++++++++++++++++++++++++++++++
 tuna/utils.py    |  28 ++++++++
 3 files changed, 246 insertions(+), 30 deletions(-)
 create mode 100755 tuna/cpupower.py
 create mode 100644 tuna/utils.py

-- 
2.48.1


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2025-03-07 18:07 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-03-07 18:07 [PATCH v3 0/2] Add cpupower idle-state functionality John B. Wyatt IV
2025-03-07 18:07 ` [PATCH v3 1/2] tuna: extract common cpu and nics determination code into a utils.py file John B. Wyatt IV
2025-03-07 18:07 ` [PATCH v3 2/2] tuna: Add idle_state control functionality John B. Wyatt IV

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox