#!/system/bin/sh
#
# load module to allow button backlight level changes

# Module location
MODULE="/system/lib/modules/backlight.ko"
SYMSEARCH_MODULE="/system/lib/modules/symsearch.ko"

# Property to disable the module
LOAD_MODULE=`getprop persist.sys.backlight.disable`

# can be loaded previously on defy gb
/system/xbin/rmmod $MODULE 2>/dev/null

if [ "$LOAD_MODULE" != "1" ]; then
    # brightness=6 to set the default brightness after test "animation" on module load
    /system/xbin/insmod $SYMSEARCH_MODULE
    /system/xbin/insmod $MODULE animate=1 brightness=6 log_enable=0 hook_enable=1 defy_plus=1
fi


