#! /bin/sh #---------------------------------------------------------------------------- # /etc/rc.d/ide - load ide cdrom drivers # # Creation: 2003-07-19 fm # Last Update: $Id$ # # Copyright (c) 2003-2011 the eisfair team, team(at)eisfair(dot)org # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. #---------------------------------------------------------------------------- . /etc/init.d/functions # get kernel version case $(uname -r) in 2.6*) load='/sbin/modprobe' unload='/sbin/modprobe -r' ide_cd='ide-cd_mod' ;; *) load='/sbin/insmod' unload='/sbin/rmmod' ide_cd='ide-cd' ;; esac case ${1} in start) boot_mesg " * Loading ide cdrom drivers ..." ${load} cdrom 2>/dev/null # load generic cdrom driver ${load} ${ide_cd} 2>/dev/null # load ide cdrom driver ${load} ide-tape 2>/dev/null # load ide cdrom driver ${load} isofs 2>/dev/null # load isofs evaluate_retval ;; stop) boot_mesg " * Unloading ide cdrom drivers ..." /bin/umount /dev/cdrom 2>/dev/null ${unload} isofs 2>/dev/null # unload isofs ${unload} ide-tape 2>/dev/null # unload ide cdrom driver ${unload} ${ide_cd} 2>/dev/null # unload ide cdrom driver ${unload} cdrom 2>/dev/null # unload generic cdrom driver evaluate_retval ;; esac set +x