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

Commit 405d55c9 authored by Wei Yongjun's avatar Wei Yongjun Committed by Michael S. Tsirkin
Browse files

tcm_vhost: remove unused variable in vhost_scsi_allocate_cmd()

The variable se_sess is initialized but never used
otherwise, so remove the unused variable.

dpatch engine is used to auto generate this patch.
(https://github.com/weiyj/dpatch

)

Signed-off-by: default avatarWei Yongjun <yongjun_wei@trendmicro.com.cn>
Signed-off-by: default avatarMichael S. Tsirkin <mst@redhat.com>
parent f9611c43
Loading
Loading
Loading
Loading
+0 −2
Original line number Original line Diff line number Diff line
@@ -414,14 +414,12 @@ static struct tcm_vhost_cmd *vhost_scsi_allocate_cmd(
{
{
	struct tcm_vhost_cmd *tv_cmd;
	struct tcm_vhost_cmd *tv_cmd;
	struct tcm_vhost_nexus *tv_nexus;
	struct tcm_vhost_nexus *tv_nexus;
	struct se_session *se_sess;


	tv_nexus = tv_tpg->tpg_nexus;
	tv_nexus = tv_tpg->tpg_nexus;
	if (!tv_nexus) {
	if (!tv_nexus) {
		pr_err("Unable to locate active struct tcm_vhost_nexus\n");
		pr_err("Unable to locate active struct tcm_vhost_nexus\n");
		return ERR_PTR(-EIO);
		return ERR_PTR(-EIO);
	}
	}
	se_sess = tv_nexus->tvn_se_sess;


	tv_cmd = kzalloc(sizeof(struct tcm_vhost_cmd), GFP_ATOMIC);
	tv_cmd = kzalloc(sizeof(struct tcm_vhost_cmd), GFP_ATOMIC);
	if (!tv_cmd) {
	if (!tv_cmd) {