On 3/24/2022 1:35 AM, QintaoShen wrote:
As the potential failuer of allocation, devm_kzalloc() may return NULL. Then the 'pd->pmb' and the follow lines of code may bring null pointer dereference. Therefore, it is better to check the return value of devm_kzalloc() to avoid this confusion. Signed-off-by: QintaoShen <unSimple1993@xxxxxxx>
Applied to https://github.com/Broadcom/stblinux/commits/drivers/next, thanks!
I modified your patch to have a Fixes: tag as replied, and follow Sergey's style recommendation.
-- Florian