* [PATCH 0/1] mpi3mr: Fix partly outside array bounds type warnings
@ 2022-08-30 8:50 Sreekanth Reddy
2022-08-30 8:50 ` [PATCH 1/1] " Sreekanth Reddy
2022-09-01 4:18 ` [PATCH 0/1] " Martin K. Petersen
0 siblings, 2 replies; 3+ messages in thread
From: Sreekanth Reddy @ 2022-08-30 8:50 UTC (permalink / raw)
To: linux-scsi; +Cc: martin.petersen, Sreekanth Reddy
[-- Attachment #1: Type: text/plain, Size: 728 bytes --]
Fix below compilation warning reported with W=1,
include/linux/find.h:40:23: warning: array subscript 'long unsigned int[0]'
is partly outside array bounds of 'u32[1]' {aka 'unsigned int[1]'}
[-Warray-bounds]
40 | val = *addr & GENMASK(size - 1, offset);
| ^~~~~
drivers/scsi/mpi3mr/mpi3mr_transport.c:1610:27: note: while referencing
'phys_to_be_added'
1610 | u32 phy_mask_xor, phys_to_be_added, phys_to_be_removed;
| ^~~~~~~~~~~~~~~~
Sreekanth Reddy (1):
mpi3mr: Fix partly outside array bounds type warnings
drivers/scsi/mpi3mr/mpi3mr_transport.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
--
2.27.0
[-- Attachment #2: S/MIME Cryptographic Signature --]
[-- Type: application/pkcs7-signature, Size: 4218 bytes --]
^ permalink raw reply [flat|nested] 3+ messages in thread
* [PATCH 1/1] mpi3mr: Fix partly outside array bounds type warnings
2022-08-30 8:50 [PATCH 0/1] mpi3mr: Fix partly outside array bounds type warnings Sreekanth Reddy
@ 2022-08-30 8:50 ` Sreekanth Reddy
2022-09-01 4:18 ` [PATCH 0/1] " Martin K. Petersen
1 sibling, 0 replies; 3+ messages in thread
From: Sreekanth Reddy @ 2022-08-30 8:50 UTC (permalink / raw)
To: linux-scsi
Cc: martin.petersen, Sreekanth Reddy, kernel test robot, Stephen Rothwell
[-- Attachment #1: Type: text/plain, Size: 890 bytes --]
Fixed 'is partly outside array bounds of' type
compilation warnings.
Reported-by: kernel test robot <lkp@intel.com>
Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Sreekanth Reddy <sreekanth.reddy@broadcom.com>
---
drivers/scsi/mpi3mr/mpi3mr_transport.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/scsi/mpi3mr/mpi3mr_transport.c b/drivers/scsi/mpi3mr/mpi3mr_transport.c
index 203251c..2367d9f 100644
--- a/drivers/scsi/mpi3mr/mpi3mr_transport.c
+++ b/drivers/scsi/mpi3mr/mpi3mr_transport.c
@@ -1607,7 +1607,8 @@ mpi3mr_update_mr_sas_port(struct mpi3mr_ioc *mrioc, struct host_port *h_port,
struct mpi3mr_sas_port *mr_sas_port)
{
struct mpi3mr_sas_phy *mr_sas_phy;
- u32 phy_mask_xor, phys_to_be_added, phys_to_be_removed;
+ u32 phy_mask_xor;
+ u64 phys_to_be_added, phys_to_be_removed;
int i;
h_port->used = 1;
--
2.27.0
[-- Attachment #2: S/MIME Cryptographic Signature --]
[-- Type: application/pkcs7-signature, Size: 4218 bytes --]
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH 0/1] mpi3mr: Fix partly outside array bounds type warnings
2022-08-30 8:50 [PATCH 0/1] mpi3mr: Fix partly outside array bounds type warnings Sreekanth Reddy
2022-08-30 8:50 ` [PATCH 1/1] " Sreekanth Reddy
@ 2022-09-01 4:18 ` Martin K. Petersen
1 sibling, 0 replies; 3+ messages in thread
From: Martin K. Petersen @ 2022-09-01 4:18 UTC (permalink / raw)
To: Sreekanth Reddy; +Cc: linux-scsi, martin.petersen
Sreekanth,
> Fix below compilation warning reported with W=1,
Amended original commit. Thanks!
--
Martin K. Petersen Oracle Linux Engineering
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2022-09-01 4:20 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-08-30 8:50 [PATCH 0/1] mpi3mr: Fix partly outside array bounds type warnings Sreekanth Reddy
2022-08-30 8:50 ` [PATCH 1/1] " Sreekanth Reddy
2022-09-01 4:18 ` [PATCH 0/1] " Martin K. Petersen
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).