* drivers/scsi/qedi/qedi_main.c:924 qedi_get_boot_tgt_info() error: snprintf() chops off the last chars of 256 vs 255
@ 2020-08-29 17:26 kernel test robot
0 siblings, 0 replies; 9+ messages in thread
From: kernel test robot @ 2020-08-29 17:26 UTC (permalink / raw)
To: kbuild
[-- Attachment #1: Type: text/plain, Size: 3224 bytes --]
CC: kbuild-all(a)lists.01.org
CC: linux-kernel(a)vger.kernel.org
TO: Manish Rangankar <mrangankar@marvell.com>
CC: "Martin K. Petersen" <martin.petersen@oracle.com>
CC: Lee Duncan <lduncan@suse.com>
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 4d41ead6ead97c3730bbd186a601a64828668f01
commit: 2f1ea39870c95aa9fff6a0b48757625a0b22f551 scsi: qedi: Remove additional char from boot target iqnname
date: 5 months ago
:::::: branch date: 18 hours ago
:::::: commit date: 5 months ago
config: i386-randconfig-m021-20200830 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-15) 9.3.0
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
New smatch warnings:
drivers/scsi/qedi/qedi_main.c:924 qedi_get_boot_tgt_info() error: snprintf() chops off the last chars of 'block->target[index]->target_name.byte': 256 vs 255
Old smatch warnings:
drivers/scsi/qedi/qedi_main.c:956 qedi_find_boot_info() warn: returning -1 instead of -ENOMEM is sloppy
# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=2f1ea39870c95aa9fff6a0b48757625a0b22f551
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout 2f1ea39870c95aa9fff6a0b48757625a0b22f551
vim +924 drivers/scsi/qedi/qedi_main.c
ace7f46ba5fde7 Manish Rangankar 2016-12-01 915
534bbdf8832ae4 Manish Rangankar 2018-05-22 916 static void qedi_get_boot_tgt_info(struct nvm_iscsi_block *block,
534bbdf8832ae4 Manish Rangankar 2018-05-22 917 struct qedi_boot_target *tgt, u8 index)
534bbdf8832ae4 Manish Rangankar 2018-05-22 918 {
534bbdf8832ae4 Manish Rangankar 2018-05-22 919 u32 ipv6_en;
534bbdf8832ae4 Manish Rangankar 2018-05-22 920
534bbdf8832ae4 Manish Rangankar 2018-05-22 921 ipv6_en = !!(block->generic.ctrl_flags &
534bbdf8832ae4 Manish Rangankar 2018-05-22 922 NVM_ISCSI_CFG_GEN_IPV6_ENABLED);
534bbdf8832ae4 Manish Rangankar 2018-05-22 923
2f1ea39870c95a Manish Rangankar 2020-04-07 @924 snprintf(tgt->iscsi_name, sizeof(tgt->iscsi_name), "%s",
534bbdf8832ae4 Manish Rangankar 2018-05-22 925 block->target[index].target_name.byte);
534bbdf8832ae4 Manish Rangankar 2018-05-22 926
534bbdf8832ae4 Manish Rangankar 2018-05-22 927 tgt->ipv6_en = ipv6_en;
534bbdf8832ae4 Manish Rangankar 2018-05-22 928
534bbdf8832ae4 Manish Rangankar 2018-05-22 929 if (ipv6_en)
534bbdf8832ae4 Manish Rangankar 2018-05-22 930 snprintf(tgt->ip_addr, IPV6_LEN, "%pI6\n",
534bbdf8832ae4 Manish Rangankar 2018-05-22 931 block->target[index].ipv6_addr.byte);
534bbdf8832ae4 Manish Rangankar 2018-05-22 932 else
534bbdf8832ae4 Manish Rangankar 2018-05-22 933 snprintf(tgt->ip_addr, IPV4_LEN, "%pI4\n",
534bbdf8832ae4 Manish Rangankar 2018-05-22 934 block->target[index].ipv4_addr.byte);
534bbdf8832ae4 Manish Rangankar 2018-05-22 935 }
534bbdf8832ae4 Manish Rangankar 2018-05-22 936
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org
[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 37460 bytes --]
^ permalink raw reply [flat|nested] 9+ messages in thread
* drivers/scsi/qedi/qedi_main.c:924 qedi_get_boot_tgt_info() error: snprintf() chops off the last chars of 256 vs 255
@ 2021-01-19 8:55 ` Dan Carpenter
0 siblings, 0 replies; 9+ messages in thread
From: Dan Carpenter @ 2021-01-19 8:55 UTC (permalink / raw)
To: kbuild, Manish Rangankar
Cc: lkp, kbuild-all, linux-kernel, Martin K. Petersen, Lee Duncan
[-- Attachment #1: Type: text/plain, Size: 2606 bytes --]
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 0da0a8a0a0e1845f495431c3d8d733d2bbf9e9e5
commit: 2f1ea39870c95aa9fff6a0b48757625a0b22f551 scsi: qedi: Remove additional char from boot target iqnname
config: x86_64-randconfig-m001-20210117 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-15) 9.3.0
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
New smatch warnings:
drivers/scsi/qedi/qedi_main.c:924 qedi_get_boot_tgt_info() error: snprintf() chops off the last chars of 'block->target[index]->target_name.byte': 256 vs 255
Old smatch warnings:
drivers/scsi/qedi/qedi_main.c:956 qedi_find_boot_info() warn: returning -1 instead of -ENOMEM is sloppy
vim +924 drivers/scsi/qedi/qedi_main.c
534bbdf8832ae484 Manish Rangankar 2018-05-22 916 static void qedi_get_boot_tgt_info(struct nvm_iscsi_block *block,
534bbdf8832ae484 Manish Rangankar 2018-05-22 917 struct qedi_boot_target *tgt, u8 index)
534bbdf8832ae484 Manish Rangankar 2018-05-22 918 {
534bbdf8832ae484 Manish Rangankar 2018-05-22 919 u32 ipv6_en;
534bbdf8832ae484 Manish Rangankar 2018-05-22 920
534bbdf8832ae484 Manish Rangankar 2018-05-22 921 ipv6_en = !!(block->generic.ctrl_flags &
534bbdf8832ae484 Manish Rangankar 2018-05-22 922 NVM_ISCSI_CFG_GEN_IPV6_ENABLED);
534bbdf8832ae484 Manish Rangankar 2018-05-22 923
2f1ea39870c95aa9 Manish Rangankar 2020-04-07 @924 snprintf(tgt->iscsi_name, sizeof(tgt->iscsi_name), "%s",
534bbdf8832ae484 Manish Rangankar 2018-05-22 925 block->target[index].target_name.byte);
tgt->iscsi_name is one char smaller than block->target[index].target_name.byte.
534bbdf8832ae484 Manish Rangankar 2018-05-22 926
534bbdf8832ae484 Manish Rangankar 2018-05-22 927 tgt->ipv6_en = ipv6_en;
534bbdf8832ae484 Manish Rangankar 2018-05-22 928
534bbdf8832ae484 Manish Rangankar 2018-05-22 929 if (ipv6_en)
534bbdf8832ae484 Manish Rangankar 2018-05-22 930 snprintf(tgt->ip_addr, IPV6_LEN, "%pI6\n",
534bbdf8832ae484 Manish Rangankar 2018-05-22 931 block->target[index].ipv6_addr.byte);
534bbdf8832ae484 Manish Rangankar 2018-05-22 932 else
534bbdf8832ae484 Manish Rangankar 2018-05-22 933 snprintf(tgt->ip_addr, IPV4_LEN, "%pI4\n",
534bbdf8832ae484 Manish Rangankar 2018-05-22 934 block->target[index].ipv4_addr.byte);
534bbdf8832ae484 Manish Rangankar 2018-05-22 935 }
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 32228 bytes --]
^ permalink raw reply [flat|nested] 9+ messages in thread
* drivers/scsi/qedi/qedi_main.c:924 qedi_get_boot_tgt_info() error: snprintf() chops off the last chars of 256 vs 255
@ 2021-01-19 8:55 ` Dan Carpenter
0 siblings, 0 replies; 9+ messages in thread
From: Dan Carpenter @ 2021-01-19 8:55 UTC (permalink / raw)
To: kbuild
[-- Attachment #1: Type: text/plain, Size: 2653 bytes --]
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 0da0a8a0a0e1845f495431c3d8d733d2bbf9e9e5
commit: 2f1ea39870c95aa9fff6a0b48757625a0b22f551 scsi: qedi: Remove additional char from boot target iqnname
config: x86_64-randconfig-m001-20210117 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-15) 9.3.0
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
New smatch warnings:
drivers/scsi/qedi/qedi_main.c:924 qedi_get_boot_tgt_info() error: snprintf() chops off the last chars of 'block->target[index]->target_name.byte': 256 vs 255
Old smatch warnings:
drivers/scsi/qedi/qedi_main.c:956 qedi_find_boot_info() warn: returning -1 instead of -ENOMEM is sloppy
vim +924 drivers/scsi/qedi/qedi_main.c
534bbdf8832ae484 Manish Rangankar 2018-05-22 916 static void qedi_get_boot_tgt_info(struct nvm_iscsi_block *block,
534bbdf8832ae484 Manish Rangankar 2018-05-22 917 struct qedi_boot_target *tgt, u8 index)
534bbdf8832ae484 Manish Rangankar 2018-05-22 918 {
534bbdf8832ae484 Manish Rangankar 2018-05-22 919 u32 ipv6_en;
534bbdf8832ae484 Manish Rangankar 2018-05-22 920
534bbdf8832ae484 Manish Rangankar 2018-05-22 921 ipv6_en = !!(block->generic.ctrl_flags &
534bbdf8832ae484 Manish Rangankar 2018-05-22 922 NVM_ISCSI_CFG_GEN_IPV6_ENABLED);
534bbdf8832ae484 Manish Rangankar 2018-05-22 923
2f1ea39870c95aa9 Manish Rangankar 2020-04-07 @924 snprintf(tgt->iscsi_name, sizeof(tgt->iscsi_name), "%s",
534bbdf8832ae484 Manish Rangankar 2018-05-22 925 block->target[index].target_name.byte);
tgt->iscsi_name is one char smaller than block->target[index].target_name.byte.
534bbdf8832ae484 Manish Rangankar 2018-05-22 926
534bbdf8832ae484 Manish Rangankar 2018-05-22 927 tgt->ipv6_en = ipv6_en;
534bbdf8832ae484 Manish Rangankar 2018-05-22 928
534bbdf8832ae484 Manish Rangankar 2018-05-22 929 if (ipv6_en)
534bbdf8832ae484 Manish Rangankar 2018-05-22 930 snprintf(tgt->ip_addr, IPV6_LEN, "%pI6\n",
534bbdf8832ae484 Manish Rangankar 2018-05-22 931 block->target[index].ipv6_addr.byte);
534bbdf8832ae484 Manish Rangankar 2018-05-22 932 else
534bbdf8832ae484 Manish Rangankar 2018-05-22 933 snprintf(tgt->ip_addr, IPV4_LEN, "%pI4\n",
534bbdf8832ae484 Manish Rangankar 2018-05-22 934 block->target[index].ipv4_addr.byte);
534bbdf8832ae484 Manish Rangankar 2018-05-22 935 }
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org
[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 32228 bytes --]
^ permalink raw reply [flat|nested] 9+ messages in thread
* drivers/scsi/qedi/qedi_main.c:924 qedi_get_boot_tgt_info() error: snprintf() chops off the last chars of 256 vs 255
@ 2021-01-19 8:55 ` Dan Carpenter
0 siblings, 0 replies; 9+ messages in thread
From: Dan Carpenter @ 2021-01-19 8:55 UTC (permalink / raw)
To: kbuild-all
[-- Attachment #1: Type: text/plain, Size: 2653 bytes --]
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 0da0a8a0a0e1845f495431c3d8d733d2bbf9e9e5
commit: 2f1ea39870c95aa9fff6a0b48757625a0b22f551 scsi: qedi: Remove additional char from boot target iqnname
config: x86_64-randconfig-m001-20210117 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-15) 9.3.0
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
New smatch warnings:
drivers/scsi/qedi/qedi_main.c:924 qedi_get_boot_tgt_info() error: snprintf() chops off the last chars of 'block->target[index]->target_name.byte': 256 vs 255
Old smatch warnings:
drivers/scsi/qedi/qedi_main.c:956 qedi_find_boot_info() warn: returning -1 instead of -ENOMEM is sloppy
vim +924 drivers/scsi/qedi/qedi_main.c
534bbdf8832ae484 Manish Rangankar 2018-05-22 916 static void qedi_get_boot_tgt_info(struct nvm_iscsi_block *block,
534bbdf8832ae484 Manish Rangankar 2018-05-22 917 struct qedi_boot_target *tgt, u8 index)
534bbdf8832ae484 Manish Rangankar 2018-05-22 918 {
534bbdf8832ae484 Manish Rangankar 2018-05-22 919 u32 ipv6_en;
534bbdf8832ae484 Manish Rangankar 2018-05-22 920
534bbdf8832ae484 Manish Rangankar 2018-05-22 921 ipv6_en = !!(block->generic.ctrl_flags &
534bbdf8832ae484 Manish Rangankar 2018-05-22 922 NVM_ISCSI_CFG_GEN_IPV6_ENABLED);
534bbdf8832ae484 Manish Rangankar 2018-05-22 923
2f1ea39870c95aa9 Manish Rangankar 2020-04-07 @924 snprintf(tgt->iscsi_name, sizeof(tgt->iscsi_name), "%s",
534bbdf8832ae484 Manish Rangankar 2018-05-22 925 block->target[index].target_name.byte);
tgt->iscsi_name is one char smaller than block->target[index].target_name.byte.
534bbdf8832ae484 Manish Rangankar 2018-05-22 926
534bbdf8832ae484 Manish Rangankar 2018-05-22 927 tgt->ipv6_en = ipv6_en;
534bbdf8832ae484 Manish Rangankar 2018-05-22 928
534bbdf8832ae484 Manish Rangankar 2018-05-22 929 if (ipv6_en)
534bbdf8832ae484 Manish Rangankar 2018-05-22 930 snprintf(tgt->ip_addr, IPV6_LEN, "%pI6\n",
534bbdf8832ae484 Manish Rangankar 2018-05-22 931 block->target[index].ipv6_addr.byte);
534bbdf8832ae484 Manish Rangankar 2018-05-22 932 else
534bbdf8832ae484 Manish Rangankar 2018-05-22 933 snprintf(tgt->ip_addr, IPV4_LEN, "%pI4\n",
534bbdf8832ae484 Manish Rangankar 2018-05-22 934 block->target[index].ipv4_addr.byte);
534bbdf8832ae484 Manish Rangankar 2018-05-22 935 }
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org
[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 32228 bytes --]
^ permalink raw reply [flat|nested] 9+ messages in thread
* drivers/scsi/qedi/qedi_main.c:924 qedi_get_boot_tgt_info() error: snprintf() chops off the last chars of 256 vs 255
@ 2021-01-17 0:16 kernel test robot
0 siblings, 0 replies; 9+ messages in thread
From: kernel test robot @ 2021-01-17 0:16 UTC (permalink / raw)
To: kbuild
[-- Attachment #1: Type: text/plain, Size: 3066 bytes --]
CC: kbuild-all(a)lists.01.org
CC: linux-kernel(a)vger.kernel.org
TO: Manish Rangankar <mrangankar@marvell.com>
CC: "Martin K. Petersen" <martin.petersen@oracle.com>
CC: Lee Duncan <lduncan@suse.com>
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 0da0a8a0a0e1845f495431c3d8d733d2bbf9e9e5
commit: 2f1ea39870c95aa9fff6a0b48757625a0b22f551 scsi: qedi: Remove additional char from boot target iqnname
date: 9 months ago
:::::: branch date: 4 hours ago
:::::: commit date: 9 months ago
config: x86_64-randconfig-m001-20210117 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-15) 9.3.0
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
New smatch warnings:
drivers/scsi/qedi/qedi_main.c:924 qedi_get_boot_tgt_info() error: snprintf() chops off the last chars of 'block->target[index]->target_name.byte': 256 vs 255
Old smatch warnings:
drivers/scsi/qedi/qedi_main.c:956 qedi_find_boot_info() warn: returning -1 instead of -ENOMEM is sloppy
drivers/scsi/qedi/qedi_main.c:1607 qedi_alloc_global_queues() warn: missing error code 'status'
vim +924 drivers/scsi/qedi/qedi_main.c
ace7f46ba5fde727 Manish Rangankar 2016-12-01 915
534bbdf8832ae484 Manish Rangankar 2018-05-22 916 static void qedi_get_boot_tgt_info(struct nvm_iscsi_block *block,
534bbdf8832ae484 Manish Rangankar 2018-05-22 917 struct qedi_boot_target *tgt, u8 index)
534bbdf8832ae484 Manish Rangankar 2018-05-22 918 {
534bbdf8832ae484 Manish Rangankar 2018-05-22 919 u32 ipv6_en;
534bbdf8832ae484 Manish Rangankar 2018-05-22 920
534bbdf8832ae484 Manish Rangankar 2018-05-22 921 ipv6_en = !!(block->generic.ctrl_flags &
534bbdf8832ae484 Manish Rangankar 2018-05-22 922 NVM_ISCSI_CFG_GEN_IPV6_ENABLED);
534bbdf8832ae484 Manish Rangankar 2018-05-22 923
2f1ea39870c95aa9 Manish Rangankar 2020-04-07 @924 snprintf(tgt->iscsi_name, sizeof(tgt->iscsi_name), "%s",
534bbdf8832ae484 Manish Rangankar 2018-05-22 925 block->target[index].target_name.byte);
534bbdf8832ae484 Manish Rangankar 2018-05-22 926
534bbdf8832ae484 Manish Rangankar 2018-05-22 927 tgt->ipv6_en = ipv6_en;
534bbdf8832ae484 Manish Rangankar 2018-05-22 928
534bbdf8832ae484 Manish Rangankar 2018-05-22 929 if (ipv6_en)
534bbdf8832ae484 Manish Rangankar 2018-05-22 930 snprintf(tgt->ip_addr, IPV6_LEN, "%pI6\n",
534bbdf8832ae484 Manish Rangankar 2018-05-22 931 block->target[index].ipv6_addr.byte);
534bbdf8832ae484 Manish Rangankar 2018-05-22 932 else
534bbdf8832ae484 Manish Rangankar 2018-05-22 933 snprintf(tgt->ip_addr, IPV4_LEN, "%pI4\n",
534bbdf8832ae484 Manish Rangankar 2018-05-22 934 block->target[index].ipv4_addr.byte);
534bbdf8832ae484 Manish Rangankar 2018-05-22 935 }
534bbdf8832ae484 Manish Rangankar 2018-05-22 936
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org
[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 32228 bytes --]
^ permalink raw reply [flat|nested] 9+ messages in thread
* drivers/scsi/qedi/qedi_main.c:924 qedi_get_boot_tgt_info() error: snprintf() chops off the last chars of 256 vs 255
@ 2021-01-05 13:41 ` Dan Carpenter
0 siblings, 0 replies; 9+ messages in thread
From: Dan Carpenter @ 2021-01-05 13:41 UTC (permalink / raw)
To: kbuild, Manish Rangankar
Cc: lkp, Dan Carpenter, kbuild-all, linux-kernel, Martin K. Petersen,
Lee Duncan
[-- Attachment #1: Type: text/plain, Size: 2680 bytes --]
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 139711f033f636cc78b6aaf7363252241b9698ef
commit: 2f1ea39870c95aa9fff6a0b48757625a0b22f551 scsi: qedi: Remove additional char from boot target iqnname
config: i386-randconfig-m021-20201230 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-15) 9.3.0
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
New smatch warnings:
drivers/scsi/qedi/qedi_main.c:924 qedi_get_boot_tgt_info() error: snprintf() chops off the last chars of 'block->target[index]->target_name.byte': 256 vs 255
Old smatch warnings:
drivers/scsi/qedi/qedi_main.c:956 qedi_find_boot_info() warn: returning -1 instead of -ENOMEM is sloppy
drivers/scsi/qedi/qedi_main.c:1607 qedi_alloc_global_queues() warn: missing error code 'status'
vim +924 drivers/scsi/qedi/qedi_main.c
534bbdf8832ae48 Manish Rangankar 2018-05-22 916 static void qedi_get_boot_tgt_info(struct nvm_iscsi_block *block,
534bbdf8832ae48 Manish Rangankar 2018-05-22 917 struct qedi_boot_target *tgt, u8 index)
534bbdf8832ae48 Manish Rangankar 2018-05-22 918 {
534bbdf8832ae48 Manish Rangankar 2018-05-22 919 u32 ipv6_en;
534bbdf8832ae48 Manish Rangankar 2018-05-22 920
534bbdf8832ae48 Manish Rangankar 2018-05-22 921 ipv6_en = !!(block->generic.ctrl_flags &
534bbdf8832ae48 Manish Rangankar 2018-05-22 922 NVM_ISCSI_CFG_GEN_IPV6_ENABLED);
534bbdf8832ae48 Manish Rangankar 2018-05-22 923
2f1ea39870c95aa Manish Rangankar 2020-04-07 @924 snprintf(tgt->iscsi_name, sizeof(tgt->iscsi_name), "%s",
534bbdf8832ae48 Manish Rangankar 2018-05-22 925 block->target[index].target_name.byte);
tgt->iscsi_name is one char smaller than block->target[index].target_name.byte.
534bbdf8832ae48 Manish Rangankar 2018-05-22 926
534bbdf8832ae48 Manish Rangankar 2018-05-22 927 tgt->ipv6_en = ipv6_en;
534bbdf8832ae48 Manish Rangankar 2018-05-22 928
534bbdf8832ae48 Manish Rangankar 2018-05-22 929 if (ipv6_en)
534bbdf8832ae48 Manish Rangankar 2018-05-22 930 snprintf(tgt->ip_addr, IPV6_LEN, "%pI6\n",
534bbdf8832ae48 Manish Rangankar 2018-05-22 931 block->target[index].ipv6_addr.byte);
534bbdf8832ae48 Manish Rangankar 2018-05-22 932 else
534bbdf8832ae48 Manish Rangankar 2018-05-22 933 snprintf(tgt->ip_addr, IPV4_LEN, "%pI4\n",
534bbdf8832ae48 Manish Rangankar 2018-05-22 934 block->target[index].ipv4_addr.byte);
534bbdf8832ae48 Manish Rangankar 2018-05-22 935 }
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 38242 bytes --]
^ permalink raw reply [flat|nested] 9+ messages in thread
* drivers/scsi/qedi/qedi_main.c:924 qedi_get_boot_tgt_info() error: snprintf() chops off the last chars of 256 vs 255
@ 2021-01-05 13:41 ` Dan Carpenter
0 siblings, 0 replies; 9+ messages in thread
From: Dan Carpenter @ 2021-01-05 13:41 UTC (permalink / raw)
To: kbuild
[-- Attachment #1: Type: text/plain, Size: 2728 bytes --]
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 139711f033f636cc78b6aaf7363252241b9698ef
commit: 2f1ea39870c95aa9fff6a0b48757625a0b22f551 scsi: qedi: Remove additional char from boot target iqnname
config: i386-randconfig-m021-20201230 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-15) 9.3.0
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
New smatch warnings:
drivers/scsi/qedi/qedi_main.c:924 qedi_get_boot_tgt_info() error: snprintf() chops off the last chars of 'block->target[index]->target_name.byte': 256 vs 255
Old smatch warnings:
drivers/scsi/qedi/qedi_main.c:956 qedi_find_boot_info() warn: returning -1 instead of -ENOMEM is sloppy
drivers/scsi/qedi/qedi_main.c:1607 qedi_alloc_global_queues() warn: missing error code 'status'
vim +924 drivers/scsi/qedi/qedi_main.c
534bbdf8832ae48 Manish Rangankar 2018-05-22 916 static void qedi_get_boot_tgt_info(struct nvm_iscsi_block *block,
534bbdf8832ae48 Manish Rangankar 2018-05-22 917 struct qedi_boot_target *tgt, u8 index)
534bbdf8832ae48 Manish Rangankar 2018-05-22 918 {
534bbdf8832ae48 Manish Rangankar 2018-05-22 919 u32 ipv6_en;
534bbdf8832ae48 Manish Rangankar 2018-05-22 920
534bbdf8832ae48 Manish Rangankar 2018-05-22 921 ipv6_en = !!(block->generic.ctrl_flags &
534bbdf8832ae48 Manish Rangankar 2018-05-22 922 NVM_ISCSI_CFG_GEN_IPV6_ENABLED);
534bbdf8832ae48 Manish Rangankar 2018-05-22 923
2f1ea39870c95aa Manish Rangankar 2020-04-07 @924 snprintf(tgt->iscsi_name, sizeof(tgt->iscsi_name), "%s",
534bbdf8832ae48 Manish Rangankar 2018-05-22 925 block->target[index].target_name.byte);
tgt->iscsi_name is one char smaller than block->target[index].target_name.byte.
534bbdf8832ae48 Manish Rangankar 2018-05-22 926
534bbdf8832ae48 Manish Rangankar 2018-05-22 927 tgt->ipv6_en = ipv6_en;
534bbdf8832ae48 Manish Rangankar 2018-05-22 928
534bbdf8832ae48 Manish Rangankar 2018-05-22 929 if (ipv6_en)
534bbdf8832ae48 Manish Rangankar 2018-05-22 930 snprintf(tgt->ip_addr, IPV6_LEN, "%pI6\n",
534bbdf8832ae48 Manish Rangankar 2018-05-22 931 block->target[index].ipv6_addr.byte);
534bbdf8832ae48 Manish Rangankar 2018-05-22 932 else
534bbdf8832ae48 Manish Rangankar 2018-05-22 933 snprintf(tgt->ip_addr, IPV4_LEN, "%pI4\n",
534bbdf8832ae48 Manish Rangankar 2018-05-22 934 block->target[index].ipv4_addr.byte);
534bbdf8832ae48 Manish Rangankar 2018-05-22 935 }
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org
[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 38242 bytes --]
^ permalink raw reply [flat|nested] 9+ messages in thread
* drivers/scsi/qedi/qedi_main.c:924 qedi_get_boot_tgt_info() error: snprintf() chops off the last chars of 256 vs 255
@ 2021-01-05 13:41 ` Dan Carpenter
0 siblings, 0 replies; 9+ messages in thread
From: Dan Carpenter @ 2021-01-05 13:41 UTC (permalink / raw)
To: kbuild-all
[-- Attachment #1: Type: text/plain, Size: 2728 bytes --]
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 139711f033f636cc78b6aaf7363252241b9698ef
commit: 2f1ea39870c95aa9fff6a0b48757625a0b22f551 scsi: qedi: Remove additional char from boot target iqnname
config: i386-randconfig-m021-20201230 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-15) 9.3.0
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
New smatch warnings:
drivers/scsi/qedi/qedi_main.c:924 qedi_get_boot_tgt_info() error: snprintf() chops off the last chars of 'block->target[index]->target_name.byte': 256 vs 255
Old smatch warnings:
drivers/scsi/qedi/qedi_main.c:956 qedi_find_boot_info() warn: returning -1 instead of -ENOMEM is sloppy
drivers/scsi/qedi/qedi_main.c:1607 qedi_alloc_global_queues() warn: missing error code 'status'
vim +924 drivers/scsi/qedi/qedi_main.c
534bbdf8832ae48 Manish Rangankar 2018-05-22 916 static void qedi_get_boot_tgt_info(struct nvm_iscsi_block *block,
534bbdf8832ae48 Manish Rangankar 2018-05-22 917 struct qedi_boot_target *tgt, u8 index)
534bbdf8832ae48 Manish Rangankar 2018-05-22 918 {
534bbdf8832ae48 Manish Rangankar 2018-05-22 919 u32 ipv6_en;
534bbdf8832ae48 Manish Rangankar 2018-05-22 920
534bbdf8832ae48 Manish Rangankar 2018-05-22 921 ipv6_en = !!(block->generic.ctrl_flags &
534bbdf8832ae48 Manish Rangankar 2018-05-22 922 NVM_ISCSI_CFG_GEN_IPV6_ENABLED);
534bbdf8832ae48 Manish Rangankar 2018-05-22 923
2f1ea39870c95aa Manish Rangankar 2020-04-07 @924 snprintf(tgt->iscsi_name, sizeof(tgt->iscsi_name), "%s",
534bbdf8832ae48 Manish Rangankar 2018-05-22 925 block->target[index].target_name.byte);
tgt->iscsi_name is one char smaller than block->target[index].target_name.byte.
534bbdf8832ae48 Manish Rangankar 2018-05-22 926
534bbdf8832ae48 Manish Rangankar 2018-05-22 927 tgt->ipv6_en = ipv6_en;
534bbdf8832ae48 Manish Rangankar 2018-05-22 928
534bbdf8832ae48 Manish Rangankar 2018-05-22 929 if (ipv6_en)
534bbdf8832ae48 Manish Rangankar 2018-05-22 930 snprintf(tgt->ip_addr, IPV6_LEN, "%pI6\n",
534bbdf8832ae48 Manish Rangankar 2018-05-22 931 block->target[index].ipv6_addr.byte);
534bbdf8832ae48 Manish Rangankar 2018-05-22 932 else
534bbdf8832ae48 Manish Rangankar 2018-05-22 933 snprintf(tgt->ip_addr, IPV4_LEN, "%pI4\n",
534bbdf8832ae48 Manish Rangankar 2018-05-22 934 block->target[index].ipv4_addr.byte);
534bbdf8832ae48 Manish Rangankar 2018-05-22 935 }
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org
[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 38242 bytes --]
^ permalink raw reply [flat|nested] 9+ messages in thread
* drivers/scsi/qedi/qedi_main.c:924 qedi_get_boot_tgt_info() error: snprintf() chops off the last chars of 256 vs 255
@ 2020-12-30 14:22 kernel test robot
0 siblings, 0 replies; 9+ messages in thread
From: kernel test robot @ 2020-12-30 14:22 UTC (permalink / raw)
To: kbuild
[-- Attachment #1: Type: text/plain, Size: 3043 bytes --]
CC: kbuild-all(a)lists.01.org
CC: linux-kernel(a)vger.kernel.org
TO: Manish Rangankar <mrangankar@marvell.com>
CC: "Martin K. Petersen" <martin.petersen@oracle.com>
CC: Lee Duncan <lduncan@suse.com>
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 139711f033f636cc78b6aaf7363252241b9698ef
commit: 2f1ea39870c95aa9fff6a0b48757625a0b22f551 scsi: qedi: Remove additional char from boot target iqnname
date: 9 months ago
:::::: branch date: 15 hours ago
:::::: commit date: 9 months ago
config: i386-randconfig-m021-20201230 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-15) 9.3.0
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
New smatch warnings:
drivers/scsi/qedi/qedi_main.c:924 qedi_get_boot_tgt_info() error: snprintf() chops off the last chars of 'block->target[index]->target_name.byte': 256 vs 255
Old smatch warnings:
drivers/scsi/qedi/qedi_main.c:956 qedi_find_boot_info() warn: returning -1 instead of -ENOMEM is sloppy
drivers/scsi/qedi/qedi_main.c:1607 qedi_alloc_global_queues() warn: missing error code 'status'
vim +924 drivers/scsi/qedi/qedi_main.c
ace7f46ba5fde72 Manish Rangankar 2016-12-01 915
534bbdf8832ae48 Manish Rangankar 2018-05-22 916 static void qedi_get_boot_tgt_info(struct nvm_iscsi_block *block,
534bbdf8832ae48 Manish Rangankar 2018-05-22 917 struct qedi_boot_target *tgt, u8 index)
534bbdf8832ae48 Manish Rangankar 2018-05-22 918 {
534bbdf8832ae48 Manish Rangankar 2018-05-22 919 u32 ipv6_en;
534bbdf8832ae48 Manish Rangankar 2018-05-22 920
534bbdf8832ae48 Manish Rangankar 2018-05-22 921 ipv6_en = !!(block->generic.ctrl_flags &
534bbdf8832ae48 Manish Rangankar 2018-05-22 922 NVM_ISCSI_CFG_GEN_IPV6_ENABLED);
534bbdf8832ae48 Manish Rangankar 2018-05-22 923
2f1ea39870c95aa Manish Rangankar 2020-04-07 @924 snprintf(tgt->iscsi_name, sizeof(tgt->iscsi_name), "%s",
534bbdf8832ae48 Manish Rangankar 2018-05-22 925 block->target[index].target_name.byte);
534bbdf8832ae48 Manish Rangankar 2018-05-22 926
534bbdf8832ae48 Manish Rangankar 2018-05-22 927 tgt->ipv6_en = ipv6_en;
534bbdf8832ae48 Manish Rangankar 2018-05-22 928
534bbdf8832ae48 Manish Rangankar 2018-05-22 929 if (ipv6_en)
534bbdf8832ae48 Manish Rangankar 2018-05-22 930 snprintf(tgt->ip_addr, IPV6_LEN, "%pI6\n",
534bbdf8832ae48 Manish Rangankar 2018-05-22 931 block->target[index].ipv6_addr.byte);
534bbdf8832ae48 Manish Rangankar 2018-05-22 932 else
534bbdf8832ae48 Manish Rangankar 2018-05-22 933 snprintf(tgt->ip_addr, IPV4_LEN, "%pI4\n",
534bbdf8832ae48 Manish Rangankar 2018-05-22 934 block->target[index].ipv4_addr.byte);
534bbdf8832ae48 Manish Rangankar 2018-05-22 935 }
534bbdf8832ae48 Manish Rangankar 2018-05-22 936
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org
[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 38242 bytes --]
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2021-01-19 9:01 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-08-29 17:26 drivers/scsi/qedi/qedi_main.c:924 qedi_get_boot_tgt_info() error: snprintf() chops off the last chars of 256 vs 255 kernel test robot
2020-12-30 14:22 kernel test robot
2021-01-05 13:41 Dan Carpenter
2021-01-05 13:41 ` Dan Carpenter
2021-01-05 13:41 ` Dan Carpenter
2021-01-17 0:16 kernel test robot
2021-01-19 8:55 Dan Carpenter
2021-01-19 8:55 ` Dan Carpenter
2021-01-19 8:55 ` Dan Carpenter
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.