Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 76ffe8a3 authored by Yi Zou's avatar Yi Zou Committed by James Bottomley
Browse files

[SCSI] libfc: remove redundant timer init for fcp



The fcp timer is already initialized when it gets allocated.

Signed-off-by: default avatarYi Zou <yi.zou@intel.com>
Tested-by: default avatarRoss Brattain <ross.b.brattain@intel.com>
Signed-off-by: default avatarRobert Love <robert.w.love@intel.com>
Signed-off-by: default avatarJames Bottomley <JBottomley@Parallels.com>
parent 7c9c6841
Loading
Loading
Loading
Loading
+1 −3
Original line number Original line Diff line number Diff line
@@ -155,6 +155,7 @@ static struct fc_fcp_pkt *fc_fcp_pkt_alloc(struct fc_lport *lport, gfp_t gfp)
		fsp->xfer_ddp = FC_XID_UNKNOWN;
		fsp->xfer_ddp = FC_XID_UNKNOWN;
		atomic_set(&fsp->ref_cnt, 1);
		atomic_set(&fsp->ref_cnt, 1);
		init_timer(&fsp->timer);
		init_timer(&fsp->timer);
		fsp->timer.data = (unsigned long)fsp;
		INIT_LIST_HEAD(&fsp->list);
		INIT_LIST_HEAD(&fsp->list);
		spin_lock_init(&fsp->scsi_pkt_lock);
		spin_lock_init(&fsp->scsi_pkt_lock);
	}
	}
@@ -1850,9 +1851,6 @@ int fc_queuecommand(struct Scsi_Host *shost, struct scsi_cmnd *sc_cmd)
	}
	}
	put_cpu();
	put_cpu();


	init_timer(&fsp->timer);
	fsp->timer.data = (unsigned long)fsp;

	/*
	/*
	 * send it to the lower layer
	 * send it to the lower layer
	 * if we get -1 return then put the request in the pending
	 * if we get -1 return then put the request in the pending