xref: /dragonfly/etc/rc.d/rndcontrol (revision 36a3d1d6)
1#!/bin/sh
2#
3# $DragonFly: src/etc/rc.d/rndcontrol,v 1.2 2005/11/19 21:47:32 swildner Exp $
4#
5
6# PROVIDE: rndcontrol
7# REQUIRE: DAEMON
8# BEFORE:  LOGIN
9
10. /etc/rc.subr
11
12name="rndcontrol"
13start_cmd="rand_start"
14
15rand_start()
16{
17	# interrupts for /dev/random device
18	#
19	case ${rand_irqs} in
20	[Nn][Oo] | '')
21		;;
22	*)
23		echo -n 'entropy IRQs:'
24		for irq in ${rand_irqs}; do
25			echo -n " ${irq}" && rndcontrol -q -s ${irq}
26		done
27		echo '.'
28		;;
29	esac
30}
31
32
33load_rc_config $name
34run_rc_command "$1"
35