Re: [PATCH 3/5] target: Make dynamic NodeACL shutdown clear comp_nacl bit

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, 2012-02-27 at 09:31 -0500, Jörn Engel wrote:
> On Mon, 27 February 2012 12:12:52 +0000, Nicholas A. Bellinger wrote:
> > 
> > This patch makes transport_deregister_session() clear the comp_nacl bit
> > to skip se_node_acl->acl_free_comp completion for dynamically generated
> > NodeACL during fabric session shutdown.
> > 
> > Also drop se_nacl conditional in transport_deregister_session() and add
> > BUG_ON(!se_nacl)
> 
> ... 
> 
> > +	bool comp_nacl = true;
> 
> ...
> 
> > +			comp_nacl = false;
> 
> Ok, now we have determined the value of this bool.  But I cannot see
> what we actually use it for.  Is there a patch missing or should we
> just drop this one?
> 

Just an FYI that comp_nacl is used to determine ->acl_free_comp before
the transport_deregister_session() call completes in patch #2:

diff --git a/drivers/target/target_core_transport.c b/drivers/target/target_core_transport.c
index 751c527..ce36360 100644
--- a/drivers/target/target_core_transport.c
+++ b/drivers/target/target_core_transport.c
@@ -414,6 +414,12 @@ void transport_deregister_session(struct se_session *se_sess)
 
        pr_debug("TARGET_CORE[%s]: Deregistered fabric_sess\n",
                se_tpg->se_tpg_tfo->get_fabric_name());
+       /*
+        * Awake sleeping ->acl_free_comp caller from configfs se_node_acl
+        * removal context
+        */
+       if (comp_nacl)
+               complete(&se_nacl->acl_free_comp);
 }

 

--
To unsubscribe from this list: send the line "unsubscribe target-devel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux SCSI]     [Kernel Newbies]     [Linux SCSI Target Infrastructure]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Device Mapper]

  Powered by Linux