* [PATCH blktests] nvme-rc: Cleanup fcloop resources in reverse order
@ 2023-04-18 12:32 Daniel Wagner
2023-04-18 16:17 ` Daniel Wagner
0 siblings, 1 reply; 2+ messages in thread
From: Daniel Wagner @ 2023-04-18 12:32 UTC (permalink / raw)
To: linux-nvme
Cc: linux-kernel, linux-block, Chaitanya Kulkarni,
Shin'ichiro Kawasaki, Daniel Wagner
We need to free the resources in the opposite order as we allocate them.
The deleting the rport first will also free the other resources. When
we try to release lport and tport they are already gone.
Signed-off-by: Daniel Wagner <dwagner@suse.de>
---
tests/nvme/rc | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/tests/nvme/rc b/tests/nvme/rc
index b44239446dcf..ec0cc2d8d8cc 100644
--- a/tests/nvme/rc
+++ b/tests/nvme/rc
@@ -204,10 +204,10 @@ _cleanup_fcloop() {
local remote_wwnn="${3:-$def_remote_wwnn}"
local remote_wwpn="${4:-$def_remote_wwpn}"
- _nvme_fcloop_del_rport "${local_wwnn}" "${local_wwpn}" \
- "${remote_wwnn}" "${remote_wwpn}"
_nvme_fcloop_del_tport "${remote_wwnn}" "${remote_wwpn}"
_nvme_fcloop_del_lport "${local_wwnn}" "${local_wwpn}"
+ _nvme_fcloop_del_rport "${local_wwnn}" "${local_wwpn}" \
+ "${remote_wwnn}" "${remote_wwpn}"
}
_cleanup_nvmet() {
--
2.40.0
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH blktests] nvme-rc: Cleanup fcloop resources in reverse order
2023-04-18 12:32 [PATCH blktests] nvme-rc: Cleanup fcloop resources in reverse order Daniel Wagner
@ 2023-04-18 16:17 ` Daniel Wagner
0 siblings, 0 replies; 2+ messages in thread
From: Daniel Wagner @ 2023-04-18 16:17 UTC (permalink / raw)
To: linux-nvme
Cc: linux-kernel, linux-block, Chaitanya Kulkarni, Shin'ichiro Kawasaki
On Tue, Apr 18, 2023 at 02:32:52PM +0200, Daniel Wagner wrote:
> We need to free the resources in the opposite order as we allocate them.
> The deleting the rport first will also free the other resources. When
> we try to release lport and tport they are already gone.
I found some more ordering issues with fcloop resources.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2023-04-18 16:17 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-04-18 12:32 [PATCH blktests] nvme-rc: Cleanup fcloop resources in reverse order Daniel Wagner
2023-04-18 16:17 ` Daniel Wagner
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®