out_le32(&chip->awacs->control, in_le32(&chip->awacs->control) & 0xfff);
}
- snd_pmac_sound_feature(chip, 0);
+ if (chip->node)
+ snd_pmac_sound_feature(chip, 0);
/* clean up mixer if any */
if (chip->mixer_free)
}
if (! sound) {
of_node_put(chip->node);
+ chip->node = NULL;
return -ENODEV;
}
prop = of_get_property(sound, "sub-frame", NULL);
printk(KERN_INFO "snd-powermac no longer handles any "
"machines with a layout-id property "
"in the device-tree, use snd-aoa.\n");
+ of_node_put(sound);
of_node_put(chip->node);
+ chip->node = NULL;
return -ENODEV;
}
/* This should be verified on older screamers */
return 0;
__error:
- if (chip->pdev)
- pci_dev_put(chip->pdev);
snd_pmac_free(chip);
return err;
}