Commit d033c36a authored by Mark Brown's avatar Mark Brown

ASoC: Display the power register in DAPM widget debugfs

Make it a bit easier to tie DAPM widgets in with the register map
without referring to the source by including the register location
controlled by the widget.
Signed-off-by: default avatarMark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: default avatarLiam Girdwood <lrg@slimlogic.co.uk>
parent dd1b3d53
...@@ -1147,9 +1147,16 @@ static ssize_t dapm_widget_power_read_file(struct file *file, ...@@ -1147,9 +1147,16 @@ static ssize_t dapm_widget_power_read_file(struct file *file,
out = is_connected_output_ep(w); out = is_connected_output_ep(w);
dapm_clear_walk(w->codec); dapm_clear_walk(w->codec);
ret = snprintf(buf, PAGE_SIZE, "%s: %s in %d out %d\n", ret = snprintf(buf, PAGE_SIZE, "%s: %s in %d out %d",
w->name, w->power ? "On" : "Off", in, out); w->name, w->power ? "On" : "Off", in, out);
if (w->reg >= 0)
ret += snprintf(buf + ret, PAGE_SIZE - ret,
" - R%d(0x%x) bit %d",
w->reg, w->reg, w->shift);
ret += snprintf(buf + ret, PAGE_SIZE - ret, "\n");
if (w->sname) if (w->sname)
ret += snprintf(buf + ret, PAGE_SIZE - ret, " stream %s %s\n", ret += snprintf(buf + ret, PAGE_SIZE - ret, " stream %s %s\n",
w->sname, w->sname,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment