aboutsummaryrefslogtreecommitdiffstats
path: root/sound/soc/imx/imx-audmux.c
diff options
context:
space:
mode:
Diffstat (limited to 'sound/soc/imx/imx-audmux.c')
-rw-r--r--sound/soc/imx/imx-audmux.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/sound/soc/imx/imx-audmux.c b/sound/soc/imx/imx-audmux.c
index 1765a197acb0..f23700359c67 100644
--- a/sound/soc/imx/imx-audmux.c
+++ b/sound/soc/imx/imx-audmux.c
@@ -73,6 +73,9 @@ static ssize_t audmux_read_file(struct file *file, char __user *user_buf,
73 if (!buf) 73 if (!buf)
74 return -ENOMEM; 74 return -ENOMEM;
75 75
76 if (!audmux_base)
77 return -ENOSYS;
78
76 if (audmux_clk) 79 if (audmux_clk)
77 clk_prepare_enable(audmux_clk); 80 clk_prepare_enable(audmux_clk);
78 81
@@ -152,7 +155,7 @@ static void __init audmux_debugfs_init(void)
152 return; 155 return;
153 } 156 }
154 157
155 for (i = 1; i < 8; i++) { 158 for (i = 0; i < MX31_AUDMUX_PORT6_SSI_PINS_6 + 1; i++) {
156 snprintf(buf, sizeof(buf), "ssi%d", i); 159 snprintf(buf, sizeof(buf), "ssi%d", i);
157 if (!debugfs_create_file(buf, 0444, audmux_debugfs_root, 160 if (!debugfs_create_file(buf, 0444, audmux_debugfs_root,
158 (void *)i, &audmux_debugfs_fops)) 161 (void *)i, &audmux_debugfs_fops))