summaryrefslogtreecommitdiff
path: root/sys-power
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2023-10-09 12:05:50 +0100
committerV3n3RiX <venerix@koprulu.sector>2023-10-09 12:05:50 +0100
commitc65def1225a421dd57ac582acefc5987c9d67e0d (patch)
treee13e2f661c997103edd9b96170e782e10da88963 /sys-power
parent431cb94e4e840d61ea21c2c2bd10e07fc27b5538 (diff)
gentoo auto-resync : 09:10:2023 - 12:05:50
Diffstat (limited to 'sys-power')
-rw-r--r--sys-power/Manifest.gzbin5226 -> 5390 bytes
-rw-r--r--sys-power/throttled/Manifest5
-rw-r--r--sys-power/throttled/files/throttled.initd5
-rw-r--r--sys-power/throttled/files/throttled.service11
-rw-r--r--sys-power/throttled/metadata.xml19
-rw-r--r--sys-power/throttled/throttled-0.10.0.ebuild43
6 files changed, 83 insertions, 0 deletions
diff --git a/sys-power/Manifest.gz b/sys-power/Manifest.gz
index 43d32633b2ec..ec4cbe690869 100644
--- a/sys-power/Manifest.gz
+++ b/sys-power/Manifest.gz
Binary files differ
diff --git a/sys-power/throttled/Manifest b/sys-power/throttled/Manifest
new file mode 100644
index 000000000000..b8f98228ff37
--- /dev/null
+++ b/sys-power/throttled/Manifest
@@ -0,0 +1,5 @@
+AUX throttled.initd 138 BLAKE2B 5f032097afb1a6aa1e7cf17c01416dafeeb16d758ebac50854f1583e788598749678ae87e8efb085ba14d4d6a669f0e6cb17360f406c431c561b3b05e7aea231 SHA512 35ce59d72146d641eefcbb8aad026677204af421526ee6b34cb799338b1b109f5a21eee8dcb6562758a2d0c2d75ece80dea128d461bde05ee149ca9efbd0c99b
+AUX throttled.service 251 BLAKE2B 2eee705a40bcdd273cb52757330083ad82018814bfa6fa52cffc29e4709ee608e5253022ff547ee9447242d06db138da4846d2ba632596a79867cc5a6f14906d SHA512 66a47dc1349a18115868cc0a92739dc19b4f141e3ae6b65beebdb2add902013488ec33ac224075c261e788a36631f7d8ba7e3249c537bc04b499d1f03acf4239
+DIST throttled-0.10.0.gh.tar.gz 22191 BLAKE2B c301ee070ff462acd613c90525209eb5237c57e7171bf25133535f9c9a50d226b919065d8f6999f95b45f7f0d4c30e63abb5e04ec768d76b3c82dd19f092a693 SHA512 b89c467295bfc592d7b3ce0c4a41fedf436acf8067f8ef63d8596b92343ed8e04d371d065a9e35fdddba40772f12255c30960c2c46f0cbd5093bfc5e72fb4e18
+EBUILD throttled-0.10.0.ebuild 998 BLAKE2B 98d61163d187c1d4c4b5da57f758625673645efc73e1b24b352796e01b3d74d6839cb58c6842508ea8bb8058f768b88f8ec0fbd9307d6ec1e8acfc2eaa2b87fd SHA512 9668ca181a1a6f3146549c7b0dfbbce9443a264bc3cccae6f2e5a860f1a821f1bc2446470150bf2498c6cbe79166e522af07045639df59d9ad9bb0df04af0c4f
+MISC metadata.xml 600 BLAKE2B e55795b1a0947d87afa39d04ba63755c97c173ab201234efe87e49833d3a41dd74a98ac2aee22bab0e4f723e34b6a36e999f07f8c71cf78915fef6fb1c11f273 SHA512 1f0ad49b2c3b2703f8508b87a63ec2fa695fc77a769ad34d9a0bd19359cab2305582211552586cd3ec608cd6a0c64ed7c5928d7ffaddcf8a50baeb348fc362bd
diff --git a/sys-power/throttled/files/throttled.initd b/sys-power/throttled/files/throttled.initd
new file mode 100644
index 000000000000..efe8b6a7e151
--- /dev/null
+++ b/sys-power/throttled/files/throttled.initd
@@ -0,0 +1,5 @@
+#!/sbin/openrc-run
+command="/usr/bin/throttled"
+pidfile="/run/throttled.pid"
+description="Stop Intel throttling"
+command_background="yes"
diff --git a/sys-power/throttled/files/throttled.service b/sys-power/throttled/files/throttled.service
new file mode 100644
index 000000000000..5b7decc435b0
--- /dev/null
+++ b/sys-power/throttled/files/throttled.service
@@ -0,0 +1,11 @@
+[Unit]
+Description=Stop Intel throttling
+
+[Service]
+Type=simple
+ExecStart=/usr/bin/throttled
+# Setting PYTHONUNBUFFERED is necessary to see the output of this service in the journal
+Environment=PYTHONUNBUFFERED=1
+
+[Install]
+WantedBy=multi-user.target
diff --git a/sys-power/throttled/metadata.xml b/sys-power/throttled/metadata.xml
new file mode 100644
index 000000000000..b7efde349add
--- /dev/null
+++ b/sys-power/throttled/metadata.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="person" proxied="yes">
+ <email>vimproved@inventati.org</email>
+ <name>Violet Purcell</name>
+ </maintainer>
+ <maintainer type="person" proxied="proxy">
+ <email>dlan@gentoo.org</email>
+ <name>Yixun Lan</name>
+ </maintainer>
+ <maintainer type="project" proxied="proxy">
+ <email>proxy-maint@gentoo.org</email>
+ <name>Proxy Maintainers</name>
+ </maintainer>
+ <upstream>
+ <remote-id type="github">erpalma/throttled</remote-id>
+ </upstream>
+</pkgmetadata>
diff --git a/sys-power/throttled/throttled-0.10.0.ebuild b/sys-power/throttled/throttled-0.10.0.ebuild
new file mode 100644
index 000000000000..9b1a5e143ffa
--- /dev/null
+++ b/sys-power/throttled/throttled-0.10.0.ebuild
@@ -0,0 +1,43 @@
+# Copyright 2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+PYTHON_COMPAT=( python3_{10..12} )
+inherit linux-info python-single-r1 systemd
+
+DESCRIPTION="Daemon to work around throttling issues on some Intel laptops"
+HOMEPAGE="https://github.com/erpalma/throttled"
+SRC_URI="https://github.com/erpalma/throttled/archive/refs/tags/v${PV}.tar.gz -> ${P}.gh.tar.gz"
+
+LICENSE="MIT"
+SLOT="0"
+KEYWORDS="~amd64"
+REQUIRED_USE="${PYTHON_REQUIRED_USE}"
+RESTRICT="test"
+
+CONFIG_CHECK="~X86_MSR ~DEVMEM"
+
+RDEPEND="
+ ${PYTHON_DEPS}
+ $(python_gen_cond_dep '
+ dev-python/dbus-python[${PYTHON_USEDEP}]
+ dev-python/pygobject[${PYTHON_USEDEP}]
+ ')
+ sys-apps/pciutils
+"
+
+pkg_setup() {
+ linux-info_pkg_setup
+ python-single-r1_pkg_setup
+}
+
+src_install() {
+ default
+ python_newscript throttled.py throttled
+ python_domodule mmio.py
+ newinitd "${FILESDIR}/throttled.initd" throttled
+ systemd_dounit "${FILESDIR}/throttled.service"
+ insinto /etc
+ doins etc/throttled.conf
+}