From 6d7fb6343d1a7f51503fc727a47caddb82e48893 Mon Sep 17 00:00:00 2001 From: Bart Van Assche Date: Thu, 16 Jan 2014 15:22:00 +0000 Subject: [PATCH] fcst: Avoid that "rmmod fcst" hangs Make sure that SCST sessions get unregistered when scst_unregister_target() is invoked. This change is necessary because of r5083 ("Disable automatic sessions unregistration"). git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5195 d57e44dd-8a1f-0410-8b47-8ef2f437770f --- fcst/ft_sess.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/fcst/ft_sess.c b/fcst/ft_sess.c index 01d8607a9..6d1ab65a3 100644 --- a/fcst/ft_sess.c +++ b/fcst/ft_sess.c @@ -24,6 +24,8 @@ #include #include "fcst.h" +static void ft_sess_put(struct ft_sess *sess); + static int ft_tport_count; static ssize_t ft_format_wwn(char *buf, size_t len, u64 wwn) @@ -357,6 +359,7 @@ static void ft_sess_close(struct ft_sess *sess) return; FT_SESS_DBG("port_id %x\n", port_id); ft_sess_unhash(sess); + ft_sess_put(sess); /* XXX should send LOGO or PRLO to rport */ }