cs8427
int snd_cs8427_iec958_build(struct snd_i2c_device *cs8427,
int snd_cs8427_iec958_active(struct snd_i2c_device *cs8427, int active);
int snd_cs8427_iec958_pcm(struct snd_i2c_device *cs8427, unsigned int rate);
struct cs8427 *chip = device->private_data;
struct cs8427 *chip = device->private_data;
static void snd_cs8427_reset(struct snd_i2c_device *cs8427);
struct cs8427 *chip;
static void snd_cs8427_reset(struct snd_i2c_device *cs8427)
struct cs8427 *chip;
if (snd_BUG_ON(!cs8427))
chip = cs8427->private_data;
snd_i2c_lock(cs8427->bus);
snd_cs8427_reg_write(cs8427, CS8427_REG_CLOCKSOURCE,
snd_cs8427_reg_write(cs8427, CS8427_REG_CLOCKSOURCE,
snd_i2c_unlock(cs8427->bus);
snd_i2c_lock(cs8427->bus);
data = snd_cs8427_reg_read(cs8427, CS8427_REG_RECVERRORS);
snd_i2c_unlock(cs8427->bus);
snd_i2c_lock(cs8427->bus);
snd_cs8427_reg_write(cs8427, CS8427_REG_CLOCKSOURCE,
snd_i2c_unlock(cs8427->bus);
struct cs8427 *chip = device->private_data;
struct cs8427 *chip = device->private_data;
int snd_cs8427_iec958_build(struct snd_i2c_device *cs8427,
struct cs8427 *chip = cs8427->private_data;
kctl = snd_ctl_new1(&snd_cs8427_iec958_controls[idx], cs8427);
err = snd_ctl_add(cs8427->bus->card, kctl);
int snd_cs8427_iec958_active(struct snd_i2c_device *cs8427, int active)
struct cs8427 *chip;
if (snd_BUG_ON(!cs8427))
chip = cs8427->private_data;
snd_ctl_notify(cs8427->bus->card,
int snd_cs8427_iec958_pcm(struct snd_i2c_device *cs8427, unsigned int rate)
struct cs8427 *chip;
if (snd_BUG_ON(!cs8427))
chip = cs8427->private_data;
snd_i2c_lock(cs8427->bus);
err = snd_cs8427_send_corudata(cs8427, 0, status, 24);
snd_ctl_notify(cs8427->bus->card,
snd_i2c_unlock(cs8427->bus);
snd_cs8427_reset(cs8427);
struct cs8427 *chip = device->private_data;
if (snd_i2c_sendbytes(ice->cs8427, ®, 1) != 1)
snd_i2c_readbytes(ice->cs8427, ®, 1);
snd_cs8427_init(ice->i2c, ice->cs8427);
snd_cs8427_reg_write(ice->cs8427, CS8427_REG_RECVERRMASK, CS8427_UNLOCK | CS8427_CONF | CS8427_BIP | CS8427_PAR);
snd_cs8427_reg_write(ice->cs8427, CS8427_REG_RECVERRMASK, CS8427_UNLOCK | CS8427_CONF | CS8427_BIP | CS8427_PAR);
if (ice->cs8427 == NULL) {
if (ice->cs8427) {
err = snd_cs8427_iec958_build(ice->cs8427,
if (snd_i2c_sendbytes(ice->cs8427, reg, 1) != 1) {
if (snd_i2c_readbytes(ice->cs8427, &val, 1) != 1) {
if (snd_i2c_sendbytes(ice->cs8427, reg, 2) != 2) {
snd_cs8427_iec958_active(ice->cs8427, 1);
snd_cs8427_iec958_active(ice->cs8427, 0);
snd_cs8427_iec958_pcm(ice->cs8427, rate);
(ice->cs8427_timeout * HZ) / 1000, &ice->cs8427);
if (ice->cs8427)
struct snd_i2c_device *cs8427; /* CS8427 I2C device */