Re: [PATCH v2] x86/sev: Fix dereference NULL return value

From: Borislav Petkov
Date: Tue Nov 19 2024 - 16:04:10 EST


On Wed, Nov 20, 2024 at 02:21:13AM +0530, Shresth Prasad wrote:
> Prevent a NULL pointer dereference in snp_kexec_finish() by checking the
> value returned by lookup_address() call.

Can this really happen?

> This issue was reported by Coverity scan:
> https://scan7.scan.coverity.com/#/project-view/52279/11354?selectedIssue=1601527

I can't open this page - all coverity folks: you either describe what the
issue is or don't bother sending patches.

> Fixes: 3074152e56c9 ("x86/sev: Convert shared memory back to private on kexec")

So I'd hope if you report a bug against some patch, the least you could do is
CC its author...

To give you the same spiel:

Please read

https://kernel.org/doc/html/latest/process/development-process.html

and especially

https://kernel.org/doc/html/latest/process/submitting-patches.html

before you submit more patches.

Thx.

--
Regards/Gruss,
Boris.

https://people.kernel.org/tglx/notes-about-netiquette