on early-boot
    # Configure DRM in 64-bit architecture. This shall be done before to start
    # the DRM service which is triggered by the 'on boot' event.
    setprop drm.64bit.enabled true

on boot

    # Set OpenGLES version
    setprop ro.opengles.version 196609

    # Set GPU 3D minimum clock to 3/64
    write /sys/bus/platform/drivers/galcore/gpu3DMinClock 3

    # change for FSL specific service
    chown root system /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
    chmod 0664 /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
    chown root system /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq
    chmod 0664 /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq
    chown root system /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
    chmod 0664 /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
    chown root system /sys/devices/system/cpu/cpu0/cpufreq/cpuinfo_cur_freq
    chmod 0440 /sys/devices/system/cpu/cpu0/cpufreq/cpuinfo_cur_freq
    chown root system /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_frequencies
    chown root system /sys/devices/system/cpu/cpu0/online
    chmod 0664 /sys/devices/system/cpu/cpu0/online
    chown root system /sys/devices/system/cpu/cpu1/online
    chmod 0664 /sys/devices/system/cpu/cpu1/online
    chown root system /sys/devices/system/cpu/cpu2/online
    chmod 0664 /sys/devices/system/cpu/cpu2/online
    chown root system /sys/devices/system/cpu/cpu3/online
    chmod 0664 /sys/devices/system/cpu/cpu3/online

on property:sys.boot_completed=1
    # Set default CPU frequency governor
    # Set timer 40ms, min sample 60ms,hispeed at cpufreq MAX freq in freq_table at load 40%
    write /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor interactive
    write /sys/devices/system/cpu/cpufreq/interactive/timer_rate 40000
    write /sys/devices/system/cpu/cpufreq/interactive/min_sample_time 60000
    write /sys/devices/system/cpu/cpufreq/interactive/go_hispeed_load 40
# change interactive atrrubuties permissions when interactive is actived
on property:sys.interactive="active"
    chown system root /sys/devices/system/cpu/cpufreq/interactive/timer_rate
    chmod 0660 /sys/devices/system/cpu/cpufreq/interactive/timer_rate
    chown system root /sys/devices/system/cpu/cpufreq/interactive/min_sample_time
    chmod 0660 /sys/devices/system/cpu/cpufreq/interactive/min_sample_time
    chown system root /sys/devices/system/cpu/cpufreq/interactive/hispeed_freq
    chmod 0660 /sys/devices/system/cpu/cpufreq/interactive/hispeed_freq
    chown system root /sys/devices/system/cpu/cpufreq/interactive/go_hispeed_load
    chmod 0660 /sys/devices/system/cpu/cpufreq/interactive/go_hispeed_load
    chown system root /sys/devices/system/cpu/cpufreq/interactive/above_hispeed_delay
    chmod 0660 /sys/devices/system/cpu/cpufreq/interactive/above_hispeed_delay
    chown system root /sys/devices/system/cpu/cpufreq/interactive/boost
    chmod 0660 /sys/devices/system/cpu/cpufreq/interactive/boost
    chown system root /sys/devices/system/cpu/cpufreq/interactive/boostpulse
    chmod 0660 /sys/devices/system/cpu/cpufreq/interactive/boostpulse
    chown system system /sys/devices/system/cpu/cpufreq/interactive/boostpulse_duration
    chmod 0660 /sys/devices/system/cpu/cpufreq/interactive/boostpulse_duration
    chown system system /sys/devices/system/cpu/cpufreq/interactive/io_is_busy
    chmod 0660 /sys/devices/system/cpu/cpufreq/interactive/io_is_busy
    write /sys/devices/system/cpu/cpufreq/interactive/timer_rate 40000
    write /sys/devices/system/cpu/cpufreq/interactive/min_sample_time 60000
    write /sys/devices/system/cpu/cpufreq/interactive/go_hispeed_load 40
