summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWulf Krueger <philantrop@gentoo.org>2007-08-17 08:57:02 +0000
committerWulf Krueger <philantrop@gentoo.org>2007-08-17 08:57:02 +0000
commit455034b55dc6c99a27619f58019a70100aefae40 (patch)
treed886239cf58c0a481e4d787c3ddb0429fe3ae38d /kde-base/kdeutils/files
parentkeyworded ~x86, bug 189021 (diff)
downloadgentoo-2-455034b55dc6c99a27619f58019a70100aefae40.tar.gz
gentoo-2-455034b55dc6c99a27619f58019a70100aefae40.tar.bz2
gentoo-2-455034b55dc6c99a27619f58019a70100aefae40.zip
Added patch to enable hibernating using klaptopdaemon with newer kernels as provided by Sergey Temerkhanov (thanks, Sergey!) on bug 188760.
(Portage version: 2.1.3.5)
Diffstat (limited to 'kde-base/kdeutils/files')
-rw-r--r--kde-base/kdeutils/files/digest-kdeutils-3.5.7-r16
-rw-r--r--kde-base/kdeutils/files/klaptopdaemon-3.5.7-has_acpi_sleep.patch43
2 files changed, 49 insertions, 0 deletions
diff --git a/kde-base/kdeutils/files/digest-kdeutils-3.5.7-r1 b/kde-base/kdeutils/files/digest-kdeutils-3.5.7-r1
new file mode 100644
index 000000000000..58ea39070808
--- /dev/null
+++ b/kde-base/kdeutils/files/digest-kdeutils-3.5.7-r1
@@ -0,0 +1,6 @@
+MD5 4a5500af2f0170c9f74501093d5393ad kdeutils-3.5-patchset-02.tar.bz2 3019
+RMD160 b4598488995ed7dc7a86349cd68da426e2238773 kdeutils-3.5-patchset-02.tar.bz2 3019
+SHA256 54ddfbec990e3bff3139abf42755be24a450a8969eb77d41a5b0da4dc72580d6 kdeutils-3.5-patchset-02.tar.bz2 3019
+MD5 5f167f53bdbf0b8c71c2d0f0ff7593fd kdeutils-3.5.7.tar.bz2 3068596
+RMD160 0382278d69e71ff77178902f06126bda0f771ee8 kdeutils-3.5.7.tar.bz2 3068596
+SHA256 e72de75dd40e1422e4da5957acafc06278418f60850aea21524d857abb97adf8 kdeutils-3.5.7.tar.bz2 3068596
diff --git a/kde-base/kdeutils/files/klaptopdaemon-3.5.7-has_acpi_sleep.patch b/kde-base/kdeutils/files/klaptopdaemon-3.5.7-has_acpi_sleep.patch
new file mode 100644
index 000000000000..33b8a448a14f
--- /dev/null
+++ b/kde-base/kdeutils/files/klaptopdaemon-3.5.7-has_acpi_sleep.patch
@@ -0,0 +1,43 @@
+--- ./klaptopdaemon/portable.cpp.old 2007-05-14 11:40:45.000000000 +0400
++++ ./klaptopdaemon/portable.cpp 2007-08-14 01:52:30.775790879 +0400
+@@ -690,15 +690,16 @@ has_acpi_sleep(int state)
+ mask = 0;
+
+ QFile p("/sys/power/state");
+- QFile f("/proc/acpi/sleep");
+
+ if (p.open(IO_ReadOnly)) {
++ QTextStream stream(&p);
+ QString l;
+- p.readLine(l,500);
++ l = stream.readLine();
++
+ QStringList ll = QStringList::split(' ',l,false);
+ for (QValueListIterator<QString> i = ll.begin(); i!=ll.end(); i++) {
+ QString s = *i;
+-
++
+ if (s.compare("standby")==0)
+ mask |= (1<<1);
+ else if (s.compare("mem")==0)
+@@ -708,20 +709,6 @@ has_acpi_sleep(int state)
+ }
+ p.close();
+ }
+- else if (f.open(IO_ReadOnly)) {
+- QString l;
+- f.readLine(l, 500);
+- QStringList ll = QStringList::split(' ',l,false);
+- for (QValueListIterator<QString> i = ll.begin(); i!=ll.end(); i++) {
+- QString s = *i;
+- if (s[0] == 'S') {
+- int c = s[1].digitValue();
+- if (c >= 0 && c <= 9)
+- mask |= 1<<c;
+- }
+- }
+- f.close();
+- }
+ }
+ return((mask&acpi_sleep_enabled&(1<<state)) != 0);
+ }