adjust the installkernel function to make it return correct value

The old implementation in installkernel() will not return success when
added wdt module is not iTCO_wdt. The returned value is related to the
comparison. This is not correct and will cause kdump load failed.

Now move the exact wdt module inserting to the right place, this can
be fixed.

Signed-off-by: Baoquan He <bhe@redhat.com>
Acked-by: Vivek Goyal <vgoyal@redhat.com>
This commit is contained in:
Baoquan He 2014-02-28 16:25:36 +08:00 committed by WANG Chao
parent 428a5e99ee
commit 5caafd2c00

View File

@ -489,7 +489,7 @@ install() {
installkernel() {
wdt=$(lsmod|cut -f1 -d' '|grep "wdt$")
if [ -n "$wdt" ]; then
instmods $wdt
[ "$wdt" = "iTCO_wdt" ] && instmods lpc_ich
instmods $wdt
fi
}