diff options
author | John Donnelly <john.p.donnelly@oracle.com> | 2020-09-24 03:19:20 +0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2020-10-29 11:55:14 +0300 |
commit | 052daa607a16822dd243ed6b63d08f6ed0ae1d3b (patch) | |
tree | 85e785e6a353173cb04da33a9053a8152efb460c /drivers/target | |
parent | d9796b5e2ab1878ab5e2c42fc783ab75a4949bf6 (diff) | |
download | linux-052daa607a16822dd243ed6b63d08f6ed0ae1d3b.tar.xz |
scsi: target: tcmu: Fix warning: 'page' may be used uninitialized
[ Upstream commit 61741d8699e1fc764a309ebd20211bb1cb193110 ]
Corrects drivers/target/target_core_user.c:688:6: warning: 'page' may be
used uninitialized.
Link: https://lore.kernel.org/r/20200924001920.43594-1-john.p.donnelly@oracle.com
Fixes: 3c58f737231e ("scsi: target: tcmu: Optimize use of flush_dcache_page")
Cc: Mike Christie <michael.christie@oracle.com>
Acked-by: Mike Christie <michael.christie@oracle.com>
Signed-off-by: John Donnelly <john.p.donnelly@oracle.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'drivers/target')
-rw-r--r-- | drivers/target/target_core_user.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/target/target_core_user.c b/drivers/target/target_core_user.c index 99314e516244..0219b5a865be 100644 --- a/drivers/target/target_core_user.c +++ b/drivers/target/target_core_user.c @@ -680,7 +680,7 @@ static void scatter_data_area(struct tcmu_dev *udev, void *from, *to = NULL; size_t copy_bytes, to_offset, offset; struct scatterlist *sg; - struct page *page; + struct page *page = NULL; for_each_sg(data_sg, sg, data_nents, i) { int sg_remaining = sg->length; |