Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

drm/tegra: rgb: Make tegra_dc_rgb_remove() return void

This function returned zero unconditionally. Make it return no value and
simplify all callers accordingly.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Thierry Reding <treding@nvidia.com>

authored by

Uwe Kleine-König and committed by
Thierry Reding
43740540 55879dad

+4 -11
+1 -6
drivers/gpu/drm/tegra/dc.c
··· 3266 3266 static int tegra_dc_remove(struct platform_device *pdev) 3267 3267 { 3268 3268 struct tegra_dc *dc = platform_get_drvdata(pdev); 3269 - int err; 3270 3269 3271 3270 host1x_client_unregister(&dc->client); 3272 3271 3273 - err = tegra_dc_rgb_remove(dc); 3274 - if (err < 0) { 3275 - dev_err(&pdev->dev, "failed to remove RGB output: %d\n", err); 3276 - return err; 3277 - } 3272 + tegra_dc_rgb_remove(dc); 3278 3273 3279 3274 pm_runtime_disable(&pdev->dev); 3280 3275
+1 -1
drivers/gpu/drm/tegra/dc.h
··· 169 169 170 170 /* from rgb.c */ 171 171 int tegra_dc_rgb_probe(struct tegra_dc *dc); 172 - int tegra_dc_rgb_remove(struct tegra_dc *dc); 172 + void tegra_dc_rgb_remove(struct tegra_dc *dc); 173 173 int tegra_dc_rgb_init(struct drm_device *drm, struct tegra_dc *dc); 174 174 int tegra_dc_rgb_exit(struct tegra_dc *dc); 175 175
+2 -4
drivers/gpu/drm/tegra/rgb.c
··· 250 250 return 0; 251 251 } 252 252 253 - int tegra_dc_rgb_remove(struct tegra_dc *dc) 253 + void tegra_dc_rgb_remove(struct tegra_dc *dc) 254 254 { 255 255 struct tegra_rgb *rgb; 256 256 257 257 if (!dc->rgb) 258 - return 0; 258 + return; 259 259 260 260 rgb = to_rgb(dc->rgb); 261 261 clk_put(rgb->pll_d2_out0); ··· 263 263 264 264 tegra_output_remove(dc->rgb); 265 265 dc->rgb = NULL; 266 - 267 - return 0; 268 266 } 269 267 270 268 int tegra_dc_rgb_init(struct drm_device *drm, struct tegra_dc *dc)