[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <DM6PR04MB6575FDCA528AE6263537A27BFCFB9@DM6PR04MB6575.namprd04.prod.outlook.com>
Date: Fri, 6 Jan 2023 08:19:44 +0000
From: Avri Altman <Avri.Altman@....com>
To: Tom Rix <trix@...hat.com>,
"alim.akhtar@...sung.com" <alim.akhtar@...sung.com>,
"bvanassche@....org" <bvanassche@....org>,
"jejb@...ux.ibm.com" <jejb@...ux.ibm.com>,
"martin.petersen@...cle.com" <martin.petersen@...cle.com>,
"nathan@...nel.org" <nathan@...nel.org>,
"ndesaulniers@...gle.com" <ndesaulniers@...gle.com>,
"beanhuo@...ron.com" <beanhuo@...ron.com>,
Arthur Simchaev <Arthur.Simchaev@....com>,
"stanley.chu@...iatek.com" <stanley.chu@...iatek.com>,
"j-young.choi@...sung.com" <j-young.choi@...sung.com>,
"peter.wang@...iatek.com" <peter.wang@...iatek.com>
CC: "linux-scsi@...r.kernel.org" <linux-scsi@...r.kernel.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"llvm@...ts.linux.dev" <llvm@...ts.linux.dev>
Subject: RE: [PATCH] scsi: ufs: core: initialize sg_cnt, sg_list
> The clang build fails with
> drivers/ufs/core/ufs_bsg.c:107:6: error: variable 'sg_cnt' is used
> uninitialized whenever 'if' condition is false [-Werror,-Wsometimes-
> uninitialized]
> if (dir != DMA_NONE) {
> ^~~~~~~~~~~~~~~
> Similar for sg_list.
>
> This is not an error because ufshcd_advanced_rpmb_req_handler() does a
> similar check, but that check can be reduced if sg_list is initialized to NULL.
> Initialize sg_cnt to silence its error.
>
> Signed-off-by: Tom Rix <trix@...hat.com>
I think that Bean already submitted a fix for that.
Thanks,
Avri
Powered by blists - more mailing lists