Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 359620 Details for
Bug 453794
sys-power/cpupower: init.d/conf.d files
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch to init script to ignore empty START/STOP_OPTS and skip nonexisting sysfs entry
cpupower.patch (text/plain), 1.25 KB, created by
Holger Hoffstätte
on 2013-09-27 15:00:42 UTC
(
hide
)
Description:
Patch to init script to ignore empty START/STOP_OPTS and skip nonexisting sysfs entry
Filename:
MIME Type:
Creator:
Holger Hoffstätte
Created:
2013-09-27 15:00:42 UTC
Size:
1.25 KB
patch
obsolete
>--- cpupower.orig 2013-09-27 16:50:25.077846609 +0200 >+++ cpupower 2013-09-27 16:53:48.227250170 +0200 >@@ -3,28 +3,34 @@ > # Distributed under the terms of the GNU General Public License v2 > # $Header: /var/cvsroot/gentoo-x86/sys-power/cpupower/files/init.d-r1,v 1.1 2013/04/24 09:44:06 ssuominen Exp $ > >+CPUFREQ_SYSFS=/sys/devices/system/cpu/cpufreq >+ > change() { > local c ret=0 opts="$1" > shift > ebegin "Running cpupower -c all frequency-set ${opts}" >- cpupower -c all frequency-set ${opts} >/dev/null 2>&1 >- : $(( ret += $? )) >+ if [ "${opts}" != "" ] ; then >+ cpupower -c all frequency-set ${opts} >/dev/null 2>&1 >+ : $(( ret += $? )) >+ fi > eend ${ret} > >- if [ $# -gt 0 ] ; then >- c=1 >- einfo "Setting extra options: $*" >- if cd /sys/devices/system/cpu/cpufreq ; then >- local o v >- for o in "$@" ; do >- v=${o#*=} >- o=${o%%=*} >- echo ${v} > ${o} || break >- done >- c=0 >+ if [ -d ${CPUFREQ_SYSFS} ] ; then >+ if [ $# -gt 0 ] ; then >+ c=1 >+ einfo "Setting extra options: $*" >+ if cd ${CPUFREQ_SYSFS} ; then >+ local o v >+ for o in "$@" ; do >+ v=${o#*=} >+ o=${o%%=*} >+ echo ${v} > ${o} || break >+ done >+ c=0 >+ fi >+ eend ${c} >+ : $(( ret += c )) > fi >- eend ${c} >- : $(( ret += c )) > fi > > return ${ret}
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 453794
:
346342
|
346372
|
346378
|
346468
|
346470
|
359620
|
359622
|
359624
|
361548