From 08234e3adc7a299c9213bcfa0b5e97c359129670 Mon Sep 17 00:00:00 2001 From: =?utf8?q?J=C3=B6rn=20Engel?= Date: Wed, 12 Jun 2013 16:27:54 -0400 Subject: [PATCH] qla_target: remove qlt_check_fcport_exist Comment from original 2012 patch: In all our testing this function has never returned true. However, the dropping of hardware_lock necessary to call this function seems to cause a use-after-free we manage to hit rather frequently. Given this cost-benefit ratio, I'm willing to remove some 100 lines of code. And since the same problem exists around shutdown_sess and put_sess, this patch changes them from taking the hardware_lock to requiring the hardware_lock to be taken. In most cases the caller already had the lock and had to drop it for the called method to reacquire it. At best that hurts performance and in rare instances it causes races with fatal consequences. We dropped the original 2012 patch when upgrading our kernel and it took us nearly half a year to discover we still need it. (nab: Fix qla_tgt_sess reference in tcm_qla2xxx_put_sess) Signed-off-by: Joern Engel Cc: Giridhar Malavali Cc: Chad Dupuis Signed-off-by: Nicholas Bellinger --- Reading git-format-patch failed