/* Description: Process a user generated VERSION message and respond accordingly. Returns zero on success, negative values on failure.  */
static int netlbl_mgmt_version(struct sk_buff *skb, struct genl_info *info)
/* Description: Process a user generated VERSION message and respond accordingly. Returns zero on success, negative values on failure.  */
static int netlbl_mgmt_version(struct sk_buff *skb, struct genl_info *info)
{
	int ret_val = -ENOMEM;
	struct sk_buff *ans_skb = NULL;
	void *data;
	ans_skb = nlmsg_new(NLMSG_DEFAULT_SIZE, GFP_KERNEL);
	if (ans_skb == NULL)
		return -ENOMEM;
	data = genlmsg_put_reply(ans_skb, info, &netlbl_mgmt_gnl_family,
				 0, NLBL_MGMT_C_VERSION);
	if (data == NULL)
		goto version_failure;
	ret_val = nla_put_u32(ans_skb,
			      NLBL_MGMT_A_VERSION,
			      NETLBL_PROTO_VERSION);
	if (ret_val != 0)
		goto version_failure;
	genlmsg_end(ans_skb, data);
	return genlmsg_reply(ans_skb, info);
version_failure:
	kfree_skb(ans_skb);
	return ret_val;
}