summaryrefslogtreecommitdiffstats
path: root/sys
diff options
context:
space:
mode:
authorrwatson <rwatson@FreeBSD.org>2006-04-01 10:54:51 +0000
committerrwatson <rwatson@FreeBSD.org>2006-04-01 10:54:51 +0000
commit7f08bc3477d0953ebfa9c4a06cbee4950933d1d4 (patch)
tree32c8788f3b142147950b88cffe06a3f7b0f37899 /sys
parentb7a0ed6a8608692856c340b3587bf46852d67aeb (diff)
downloadFreeBSD-src-7f08bc3477d0953ebfa9c4a06cbee4950933d1d4.zip
FreeBSD-src-7f08bc3477d0953ebfa9c4a06cbee4950933d1d4.tar.gz
Add a comment describing SS_PROTOREF in detail. This will eventually be
in socket(9). MFC after: 3 months
Diffstat (limited to 'sys')
-rw-r--r--sys/sys/socketvar.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/sys/sys/socketvar.h b/sys/sys/socketvar.h
index 1ff3843..b1d7dd7 100644
--- a/sys/sys/socketvar.h
+++ b/sys/sys/socketvar.h
@@ -208,6 +208,13 @@ extern struct mtx accept_mtx;
#define SS_ASYNC 0x0200 /* async i/o notify */
#define SS_ISCONFIRMING 0x0400 /* deciding to accept connection req */
#define SS_ISDISCONNECTED 0x2000 /* socket disconnected from peer */
+/*
+ * Protocols can mark a socket as SS_PROTOREF to indicate that, following
+ * pru_detach, they still want the socket to persist, and will free it
+ * themselves when they are done. Protocols should only ever call sofree()
+ * following setting this flag in pru_detach(), and never otherwise, as
+ * sofree() bypasses socket reference counting.
+ */
#define SS_PROTOREF 0x4000 /* strong protocol reference */
/*
OpenPOWER on IntegriCloud