summaryrefslogtreecommitdiffstats
path: root/etc/rc.d/lkm2
blob: 23608df5fc2e9c570f0a8e19b89dac9918c5150d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
#!/bin/sh
#
# $NetBSD: lkm2,v 1.4 2000/09/19 13:04:38 lukem Exp $
# $FreeBSD$
#

# PROVIDE: beforemountlkm
# REQUIRE: syslogd

. /etc/rc.subr

name="lkm2"
rcvar="lkm"
start_cmd="lkm2_start"
stop_cmd="lkm2_stop"

#		load kernel modules specified in /etc/lkm.conf
#
lkm2_start()
{
	if [ -r /etc/rc.lkm ]; then
		lkmstage=BEFOREMOUNT
		set start ; . /etc/rc.lkm
	else
		warn "/etc/rc.lkm not found; LKMs not loaded."
	fi
}

lkm2_stop()
{
	if [ -r /etc/rc.lkm ]; then
		lkmstage=BEFOREMOUNT
		set stop ; . /etc/rc.lkm
	fi
}

load_rc_config lkm
run_rc_command "$1"
OpenPOWER on IntegriCloud