linux/sound/i2c/other/ak4114.c

// SPDX-License-Identifier: GPL-2.0-or-later
/*
 *  Routines for control of the AK4114 via I2C and 4-wire serial interface
 *  IEC958 (S/PDIF) receiver by Asahi Kasei
 *  Copyright (c) by Jaroslav Kysela <[email protected]>
 */

#include <linux/slab.h>
#include <linux/delay.h>
#include <linux/module.h>
#include <sound/core.h>
#include <sound/control.h>
#include <sound/pcm.h>
#include <sound/ak4114.h>
#include <sound/asoundef.h>
#include <sound/info.h>

MODULE_AUTHOR();
MODULE_DESCRIPTION();
MODULE_LICENSE();

#define AK4114_ADDR

static void ak4114_stats(struct work_struct *work);
static void ak4114_init_regs(struct ak4114 *chip);

static void reg_write(struct ak4114 *ak4114, unsigned char reg, unsigned char val)
{}

static inline unsigned char reg_read(struct ak4114 *ak4114, unsigned char reg)
{}

#if 0
static void reg_dump(struct ak4114 *ak4114)
{
	int i;

	printk(KERN_DEBUG "AK4114 REG DUMP:\n");
	for (i = 0; i < 0x20; i++)
		printk(KERN_DEBUG "reg[%02x] = %02x (%02x)\n", i, reg_read(ak4114, i), i < ARRAY_SIZE(ak4114->regmap) ? ak4114->regmap[i] : 0);
}
#endif

static void snd_ak4114_free(struct ak4114 *chip)
{}

static int snd_ak4114_dev_free(struct snd_device *device)
{}

int snd_ak4114_create(struct snd_card *card,
		      ak4114_read_t *read, ak4114_write_t *write,
		      const unsigned char pgm[6], const unsigned char txcsb[5],
		      void *private_data, struct ak4114 **r_ak4114)
{}
EXPORT_SYMBOL();

void snd_ak4114_reg_write(struct ak4114 *chip, unsigned char reg, unsigned char mask, unsigned char val)
{}
EXPORT_SYMBOL();

static void ak4114_init_regs(struct ak4114 *chip)
{}

void snd_ak4114_reinit(struct ak4114 *chip)
{}
EXPORT_SYMBOL();

static unsigned int external_rate(unsigned char rcs1)
{}

static int snd_ak4114_in_error_info(struct snd_kcontrol *kcontrol,
				    struct snd_ctl_elem_info *uinfo)
{}

static int snd_ak4114_in_error_get(struct snd_kcontrol *kcontrol,
				   struct snd_ctl_elem_value *ucontrol)
{}

#define snd_ak4114_in_bit_info

static int snd_ak4114_in_bit_get(struct snd_kcontrol *kcontrol,
				 struct snd_ctl_elem_value *ucontrol)
{}

static int snd_ak4114_rate_info(struct snd_kcontrol *kcontrol,
				struct snd_ctl_elem_info *uinfo)
{}

static int snd_ak4114_rate_get(struct snd_kcontrol *kcontrol,
			       struct snd_ctl_elem_value *ucontrol)
{}

static int snd_ak4114_spdif_info(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_info *uinfo)
{}

static int snd_ak4114_spdif_get(struct snd_kcontrol *kcontrol,
				struct snd_ctl_elem_value *ucontrol)
{}

static int snd_ak4114_spdif_playback_get(struct snd_kcontrol *kcontrol,
					 struct snd_ctl_elem_value *ucontrol)
{}

static int snd_ak4114_spdif_playback_put(struct snd_kcontrol *kcontrol,
					 struct snd_ctl_elem_value *ucontrol)
{}

static int snd_ak4114_spdif_mask_info(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_info *uinfo)
{}

static int snd_ak4114_spdif_mask_get(struct snd_kcontrol *kcontrol,
				      struct snd_ctl_elem_value *ucontrol)
{}

static int snd_ak4114_spdif_pinfo(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_info *uinfo)
{}

static int snd_ak4114_spdif_pget(struct snd_kcontrol *kcontrol,
				 struct snd_ctl_elem_value *ucontrol)
{}

static int snd_ak4114_spdif_qinfo(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_info *uinfo)
{}

static int snd_ak4114_spdif_qget(struct snd_kcontrol *kcontrol,
				 struct snd_ctl_elem_value *ucontrol)
{}

/* Don't forget to change AK4114_CONTROLS define!!! */
static const struct snd_kcontrol_new snd_ak4114_iec958_controls[] =;


static void snd_ak4114_proc_regs_read(struct snd_info_entry *entry,
		struct snd_info_buffer *buffer)
{}

static void snd_ak4114_proc_init(struct ak4114 *ak4114)
{}

int snd_ak4114_build(struct ak4114 *ak4114,
		     struct snd_pcm_substream *ply_substream,
		     struct snd_pcm_substream *cap_substream)
{}
EXPORT_SYMBOL();

/* notify kcontrols if any parameters are changed */
static void ak4114_notify(struct ak4114 *ak4114,
			  unsigned char rcs0, unsigned char rcs1,
			  unsigned char c0, unsigned char c1)
{}

int snd_ak4114_external_rate(struct ak4114 *ak4114)
{}
EXPORT_SYMBOL();

int snd_ak4114_check_rate_and_errors(struct ak4114 *ak4114, unsigned int flags)
{}
EXPORT_SYMBOL();

static void ak4114_stats(struct work_struct *work)
{}

#ifdef CONFIG_PM
void snd_ak4114_suspend(struct ak4114 *chip)
{}
EXPORT_SYMBOL();

void snd_ak4114_resume(struct ak4114 *chip)
{}
EXPORT_SYMBOL();
#endif