[PATCH] drm/ttm: add a check against null pointer dereference

2021-07-15 Thread Zheyu Ma
When calling ttm_range_man_fini(), 'man' may be uninitialized, which may cause a null pointer dereference bug. Fix this by checking if it is a null pointer. This log reveals it: [7.902580 ] BUG: kernel NULL pointer dereference, address: 0058 [7.905721 ] RIP: 0010:ttm_range_ma

Re: [PATCH] drm/ttm: add a check against null pointer dereference

2021-07-14 Thread Christian König
Am 14.07.21 um 16:54 schrieb Zheyu Ma: When calling ttm_range_man_fini(), 'man' may be uninitialized, which may cause a null pointer dereference bug. Fix this by checking if it is a null pointer. It would be better if the driver doesn't try to fini a manager which was never initialized, but f