Commit e410331
Revert "RDMA/cma: Simplify rdma_resolve_addr() error flow"
This reverts commit 219d2e9.
The call chain below requires the cm_id_priv's destination address to be
setup before performing rdma_bind_addr(). Otherwise source port allocation
fails as cma_port_is_unique() no longer sees the correct tuple to allow
duplicate users of the source port.
rdma_resolve_addr()
cma_bind_addr()
rdma_bind_addr()
cma_get_port()
cma_alloc_any_port()
cma_port_is_unique() <- compared with zero daddr
This can result in false failures to connect, particularly if the source
port range is restricted.
Fixes: 219d2e9 ("RDMA/cma: Simplify rdma_resolve_addr() error flow")
Link: https://lore.kernel.org/r/20200212072635.682689-4-leon@kernel.org
Signed-off-by: Parav Pandit <parav@mellanox.com>
Signed-off-by: Leon Romanovsky <leonro@mellanox.com>
Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>1 parent 11a48a5 commit e410331
1 file changed
Lines changed: 11 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3212 | 3212 | | |
3213 | 3213 | | |
3214 | 3214 | | |
| 3215 | + | |
3215 | 3216 | | |
3216 | 3217 | | |
3217 | | - | |
| 3218 | + | |
| 3219 | + | |
| 3220 | + | |
3218 | 3221 | | |
| 3222 | + | |
3219 | 3223 | | |
3220 | 3224 | | |
3221 | | - | |
| 3225 | + | |
| 3226 | + | |
3222 | 3227 | | |
| 3228 | + | |
3223 | 3229 | | |
3224 | | - | |
| 3230 | + | |
| 3231 | + | |
3225 | 3232 | | |
| 3233 | + | |
3226 | 3234 | | |
3227 | | - | |
3228 | 3235 | | |
3229 | 3236 | | |
3230 | 3237 | | |
| |||
0 commit comments