summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/omapdrm/displays
diff options
context:
space:
mode:
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>2016-12-12 11:57:24 +0200
committerLaurent Pinchart <laurent.pinchart@ideasonboard.com>2016-12-19 11:25:05 +0200
commitd501b12999eb9cdfc488127fabaf794171dd9bbf (patch)
tree4b97a912c76f6ac6d2cf6c62fc82540d8be47f58 /drivers/gpu/drm/omapdrm/displays
parent84e1d4578fe9de486b367cc22a405f4a299ab17c (diff)
drm: omapdrm: Use sizeof(*var) instead of sizeof(type) for structures
By linking the sizeof to a variable type the code will be less prone to bugs due to future type changes of variables. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Reviewed-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
Diffstat (limited to 'drivers/gpu/drm/omapdrm/displays')
-rw-r--r--drivers/gpu/drm/omapdrm/displays/panel-dsi-cm.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/omapdrm/displays/panel-dsi-cm.c b/drivers/gpu/drm/omapdrm/displays/panel-dsi-cm.c
index dc026a843712..a2bb855a2851 100644
--- a/drivers/gpu/drm/omapdrm/displays/panel-dsi-cm.c
+++ b/drivers/gpu/drm/omapdrm/displays/panel-dsi-cm.c
@@ -1253,7 +1253,7 @@ static int dsicm_probe(struct platform_device *pdev)
dsicm_hw_reset(ddata);
if (ddata->use_dsi_backlight) {
- memset(&props, 0, sizeof(struct backlight_properties));
+ memset(&props, 0, sizeof(props));
props.max_brightness = 255;
props.type = BACKLIGHT_RAW;