AC97 register 0x54 is used by ICH to control GPIOs, which we don't want to access
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6907 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -586,11 +586,6 @@ ac97_reg_is_valid(ac97_dev *dev, uint8 reg)
|
||||
return false;
|
||||
|
||||
switch (dev->codec_id) {
|
||||
case CODEC_ID_ALC201A:
|
||||
if (reg != 0x54) /* reading register 0x54 causes a semaphore timeout on the next register accessed */
|
||||
return true;
|
||||
return false;
|
||||
|
||||
case CODEC_ID_AK4540:
|
||||
case CODEC_ID_AK4542:
|
||||
if (reg < 0x1e || reg == 0x20 || reg == 0x26 || reg > 0x7a)
|
||||
|
||||
@@ -130,7 +130,10 @@ ich_codec_read(int regno)
|
||||
{
|
||||
status_t rv;
|
||||
ASSERT(regno >= 0);
|
||||
ASSERT((regno & 1) == 0);
|
||||
ASSERT(((config->type & TYPE_ICH4) != 0 && regno <= 511) || regno <= 255);
|
||||
if (regno == 0x54) // intel uses 0x54 for GPIO access, we filter it!
|
||||
return 0;
|
||||
rv = ich_codec_wait();
|
||||
if (rv != B_OK)
|
||||
PRINT(("semaphore timeout reading register %#x\n",regno));
|
||||
@@ -145,7 +148,10 @@ ich_codec_write(int regno, uint16 value)
|
||||
{
|
||||
status_t rv;
|
||||
ASSERT(regno >= 0);
|
||||
ASSERT((regno & 1) == 0);
|
||||
ASSERT(((config->type & TYPE_ICH4) != 0 && regno <= 511) || regno <= 255);
|
||||
if (regno == 0x54) // intel uses 0x54 for GPIO access, we filter it!
|
||||
return;
|
||||
rv = ich_codec_wait();
|
||||
if (rv != B_OK)
|
||||
PRINT(("semaphore timeout writing register %#x\n",regno));
|
||||
|
||||
Reference in New Issue
Block a user