Files
2026-10-13 17:14:56 -05:00

54 lines
2.2 KiB
Plaintext

# Copyright (C) 2019 The LineageOS Project
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
import /vendor/etc/init/hw/init.tegra.rc
import /vendor/etc/init/hw/init.t210.rc
import /vendor/etc/init/hw/init.loki_foster_e_common.rc
import /vendor/etc/init/hw/init.sensors.nx.rc
import /vendor/etc/init/hw/init.${ro.boot.hardware.sku}.rc
on init
#setprop ro.surface_flinger.primary_display_orientation ORIENTATION_270
setprop ro.boot.secureos none
#setprop vendor.powerhal.config powerhint.${ro.boot.hardware.sku}.json
on fs
mount_all /vendor/etc/fstab.nx
swapon_all /vendor/etc/fstab.nx
mount tmpfs tmpfs /metadata size=10m
on post-fs-data
chmod 0664 /sys/devices/57000000.gpu/devfreq/57000000.gpu/max_freq
chown system system /sys/devices/57000000.gpu/devfreq/57000000.gpu/max_freq
chmod 0664 /sys/devices/57000000.gpu/devfreq/57000000.gpu/min_freq
chown system system /sys/devices/57000000.gpu/devfreq/57000000.gpu/min_freq
chmod 0666 /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
chown system system /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
chmod 0666 /sys/class/backlight/backlight/brightness
chown system system /sys/class/backlight/backlight/brightness
chmod 0664 /sys/kernel/tegra_cpufreq/overclock
chown system system /sys/kernel/tegra_cpufreq/overclock
chown system system /sys/bus/platform/devices/tegradc.0/enable
# enable oc only if passed from bootloader (no userspace toggle)
#on property:vold.post_fs_data_done=1 && property:ro.boot.oc=1
# write /sys/kernel/tegra_cpufreq/overclock 1
on boot
write /sys/devices/system/cpu/cpufreq/schedutil/up_rate_limit_us 500
write /sys/module/input_cfboost/parameters/boost_gpu 460800