-
Overview
-
redpesk OS releases
-
Security updates
-
Redpesk OS Tips and Tricks
-
Application Framework Manager
-
Application Framework Binder
-
APIs & Services
-
Security manager
-
OP-TEE within redpesk
-
Trusted Boot
-
Recovery features
-
redpak
-
Minimal image
- Reduce image size
- Optimizing boot time
-
Kernel fragments description
- Introduction to Linux Kernel Configuration
- 01 Disable IPC, Timers and Audit
- 02 Disable Kconfig, Scheduler and Initrd
- 03 Disable Perf, Profiling and Errata
- 04 Disable EFI, Power Management Debug and Energy Model
- 05 Disable Schedutil, CPUFreq Governors and Virtualization
- 06 Disable Kprobes and Jump Labels
- 07 Disable GCC Plugins and Function Alignment
- 08 Disable Partition Parsers
- 09 Enable Inline Spinlocks and Kernel Operations
- 10 Disable Swap, Memory Hotplug and KSM
- 11 Disable Networking IPv4, IPv6, Netfilter
- 12 Disable SCTP, VLAN, TIPC, BATMAN
- 13 Disable Wireless, Bluetooth, CAN and RFKILL
- 14 Disable PCI and Firmware
- 15 Disable GNSS and ProcEvents
- 16 Disable Block Storage NBD and AoE
- 17 Disable EEPROM and Misc Drivers
- 18 Disable Network Device Drivers
- 19 Disable PHY Drivers
- 20 Disable PPP, WLAN Coexistence, and Failover
- 21 Disable Input Devices
- 22 Disable Serial, TTY and TPM
- 23 Disable I2C, Power and Sensor Drivers
- 24 Disable MFD, Display and Media Drivers
- 25 Disable USB, Sound, RTC and VirtIO
- 26 Disable Filesystem Encodings and Compatibility
- 27 Enable Minimal Cryptographic Core with SHA3 and XTS
- 28 Disable Hardware Cryptography, Keep DRBG and Jitter Entropy
- 29 Disable Kernel Debugging Features
- 30 Disable Filesystem Verity and SecurityFS
-
Zephyr in Redpesk
-
PERM-CHECK extension
-
Mender redpesk (OTA)
-
Hardware support
- Download images
- Image metrics
- Trusted Boot
- Boards - ARM64
- Boards - x86_64
- Boards - Virtual
- Miscs
Useful command lines
Determining the Board’s IP Address
Use ip a command:
root@m3ulcb:~# ip a
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default
inet 127.0.0.1/8 scope host lo
valid_lft forever preferred_lft forever
3: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP group default qlen 1000
inet 10.0.12.15/24 brd 10.0.2.255 scope global eth0
valid_lft forever preferred_lft forever
dnf / package management
Add repo (1st time)
dnf config-manager --add-repo repository_url
List the repositories
dnf repolist
Update the repo
dnf update --refresh
Install the package on board
sudo dnf install my-package
Uninstall a package
sudo dnf remove my-package
Power saving management
Kernel
CPU Freq
Most boards now use SoC that usually supports dynamic CPU frequency/voltage scaling. This technology allows the CPU frequency to be changed according to some kernel events (like the load of the system or using scripts and algorithms).
The Linux Kernel natively supports that and users can learn how it works using the Linux documentation available here:
Quick tips and examples
Here are some tips to help users change the CPU frequency (and voltage: this is usually done by driver management automatically).
To see which CPU scaling governor is available :
cat /sys/devices/system/cpu/cpufreq/policy0/scaling_available_governors
To change actual CPU scaling governor:
echo "powersave" > /sys/devices/system/cpu/cpufreq/policy0/scaling_governor
To get actual CPU frequency:
cat /sys/devices/system/cpu/cpufreq/policy0/scaling_cur_freq
Linux Sleep States
To reduce power of the system, it could be interesting to suspend the system during the time where nothing is done. The kernel Linux provides a feature that allows the system to sleep during this phase of “doing nothing”. In this mode, the system will sleep (no user code can be run and devices are suspended) and wait for an event to wake up and restore everything to be able to run user code again.
Depending on your system, the Linux kernel can support up to 4 different sleep modes known as “system sleep states”:
- Suspend-to-Idle
- Standby
- Suspend-to-RAM
- Hibernation
To learn more about how it works, please read the linux documentation available here:
NOTE:
See your BSP vendors’s characteristics to know which mode is supported or not
Quick tips and examples
Looking for available “wakeup” devices:
find /sys/devices/ -name wakeup
Allow a serial port to wakeup the system from a sleep state:
echo enabled > /sys/devices/soc0/soc.1/2100000.aipsbus/21f0000.serial/tty/ttymxc3/power/wakeup
Putting the system into a sleeping state to reduce power consumption:
echo mem > /sys/power/state
or
echo standby > /sys/power/state