9P: Fix race between p9_write_work() and p9_fd_request()
thread A thread B
req->status = REQ_STATUS_UNSENT;
if (n & POLLOUT &&
--> not done because Wworksched is set
--> nobody will take care of sending the new request.
This is not very likely to happen though, because p9_write_work()
being called with an empty unsent_req_list is not frequent.
But this also means that taking the lock earlier will not be costly.
Signed-off-by: Simon Derr <email@example.com>
Signed-off-by: Eric Van Hensbergen <firstname.lastname@example.org>
1 file changed