On Tue, Apr 25, 2023 at 07:15:43PM +0200, Jesper Dangaard Brouer wrote: > Performance is very important for page pool (PP). This add the use of > static_key APIs for regaining a single instruction, which makes the > new PP shutdown scheme zero impact. > > We are uncertain if this is 100% correct, because static_key APIs uses > a mutex lock and it is uncertain if all contexts that can return pages > can support this. We could spawn a workqueue (like we just removed) to > workaround this issue. With debug atomic sleep the issue should be trivial to see. iirc the callers of xdp_flush_frame_bulk() need to do it under rcu_read_lock equivalent, which is not sleepable and mutex-es should warn.