| 3551 | } |
| 3552 | |
| 3553 | static void __noinline |
| 3554 | vdropl_final(struct vnode *vp) |
| 3555 | { |
| 3556 | |
| 3557 | ASSERT_VI_LOCKED(vp, __func__); |
| 3558 | VNPASS(VN_IS_DOOMED(vp), vp); |
| 3559 | /* |
| 3560 | * Set the VHOLD_NO_SMR flag. |
| 3561 | * |
| 3562 | * We may be racing against vhold_smr. If they win we can just pretend |
| 3563 | * we never got this far, they will vdrop later. |
| 3564 | */ |
| 3565 | if (__predict_false(!atomic_cmpset_int(&vp->v_holdcnt, 0, VHOLD_NO_SMR))) { |
| 3566 | vn_freevnodes_inc(); |
| 3567 | VI_UNLOCK(vp); |
| 3568 | /* |
| 3569 | * We lost the aforementioned race. Any subsequent access is |
| 3570 | * invalid as they might have managed to vdropl on their own. |
| 3571 | */ |
| 3572 | return; |
| 3573 | } |
| 3574 | /* |
| 3575 | * Don't bump freevnodes as this one is going away. |
| 3576 | */ |
| 3577 | freevnode(vp); |
| 3578 | } |
| 3579 | |
| 3580 | void |
| 3581 | vdrop(struct vnode *vp) |
no test coverage detected