blob: f728d9cad170b5cd73bef652924ff4f0dd9709e4 [file] [log] [blame]
Greg Kroah-Hartmanb2441312017-11-01 15:07:57 +01001/* SPDX-License-Identifier: GPL-2.0 */
Tom Tucker792d1932006-07-30 20:43:26 -07002#ifndef _NET_EVENT_H
3#define _NET_EVENT_H
4
5/*
6 * Generic netevent notifiers
7 *
8 * Authors:
9 * Tom Tucker <tom@opengridcomputing.com>
10 * Steve Wise <swise@opengridcomputing.com>
11 *
12 * Changes:
13 */
Tom Tucker792d1932006-07-30 20:43:26 -070014
Herbert Xu274b3422007-11-13 21:34:34 -080015struct dst_entry;
David S. Miller1d248b12012-07-03 01:01:51 -070016struct neighbour;
Tom Tucker792d1932006-07-30 20:43:26 -070017
18struct netevent_redirect {
19 struct dst_entry *old;
20 struct dst_entry *new;
YOSHIFUJI Hideaki / 吉藤英明60592832013-01-14 09:28:27 +000021 struct neighbour *neigh;
David S. Miller1d248b12012-07-03 01:01:51 -070022 const void *daddr;
Tom Tucker792d1932006-07-30 20:43:26 -070023};
24
25enum netevent_notif_type {
26 NETEVENT_NEIGH_UPDATE = 1, /* arg is struct neighbour ptr */
Tom Tucker792d1932006-07-30 20:43:26 -070027 NETEVENT_REDIRECT, /* arg is struct netevent_redirect ptr */
Ido Schimmel2a4501a2016-07-05 11:27:42 +020028 NETEVENT_DELAY_PROBE_TIME_UPDATE, /* arg is struct neigh_parms ptr */
Tom Tucker792d1932006-07-30 20:43:26 -070029};
30
Joe Perches4f690532013-09-21 10:22:50 -070031int register_netevent_notifier(struct notifier_block *nb);
32int unregister_netevent_notifier(struct notifier_block *nb);
33int call_netevent_notifiers(unsigned long val, void *v);
Tom Tucker792d1932006-07-30 20:43:26 -070034
35#endif