From a81dde7e0216d2520f04027d0dfbb94d9713e8b4 Mon Sep 17 00:00:00 2001 From: Jitendra Bhivare Date: Thu, 7 Jun 2018 13:54:41 +0530 Subject: scsi: be2iscsi: Include null char in SET_HOST_DATA FW needs NULL terminated driver version string. Signed-off-by: Ketan Mukadam Reviewed-by: Jitendra Bhivare Signed-off-by: Jitendra Bhivare Signed-off-by: Martin K. Petersen --- drivers/scsi/be2iscsi/be_cmds.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'drivers/scsi/be2iscsi') diff --git a/drivers/scsi/be2iscsi/be_cmds.c b/drivers/scsi/be2iscsi/be_cmds.c index 2eb66df3e3d6..c10aac4dbc5e 100644 --- a/drivers/scsi/be2iscsi/be_cmds.c +++ b/drivers/scsi/be2iscsi/be_cmds.c @@ -1545,7 +1545,7 @@ int beiscsi_set_host_data(struct beiscsi_hba *phba) snprintf((char *)ioctl->param.req.param_data, sizeof(ioctl->param.req.param_data), "Linux iSCSI v%s", BUILD_STR); - ioctl->param.req.param_len = ALIGN(ioctl->param.req.param_len, 4); + ioctl->param.req.param_len = ALIGN(ioctl->param.req.param_len + 1, 4); if (ioctl->param.req.param_len > BE_CMD_MAX_DRV_VERSION) ioctl->param.req.param_len = BE_CMD_MAX_DRV_VERSION; ret = be_mbox_notify(ctrl); -- cgit v1.2.3