summaryrefslogtreecommitdiff
path: root/build_tools
diff options
context:
space:
mode:
authorTzafrir Cohen <tzafrir.cohen@xorcom.com>2010-06-08 14:44:37 +0000
committerTzafrir Cohen <tzafrir.cohen@xorcom.com>2010-06-08 14:44:37 +0000
commit596aff760f327377616b749159905cc0a39abe3b (patch)
tree7f4255df001634059cadd22866a2d4fe47b5448a /build_tools
parentd97cca594a35cee15239c149efb0e76cc9b1d910 (diff)
live_dahdi: load firmware_class if required
Modprobe firmware_class for modules that may need it (and that we insmod later) git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@8751 a0bf4364-ded3-4de4-8d8a-66a801d63aff
Diffstat (limited to 'build_tools')
-rwxr-xr-xbuild_tools/live_dahdi7
1 files changed, 6 insertions, 1 deletions
diff --git a/build_tools/live_dahdi b/build_tools/live_dahdi
index 2fcd17b..3d6aad5 100755
--- a/build_tools/live_dahdi
+++ b/build_tools/live_dahdi
@@ -8,6 +8,7 @@ XPP_SYNC=${XPP_SYNC:-auto}
AST_SCRIPT=${AST_SCRIPT:-/etc/init.d/asterisk}
# Use this file to pass options to modules:
PERLLIBDIR=`perl -V:sitelib | cut -d "'" -f 2`
+EXTRA_MODS="crc_ccitt"
# Manual list of modules. They will be loaded by insmod.
# If reside in a subdir, add it explicitly.
@@ -55,6 +56,7 @@ export ASTRIBANK_HEXLOAD
# make sure Astribank initialization scripts are from our tree.
xpp_ARGS="$xpp_ARGS initdir=$FIRMWARE_DIR"
+dahdi_ARGS="$dahdi_ARGS initdir=$FIRMWARE_DIR"
# the same as xpp/utils/dahdi_drivers .
# With the remote mode, I can't rely on files in the source directory.
@@ -84,6 +86,7 @@ set_modules_to_load() {
# FIXME: better automation of the voicebus
# dependency:
MODULES_LOAD="$MODULES_LOAD voicebus/dahdi_voicebus $mod/$mod"
+ EXTRA_MODS="$EXTRA_MODS firmware_class"
;;
wct4xxp | wcte12xp | wctc4xp | wcb4xxp)
MODULES_LOAD="$MODULES_LOAD $mod/$mod"
@@ -196,7 +199,9 @@ load)
# TODO: Find a way to use modprobe.
# Or implement a way to pass arguments to modules here (yuck)
set_modules_to_load
- modprobe crc_ccitt || : # FIXME: Make this optional?
+ for mod in $EXTRA_MODS; do
+ modprobe $mod || : # FIXME: Make this optional?
+ done
for module in $MODULES_LOAD; do
eval module_args="\$`basename ${module}`_ARGS"
insmod $MODULES_DIR/$module.ko $module_args