void mods_exit_tegradc(void) { #if defined(CONFIG_TEGRA_NVSD) int i; LOG_ENT(); for (i = 0; i < TEGRA_MAX_DC; i++) { struct tegra_dc *dc = tegra_dc_get_dc(i); if (!dc) continue; if (!tegra_dc_saved_sd_settings[i]) nvsd_remove_sysfs(&dc->ndev->dev); dc->out->sd_settings = tegra_dc_saved_sd_settings[i]; if (dc->enabled) nvsd_init(dc, dc->out->sd_settings); } #endif }
void __devexit tegra_dc_remove_sysfs(struct device *dev) { struct nvhost_device *ndev = to_nvhost_device(dev); struct tegra_dc *dc = nvhost_get_drvdata(ndev); struct tegra_dc_sd_settings *sd_settings = dc->out->sd_settings; device_remove_file(dev, &dev_attr_mode); device_remove_file(dev, &dev_attr_nvdps); device_remove_file(dev, &dev_attr_enable); device_remove_file(dev, &dev_attr_stats_enable); device_remove_file(dev, &dev_attr_crc_checksum_latched); if (dc->out->stereo) { device_remove_file(dev, &dev_attr_stereo_orientation); device_remove_file(dev, &dev_attr_stereo_mode); } if (sd_settings) nvsd_remove_sysfs(dev); }