OpenCloudOS-Kernel/drivers/scsi/esas2r
Kees Cook 1ce871de4f scsi: esas2r: Use flex array destination for memcpy()
In preparation for FORTIFY_SOURCE performing run-time destination buffer
bounds checking for memcpy(), specify the destination output buffer
explicitly, instead of asking memcpy() to write past the end of what looked
like a fixed-size object. Silences future run-time warning:

  memcpy: detected field-spanning write (size 80) of single field "trc + 1" (size 64)

There is no binary code output differences from this change.

Link: https://lore.kernel.org/r/20220901205729.2260982-1-keescook@chromium.org
Cc: Bradley Grove <linuxdrivers@attotech.com>
Cc: "James E.J. Bottomley" <jejb@linux.ibm.com>
Cc: "Martin K. Petersen" <martin.petersen@oracle.com>
Cc: linux-scsi@vger.kernel.org
Reviewed-by: Gustavo A. R. Silva <gustavoars@kernel.org>
Signed-off-by: Kees Cook <keescook@chromium.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2022-09-06 22:24:37 -04:00
..
Kconfig treewide: replace '---help---' in Kconfig files with 'help' 2020-06-14 01:57:21 +09:00
Makefile treewide: Add SPDX license identifier - Makefile/Kconfig 2019-05-21 10:50:46 +02:00
atioctl.h scsi: esas2r: Use flex array destination for memcpy() 2022-09-06 22:24:37 -04:00
atvda.h
esas2r.h scsi: esas2r: Use generic power management 2020-11-25 23:14:31 -05:00
esas2r_disc.c scsi: esas2r: esas2r_disc: Place brackets around a potentially empty if() 2020-11-10 22:27:46 -05:00
esas2r_flash.c scsi: esas2r: Fix typo in comment 2022-05-23 23:24:09 -04:00
esas2r_init.c scsi: esas2r: Use generic power management 2020-11-25 23:14:31 -05:00
esas2r_int.c scsi: esas2r: esas2r_int: Add brackets around potentially empty if()s 2020-11-10 22:27:47 -05:00
esas2r_io.c
esas2r_ioctl.c scsi: esas2r: Use flex array destination for memcpy() 2022-09-06 22:24:37 -04:00
esas2r_log.c scsi: esas2r: Supply __printf(x, y) formatting for esas2r_log_master() 2021-03-15 22:28:58 -04:00
esas2r_log.h scsi: esas2r: Fix format string type mistakes 2017-01-09 23:52:26 -05:00
esas2r_main.c scsi: esas2r: Call scsi_done() directly 2021-10-16 21:28:46 -04:00
esas2r_targdb.c
esas2r_vda.c