diff options
author | Shawn Guo <shawn.guo@linaro.org> | 2012-03-05 09:30:54 -0500 |
---|---|---|
committer | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2012-03-05 19:03:04 -0500 |
commit | af4872fb39301bbe196d0778f80d22ec51d8884b (patch) | |
tree | c2c72d11003bd24141c03ab9faefbd9529a7760e /sound/soc/imx/imx-audmux.c | |
parent | 3c77c29c49c6213c55ad8dacc687817b3568c0ce (diff) |
ASoC: imx: rename audmux prefix mxc to imx
It renames the legacy name mxc used in audmux function and macro
to imx.
Signed-off-by: Shawn Guo <shawn.guo@linaro.org>
Acked-by: Sascha Hauer <s.hauer@pengutronix.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Diffstat (limited to 'sound/soc/imx/imx-audmux.c')
-rw-r--r-- | sound/soc/imx/imx-audmux.c | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/sound/soc/imx/imx-audmux.c b/sound/soc/imx/imx-audmux.c index 7b162662fe6b..87f8768e1cdc 100644 --- a/sound/soc/imx/imx-audmux.c +++ b/sound/soc/imx/imx-audmux.c | |||
@@ -32,8 +32,8 @@ | |||
32 | static struct clk *audmux_clk; | 32 | static struct clk *audmux_clk; |
33 | static void __iomem *audmux_base; | 33 | static void __iomem *audmux_base; |
34 | 34 | ||
35 | #define MXC_AUDMUX_V2_PTCR(x) ((x) * 8) | 35 | #define IMX_AUDMUX_V2_PTCR(x) ((x) * 8) |
36 | #define MXC_AUDMUX_V2_PDCR(x) ((x) * 8 + 4) | 36 | #define IMX_AUDMUX_V2_PDCR(x) ((x) * 8 + 4) |
37 | 37 | ||
38 | #ifdef CONFIG_DEBUG_FS | 38 | #ifdef CONFIG_DEBUG_FS |
39 | static struct dentry *audmux_debugfs_root; | 39 | static struct dentry *audmux_debugfs_root; |
@@ -80,8 +80,8 @@ static ssize_t audmux_read_file(struct file *file, char __user *user_buf, | |||
80 | if (audmux_clk) | 80 | if (audmux_clk) |
81 | clk_enable(audmux_clk); | 81 | clk_enable(audmux_clk); |
82 | 82 | ||
83 | ptcr = readl(audmux_base + MXC_AUDMUX_V2_PTCR(port)); | 83 | ptcr = readl(audmux_base + IMX_AUDMUX_V2_PTCR(port)); |
84 | pdcr = readl(audmux_base + MXC_AUDMUX_V2_PDCR(port)); | 84 | pdcr = readl(audmux_base + IMX_AUDMUX_V2_PDCR(port)); |
85 | 85 | ||
86 | if (audmux_clk) | 86 | if (audmux_clk) |
87 | clk_disable(audmux_clk); | 87 | clk_disable(audmux_clk); |
@@ -89,7 +89,7 @@ static ssize_t audmux_read_file(struct file *file, char __user *user_buf, | |||
89 | ret = snprintf(buf, PAGE_SIZE, "PDCR: %08x\nPTCR: %08x\n", | 89 | ret = snprintf(buf, PAGE_SIZE, "PDCR: %08x\nPTCR: %08x\n", |
90 | pdcr, ptcr); | 90 | pdcr, ptcr); |
91 | 91 | ||
92 | if (ptcr & MXC_AUDMUX_V2_PTCR_TFSDIR) | 92 | if (ptcr & IMX_AUDMUX_V2_PTCR_TFSDIR) |
93 | ret += snprintf(buf + ret, PAGE_SIZE - ret, | 93 | ret += snprintf(buf + ret, PAGE_SIZE - ret, |
94 | "TxFS output from %s, ", | 94 | "TxFS output from %s, ", |
95 | audmux_port_string((ptcr >> 27) & 0x7)); | 95 | audmux_port_string((ptcr >> 27) & 0x7)); |
@@ -97,7 +97,7 @@ static ssize_t audmux_read_file(struct file *file, char __user *user_buf, | |||
97 | ret += snprintf(buf + ret, PAGE_SIZE - ret, | 97 | ret += snprintf(buf + ret, PAGE_SIZE - ret, |
98 | "TxFS input, "); | 98 | "TxFS input, "); |
99 | 99 | ||
100 | if (ptcr & MXC_AUDMUX_V2_PTCR_TCLKDIR) | 100 | if (ptcr & IMX_AUDMUX_V2_PTCR_TCLKDIR) |
101 | ret += snprintf(buf + ret, PAGE_SIZE - ret, | 101 | ret += snprintf(buf + ret, PAGE_SIZE - ret, |
102 | "TxClk output from %s", | 102 | "TxClk output from %s", |
103 | audmux_port_string((ptcr >> 22) & 0x7)); | 103 | audmux_port_string((ptcr >> 22) & 0x7)); |
@@ -107,11 +107,11 @@ static ssize_t audmux_read_file(struct file *file, char __user *user_buf, | |||
107 | 107 | ||
108 | ret += snprintf(buf + ret, PAGE_SIZE - ret, "\n"); | 108 | ret += snprintf(buf + ret, PAGE_SIZE - ret, "\n"); |
109 | 109 | ||
110 | if (ptcr & MXC_AUDMUX_V2_PTCR_SYN) { | 110 | if (ptcr & IMX_AUDMUX_V2_PTCR_SYN) { |
111 | ret += snprintf(buf + ret, PAGE_SIZE - ret, | 111 | ret += snprintf(buf + ret, PAGE_SIZE - ret, |
112 | "Port is symmetric"); | 112 | "Port is symmetric"); |
113 | } else { | 113 | } else { |
114 | if (ptcr & MXC_AUDMUX_V2_PTCR_RFSDIR) | 114 | if (ptcr & IMX_AUDMUX_V2_PTCR_RFSDIR) |
115 | ret += snprintf(buf + ret, PAGE_SIZE - ret, | 115 | ret += snprintf(buf + ret, PAGE_SIZE - ret, |
116 | "RxFS output from %s, ", | 116 | "RxFS output from %s, ", |
117 | audmux_port_string((ptcr >> 17) & 0x7)); | 117 | audmux_port_string((ptcr >> 17) & 0x7)); |
@@ -119,7 +119,7 @@ static ssize_t audmux_read_file(struct file *file, char __user *user_buf, | |||
119 | ret += snprintf(buf + ret, PAGE_SIZE - ret, | 119 | ret += snprintf(buf + ret, PAGE_SIZE - ret, |
120 | "RxFS input, "); | 120 | "RxFS input, "); |
121 | 121 | ||
122 | if (ptcr & MXC_AUDMUX_V2_PTCR_RCLKDIR) | 122 | if (ptcr & IMX_AUDMUX_V2_PTCR_RCLKDIR) |
123 | ret += snprintf(buf + ret, PAGE_SIZE - ret, | 123 | ret += snprintf(buf + ret, PAGE_SIZE - ret, |
124 | "RxClk output from %s", | 124 | "RxClk output from %s", |
125 | audmux_port_string((ptcr >> 12) & 0x7)); | 125 | audmux_port_string((ptcr >> 12) & 0x7)); |
@@ -201,7 +201,7 @@ static const uint8_t port_mapping[] = { | |||
201 | 0x0, 0x4, 0x8, 0x10, 0x14, 0x1c, | 201 | 0x0, 0x4, 0x8, 0x10, 0x14, 0x1c, |
202 | }; | 202 | }; |
203 | 203 | ||
204 | int mxc_audmux_v1_configure_port(unsigned int port, unsigned int pcr) | 204 | int imx_audmux_v1_configure_port(unsigned int port, unsigned int pcr) |
205 | { | 205 | { |
206 | if (audmux_type != IMX21_AUDMUX) | 206 | if (audmux_type != IMX21_AUDMUX) |
207 | return -EINVAL; | 207 | return -EINVAL; |
@@ -216,9 +216,9 @@ int mxc_audmux_v1_configure_port(unsigned int port, unsigned int pcr) | |||
216 | 216 | ||
217 | return 0; | 217 | return 0; |
218 | } | 218 | } |
219 | EXPORT_SYMBOL_GPL(mxc_audmux_v1_configure_port); | 219 | EXPORT_SYMBOL_GPL(imx_audmux_v1_configure_port); |
220 | 220 | ||
221 | int mxc_audmux_v2_configure_port(unsigned int port, unsigned int ptcr, | 221 | int imx_audmux_v2_configure_port(unsigned int port, unsigned int ptcr, |
222 | unsigned int pdcr) | 222 | unsigned int pdcr) |
223 | { | 223 | { |
224 | if (audmux_type != IMX31_AUDMUX) | 224 | if (audmux_type != IMX31_AUDMUX) |
@@ -230,15 +230,15 @@ int mxc_audmux_v2_configure_port(unsigned int port, unsigned int ptcr, | |||
230 | if (audmux_clk) | 230 | if (audmux_clk) |
231 | clk_enable(audmux_clk); | 231 | clk_enable(audmux_clk); |
232 | 232 | ||
233 | writel(ptcr, audmux_base + MXC_AUDMUX_V2_PTCR(port)); | 233 | writel(ptcr, audmux_base + IMX_AUDMUX_V2_PTCR(port)); |
234 | writel(pdcr, audmux_base + MXC_AUDMUX_V2_PDCR(port)); | 234 | writel(pdcr, audmux_base + IMX_AUDMUX_V2_PDCR(port)); |
235 | 235 | ||
236 | if (audmux_clk) | 236 | if (audmux_clk) |
237 | clk_disable(audmux_clk); | 237 | clk_disable(audmux_clk); |
238 | 238 | ||
239 | return 0; | 239 | return 0; |
240 | } | 240 | } |
241 | EXPORT_SYMBOL_GPL(mxc_audmux_v2_configure_port); | 241 | EXPORT_SYMBOL_GPL(imx_audmux_v2_configure_port); |
242 | 242 | ||
243 | static int __init imx_audmux_probe(struct platform_device *pdev) | 243 | static int __init imx_audmux_probe(struct platform_device *pdev) |
244 | { | 244 | { |