aboutsummaryrefslogtreecommitdiffstats
path: root/comms/ib-kmod/files/pkg-deinstall.in
blob: 1056f4e8181983e10e295ca331ac452ea9426b6e (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#!/bin/sh
#
# Unload if_ib module if necessary
#
# $FreeBSD$
#

KMODDIR="%%KMODDIR%%"

case "$2" in
DEINSTALL)
    echo "Unloading if_ib kernel module."

    # Unload the module if it is currently loaded.
    kldstat -n if_ib 2>/dev/null >/dev/null && kldunload if_ib || true
    ;;
POST-DEINSTALL)
    type kldxref >/dev/null 2>&1 && kldxref ${KMODDIR} || true
    ;;
esac