summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/rcar-du/rcar_du_drv.c
diff options
context:
space:
mode:
authorWolfram Sang2016-10-16 10:01:47 +0200
committerLaurent Pinchart2017-04-04 16:03:43 +0200
commit9e7d80e648793d5bf263a3ec9cfb1cf29b86a6e0 (patch)
tree1e962d6cc118d4ec28d59092eb552a870901d33b /drivers/gpu/drm/rcar-du/rcar_du_drv.c
parentdrm: rcar-du: Switch to encoder .atomic_mode_set() helper function (diff)
downloadkernel-qcow2-linux-9e7d80e648793d5bf263a3ec9cfb1cf29b86a6e0.tar.gz
kernel-qcow2-linux-9e7d80e648793d5bf263a3ec9cfb1cf29b86a6e0.tar.xz
kernel-qcow2-linux-9e7d80e648793d5bf263a3ec9cfb1cf29b86a6e0.zip
drm: rcar-du: Don't open code of_device_get_match_data()
This change will also make Coverity happy by avoiding a theoretical NULL pointer dereference; yet another reason is to use the above helper function to tighten the code and make it more readable. Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Tested-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Diffstat (limited to 'drivers/gpu/drm/rcar-du/rcar_du_drv.c')
-rw-r--r--drivers/gpu/drm/rcar-du/rcar_du_drv.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/rcar-du/rcar_du_drv.c b/drivers/gpu/drm/rcar-du/rcar_du_drv.c
index 62a3b3e32153..3a6c118457c3 100644
--- a/drivers/gpu/drm/rcar-du/rcar_du_drv.c
+++ b/drivers/gpu/drm/rcar-du/rcar_du_drv.c
@@ -321,7 +321,7 @@ static int rcar_du_probe(struct platform_device *pdev)
init_waitqueue_head(&rcdu->commit.wait);
rcdu->dev = &pdev->dev;
- rcdu->info = of_match_device(rcar_du_of_table, rcdu->dev)->data;
+ rcdu->info = of_device_get_match_data(rcdu->dev);
platform_set_drvdata(pdev, rcdu);