static int __devexit tegra_i2s_platform_remove(struct platform_device *pdev) { struct tegra_i2s *i2s = dev_get_drvdata(&pdev->dev); snd_soc_unregister_dai(&pdev->dev); tegra_i2s_debug_remove(i2s); clk_put(i2s->clk_i2s); return 0; }
static int __devexit tegra_i2s_platform_remove(struct platform_device *pdev) { struct tegra_i2s *i2s = dev_get_drvdata(&pdev->dev); struct resource *res; snd_soc_unregister_dai(&pdev->dev); tegra_i2s_debug_remove(i2s); iounmap(i2s->regs); res = platform_get_resource(pdev, IORESOURCE_MEM, 0); release_mem_region(res->start, resource_size(res)); clk_put(i2s->clk_i2s); kfree(i2s); return 0; }