blob: 526ca52dda01e642e6a03dbe8e5241ce5ae759bc (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
|
#!/bin/sh
alias debug=${DEBUG:-:}
# valid interface?
if_valid () (
ifconfig "$1" >&- 2>&- ||
[ "${1%%[0-9]}" = "br" ] ||
{ debug "# missing interface '$1' ignored"; false; }
)
hotplug_dev() {
env -i ACTION=$1 INTERFACE=$2 /sbin/hotplug net
}
|