static int snapper_set_capture_source(pmac_tumbler_t *mix)
{
+ if (! mix->i2c.client)
+ return -ENODEV;
return snd_pmac_keywest_write_byte(&mix->i2c, TAS_REG_ACS,
mix->capture_source ? 2 : 0);
}
/* interrupt - headphone plug changed */
static irqreturn_t headphone_intr(int irq, void *devid, struct pt_regs *regs)
{
- pmac_t *chip = snd_magic_cast(pmac_t, devid, return);
+ pmac_t *chip = snd_magic_cast(pmac_t, devid, return IRQ_NONE);
if (chip->update_automute && chip->initialized) {
chip->update_automute(chip, 1);
return IRQ_HANDLED;