lkml.org 
[lkml]   [2023]   [Jan]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v2] net: wan: Add checks for NULL. If uhdlc_priv_tsa != 1 then utdm is not initialized. And if ret != NULL then goto undo_uhdlc_init, where utdm is dereferenced. Same if dev == NULL.
On Tue, 10 Jan 2023 14:47:45 +0300 Esina Ekaterina wrote:
> Subject: [PATCH v2] net: wan: Add checks for NULL. If uhdlc_priv_tsa != 1 then utdm is not initialized. And if ret != NULL then goto undo_uhdlc_init, where utdm is dereferenced. Same if dev == NULL.
>
> Found by Linux Verification Center (linuxtesting.org) with SVACE.
>
> Signed-off-by: Esina Ekaterina <eesina@astralinux.ru>
>
> v2: Add check for NULL for unmap_si_regs
> ---

The format of your commit is wrong. You should make the commit message
look like this in git:

net: wan: Add checks for NULL

If uhdlc_priv_tsa != 1 then utdm is not initialized.
And if ret != NULL then goto undo_uhdlc_init, where
utdm is dereferenced. Same if dev == NULL.

Found by Linux Verification Center (linuxtesting.org) with SVACE.

Signed-off-by: Esina Ekaterina <eesina@astralinux.ru>
---
v2: Add check for NULL for unmap_si_regs

But the first line (subject) is still not specific enough.
Refer to the bug that's being fixed, not how it's fixed.

Also no braces needed around single-line if blocks.

\
 
 \ /
  Last update: 2023-03-26 23:35    [W:0.492 / U:0.308 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site