Re: [PATCH] dpu1: dpu_encoder: fix a missing check on list iterator

2022-04-10 Thread Dmitry Baryshkov
On 11/04/2022 03:56, Dmitry Baryshkov wrote: On 27/03/2022 10:32, Xiaomeng Tong wrote: The bug is here: cstate = to_dpu_crtc_state(drm_crtc->state); For the drm_for_each_crtc(), just like list_for_each_entry(), the list iterator 'drm_crtc' will point to a bogus position containing HEAD if

Re: [PATCH] dpu1: dpu_encoder: fix a missing check on list iterator

2022-04-10 Thread Dmitry Baryshkov
On 27/03/2022 10:32, Xiaomeng Tong wrote: The bug is here: cstate = to_dpu_crtc_state(drm_crtc->state); For the drm_for_each_crtc(), just like list_for_each_entry(), the list iterator 'drm_crtc' will point to a bogus position containing HEAD if the list is empty or no element is found.