OSDN Git Service

Detect (at runtime) kernel support for the "hdmi_audio" switch.
authorJohn Grossman <johngro@google.com>
Tue, 6 Mar 2012 00:01:26 +0000 (16:01 -0800)
committerJohn Grossman <johngro@google.com>
Wed, 7 Mar 2012 01:59:02 +0000 (17:59 -0800)
commitd7af347922064be585d3b9406cf7f9edd9d2f049
tree948347f2b4e239bea832351019e7afd6efcf063b
parent9e879c806ed199e043bee5f83ef1c5e5d9470112
Detect (at runtime) kernel support for the "hdmi_audio" switch.

A new switch was introduced in AndroidAtHome to deal with a race
condition between the WiredAccessoryObserver and the HW composer HAL.
When the new switch ("hdmi_audio") is present, we want to pay
attention to it instead of paying attention to the old switch
("hdmi").  This change checks at startup for the presence or absence
of the new switch and uses it if available, otherwise it falls back on
classic behavior.

see change ID I960cfc2f3e8df5342e7248a26fd313fdad2ca322 for the kernel
side changes.

see bug 6023647 for a discussion of the issue.

Change-Id: Ia2f2c399c3d85896ede0fff57ecbd51f332b3e0e
Signed-off-by: John Grossman <johngro@google.com>
services/java/com/android/server/WiredAccessoryObserver.java