Lines Matching refs:value

163 op_ip(struct snmp_context *ctx, struct snmp_value *value,  in op_ip()  argument
181 switch (value->var.subs[sub - 1]) { in op_ip()
185 ctx->scratch->int2 = value->v.integer; in op_ip()
186 if (value->v.integer == 1) { in op_ip()
190 } else if (value->v.integer == 2) { in op_ip()
200 ctx->scratch->int2 = value->v.integer; in op_ip()
201 if (value->v.integer < 1 || value->v.integer > 255) in op_ip()
203 if (ip_defttl != value->v.integer && in op_ip()
204 ip_setttl(value->v.integer, &old)) in op_ip()
212 switch (value->var.subs[sub - 1]) { in op_ip()
239 switch (value->var.subs[sub - 1]) { in op_ip()
242 value->v.integer = ip_forwarding ? 1 : 2; in op_ip()
246 value->v.integer = ip_defttl; in op_ip()
256 op_ipstat(struct snmp_context *ctx __unused, struct snmp_value *value, in op_ipstat() argument
278 switch (value->var.subs[sub - 1]) { in op_ipstat()
281 value->v.uint32 = ipstat.ips_total; in op_ipstat()
285 value->v.uint32 = ipstat.ips_badsum + ipstat.ips_tooshort in op_ipstat()
292 value->v.uint32 = ipstat.ips_cantforward; in op_ipstat()
296 value->v.uint32 = ipstat.ips_forward; in op_ipstat()
300 value->v.uint32 = ipstat.ips_noproto; in op_ipstat()
304 value->v.uint32 = ip_idrop; in op_ipstat()
308 value->v.uint32 = ipstat.ips_delivered; in op_ipstat()
312 value->v.uint32 = ipstat.ips_localout; in op_ipstat()
316 value->v.uint32 = ipstat.ips_odropped; in op_ipstat()
320 value->v.uint32 = ipstat.ips_noroute; in op_ipstat()
324 value->v.integer = ip_fragttl; in op_ipstat()
328 value->v.uint32 = ipstat.ips_fragments; in op_ipstat()
332 value->v.uint32 = ipstat.ips_reassembled; in op_ipstat()
336 value->v.uint32 = ipstat.ips_fragdropped in op_ipstat()
341 value->v.uint32 = ipstat.ips_fragmented; in op_ipstat()
345 value->v.uint32 = ipstat.ips_cantfrag; in op_ipstat()
349 value->v.uint32 = ipstat.ips_ofragments; in op_ipstat()
359 op_icmpstat(struct snmp_context *ctx __unused, struct snmp_value *value, in op_icmpstat() argument
383 switch (value->var.subs[sub - 1]) { in op_icmpstat()
386 value->v.integer = 0; in op_icmpstat()
388 value->v.integer += icmpstat.icps_inhist[i]; in op_icmpstat()
389 value->v.integer += icmpstat.icps_tooshort + in op_icmpstat()
395 value->v.integer = icmpstat.icps_tooshort + in op_icmpstat()
404 value->v.integer = icmpstat.icps_inhist[ICMP_UNREACH]; in op_icmpstat()
408 value->v.integer = icmpstat.icps_inhist[ICMP_TIMXCEED]; in op_icmpstat()
412 value->v.integer = icmpstat.icps_inhist[ICMP_PARAMPROB]; in op_icmpstat()
416 value->v.integer = icmpstat.icps_inhist[ICMP_SOURCEQUENCH]; in op_icmpstat()
420 value->v.integer = icmpstat.icps_inhist[ICMP_REDIRECT]; in op_icmpstat()
424 value->v.integer = icmpstat.icps_inhist[ICMP_ECHO]; in op_icmpstat()
428 value->v.integer = icmpstat.icps_inhist[ICMP_ECHOREPLY]; in op_icmpstat()
432 value->v.integer = icmpstat.icps_inhist[ICMP_TSTAMP]; in op_icmpstat()
436 value->v.integer = icmpstat.icps_inhist[ICMP_TSTAMPREPLY]; in op_icmpstat()
440 value->v.integer = icmpstat.icps_inhist[ICMP_MASKREQ]; in op_icmpstat()
444 value->v.integer = icmpstat.icps_inhist[ICMP_MASKREPLY]; in op_icmpstat()
448 value->v.integer = 0; in op_icmpstat()
450 value->v.integer += icmpstat.icps_outhist[i]; in op_icmpstat()
451 value->v.integer += icmpstat.icps_badaddr + in op_icmpstat()
456 value->v.integer = icmpstat.icps_badaddr + in op_icmpstat()
461 value->v.integer = icmpstat.icps_outhist[ICMP_UNREACH]; in op_icmpstat()
465 value->v.integer = icmpstat.icps_outhist[ICMP_TIMXCEED]; in op_icmpstat()
469 value->v.integer = icmpstat.icps_outhist[ICMP_PARAMPROB]; in op_icmpstat()
473 value->v.integer = icmpstat.icps_outhist[ICMP_SOURCEQUENCH]; in op_icmpstat()
477 value->v.integer = icmpstat.icps_outhist[ICMP_REDIRECT]; in op_icmpstat()
481 value->v.integer = icmpstat.icps_outhist[ICMP_ECHO]; in op_icmpstat()
485 value->v.integer = icmpstat.icps_outhist[ICMP_ECHOREPLY]; in op_icmpstat()
489 value->v.integer = icmpstat.icps_outhist[ICMP_TSTAMP]; in op_icmpstat()
493 value->v.integer = icmpstat.icps_outhist[ICMP_TSTAMPREPLY]; in op_icmpstat()
497 value->v.integer = icmpstat.icps_outhist[ICMP_MASKREQ]; in op_icmpstat()
501 value->v.integer = icmpstat.icps_outhist[ICMP_MASKREPLY]; in op_icmpstat()