hikey: Enable usb audio support

It was noticed on the 96boards forum by user "niruyadla"
that USB audio support was missing, so this patch enables
it along with adding tinyplay for help w/ testing.

Also adds r_submix and tweaks audio policy to be consistent

Change-Id: Ia65468ddd2144b2cba3304fefcefbe01574ab772
Signed-off-by: John Stultz <john.stultz@linaro.org>
diff --git a/audio/audio_policy.conf b/audio/audio_policy.conf
index dc1c653..82b5979 100644
--- a/audio/audio_policy.conf
+++ b/audio/audio_policy.conf
@@ -71,8 +71,8 @@
     inputs {
       usb_device {
         sampling_rates dynamic
-        channel_masks AUDIO_CHANNEL_IN_STEREO
-        formats AUDIO_FORMAT_PCM_16_BIT
+        channel_masks dynamic
+        formats dynamic
         devices AUDIO_DEVICE_IN_USB_DEVICE
       }
     }
diff --git a/device.mk b/device.mk
index d03137c..09f9d95 100644
--- a/device.mk
+++ b/device.mk
@@ -49,8 +49,12 @@
 # Build and run only ART
 PRODUCT_RUNTIMES := runtime_libart_default
 
-# Build BT a2dp audio HAL
-PRODUCT_PACKAGES += audio.a2dp.default
+# Build HiKey HDMI, bluetooth a2dp and usb audio HALs
+PRODUCT_PACKAGES += audio.primary.hikey \
+		    audio.a2dp.default \
+		    audio.usb.default \
+		    audio.r_submix.default \
+		    tinyplay
 
 # Include USB speed switch App
 PRODUCT_PACKAGES += UsbSpeedSwitch
@@ -61,9 +65,6 @@
 # Build gralloc for hikey
 PRODUCT_PACKAGES += gralloc.hikey
 
-# Build Audio Hal for hikey
-PRODUCT_PACKAGES += audio.primary.hikey
-
 # Set zygote config
 PRODUCT_DEFAULT_PROPERTY_OVERRIDES += ro.zygote=zygote64_32
 PRODUCT_COPY_FILES += system/core/rootdir/init.zygote64_32.rc:root/init.zygote64_32.rc
@@ -80,7 +81,8 @@
         frameworks/native/data/etc/android.hardware.ethernet.xml:system/etc/permissions/android.hardware.ethernet.xml \
         frameworks/native/data/etc/android.software.app_widgets.xml:system/etc/permissions/android.software.app_widgets.xml \
         frameworks/native/data/etc/android.software.backup.xml:system/etc/permissions/android.software.backup.xml \
-        frameworks/native/data/etc/android.hardware.usb.accessory.xml:system/etc/permissions/android.hardware.usb.accessory.xml
+        frameworks/native/data/etc/android.hardware.usb.accessory.xml:system/etc/permissions/android.hardware.usb.accessory.xml \
+        frameworks/native/data/etc/android.hardware.usb.host.xml:system/etc/permissions/android.hardware.usb.host.xml
 
 # Include vendor binaries
 $(call inherit-product-if-exists, vendor/linaro/hikey/device-vendor.mk)