wm8731.c (871039f02f8ec4ab2e5e9010718caa8e085786f1) wm8731.c (e135443e2133473f44aa439ad333554dad14c21a)
1/*
2 * wm8731.c -- WM8731 ALSA SoC Audio driver
3 *
4 * Copyright 2005 Openedhand Ltd.
5 *
6 * Author: Richard Purdie <richard@openedhand.com>
7 *
8 * Based on wm8753.c by Liam Girdwood

--- 4 unchanged lines hidden (view full) ---

13 */
14
15#include <linux/module.h>
16#include <linux/moduleparam.h>
17#include <linux/init.h>
18#include <linux/delay.h>
19#include <linux/pm.h>
20#include <linux/i2c.h>
1/*
2 * wm8731.c -- WM8731 ALSA SoC Audio driver
3 *
4 * Copyright 2005 Openedhand Ltd.
5 *
6 * Author: Richard Purdie <richard@openedhand.com>
7 *
8 * Based on wm8753.c by Liam Girdwood

--- 4 unchanged lines hidden (view full) ---

13 */
14
15#include <linux/module.h>
16#include <linux/moduleparam.h>
17#include <linux/init.h>
18#include <linux/delay.h>
19#include <linux/pm.h>
20#include <linux/i2c.h>
21#include <linux/slab.h>
22#include <linux/platform_device.h>
23#include <linux/regulator/consumer.h>
24#include <linux/spi/spi.h>
25#include <sound/core.h>
26#include <sound/pcm.h>
27#include <sound/pcm_params.h>
28#include <sound/soc.h>
29#include <sound/soc-dapm.h>

--- 355 unchanged lines hidden (view full) ---

385 snd_soc_write(codec, WM8731_ACTIVE, 0x0);
386 snd_soc_write(codec, WM8731_PWR, 0xffff);
387 break;
388 }
389 codec->bias_level = level;
390 return 0;
391}
392
21#include <linux/platform_device.h>
22#include <linux/regulator/consumer.h>
23#include <linux/spi/spi.h>
24#include <sound/core.h>
25#include <sound/pcm.h>
26#include <sound/pcm_params.h>
27#include <sound/soc.h>
28#include <sound/soc-dapm.h>

--- 355 unchanged lines hidden (view full) ---

384 snd_soc_write(codec, WM8731_ACTIVE, 0x0);
385 snd_soc_write(codec, WM8731_PWR, 0xffff);
386 break;
387 }
388 codec->bias_level = level;
389 return 0;
390}
391
393#define WM8731_RATES (SNDRV_PCM_RATE_8000 | SNDRV_PCM_RATE_11025 |\
394 SNDRV_PCM_RATE_16000 | SNDRV_PCM_RATE_22050 |\
395 SNDRV_PCM_RATE_32000 | SNDRV_PCM_RATE_44100 |\
396 SNDRV_PCM_RATE_48000 | SNDRV_PCM_RATE_88200 |\
397 SNDRV_PCM_RATE_96000)
392#define WM8731_RATES SNDRV_PCM_RATE_8000_96000
398
399#define WM8731_FORMATS (SNDRV_PCM_FMTBIT_S16_LE | SNDRV_PCM_FMTBIT_S20_3LE |\
400 SNDRV_PCM_FMTBIT_S24_LE)
401
402static struct snd_soc_dai_ops wm8731_dai_ops = {
403 .prepare = wm8731_pcm_prepare,
404 .hw_params = wm8731_hw_params,
405 .shutdown = wm8731_shutdown,

--- 349 unchanged lines hidden ---
393
394#define WM8731_FORMATS (SNDRV_PCM_FMTBIT_S16_LE | SNDRV_PCM_FMTBIT_S20_3LE |\
395 SNDRV_PCM_FMTBIT_S24_LE)
396
397static struct snd_soc_dai_ops wm8731_dai_ops = {
398 .prepare = wm8731_pcm_prepare,
399 .hw_params = wm8731_hw_params,
400 .shutdown = wm8731_shutdown,

--- 349 unchanged lines hidden ---