drm/rockchip: fix some warning from smatch check
drivers/gpu/drm/rockchip/rockchip_drm_drv.c:489
update_state() warn: variable dereferenced before check 'encoder' (see line 488)
drivers/gpu/drm/rockchip/rockchip_drm_drv.c:687
rockchip_register_crtc_funcs() error: buffer overflow 'priv->crtc_funcs' 2 <= 2
drivers/gpu/drm/rockchip/rockchip_drm_drv.c:700
rockchip_unregister_crtc_funcs() error: buffer overflow 'priv->crtc_funcs' 2 <= 2
drivers/gpu/drm/rockchip/rockchip_drm_rga.c:848
rga_probe() warn: passing zero to 'PTR_ERR'
drivers/gpu/drm/rockchip/rockchip_drm_vop.c:597
vop_csc_setup() warn: variable dereferenced before check 'y2r_table' (see line 578)
drivers/gpu/drm/rockchip/rockchip_drm_vop.c:1059
vop_plane_atomic_update() warn: variable dereferenced before check 'crtc' (see line 1041)
drivers/gpu/drm/rockchip/rockchip_lvds.c:88
lvds_name_to_format() error: strncmp() '"vesa"' too small (5 vs 6)
I don't konw how to fix following error, maybe rga owner can fix it.
drivers/gpu/drm/rockchip/rockchip_drm_rga.c:174
rga_alloc_dma_buf_for_cmdlist() error: buffer overflow 'cmdlist->data' 64 <= 64
Change-Id: I41cd098dbd2f311d01b4e84cf0d51598264c8e31
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>