lkml.org 
[lkml]   [2019]   [Mar]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH] scsi: lpfc: avoid uninitialized variable warning
From
Date

Arnd,

> clang -Wuninitialized incorrectly sees a variable being used without
> initialization:
>
> drivers/scsi/lpfc/lpfc_nvme.c:2102:37: error: variable 'localport' is uninitialized when used here
> [-Werror,-Wuninitialized]
> lport = (struct lpfc_nvme_lport *)localport->private;
> ^~~~~~~~~
> drivers/scsi/lpfc/lpfc_nvme.c:2059:38: note: initialize the variable 'localport' to silence this warning
> struct nvme_fc_local_port *localport;
> ^
> = NULL
> 1 error generated.

Applied to 5.2/scsi-queue, thanks!

--
Martin K. Petersen Oracle Linux Engineering

\
 
 \ /
  Last update: 2019-03-26 03:18    [W:0.036 / U:0.792 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site