EDAC, ghes: Add a null pointer check in ghes_edac_unregister()
Add a null check for ghes_pvt, before dereferencing it. The pointer could still be null in case the return path is taken before initialising ghes_pvt in the registration function. Reviewed-by: NToshi Kani <toshi.kani@hpe.com> Signed-off-by: NSughosh Ganu <sughosh.ganu@arm.com> Cc: Mauro Carvalho Chehab <mchehab@kernel.org> Cc: linux-edac <linux-edac@vger.kernel.org> Cc: lkml <linux-kernel@vger.kernel.org> Link: http://lkml.kernel.org/r/1524737809-24475-1-git-send-email-sughosh.ganu@arm.comSigned-off-by: NBorislav Petkov <bp@suse.de>
Showing
想要评论请 注册 或 登录