diff options
author | Antonio Quartulli <ordex@autistici.org> | 2011-04-26 18:26:01 +0200 |
---|---|---|
committer | Sven Eckelmann <sven@narfation.org> | 2011-06-20 11:37:33 +0200 |
commit | c6bda689c2c94788e1e567463ce861d1f135857f (patch) | |
tree | b2876d0b57ee5de081cf612420644e39dc4b78c0 /net/batman-adv/bat_sysfs.h | |
parent | 7683fdc1e88644ee8108a1f33faba80545f0024d (diff) | |
download | linux-stable-c6bda689c2c94788e1e567463ce861d1f135857f.tar.gz linux-stable-c6bda689c2c94788e1e567463ce861d1f135857f.tar.bz2 linux-stable-c6bda689c2c94788e1e567463ce861d1f135857f.zip |
batman-adv: add wrapper function to throw uevent in userspace
Using throw_uevent() is now possible to trigger uevent signal that can
be recognised in userspace. Uevents will be triggered through the
/devices/virtual/net/{MESH_IFACE} kobject.
A triggered uevent has three properties:
- type: the event class. Who generates the event (only 'gw' is currently
defined). Corresponds to the BATTYPE uevent variable.
- action: the associated action with the event ('add'/'change'/'del' are
currently defined). Corresponds to the BATACTION uevent variable.
- data: any useful data for the userspace. Corresponds to the BATDATA
uevent variable.
Signed-off-by: Antonio Quartulli <ordex@autistici.org>
Signed-off-by: Sven Eckelmann <sven@narfation.org>
Diffstat (limited to 'net/batman-adv/bat_sysfs.h')
-rw-r--r-- | net/batman-adv/bat_sysfs.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/net/batman-adv/bat_sysfs.h b/net/batman-adv/bat_sysfs.h index 02f1fa7aadfa..a3f75a723c56 100644 --- a/net/batman-adv/bat_sysfs.h +++ b/net/batman-adv/bat_sysfs.h @@ -38,5 +38,7 @@ int sysfs_add_meshif(struct net_device *dev); void sysfs_del_meshif(struct net_device *dev); int sysfs_add_hardif(struct kobject **hardif_obj, struct net_device *dev); void sysfs_del_hardif(struct kobject **hardif_obj); +int throw_uevent(struct bat_priv *bat_priv, enum uev_type type, + enum uev_action action, const char *data); #endif /* _NET_BATMAN_ADV_SYSFS_H_ */ |