Returns the address of a protocol switch table entry.
Item | Description |
---|---|
family | Specifies the address family for which to search. |
protocol | Indicates the protocol within the address family. |
type | Specifies the type of socket (for example, SOCK_RAW). |
The pffindproto kernel service first searches the domain switch table for the address family specified by the family parameter. If found, the pffindproto service then searches the protocol switch table for that domain and checks for matches with the type and protocol parameters.
If a match is found, the pffindproto service returns the address of the protocol switch table entry. If the type parameter is set to SOCK_RAW, the pffindproto service returns the first entry it finds with protocol equal to 0 and type equal to SOCK_RAW.
The pffindproto kernel service can be called from either the process or interrupt environment.
The pffindproto service returns a null value if a protocol switch table entry was not found for the given search criteria. Upon success, the pffindproto service returns the address of a protocol switch table entry.