]> git.baikalelectronics.ru Git - kernel.git/commit
drm/vc4: clean up error exit path on failed dpi_connector allocation
authorColin Ian King <colin.king@canonical.com>
Thu, 2 Jun 2016 09:38:29 +0000 (10:38 +0100)
committerEric Anholt <eric@anholt.net>
Mon, 6 Jun 2016 21:28:40 +0000 (14:28 -0700)
commitf7640da98a16378c846e1a3e66b19d87e15b1297
treedd2914b565a3b4efcdba2dcae6e1624159f08139
parenteafb69e30fd2c5eb541ab8464cb7c24186e23039
drm/vc4: clean up error exit path on failed dpi_connector allocation

There is redundant code in the clean up exit path when dpi_connector
fails to be allocated.  The current code checks if connector is NULL
before destroying it, in fact, connector is NULL at this point so
the check is redundant and can be removed. The final clean up is
that we can remove the goto fail with a simple return and the unused
variable ret.

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Reviewed-by: Eric Anholt <eric@anholt.net>
drivers/gpu/drm/vc4/vc4_dpi.c