mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 10:41:38 -04:00
ASoC: arm: make pxa2xx-ac97-lib ac97 codec agnostic
All pxa library functions don't use the input parameters for nothing but slot number. This simplifies their prototypes, and makes them usable by both the legacy ac97 bus and the new ac97 bus. Signed-off-by: Robert Jarzmik <[email protected]> Signed-off-by: Mark Brown <[email protected]>
This commit is contained in:
parent
8d43344108
commit
6f8acad646
4 changed files with 83 additions and 36 deletions
|
|
@ -1,10 +1,13 @@
|
|||
#ifndef PXA2XX_LIB_H
|
||||
#define PXA2XX_LIB_H
|
||||
|
||||
#include <uapi/sound/asound.h>
|
||||
#include <linux/platform_device.h>
|
||||
#include <sound/ac97_codec.h>
|
||||
|
||||
/* PCM */
|
||||
struct snd_pcm_substream;
|
||||
struct snd_pcm_hw_params;
|
||||
struct snd_pcm;
|
||||
|
||||
extern int __pxa2xx_pcm_hw_params(struct snd_pcm_substream *substream,
|
||||
struct snd_pcm_hw_params *params);
|
||||
|
|
@ -21,12 +24,12 @@ extern void pxa2xx_pcm_free_dma_buffers(struct snd_pcm *pcm);
|
|||
|
||||
/* AC97 */
|
||||
|
||||
extern unsigned short pxa2xx_ac97_read(struct snd_ac97 *ac97, unsigned short reg);
|
||||
extern void pxa2xx_ac97_write(struct snd_ac97 *ac97, unsigned short reg, unsigned short val);
|
||||
extern int pxa2xx_ac97_read(int slot, unsigned short reg);
|
||||
extern int pxa2xx_ac97_write(int slot, unsigned short reg, unsigned short val);
|
||||
|
||||
extern bool pxa2xx_ac97_try_warm_reset(struct snd_ac97 *ac97);
|
||||
extern bool pxa2xx_ac97_try_cold_reset(struct snd_ac97 *ac97);
|
||||
extern void pxa2xx_ac97_finish_reset(struct snd_ac97 *ac97);
|
||||
extern bool pxa2xx_ac97_try_warm_reset(void);
|
||||
extern bool pxa2xx_ac97_try_cold_reset(void);
|
||||
extern void pxa2xx_ac97_finish_reset(void);
|
||||
|
||||
extern int pxa2xx_ac97_hw_suspend(void);
|
||||
extern int pxa2xx_ac97_hw_resume(void);
|
||||
|
|
|
|||
Loading…
Reference in a new issue