pmaports/device/testing/device-pine64-pinebookpro/device-pine64-pinebookpro.post-install
Clayton Craft 55dc5819e4
pine64-pinebookpro: add service for setting low power state on boot (MR 2306)
This adds a very basic openrc runscript that sets the power state on
/dev/nvme0 to level 2, which seems(?) to be the lowest operational power
state based on some cursory internet searching (and querying the nvme
drives I have, Samsung EVO and Pro)

The drive path is hard coded, but could be made configurable later on. I
basically wanted to get something in pmaports quickly, since this power
stuff is a major source of instability for me and probably others too
who add nvme drives to this device.
2021-07-04 13:42:43 -07:00

8 lines
180 B
Bash

#!/bin/sh
# We'll update the hwdb so that the meta key gets fixed
echo "UPDATING HWDB..."
udevadm hwdb --update
rc-update add nvme-powersave boot
rc-update add sysfsconf default