Commit 1a633bd
RDMA/rxe: Let destroy qp succeed with stuck packet
In some situations a sent packet may get queued in the NIC longer than
than timeout of a ULP. Currently if this happens the ULP may try to reset
the link by destroying the qp and setting up an alternate connection but
will fail because the rxe driver is waiting for the packet to finish
getting sent and be returned to the skb destructor function where the qp
reference holding things up will be dropped. This patch modifies the way
that the qp is passed to the destructor to pass the qp index and not a qp
pointer. Then the destructor will attempt to lookup the qp from its index
and if it fails exit early. This requires taking a reference on the struct
sock rather than the qp allowing the qp to be destroyed while the sk is
still around waiting for the packet to finish.
Link: https://lore.kernel.org/r/20240329145513.35381-15-rpearsonhpe@gmail.com
Signed-off-by: Bob Pearson <rpearsonhpe@gmail.com>
Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>1 parent 9cc6290 commit 1a633bd
2 files changed
Lines changed: 32 additions & 12 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
345 | 345 | | |
346 | 346 | | |
347 | 347 | | |
348 | | - | |
349 | | - | |
350 | | - | |
| 348 | + | |
| 349 | + | |
| 350 | + | |
| 351 | + | |
| 352 | + | |
| 353 | + | |
| 354 | + | |
| 355 | + | |
| 356 | + | |
| 357 | + | |
| 358 | + | |
351 | 359 | | |
352 | | - | |
353 | | - | |
| 360 | + | |
| 361 | + | |
| 362 | + | |
| 363 | + | |
| 364 | + | |
| 365 | + | |
| 366 | + | |
| 367 | + | |
| 368 | + | |
| 369 | + | |
354 | 370 | | |
355 | 371 | | |
356 | 372 | | |
| 373 | + | |
| 374 | + | |
| 375 | + | |
357 | 376 | | |
358 | 377 | | |
359 | 378 | | |
360 | 379 | | |
361 | 380 | | |
| 381 | + | |
362 | 382 | | |
| 383 | + | |
| 384 | + | |
363 | 385 | | |
364 | | - | |
365 | | - | |
366 | | - | |
367 | 386 | | |
368 | 387 | | |
369 | 388 | | |
| |||
379 | 398 | | |
380 | 399 | | |
381 | 400 | | |
| 401 | + | |
| 402 | + | |
382 | 403 | | |
383 | 404 | | |
| 405 | + | |
| 406 | + | |
384 | 407 | | |
385 | | - | |
386 | | - | |
387 | | - | |
388 | 408 | | |
389 | 409 | | |
390 | 410 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
244 | 244 | | |
245 | 245 | | |
246 | 246 | | |
247 | | - | |
| 247 | + | |
248 | 248 | | |
249 | 249 | | |
250 | 250 | | |
| |||
0 commit comments