Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

scsi: 3w-sas: Remove unneeded variable 'retval'

Fix the following coccicheck warning:

./drivers/scsi/3w-sas.c:866:5-11: Unneeded variable: "retval". Return "1"
on line 898

Link: https://lore.kernel.org/r/1615272064-42109-1-git-send-email-yang.lee@linux.alibaba.com
Reported-by: Abaci Robot <abaci@linux.alibaba.com>
Signed-off-by: Yang Li <yang.lee@linux.alibaba.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>

authored by

Yang Li and committed by
Martin K. Petersen
2af0bf34 59f90f5e

+1 -2
+1 -2
drivers/scsi/3w-sas.c
··· 860 860 TW_Command_Full *full_command_packet; 861 861 unsigned short error; 862 862 char *error_str; 863 - int retval = 1; 864 863 865 864 header = tw_dev->sense_buffer_virt[i]; 866 865 full_command_packet = tw_dev->command_packet_virt[request_id]; ··· 891 892 goto out; 892 893 } 893 894 out: 894 - return retval; 895 + return 1; 895 896 } /* End twl_fill_sense() */ 896 897 897 898 /* This function will free up device extension resources */