summaryrefslogtreecommitdiffstats
path: root/sound/hda
diff options
context:
space:
mode:
authorMark Brown <broonie@kernel.org>2016-05-13 14:27:16 +0100
committerMark Brown <broonie@kernel.org>2016-05-13 14:27:16 +0100
commit515511a7920c69aebf7f5fef0cb8e1df6767f34c (patch)
tree2cd9ac2853bb11aa2eeb766bb18c0b1846d8d941 /sound/hda
parent180bc41ad11b9a7ec5b420fbcef6570163d09204 (diff)
parent8f658815da156a9239b98b34e5ba1d3db71a2f6e (diff)
downloadop-kernel-dev-515511a7920c69aebf7f5fef0cb8e1df6767f34c.zip
op-kernel-dev-515511a7920c69aebf7f5fef0cb8e1df6767f34c.tar.gz
Merge remote-tracking branch 'asoc/topic/hdmi' into asoc-next
Diffstat (limited to 'sound/hda')
-rw-r--r--sound/hda/local.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/sound/hda/local.h b/sound/hda/local.h
index d692f41..0d5bb15 100644
--- a/sound/hda/local.h
+++ b/sound/hda/local.h
@@ -16,6 +16,16 @@ static inline int get_wcaps_type(unsigned int wcaps)
return (wcaps & AC_WCAP_TYPE) >> AC_WCAP_TYPE_SHIFT;
}
+static inline unsigned int get_wcaps_channels(u32 wcaps)
+{
+ unsigned int chans;
+
+ chans = (wcaps & AC_WCAP_CHAN_CNT_EXT) >> 13;
+ chans = (chans + 1) * 2;
+
+ return chans;
+}
+
extern const struct attribute_group *hdac_dev_attr_groups[];
int hda_widget_sysfs_init(struct hdac_device *codec);
void hda_widget_sysfs_exit(struct hdac_device *codec);
OpenPOWER on IntegriCloud