From: Koenig, Christian
Sent: Friday, September 10, 2021 2:37 PM
To: Pan, Xinhui ; amd-...@lists.freedesktop.org;
dri-devel@lists.freedesktop.org; Deucher, Alexander
; Chen, Guchun
Cc: Shi, Leslie
Subject: Re: [PATCH] drm/ttm: add a BUG_ON in ttm_set_driver_manager when array
bounds
Yeah
*To:* amd-...@lists.freedesktop.org ;
dri-devel@lists.freedesktop.org ;
Koenig, Christian ; Pan, Xinhui
; Deucher, Alexander
*Cc:* Chen, Guchun ; Shi, Leslie
*Subject:* [PATCH] drm/ttm: add a BUG_ON in ttm_set_driver_manager
when array bounds
Vendor will define their own memory types
; Koenig,
Christian ; Pan, Xinhui ;
Deucher, Alexander
Cc: Chen, Guchun ; Shi, Leslie
Subject: [PATCH] drm/ttm: add a BUG_ON in ttm_set_driver_manager when array
bounds
Vendor will define their own memory types on top of TTM_PL_PRIV,
but call ttm_set_driver_manager directly without checking mem_type
Vendor will define their own memory types on top of TTM_PL_PRIV,
but call ttm_set_driver_manager directly without checking mem_type
value when setting up memory manager. So add such check to aware
the case when array bounds.
Signed-off-by: Leslie Shi
Signed-off-by: Guchun Chen
---
include/drm/t