Commit 7a444d1f authored by Masanari Iida's avatar Masanari Iida Committed by Thomas Hellstrom

drm/ttm: Fix memory leak in ttm_agp_backend.c

This patch fix a memory leak found by cppcheck.
[drivers/gpu/drm/ttm/ttm_agp_backend.c:129]:
(error) Memory leak: agp_be
Signed-off-by: default avatarMasanari Iida <standby24x7@gmail.com>
Reviewed-by: default avatarThomas Hellstrom <thellstrom@vmware.com>
parent 728a0cdf
......@@ -126,6 +126,7 @@ struct ttm_tt *ttm_agp_tt_create(struct ttm_bo_device *bdev,
agp_be->ttm.func = &ttm_agp_func;
if (ttm_tt_init(&agp_be->ttm, bdev, size, page_flags, dummy_read_page)) {
kfree(agp_be);
return NULL;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment