|
From: <swg...@us...> - 2008-04-24 09:31:06
|
Revision: 356
http://scst.svn.sourceforge.net/scst/?rev=356&view=rev
Author: swgruszka
Date: 2008-04-24 02:31:02 -0700 (Thu, 24 Apr 2008)
Log Message:
-----------
Bugfix: put initiator reference counter when finish task management.
Modified Paths:
--------------
trunk/qla_isp/linux/isp_scst.c
Modified: trunk/qla_isp/linux/isp_scst.c
===================================================================
--- trunk/qla_isp/linux/isp_scst.c 2008-04-24 06:34:08 UTC (rev 355)
+++ trunk/qla_isp/linux/isp_scst.c 2008-04-24 09:31:02 UTC (rev 356)
@@ -90,6 +90,7 @@
#define cd_bus cd_hreserved[1].ptrs[0]
#define cd_hnext cd_hreserved[2].ptrs[0]
#define cd_ini cd_hreserved[3].ptrs[0]
+#define nt_ini nt_hreserved
/* command private flags */
#define CDF_PRIVATE_ABORTED 0x1000
@@ -723,13 +724,15 @@
}
spin_unlock_irqrestore(&scsi_target_lock, flags);
- SDprintk("scsi_target: MGT code %x from %s%d iid 0x%016llx\n", np->nt_ncode, bp->h.r_name, bp->h.r_inst, np->nt_iid);
+ SDprintk("scsi_target: MGT code %x from %s%d iid 0x%016llx tag %llx\n",
+ np->nt_ncode, bp->h.r_name, bp->h.r_inst, np->nt_iid, np->nt_tagval);
bc = &bp->bchan[np->nt_channel];
spin_lock_irqsave(&bc->tmds_lock, flags);
ini = ini_from_iid(bc, np->nt_iid);
- __ini_get(ini);
+ np->nt_ini = ini;
+ __ini_get(np->nt_ini);
spin_unlock_irqrestore(&bc->tmds_lock, flags);
switch (np->nt_ncode) {
@@ -1210,9 +1213,9 @@
isp_task_mgmt_fn_done(struct scst_mgmt_cmd *mgmt_cmd)
{
tmd_notify_t *np = mgmt_cmd->tgt_priv;
- bus_t *bp;
+ bus_t *bp = bus_from_notify(np);
- bp = bus_from_notify(np);
+ ini_put(&bp->bchan[np->nt_channel], np->nt_ini);
SDprintk("%s: NOTIFY_ACK[%llx]\n", __FUNCTION__, np->nt_tagval);
(*bp->h.r_action) (QIN_NOTIFY_ACK, np);
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|