1net_isvalidchecksum(9F) Kernel Functions for Drivers net_isvalidchecksum(9F)
2
3
4
6 net_isvalidchecksum - verify layer 3 and layer 4 checksums
7
9 #include <sys/neti.h>
10
11 int net_isvalidchecksum(const net_data_t net, mblk_t *mb);
12
13
15 Solaris DDI specific (Solaris DDI).
16
18 net value returned from a successful call to net_proto‐
19 col_lookup(9F).
20
21
22 mb the mblk structure holding a packet that is the subject of this
23 query.
24
25
27 The net_isvalidchecksum() function verifies the layer 3 checksum (and,
28 in some case, the layer 4 checksum) in the packet. If possible, fields
29 that are used by hardware checksum'ing are examined rather than manu‐
30 ally verifying that the checksums are present for packets received from
31 a network interface.
32
33
34 For both IPv4 and IPv6, TCP, UDP and ICMP (including ICMPV6 for IPv6)
35 layer 4 checksums are currently validated.
36
38 The net_isvalidchecksum() function returns:
39
40 -1 The network protocol does not support this function.
41
42
43 0 The packet does not contain partial checksums.
44
45
46 1 The packet does contain partial checksums.
47
48
50 The net_isvalidchecksum() function may be called from user, kernel, or
51 interrupt context.
52
54 See attributes(5) for descriptions of the following attributes:
55
56
57
58
59 ┌─────────────────────────────┬─────────────────────────────┐
60 │ ATTRIBUTE TYPE │ ATTRIBUTE VALUE │
61 ├─────────────────────────────┼─────────────────────────────┤
62 │Availability │SUNWcsu │
63 ├─────────────────────────────┼─────────────────────────────┤
64 │Interface Stability │Committed │
65 └─────────────────────────────┴─────────────────────────────┘
66
68 net_ispartialchecksum(9F), net_protocol_lookup(9F), attributes(5)
69
70
71
72SunOS 5.11 1 May 2008 net_isvalidchecksum(9F)