diff options
author | Ezequiel Garcia <ezequiel@vanguardiasur.com.ar> | 2014-09-02 09:51:15 -0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2014-11-14 08:59:53 -0800 |
commit | a2b44bbfd2e9450d87a9a482f463115b8415e356 (patch) | |
tree | 9c5dd819be9eaf8c4228d6c2001a5ff08c6876e1 /drivers/gpu/drm/drm_bufs.c | |
parent | 3e54c4b7e1e37a0b93782cc01749a1b4e1fc521e (diff) | |
download | lwn-a2b44bbfd2e9450d87a9a482f463115b8415e356.tar.gz lwn-a2b44bbfd2e9450d87a9a482f463115b8415e356.zip |
drm/tilcdc: Fix the error path in tilcdc_load()
commit b478e336b3e75505707a11e78ef8b964ef0a03af upstream.
The current error path calls tilcdc_unload() in case of an error to release
the resources. However, this is wrong because not all resources have been
allocated by the time an error occurs in tilcdc_load().
To fix it, this commit adds proper labels to bail out at the different
stages in the load function, and release only the resources actually allocated.
Tested-by: Darren Etheridge <detheridge@ti.com>
Tested-by: Johannes Pointner <johannes.pointner@br-automation.com>
Signed-off-by: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Fixes: 3a49012224ca ("drm/tilcdc: panel: fix leak when unloading the module")
Signed-off-by: Matwey V. Kornilov <matwey.kornilov@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/gpu/drm/drm_bufs.c')
0 files changed, 0 insertions, 0 deletions