Files
bananarchy/overlay/rootfs/etc/local.d/10-power-save.start
T

19 lines
798 B
Bash
Raw Normal View History

#!/bin/sh
# Bananarchy kernel and runtime power management optimizations
# Disable fbcon cursor blinking (eliminates 5 Hz fb_flashcursor + drm_fb_helper_damage_work wakeups)
if [ -w /sys/class/graphics/fbcon/cursor_blink ]; then
echo 0 > /sys/class/graphics/fbcon/cursor_blink 2>/dev/null || true
fi
# Reduce periodic VM stat shepherd and dirty writeback timer wakeups
{ echo 10 > /proc/sys/vm/stat_interval; } 2>/dev/null || true
{ echo 1500 > /proc/sys/vm/dirty_writeback_centisecs; } 2>/dev/null || true
{ echo 3000 > /proc/sys/vm/dirty_expire_centisecs; } 2>/dev/null || true
{ echo "1 4 1 4" > /proc/sys/kernel/printk; } 2>/dev/null || true
# Automount microSD card if present at boot
if [ -x /usr/bin/sxmo_sdcard.sh ]; then
/usr/bin/sxmo_sdcard.sh automount boot >/dev/null 2>&1 &
fi