forked from ellysh/mxu11x0
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmxinstall
executable file
·35 lines (32 loc) · 886 Bytes
/
mxinstall
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
#!/bin/sh
###############################################################################
# Program:
# MOXA Linux driver installer
#
# History:
# 2009/09/11
#
# Author:
# Ken Huang, [email protected]
#
# Discription:
# The script install and load the MOXA Linux driver.
#
###############################################################################
TARGET_DRIVER=mxu11x0
MXVER=1.3.11
if lsmod | grep -q $TARGET_DRIVER ; then
echo "Found driver in system..."
echo "Unloading driver..."
rmmod $TARGET_DRIVER
echo "Unload driver successfully."
echo ""
fi
if make install ; then
echo ""
echo "Loading driver..."
modprobe $TARGET_DRIVER
echo "************************************************************************"
echo " MOXA UPort 11x0 series driver ver $MXVER loaded successfully."
echo "************************************************************************"
fi