From b3ca75728b99231d0e1a59868cbf507cb882f65e Mon Sep 17 00:00:00 2001 From: =?utf8?q?Jan=20R=C4=99korajski?= Date: Sat, 4 Mar 2017 12:21:08 +0100 Subject: [PATCH] - drop sata-alpm patch, it's already covered by intel-sata-powermgmt --- laptop-mode-tools.spec | 4 +- sata-alpm.patch | 102 ----------------------------------------- 2 files changed, 1 insertion(+), 105 deletions(-) delete mode 100644 sata-alpm.patch diff --git a/laptop-mode-tools.spec b/laptop-mode-tools.spec index 19aaec8..0b5d90f 100644 --- a/laptop-mode-tools.spec +++ b/laptop-mode-tools.spec @@ -18,7 +18,7 @@ Summary: Laptop Mode Tools Summary(pl.UTF-8): Narzędzia do trybu laptopowego Name: laptop-mode-tools Version: 1.71 -Release: 2 +Release: 3 License: GPL Group: Applications/System Source0: https://github.com/rickysarraf/laptop-mode-tools/archive/%{version}/%{name}-%{version}.tar.gz @@ -26,7 +26,6 @@ Source0: https://github.com/rickysarraf/laptop-mode-tools/archive/%{version}/%{n Source1: %{name}.init Patch0: no-exec-redirection.patch Patch1: cpufreq-pstate.patch -Patch2: sata-alpm.patch URL: https://github.com/rickysarraf/laptop-mode-tools BuildRequires: rpm-pythonprov BuildRequires: rpmbuild(macros) >= 1.714 @@ -105,7 +104,6 @@ GUI dla narzędzi do trybu laptopowego. %setup -q %patch0 -p1 %patch1 -p1 -%patch2 -p1 %{__sed} -i -e 's|/usr/bin/env python2|/usr/bin/python|' gui/LMT.py diff --git a/sata-alpm.patch b/sata-alpm.patch deleted file mode 100644 index a101d9b..0000000 --- a/sata-alpm.patch +++ /dev/null @@ -1,102 +0,0 @@ ---- /dev/null 2017-02-28 21:16:52.000000000 +0100 -+++ laptop-mode-tools-1.71/usr/share/laptop-mode-tools/modules/sata-alpm 2017-03-04 10:16:55.823426823 +0100 -@@ -0,0 +1,26 @@ -+#!/bin/sh -+# -+# SATA link power management -+ -+if [ "$KLEVEL" = "2.6" -a "$KMINOR" -lt 33 ] ; then -+ log "VERBOSE" "Changing SATA link power management may cause filesystem corruption on kernels before 2.6.33. Disabling." -+ CONTROL_SATA_ALPM=0 -+fi -+ -+if [ x$CONTROL_SATA_ALPM = x1 ] || [ x$ENABLE_AUTO_MODULES = x1 -a x$CONTROL_SATA_ALPM = xauto ]; then -+ if [ $ON_AC -eq 1 ] ; then -+ if [ "$ACTIVATE" -eq 1 ] ; then -+ SATA_LINK_POLICY="$LM_AC_SATA_LINK_POLICY" -+ else -+ SATA_LINK_POLICY="$NOLM_AC_SATA_LINK_POLICY" -+ fi -+ else -+ SATA_LINK_POLICY="$BATT_SATA_LINK_POLICY" -+ fi -+ for SATAHOST in /sys/class/scsi_host/host*; do -+ if [ -w "$SATAHOST/link_power_management_policy" ]; then -+ log "VERBOSE" "Setting SATA APLM on $SATAHOST to $SATA_LINK_POLICY." -+ echo "$SATA_LINK_POLICY" > "$SATAHOST/link_power_management_policy" -+ fi -+ done -+fi ---- /dev/null 2017-02-28 21:16:52.000000000 +0100 -+++ laptop-mode-tools-1.71/etc/laptop-mode/conf.d/sata-alpm.conf 2017-03-04 10:16:16.082421957 +0100 -@@ -0,0 +1,57 @@ -+# -+# Configuration file for Laptop Mode Tools module sata-alpm. -+# -+# For more information, consult the laptop-mode.conf(8) manual page. -+# -+ -+############################################################################### -+# SATA link power management -+# ------------------------------------ -+# -+#__COMMENT Laptop mode tools can automatically adjust SATA link power management policy -+#__COMMENT setting. -+#__COMMENT -+#__COMMENT This hook tries to save power by allowing SATA controllers to -+#__COMMENT reduce power usage when the SATA subsystem is otherwise idle. -+#__COMMEN -+#__COMMENT This adds a little bit of latency to drive accesses in -+#__COMMENT exchange for moderate power savings if you are not using the drive. -+#__COMMENT -+#__COMMENT see kernel commit 6013efd8860bf15c1f86f365332642cfe557152f -+#__COMMENT -+#__COMMENT This feature only works on 2.6.33+ kernels. -+############################################################################### -+ -+# Enable debug mode for this module -+# Set to 1 if you want to debug this module -+DEBUG=0 -+ -+# -+# Should laptop mode tools control SATA link power settings? -+# -+# Set to 0 to disable -+SATA_ALPM_FREQUENCY="auto" -+ -+ -+# -+# This parameter allows the user to set the link (interface) power management. -+# There are 4 possible options: -+# -+# Value Effect -+# ---------------------------------------------------------------------------- -+# firmware_defaults Inherit configuration from the state programmed by -+# the firmware during system init. -+# -+# min_power Tell the controller to try to make the link use the -+# least possible power when possible. This may -+# sacrifice some performance due to increased latency -+# when coming out of lower power states. -+# -+# max_performance Generally, this means no power management. Tell -+# the controller to have performance be a priority -+# over power management. -+# -+# medium_power Tell the controller to enter a lower power state -+# when possible, but do not enter the lowest power -+# state, thus improving latency over min_power setting. -+# -+BATT_SATA_LINK_POLICY=medium_power -+LM_AC_SATA_LINK_POLICY=max_performance -+NOLM_AC_SATA_LINK_POLICY=max_performance ---- laptop-mode-tools-1.71/etc/laptop-mode/laptop-mode.conf~ 2017-01-12 09:06:23.000000000 +0100 -+++ laptop-mode-tools-1.71/etc/laptop-mode/laptop-mode.conf 2017-03-04 11:22:17.909951954 +0100 -@@ -120,6 +120,7 @@ - # nmi-watchdog - # pcie-aspm - # runtime-pm -+# sata-alpm - # sched-mc-power-savings - # sched-smt-power-savings - # terminal-blanking -- 2.44.0