diff options
author | Alessandro Barbieri <lssndrbarbieri@gmail.com> | 2021-04-04 23:51:38 +0200 |
---|---|---|
committer | Alessandro Barbieri <lssndrbarbieri@gmail.com> | 2021-04-04 23:53:27 +0200 |
commit | f347b4e080235a9c1d623a449df91195d5c22bf1 (patch) | |
tree | d7f56d9be1ba1a1e915f7ab6cda0737f2b5ded9a /sys-power | |
parent | sys-power/ZenStates-Linux: new package (diff) | |
download | guru-f347b4e080235a9c1d623a449df91195d5c22bf1.tar.gz guru-f347b4e080235a9c1d623a449df91195d5c22bf1.tar.bz2 guru-f347b4e080235a9c1d623a449df91195d5c22bf1.zip |
sys-power/disable-c6: new package
Package-Manager: Portage-3.0.18, Repoman-3.0.3
Signed-off-by: Alessandro Barbieri <lssndrbarbieri@gmail.com>
Diffstat (limited to 'sys-power')
-rw-r--r-- | sys-power/disable-c6/Manifest | 1 | ||||
-rw-r--r-- | sys-power/disable-c6/disable-c6-0_p20190603.ebuild | 24 | ||||
-rw-r--r-- | sys-power/disable-c6/disable-c6.service.template | 13 | ||||
-rw-r--r-- | sys-power/disable-c6/disable-c6.service.template2 | 13 | ||||
-rw-r--r-- | sys-power/disable-c6/files/disable-c6 | 8 | ||||
-rw-r--r-- | sys-power/disable-c6/files/fix-path.patch | 11 | ||||
-rw-r--r-- | sys-power/disable-c6/metadata.xml | 8 |
7 files changed, 78 insertions, 0 deletions
diff --git a/sys-power/disable-c6/Manifest b/sys-power/disable-c6/Manifest new file mode 100644 index 000000000..929bb4d33 --- /dev/null +++ b/sys-power/disable-c6/Manifest @@ -0,0 +1 @@ +DIST disable-c6-82765d490290a99ba18282e187e9de3d7c11dd49.tar.gz 2505 BLAKE2B 8995e970e8e4643e752aaf2a27f94eae282c6d2416a5a93f41e69bb367dc50226ca28deb7cdcbc8ef7bbc8105b9c488bd51374b2d3c1ef58322180b3dae1eee1 SHA512 77843b71cb3b485b949ed8a65bf76bdeffd661e21139ccc517f7641adf2802a32c6b2cf1317067e945d37153fc946fffdfc5d42619b508bedcb1fab25576f7ec diff --git a/sys-power/disable-c6/disable-c6-0_p20190603.ebuild b/sys-power/disable-c6/disable-c6-0_p20190603.ebuild new file mode 100644 index 000000000..1c908529f --- /dev/null +++ b/sys-power/disable-c6/disable-c6-0_p20190603.ebuild @@ -0,0 +1,24 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit systemd + +DESCRIPTION="disable the C6 state upon system boot, preventing Ryzen freezes" +HOMEPAGE="https://github.com/jfredrickson/disable-c6" +COMMIT=82765d490290a99ba18282e187e9de3d7c11dd49 +SRC_URI="https://github.com/jfredrickson/disable-c6/archive/${COMMIT}.tar.gz -> disable-c6-${COMMIT}.tar.gz" +LICENSE="MIT" +SLOT="0" +KEYWORDS="-* ~amd64" +RDEPEND="sys-power/ZenStates-Linux" +DOCS=( ACKNOWLEDGMENTS README.md ) +PATCHES=( "${FILESDIR}/fix-path.patch" ) +S="${WORKDIR}/${PN}-${COMMIT}" + +src_install() { + einstalldocs + doinitd "${FILESDIR}/disable-c6" + systemd_newunit "disable-c6.service.template" "disable-c6-service" +} diff --git a/sys-power/disable-c6/disable-c6.service.template b/sys-power/disable-c6/disable-c6.service.template new file mode 100644 index 000000000..6d5efab25 --- /dev/null +++ b/sys-power/disable-c6/disable-c6.service.template @@ -0,0 +1,13 @@ +[Unit] +Description=Ryzen Disable C6 +DefaultDependencies=no +After=sysinit.target local-fs.target suspend.target hibernate.target +Before=basic.target + +[Service] +Type=oneshot +ExecStart={{PREFIX}}/bin/zenstates.py --c6-disable + +[Install] +WantedBy=basic.target suspend.target hibernate.target + diff --git a/sys-power/disable-c6/disable-c6.service.template2 b/sys-power/disable-c6/disable-c6.service.template2 new file mode 100644 index 000000000..3f31cb382 --- /dev/null +++ b/sys-power/disable-c6/disable-c6.service.template2 @@ -0,0 +1,13 @@ +[Unit] +Description=Ryzen Disable C6 +DefaultDependencies=no +After=sysinit.target local-fs.target suspend.target hibernate.target +Before=basic.target + +[Service] +Type=oneshot +ExecStart=/usr/sbin/zenstates --c6-disable + +[Install] +WantedBy=basic.target suspend.target hibernate.target + diff --git a/sys-power/disable-c6/files/disable-c6 b/sys-power/disable-c6/files/disable-c6 new file mode 100644 index 000000000..b538b8b1c --- /dev/null +++ b/sys-power/disable-c6/files/disable-c6 @@ -0,0 +1,8 @@ +#!/sbin/openrc-run +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 +command=/usr/sbin/zenstates +command_args="--c6-disable" +pidfile= +name="disable-c6" +description="Ryzen Disable C6" diff --git a/sys-power/disable-c6/files/fix-path.patch b/sys-power/disable-c6/files/fix-path.patch new file mode 100644 index 000000000..434a8cc5b --- /dev/null +++ b/sys-power/disable-c6/files/fix-path.patch @@ -0,0 +1,11 @@ +--- a/disable-c6.service.template 2021-04-04 23:46:51.260313163 +0200 ++++ b/disable-c6.service.template 2021-04-04 23:47:25.910835088 +0200 +@@ -6,7 +6,7 @@ + + [Service] + Type=oneshot +-ExecStart={{PREFIX}}/bin/zenstates.py --c6-disable ++ExecStart=/usr/sbin/zenstates --c6-disable + + [Install] + WantedBy=basic.target suspend.target hibernate.target diff --git a/sys-power/disable-c6/metadata.xml b/sys-power/disable-c6/metadata.xml new file mode 100644 index 000000000..673116b5b --- /dev/null +++ b/sys-power/disable-c6/metadata.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <upstream> + <bugs-to>https://github.com/jfredrickson/disable-c6/issues</bugs-to> + <remote-id type="github">jfredrickson/disable-c6</remote-id> + </upstream> +</pkgmetadata> |