Re: [QUESTION] RDMA/srpt: is target_send_busy() safe before target_init_cmd()?

Bart Van Assche <[email protected]> Fri, 17 Jul 2026 10:59:35 -0700
Newsgroups org.kernel.vger.target-devel,org.kernel.vger.linux-rdma
Message-ID <[email protected]>
On 7/16/26 7:54 PM, [email protected] wrote:
> 1. Is calling target_send_busy() before target_init_cmd() intentional /
>     known-safe?

I think that's a bug.

> 2. If not, should ib_srpt.c send a fabric-local SRP_RSP BUSY (or otherwise
>     free the send ioctx) when se_tfo is unset, and keep target_send_busy()
>     only for the post-init failure path?

How about swapping the order of the target_init_cmd() and
srp_get_desc_tbl() calls and initializing .data_length and 
.data_direction after the srp_get_desc_tbl() call?

Thanks,

Bart.