diff options
author | rwatson <rwatson@FreeBSD.org> | 2004-06-20 21:39:46 +0000 |
---|---|---|
committer | rwatson <rwatson@FreeBSD.org> | 2004-06-20 21:39:46 +0000 |
commit | e9c176f24779f794f2b4d84ff880a7682c36d086 (patch) | |
tree | f45245060c90f02c0c04602dcc45ffc1a97d4c83 | |
parent | 8c7c75cc622acf9af15b4ff664dd1e47d92a1119 (diff) | |
download | FreeBSD-src-e9c176f24779f794f2b4d84ff880a7682c36d086.zip FreeBSD-src-e9c176f24779f794f2b4d84ff880a7682c36d086.tar.gz |
Annotate so_state as locked with SOCK_LOCK(so).
Add a commenting indicating that the SB_ constants apply to sb_flags.
-rw-r--r-- | sys/sys/socketvar.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/sys/sys/socketvar.h b/sys/sys/socketvar.h index ee6af8a..8173715 100644 --- a/sys/sys/socketvar.h +++ b/sys/sys/socketvar.h @@ -61,7 +61,7 @@ struct socket { short so_type; /* (a) generic type, see socket.h */ short so_options; /* from socket call, see socket.h */ short so_linger; /* time to linger while closing */ - short so_state; /* internal state flags SS_* */ + short so_state; /* (b) internal state flags SS_* */ int so_qstate; /* (e) internal state flags SQ_* */ void *so_pcb; /* protocol control block */ struct protosw *so_proto; /* (a) protocol handle */ @@ -111,6 +111,9 @@ struct socket { short sb_flags; /* (c/d) flags, see below */ short sb_state; /* (c/d) socket state on sockbuf */ } so_rcv, so_snd; +/* + * Constants for sb_flags field of struct sockbuf. + */ #define SB_MAX (256*1024) /* default for max chars in sockbuf */ #define SB_LOCK 0x01 /* lock on data queue */ #define SB_WANT 0x02 /* someone is waiting to lock */ |