alsactl: avoid needless wakeups in monitor loop.
PATCH 1/1 alsactl: avoid needless wakeups in monitor loop.
The timeout wasn't really being used for anything; disabling it should reduce idle energy consumption slightly.
--- alsactl/monitor.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
alsactl/monitor.c +1 -1
@@ -340,7 +340,7 @@ static int run_dispatcher(int epfd, int sigfd, int infd, struct list_head *srcs,int count;int i; - count =epoll_wait (epfd, epev, max_ev_count,200 ); + count =epoll_wait (epfd, epev, max_ev_count,-1 );if (count <0 ) { err = count;break ;
Signature · 6 lines
2.23.0 _______________________________________________ Alsa-devel mailing list [email protected] https://mailman.alsa-project.org/mailman/listinfo/alsa-devel
Ping -- it's been a while since I sent this and
https://mailman.alsa-project.org/pipermail/alsa-devel/2019-October/156866.html, never saw any response though. Any problems with these patches?
Thanks,
Zev Weiss
Quoted 24 lines · Zev Weiss
The timeout wasn't really being used for anything; disabling it should reduce idle energy consumption slightly.
Signed-off-by Zev Weiss <[email protected]>---
alsactl/monitor.c| 2 +-1 file changed, 1 insertion(+), 1 deletion(-)alsactl/monitor.c +1
-1@@ -340,7 +340,7 @@ static int run_dispatcher(int epfd, int sigfd, int infd, struct list_head *srcs,int count;int i; - count =epoll_wait (epfd, epev, max_ev_count,200 ); + count =epoll_wait (epfd, epev, max_ev_count,-1 );if (count <0 ) { err = count;break ;Signature · 1 line
2.23.0
Hi,
Quoted 7 lines · Zev Weiss
The timeout wasn't really being used for anything; disabling it should reduce idle energy consumption slightly.
Signed-off-by Zev Weiss <[email protected]>--- alsactl/monitor.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
I overlooked it as well... It looks good to me.
Quoted 15 lines
alsactl/monitor.c +1
-1@@ -340,7 +340,7 @@ static int run_dispatcher(int epfd, int sigfd, int infd, struct list_head *srcs,int count;int i; - count =epoll_wait (epfd, epev, max_ev_count,200 ); + count =epoll_wait (epfd, epev, max_ev_count,-1 );if (count <0 ) { err = count;break ;Signature · 1 line
2.23.0
Regards
Takashi Sakamoto
Jaroslav Kysela
AppliedDne 12. 04. 20 v 4:19 Takashi Sakamoto napsal(a):
Quoted 11 lines
Hi,
Quoted 7 lines · Zev Weiss
The timeout wasn't really being used for anything; disabling it should reduce idle energy consumption slightly.
Signed-off-by Zev Weiss <[email protected]>--- alsactl/monitor.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
Quoted 4 lines
I overlooked it as well... It looks good to me.
Reviewed-by Takashi Sakamoto <[email protected]>Tested-by Takashi Sakamoto <[email protected]>
Applied. Thanks.
Jaroslav
Quoted 21 lines
Quoted 16 lines
alsactl/monitor.c +1
-1@@ -340,7 +340,7 @@ static int run_dispatcher(int epfd, int sigfd, int infd, struct list_head *srcs,int count;int i; - count =epoll_wait (epfd, epev, max_ev_count,200 ); + count =epoll_wait (epfd, epev, max_ev_count,-1 );if (count <0 ) { err = count;break ;Signature · 1 line
2.23.0Regards
Takashi Sakamoto
Signature · 2 lines
Jaroslav Kysela <[email protected]> Linux Sound Maintainer; ALSA Project; Red Hat, Inc.