Merge pull request #1704 from Dasharo/nitropad-shutdown

nitropad-nx: use standard shutdown/reboot commands
This commit is contained in:
Thierry Laurion 2024-06-21 10:24:45 -04:00 committed by GitHub
commit 96b619b5fd
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 0 additions and 46 deletions

View File

@ -1,36 +0,0 @@
#!/bin/ash
# Method to access IT5570 IO Depth 2 registers
it5570_i2ec() {
# TODO: Use /dev/port instead of iotools
# Address high byte
iotools io_write8 0x2e 0x2e
iotools io_write8 0x2f 0x11
iotools io_write8 0x2e 0x2f
iotools io_write8 0x2f $(($2>>8 & 0xff))
# Address low byte
iotools io_write8 0x2e 0x2e
iotools io_write8 0x2f 0x10
iotools io_write8 0x2e 0x2f
iotools io_write8 0x2f $(($2 & 0xff))
# Data
iotools io_write8 0x2e 0x2e
iotools io_write8 0x2f 0x12
iotools io_write8 0x2e 0x2f
case $1 in
"r")
iotools io_read8 0x2f
;;
"w")
iotools io_write8 0x2f "$3"
;;
esac
}
# shut down using EC external watchdog reset
it5570_i2ec w 0x1f01 0x20
it5570_i2ec w 0x1f07 0x01

View File

@ -8,11 +8,6 @@ if [ "$CONFIG_TPM" = "y" ]; then
tpmr shutdown
fi
# Run special EC-based poweroff for Nitropad-Nxx
if [ "$CONFIG_BOARD" = "nitropad-nv41" ] || [ "$CONFIG_BOARD" = "nitropad-ns50" ]; then
/bin/nitropad-shutdown.sh
fi
# Sync all mounted filesystems
echo s > /proc/sysrq-trigger

View File

@ -17,11 +17,6 @@ if [ "$CONFIG_TPM" = "y" ]; then
tpmr shutdown
fi
# Run special EC-based poweroff for Nitropad-Nxx
if [ "$CONFIG_BOARD" = "nitropad-nv41" ] || [ "$CONFIG_BOARD" = "nitropad-ns50" ]; then
/bin/nitropad-shutdown.sh
fi
# Sync all mounted filesystems
echo s > /proc/sysrq-trigger