counter: fix SYSCTL_COUNTER_U64_ARRAY type
There is nothing wrong with declaring an array as CTLTYPE_U64. Note that sysctl(8) is able to print such arrays and doesn't need any change. Fixes: b5b7b142a7e0e74bdd8c497f6a14804e71654dfd
This commit is contained in:
parent
f1ad5e3931
commit
bc5708c0e2
@ -757,8 +757,8 @@ TAILQ_HEAD(sysctl_ctx_list, sysctl_ctx_entry);
|
||||
/* Oid for an array of counter(9)s. The pointer and length must be non zero. */
|
||||
#define SYSCTL_COUNTER_U64_ARRAY(parent, nbr, name, access, ptr, len, descr) \
|
||||
SYSCTL_OID(parent, nbr, name, \
|
||||
CTLTYPE_OPAQUE | CTLFLAG_MPSAFE | CTLFLAG_STATS | (access), \
|
||||
(ptr), (len), sysctl_handle_counter_u64_array, "S", descr); \
|
||||
CTLTYPE_U64 | CTLFLAG_MPSAFE | CTLFLAG_STATS | (access), \
|
||||
(ptr), (len), sysctl_handle_counter_u64_array, "QU", descr);\
|
||||
CTASSERT((((access) & CTLTYPE) == 0 || \
|
||||
((access) & SYSCTL_CT_ASSERT_MASK) == CTLTYPE_OPAQUE) && \
|
||||
sizeof(counter_u64_t) == sizeof(*(ptr)) && \
|
||||
|
Loading…
x
Reference in New Issue
Block a user