Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(397)

Side by Side Diff: sound/soc/samsung/s3c24xx_uda134x.c

Issue 6577007: CHROMIUM: ASoC: Import entire upstream ASoC tree (Closed)
Patch Set: Created 9 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « sound/soc/samsung/s3c24xx_simtec_tlv320aic23.c ('k') | sound/soc/samsung/smartq_wm8987.c » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Modifications by Christian Pellegrin <chripell@evolware.org> 2 * Modifications by Christian Pellegrin <chripell@evolware.org>
3 * 3 *
4 * s3c24xx_uda134x.c -- S3C24XX_UDA134X ALSA SoC Audio board driver 4 * s3c24xx_uda134x.c -- S3C24XX_UDA134X ALSA SoC Audio board driver
5 * 5 *
6 * Copyright 2007 Dension Audio Systems Ltd. 6 * Copyright 2007 Dension Audio Systems Ltd.
7 * Author: Zoltan Devai 7 * Author: Zoltan Devai
8 * 8 *
9 * This program is free software; you can redistribute it and/or modify 9 * This program is free software; you can redistribute it and/or modify
10 * it under the terms of the GNU General Public License version 2 as 10 * it under the terms of the GNU General Public License version 2 as
11 * published by the Free Software Foundation. 11 * published by the Free Software Foundation.
12 */ 12 */
13 13
14 #include <linux/module.h>
15 #include <linux/clk.h> 14 #include <linux/clk.h>
16 #include <linux/mutex.h>
17 #include <linux/gpio.h> 15 #include <linux/gpio.h>
18 #include <sound/pcm.h> 16
19 #include <sound/pcm_params.h>
20 #include <sound/soc.h> 17 #include <sound/soc.h>
21 #include <sound/soc-dapm.h>
22 #include <sound/s3c24xx_uda134x.h> 18 #include <sound/s3c24xx_uda134x.h>
23 #include <sound/uda134x.h>
24 19
25 #include <plat/regs-iis.h> 20 #include <plat/regs-iis.h>
26 21
27 #include "s3c-dma.h"
28 #include "s3c24xx-i2s.h" 22 #include "s3c24xx-i2s.h"
29 #include "../codecs/uda134x.h"
30
31 23
32 /* #define ENFORCE_RATES 1 */ 24 /* #define ENFORCE_RATES 1 */
33 /* 25 /*
34 Unfortunately the S3C24XX in master mode has a limited capacity of 26 Unfortunately the S3C24XX in master mode has a limited capacity of
35 generating the clock for the codec. If you define this only rates 27 generating the clock for the codec. If you define this only rates
36 that are really available will be enforced. But be careful, most 28 that are really available will be enforced. But be careful, most
37 user level application just want the usual sampling frequencies (8, 29 user level application just want the usual sampling frequencies (8,
38 11.025, 22.050, 44.1 kHz) and anyway resampling is a costly 30 11.025, 22.050, 44.1 kHz) and anyway resampling is a costly
39 operation for embedded systems. So if you aren't very lucky or your 31 operation for embedded systems. So if you aren't very lucky or your
40 hardware engineer wasn't very forward-looking it's better to leave 32 hardware engineer wasn't very forward-looking it's better to leave
(...skipping 181 matching lines...) Expand 10 before | Expand all | Expand 10 after
222 .startup = s3c24xx_uda134x_startup, 214 .startup = s3c24xx_uda134x_startup,
223 .shutdown = s3c24xx_uda134x_shutdown, 215 .shutdown = s3c24xx_uda134x_shutdown,
224 .hw_params = s3c24xx_uda134x_hw_params, 216 .hw_params = s3c24xx_uda134x_hw_params,
225 }; 217 };
226 218
227 static struct snd_soc_dai_link s3c24xx_uda134x_dai_link = { 219 static struct snd_soc_dai_link s3c24xx_uda134x_dai_link = {
228 .name = "UDA134X", 220 .name = "UDA134X",
229 .stream_name = "UDA134X", 221 .stream_name = "UDA134X",
230 .codec_name = "uda134x-hifi", 222 .codec_name = "uda134x-hifi",
231 .codec_dai_name = "uda134x-hifi", 223 .codec_dai_name = "uda134x-hifi",
232 » .cpu_dai_name = "s3c24xx-i2s", 224 » .cpu_dai_name = "s3c24xx-iis",
233 .ops = &s3c24xx_uda134x_ops, 225 .ops = &s3c24xx_uda134x_ops,
234 » .platform_name» = "s3c24xx-pcm-audio", 226 » .platform_name» = "samsung-audio",
235 }; 227 };
236 228
237 static struct snd_soc_card snd_soc_s3c24xx_uda134x = { 229 static struct snd_soc_card snd_soc_s3c24xx_uda134x = {
238 .name = "S3C24XX_UDA134X", 230 .name = "S3C24XX_UDA134X",
239 .dai_link = &s3c24xx_uda134x_dai_link, 231 .dai_link = &s3c24xx_uda134x_dai_link,
240 .num_links = 1, 232 .num_links = 1,
241 }; 233 };
242 234
243 static struct s3c24xx_uda134x_platform_data *s3c24xx_uda134x_l3_pins; 235 static struct s3c24xx_uda134x_platform_data *s3c24xx_uda134x_l3_pins;
244 236
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after
359 platform_driver_unregister(&s3c24xx_uda134x_driver); 351 platform_driver_unregister(&s3c24xx_uda134x_driver);
360 } 352 }
361 353
362 354
363 module_init(s3c24xx_uda134x_init); 355 module_init(s3c24xx_uda134x_init);
364 module_exit(s3c24xx_uda134x_exit); 356 module_exit(s3c24xx_uda134x_exit);
365 357
366 MODULE_AUTHOR("Zoltan Devai, Christian Pellegrin <chripell@evolware.org>"); 358 MODULE_AUTHOR("Zoltan Devai, Christian Pellegrin <chripell@evolware.org>");
367 MODULE_DESCRIPTION("S3C24XX_UDA134X ALSA SoC audio driver"); 359 MODULE_DESCRIPTION("S3C24XX_UDA134X ALSA SoC audio driver");
368 MODULE_LICENSE("GPL"); 360 MODULE_LICENSE("GPL");
OLDNEW
« no previous file with comments | « sound/soc/samsung/s3c24xx_simtec_tlv320aic23.c ('k') | sound/soc/samsung/smartq_wm8987.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698