On Wed, Feb 23, 2022 at 05:07:08PM -0600, Bob Pearson wrote: > + /* schedule rxe_destroy_mca and then wait for > + * completion before returning to rdma-core. > + * Having an outstanding call_rcu() causes > + * rdma-core to fail. It may be simpler to > + * just call synchronize_rcu() and then > + * rxe_destroy_rcu(), but this works OK. > + */ > + call_rcu(&mca->rcu, rxe_destroy_mca); > + wait_for_completion(&mca->complete); What you've done here is just open code synchronize_rcu(). The trouble with synchronize_ruc() is rcu grace periods can take huge amounts of time (>1s) on busy servers, so you really don't want to write synchronize_rcu(), it might take minutes to close a verbs FD if the user created lots of MCAs. It is the dark side of RCU locking, you have to be able to work in the call_rcu style async cleanup, or it doesn't really work. Jason