Date: Sat, 9 Mar 2019 01:37:00 +0000 (UTC) From: "Bjoern A. Zeeb" <bz@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r344956 - head/sys/sys Message-ID: <201903090137.x291b0Hg070551@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: bz Date: Sat Mar 9 01:37:00 2019 New Revision: 344956 URL: https://svnweb.freebsd.org/changeset/base/344956 Log: Try to improve comment for socket state bits. In r324227 the comment moved into socketvar.h originally from sockstate.h r180948. Try to improve English and as a consequence rewrap the comment. No functional changes. Reviewed by: jhb (a wording suggestion) Differential Revision: https://reviews.freebsd.org/D13865 Modified: head/sys/sys/socketvar.h Modified: head/sys/sys/socketvar.h ============================================================================== --- head/sys/sys/socketvar.h Sat Mar 9 01:18:16 2019 (r344955) +++ head/sys/sys/socketvar.h Sat Mar 9 01:37:00 2019 (r344956) @@ -180,13 +180,13 @@ struct socket { /* * Socket state bits. * - * Historically, this bits were all kept in the so_state field. For - * locking reasons, they are now in multiple fields, as they are - * locked differently. so_state maintains basic socket state protected - * by the socket lock. so_qstate holds information about the socket - * accept queues. Each socket buffer also has a state field holding - * information relevant to that socket buffer (can't send, rcv). Many - * fields will be read without locks to improve performance and avoid + * Historically, these bits were all kept in the so_state field. + * They are now split into separate, lock-specific fields. + * so_state maintains basic socket state protected by the socket lock. + * so_qstate holds information about the socket accept queues. + * Each socket buffer also has a state field holding information + * relevant to that socket buffer (can't send, rcv). + * Many fields will be read without locks to improve performance and avoid * lock order issues. However, this approach must be used with caution. */ #define SS_NOFDREF 0x0001 /* no file table ref any more */
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201903090137.x291b0Hg070551>