From: Laurent Pinchart Date: Fri, 13 Oct 2017 14:59:03 +0000 (+0300) Subject: drm: omapdrm: dpi: Remove dpi_data port_initialized field X-Git-Tag: Ubuntu-5.2.0-15.16~5065^2~20^2~8 X-Git-Url: https://git.proxmox.com/?a=commitdiff_plain;h=9dd894d5dc5c1c4ddd3853d290d88d910f29582c;p=mirror_ubuntu-eoan-kernel.git drm: omapdrm: dpi: Remove dpi_data port_initialized field The dpi_data structure port_initialized field is used to check in the cleanup path whether the DPI has been initialized. This can be performed through the associated device_node data field instead. Remove the port_initialized field. Signed-off-by: Laurent Pinchart Reviewed-by: Sebastian Reichel Signed-off-by: Tomi Valkeinen --- diff --git a/drivers/gpu/drm/omapdrm/dss/dpi.c b/drivers/gpu/drm/omapdrm/dss/dpi.c index ca1e3b489540..7f0bcdd39b93 100644 --- a/drivers/gpu/drm/omapdrm/dss/dpi.c +++ b/drivers/gpu/drm/omapdrm/dss/dpi.c @@ -52,8 +52,6 @@ struct dpi_data { int data_lines; struct omap_dss_device output; - - bool port_initialized; }; static struct dpi_data *dpi_get_data_from_dssdev(struct omap_dss_device *dssdev) @@ -786,8 +784,6 @@ int dpi_init_port(struct platform_device *pdev, struct device_node *port, dpi_init_output_port(dpi, port); - dpi->port_initialized = true; - return 0; err_datalines: @@ -800,7 +796,7 @@ void dpi_uninit_port(struct device_node *port) { struct dpi_data *dpi = port->data; - if (!dpi->port_initialized) + if (!dpi) return; dpi_uninit_output_port(port);