c
// Assuming icmpv6msg_offsets is an array of appropriate size and type
static unsigned int icmpv6msg_offsets[256]; // Initialize this table appropriately

void ICMP6MSGOUT_INC_STATS(struct net *net, struct inet6_dev *idev, u8 field) {
    _DEVINC_ATOMIC_ATOMIC(net, icmpv6msg, idev, icmpv6msg_offsets[field]);
}
