Profiling my laptop power usage with PowerTOP, I noticed Timidity wakes
up rather often, 100 times per second, even when it's not being used.
The curlpit is Timidity ALSA sequencer interface. Examining the source
code, I created the following patch, which should disable this polling,
when it's not needed.
The patch attached, or if it doesn't come through, see
http://fedev.blogspot.com/2007/07/timidity-power-usage.html
A bit more details there, too.
--
Niko Kiirala
[EMAIL PROTECTED]
http://niko.kiirala.com/
--- interface/alsaseq_c.c~ 2004-07-10 08:07:00.000000000 +0300
+++ interface/alsaseq_c.c 2007-05-12 17:11:49.000000000 +0300
@@ -529,13 +529,18 @@
}
if (! ctxp->active || ! IS_STREAM_TRACE) {
fd_set rfds;
- struct timeval timeout;
FD_ZERO(&rfds);
FD_SET(ctxp->fd, &rfds);
- timeout.tv_sec = 0;
- timeout.tv_usec = 10000; /* 10ms */
- if (select(ctxp->fd + 1, &rfds, NULL, NULL, &timeout) < 0)
- goto __done;
+ if (! IS_STREAM_TRACE) {
+ struct timeval timeout;
+ timeout.tv_sec = 0;
+ timeout.tv_usec = 10000; /* 10ms */
+ if (select(ctxp->fd + 1, &rfds, NULL, NULL, &timeout) < 0)
+ goto __done;
+ } else {
+ if (select(ctxp->fd + 1, &rfds, NULL, NULL, NULL) < 0)
+ goto __done;
+ }
}
}
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Timidity-talk mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/timidity-talk