summaryrefslogtreecommitdiffhomepage
path: root/interface-event.c
AgeCommit message (Collapse)Author
2018-07-05Introduce new interface event "create" (IFEV_CREATE)Alexander Couzens
"create" will be called before the proto handlers initialised. Acked-by: Hans Dedecker <dedeckeh@gmail.com> Signed-off-by: Alexander Couzens <lynxis@fe80.eu>
2017-05-09interface: add new "ifup-failed" hotplug eventMartin Schiller
This hook makes it possible to do some helper work in hotplug scripts when a connection is not established successfully. example: try several username/passwords from a pool to establish a pppoe or wwan connection by replacing the configured values of the connection in a hotplug script. Signed-off-by: Martin Schiller <ms@dev.tdt.de>
2016-09-14interface-event: Don't dequeue hotplug event in case of interface reload eventHans Dedecker
Dropping hotplug event in case of interface reload results into hotplug scripts not being being run for the interface and thus external actors not being informed about the actual state of the interface. This is clearly visible if the interface auto parameter is set to disabled for multiple interfaces resulting into no hotplug down event for all interfaces. Therefore don't flush the interface hotplug queue in case an interface reload event is observed. Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
2016-07-29interface: do not process hotplug events for link up eventFelix Fietkau
Signed-off-by: Felix Fietkau <nbd@nbd.name>
2016-07-29interface: report link up events for force_link interfacesFelix Fietkau
Signed-off-by: Felix Fietkau <nbd@nbd.name>
2016-02-01interface-event: Fix possible out of bounds array accessHans Dedecker
The array eventnames is of size 3 while the interface_event type may use the indexes 3 or 4. Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
2015-02-17netifd: Fix possible hotplug race conditionsHans Dedecker
Don't drop ifup/ifdown events in case an interface event is cached as it leads to possible race conditions (eg firewall not being reloaded as ifup is dropped) when multiple interface events are fired in a short timeframe (eg multiple PPP link flaps). Always overwrite the cached interface event except for the interface update event so the hotplug scripts are launched with the last known status. Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
2014-07-23Set DEVICE for legacy ifupdate event as wellSteven Barth
Signed-off-by: Steven Barth <steven@midlink.org>
2014-04-26interface-event: make eventnames static and constFelix Fietkau
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
2014-04-26netifd: Rework hotplug event queueing in case of congestionHans Dedecker
In case of event congestion (e.g. when several interfaces become active in a short notice) : -hotplug events will be handled on a first come first served basis (before it was lifo) -drop a new ifupdate event in favour of an already queued ifup event (before the ifup event was overwritten by the ifupdate event resulting in some hotplug scripts "missing" the ifup event) Additonal the event flow has been documented Signed-off-by: Hans Dedecker <dedeckeh@gmail.com> Signed-off-by: Joeri Barbarien <joeri.barbarien@gmail.com>
2014-01-17Add indicator-flags to ubus and hotplug update-eventsSteven Barth
2013-10-22utils: add a function for checking if a process given by pid is still aliveFelix Fietkau
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
2013-10-19Fix ifupdate eventsSteven Barth
2013-10-17Add protocol update notifications and hotplug legacy callsSteven Barth
2012-05-18fix segfault on interface free because of uninitialized event listFelix Fietkau
2012-05-04add copyright headersFelix Fietkau
2012-05-04convert interface event queueing to global interface notifierFelix Fietkau
2012-03-23move l3 device tracking to interface core to enforce proper order of ↵Felix Fietkau
address/route removal on device or interface state changes
2011-10-20fix path and invocation for hotplug callsFelix Fietkau
2011-10-19include the DEVICE variable in hotplug eventsFelix Fietkau
2011-10-09add ubus events for interface up/downFelix Fietkau
2011-10-09rename interface-hotplug.c to interface-event.cFelix Fietkau