libtriple: avoid audio noise when going to standby

Origin commit data
------------------
Branch: master
Commit: 9cc59bbd24
Author: Stefan Seyfried <seife@tuxbox-git.slipkontur.de>
Date: 2012-01-08 (Sun, 08 Jan 2012)


------------------
No further description and justification available within origin commit message!

------------------
This commit was generated by Migit
This commit is contained in:
Stefan Seyfried
2012-01-08 00:51:01 +01:00
parent 21b2b8bcf1
commit 33be04bfe3

View File

@@ -52,9 +52,15 @@ bool cCpuFreqManager::SetCpuFreq(unsigned long f)
return false; return false;
} }
if (f) if (f)
{
ioctl(fd, IOC_AVS_SET_VOLUME, 31); /* mute AVS to avoid ugly noise */
ioctl(fd, IOC_AVS_STANDBY_ENTER); ioctl(fd, IOC_AVS_STANDBY_ENTER);
}
else else
{
ioctl(fd, IOC_AVS_STANDBY_LEAVE); ioctl(fd, IOC_AVS_STANDBY_LEAVE);
ioctl(fd, IOC_AVS_SET_VOLUME, 0); /* max gain */
}
close(fd); close(fd);
return true; return true;