[PATCH] PATCH 10/16: NFSD: TCP: rationalise locking in RPC server routines
Tidy up SMP locking for svc_sock sk_lock is not necessary and is now removed. The only things that were happening under sk_lock but not the more global sv_lock were testing and setting some of the flags: sk_busy, sk_conn, sk_data etc. These have been changed to bits in a flags word which are atomically set and tested. Also, by establishing some simple rules about that must be done after setting these flags, the locking is not needed. With this patch sk_conn and sk_data are now flags, not counts (sk_data was already a flag for udp). They are set if there might be a connection or data, and only clear when we are sure there aren't (or when we are about to check if there is). svc_sock_accepted becomes identical to svc_sock_recieved and so is discarded in favour of the latter. sk_rqstp was never used and is now gone.
Showing
Please register or sign in to comment