• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */
2 /*
3  * linux/include/linux/netfilter/xt_IDLETIMER.h
4  *
5  * Header file for Xtables timer target module.
6  *
7  * Copyright (C) 2004, 2010 Nokia Corporation
8  *
9  * Written by Timo Teras <ext-timo.teras@nokia.com>
10  *
11  * Converted to x_tables and forward-ported to 2.6.34
12  * by Luciano Coelho <luciano.coelho@nokia.com>
13  *
14  * Contact: Luciano Coelho <luciano.coelho@nokia.com>
15  *
16  * This program is free software; you can redistribute it and/or
17  * modify it under the terms of the GNU General Public License
18  * version 2 as published by the Free Software Foundation.
19  *
20  * This program is distributed in the hope that it will be useful, but
21  * WITHOUT ANY WARRANTY; without even the implied warranty of
22  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
23  * General Public License for more details.
24  *
25  * You should have received a copy of the GNU General Public License
26  * along with this program; if not, write to the Free Software
27  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
28  * 02110-1301 USA
29  */
30 
31 #ifndef _XT_IDLETIMER_H
32 #define _XT_IDLETIMER_H
33 
34 #include <linux/types.h>
35 
36 #define MAX_IDLETIMER_LABEL_SIZE 28
37 #define NLMSG_MAX_SIZE 64
38 
39 #define NL_EVENT_TYPE_INACTIVE 0
40 #define NL_EVENT_TYPE_ACTIVE 1
41 
42 struct idletimer_tg_info {
43 	__u32 timeout;
44 
45 	char label[MAX_IDLETIMER_LABEL_SIZE];
46 
47 	/* Use netlink messages for notification in addition to sysfs */
48 	__u8 send_nl_msg;
49 
50 	/* for kernel module internal use only */
51 	struct idletimer_tg *timer __attribute__((aligned(8)));
52 };
53 
54 #endif
55