lkml.org 
[lkml]   [2022]   [Mar]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRE: [PATCH v2] ufs: fix an NULL check on list iterator
From
Date
Hi Xiaomeng Tong,

>The list iterator is always non-NULL so the check 'if (!rgn)'
>is always false and the dev_err() is never called. Move the
>check outside the loop and determine if 'victim_rgn' is NULL,
>to fix this bug.
>
>Fixes: 4b5f49079c52a ("scsi: ufs: ufshpb: L2P map management for HPB read")
>Signed-off-by: Xiaomeng Tong <xiam0nd.tong@gmail.com>
>---

Good catch. Free to add my reviewed-by tag.

Reviewed-by: Daejun Park <daejun7.park@samsung.com>

Thanks,
Daejun

\
 
 \ /
  Last update: 2022-03-22 00:28    [W:0.138 / U:0.012 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site