[PATCH 0/4] gpu/drm: fix memory leak when radeon_driver_load_kms fails

From: Xiaotian Feng
Date: Fri Jul 31 2009 - 04:57:07 EST


I've noticed a bundle of kmemleak reports on drm. When I look into dmesg,
I found: "[drm:radeon_driver_load_kms] *ERROR* Failed to initialize radeon,
disabling IOCTL".

In radeon_driver_load_kms, if radeon_device_init fails, rdev is not freed.
Then radeon_driver_load_kms as dev->driver->load, if load fails in
drm_get_dev, memories allocated in drm_fill_in_dev will not be freed.

This patchset fixes those memory leaks, after this patchset applied, I didn't
see those drm kmemleak report.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/