lintweaker;649299 Wrote: 
> I've been using the tweaks on my touches with great success and decided
> to contribute a bit myself.
> 
> In case the IRQ's, process numbers etc. change you can use a more
> dynamic version I hacked together (It is not fool proof!):
> 
> To test it out by hand just copy and paste the following into a ssh
> session with the touch:
> 
> === begin code ===
> # Get IRQ for RTC
> tmp=`cat /proc/interrupts |grep "mxc_rtc"|cut -f2 -d" "|cut -f1 -d":"`
> echo -n "RTC IRQ is $tmp"
> # Get proc # for RTC
> rtc=`ps -e|grep IRQ-$tmp|cut -f3 -d" "`
> echo ", process #: $rtc"
> # Get IRQ of SPDIF I/F
> tmp=`cat /proc/interrupts |grep "spdif"|cut -f2 -d" "|cut -f1 -d":"`
> echo -n "SPDIF IRQ is $tmp"
> # Get proc # for SPDIF
> spdif=`ps -e|grep IRQ-$tmp|cut -f3 -d" "`
> echo ", proces # $spdif"
> 
> # Get proces number for audio threads
> aud1=`ps -e|grep "sirq-hrtimer/0"|cut -f4 -d" "`
> echo "Proces nummber for sirq-hrtimer/0: $aud1"
> aud2=`ps -e|grep "sirq-timer/0"|cut -f5 -d" "`
> echo "Proces nummber for sirq-timer/0: $aud2"
> echo "Setting new priorities.."
> chrt -f -p 93 $aud1
> chrt -f -p 91 $aud2
> chrt -f -p 59 $spdif
> chrt -f -p 87 $rtc
> 
> === end code ===
> 
> I you want you can add a more quiet version straight to
> etc/init.d/rcS:
> 
> === start code ===
> # Get IRQ for RTC
> tmp=`cat /proc/interrupts |grep "mxc_rtc"|cut -f2 -d" "|cut -f1 -d":"`
> # Get proc # for RTC
> rtc=`ps -e|grep IRQ-$tmp|cut -f3 -d" "`
> # Get IRQ of SPDIF I/F
> tmp=`cat /proc/interrupts |grep "spdif"|cut -f2 -d" "|cut -f1 -d":"`
> # Get proc # for SPDIF
> spdif=`ps -e|grep IRQ-$tmp|cut -f3 -d" "`
> 
> # Get proces number for audio threads
> aud1=`ps -e|grep "sirq-hrtimer/0"|cut -f4 -d" "`
> aud2=`ps -e|grep "sirq-timer/0"|cut -f5 -d" "`
> 
> # Set new priorities
> chrt -f -p 93 $aud1 > /dev/null
> chrt -f -p 91 $aud2 > /dev/null
> chrt -f -p 59 $spdif > /dev/null
> chrt -f -p 87 $rtc > /dev/null
> 
> === end code ===

Hi lintweaker,

I successfully use your code to set the 4 new priorities and tried to
add another for jive_alsa. The original 4 still set but I can't get
jive_alsa to set to a new priority. It works if I use the code at the
command line though. Any suggestions?

========== Start code ==========

#Change priorities

# Get IRQ for RTC
tmp=`cat /proc/interrupts |grep "mxc_rtc"|cut -f2 -d" "|cut -f1 -d":"`
# Get proc # for RTC
rtc=`ps -e|grep IRQ-$tmp|cut -f3 -d" "`
# Get IRQ of SPDIF I/F
tmp=`cat /proc/interrupts |grep "spdif"|cut -f2 -d" "|cut -f1 -d":"`
# Get proc # for SPDIF
spdif=`ps -e|grep IRQ-$tmp|cut -f3 -d" "`

# Get proces number for audio threads
aud1=`ps -e|grep "sirq-timer/0"|cut -f5 -d" "`
aud2=`ps -e|grep "sirq-hrtimer/0"|cut -f4 -d" "`

# Get process number for jive_alsa 'music'
jalsa1=`ps -eo pid,args|grep "jive_alsa -d default"|head -1|cut -f3 -d"
"`

# Get process number for jive_alsa 'sound effects' - not used but a
possibility!
jalsa2=`ps -eo pid,args|grep "jive_alsa -d plughw"|head -1|cut -f3 -d"
"` 

# Set new priorities
chrt -f -p 91 $aud1 > /dev/null
chrt -f -p 93 $aud2 > /dev/null
chrt -f -p 44 $spdif > /dev/null
chrt -f -p 87 $rtc > /dev/null
chrt -f -p 55 $jalsa1 > /dev/null

========== End code ==========

Thanks

Bob


-- 
bobertuk

1 x Touch - SC 7.6.0 - SSOTS v4.91
1 x Radio
1 x Boom
Lavry DA-10 DAC
QNAP TS-509 3.3.6 build 1110T
Starfish Pre-amp : Based on NAIM
Heavily modified NAIM NAP 250 Power-amp
Behringer DEQ2496
Linn Isobarik DMS
------------------------------------------------------------------------
bobertuk's Profile: http://forums.slimdevices.com/member.php?userid=30376
View this thread: http://forums.slimdevices.com/showthread.php?t=89359

_______________________________________________
audiophiles mailing list
[email protected]
http://lists.slimdevices.com/mailman/listinfo/audiophiles

Reply via email to