mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-11-25 03:00:53 +07:00
[SCSI] fix C syntax problem in scsi_lib.c
Older gcc's require variable definitions at the beginning of a block. Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
This commit is contained in:
parent
84743bbcf9
commit
1ccb48bb16
@ -336,14 +336,15 @@ int scsi_execute_req(struct scsi_device *sdev, const unsigned char *cmd,
|
||||
struct scsi_sense_hdr *sshdr, int timeout, int retries)
|
||||
{
|
||||
char *sense = NULL;
|
||||
|
||||
int result;
|
||||
|
||||
if (sshdr) {
|
||||
sense = kmalloc(SCSI_SENSE_BUFFERSIZE, GFP_KERNEL);
|
||||
if (!sense)
|
||||
return DRIVER_ERROR << 24;
|
||||
memset(sense, 0, sizeof(*sense));
|
||||
}
|
||||
int result = scsi_execute(sdev, cmd, data_direction, buffer, bufflen,
|
||||
result = scsi_execute(sdev, cmd, data_direction, buffer, bufflen,
|
||||
sense, timeout, retries, 0);
|
||||
if (sshdr)
|
||||
scsi_normalize_sense(sense, sizeof(*sense), sshdr);
|
||||
|
Loading…
Reference in New Issue
Block a user