#include <sys/protosw.h>

sys/protosw.h

includes: sys/appleapiopts.h, sys/cdefs.h
24 macros

macroPR_SLOWHZ

XXX: this will go away
#define PR_SLOWHZ 2
2 slow timeouts per second

macroPRC_IFDOWN

The arguments to the ctlinput routine are (*protosw[].pr_ctlinput)(cmd, sa, arg, ifnet); where `cmd' is one of the commands below, `sa' is a pointer to a sockaddr, `arg' is a `void *' argument used within a protocol family (typically that's a `struct ipctlparam *') and `ifp' is a pointer to the network interface.
#define PRC_IFDOWN 0
interface transition

macroPRC_ROUTEDEAD

#define PRC_ROUTEDEAD 1
select new route if possible ???

macroPRC_IFUP

#define PRC_IFUP 2
interface has come back up

macroPRC_QUENCH2

#define PRC_QUENCH2 3
DEC congestion bit says slow down

macroPRC_QUENCH

#define PRC_QUENCH 4
some one said to slow down

macroPRC_MSGSIZE

#define PRC_MSGSIZE 5
message size forced drop

macroPRC_HOSTDEAD

#define PRC_HOSTDEAD 6
host appears to be down

macroPRC_HOSTUNREACH

#define PRC_HOSTUNREACH 7
deprecated (use PRC_UNREACH_HOST)

macroPRC_UNREACH_NET

#define PRC_UNREACH_NET 8
no route to network

macroPRC_UNREACH_HOST

#define PRC_UNREACH_HOST 9
no route to host

macroPRC_UNREACH_PROTOCOL

#define PRC_UNREACH_PROTOCOL 10
dst says bad protocol

macroPRC_UNREACH_PORT

#define PRC_UNREACH_PORT 11
bad port #

macroPRC_UNREACH_SRCFAIL

was PRC_UNREACH_NEEDFRAG 12 (use PRC_MSGSIZE)
#define PRC_UNREACH_SRCFAIL 13
source route failed

macroPRC_REDIRECT_NET

#define PRC_REDIRECT_NET 14
net routing redirect

macroPRC_REDIRECT_HOST

#define PRC_REDIRECT_HOST 15
host routing redirect

macroPRC_REDIRECT_TOSNET

#define PRC_REDIRECT_TOSNET 16
redirect for type of service & net

macroPRC_REDIRECT_TOSHOST

#define PRC_REDIRECT_TOSHOST 17
redirect for tos & host

macroPRC_TIMXCEED_INTRANS

#define PRC_TIMXCEED_INTRANS 18
packet lifetime expired in transit

macroPRC_TIMXCEED_REASS

#define PRC_TIMXCEED_REASS 19
lifetime expired on reass q

macroPRC_PARAMPROB

#define PRC_PARAMPROB 20
header incorrect

macroPRC_UNREACH_ADMIN_PROHIB

#define PRC_UNREACH_ADMIN_PROHIB 21
packet administrativly prohibited

macroPRC_NCMDS

#define PRC_NCMDS 22

macroPRC_IS_REDIRECT

#define PRC_IS_REDIRECT(cmd) ((cmd) >= PRC_REDIRECT_NET && (cmd) <= PRC_REDIRECT_TOSHOST)