Initial commit

This commit is contained in:
Your Name
2026-04-23 17:07:55 +08:00
commit b7e39e063b
16725 changed files with 1625565 additions and 0 deletions
@@ -0,0 +1,11 @@
[Unit]
Description=GXP EHCI Owner Reset Service
Wants=start-ipkvm.service
After=start-ipkvm.service
StartLimitIntervalSec=0
[Service]
Type=oneshot
ExecStart=/bin/sh -c "udc-reconnect.sh %i"
SyslogIdentifier=host-ehci-owner-reset@%i
@@ -0,0 +1,5 @@
DEVPATH=/dev/input/by-path/platform-ahb@80000000:vuhc-event
KEY=200
POLARITY=1
TARGET=host-ehci-owner-reset@udc0.service
EXTRA_ARGS=--continue
@@ -0,0 +1,5 @@
DEVPATH=/dev/input/by-path/platform-ahb@80000000:vuhc-event
KEY=201
POLARITY=1
TARGET=host-ehci-owner-reset@udc1.service
EXTRA_ARGS=--continue
@@ -0,0 +1,5 @@
DEVPATH=/dev/input/by-path/platform-ahb@80000000:vuhc-event
KEY=202
POLARITY=1
TARGET=host-ehci-owner-reset@udc2.service
EXTRA_ARGS=--continue
@@ -0,0 +1,37 @@
#!/bin/sh
if [ "$1" = "udc0" ]; then
function=$(cat /sys/class/udc/80401000.udc/function)
if [ "func-$function" != "func-" ]; then
echo "UDC0 owner is changed"
echo disconnect > /sys/class/udc/80401000.udc/soft_connect
sleep 3
echo connect > /sys/class/udc/80401000.udc/soft_connect
else
echo "UDC0 is not attached"
fi
else
if [ "$1" = "udc1" ]; then
function=$(cat /sys/class/udc/80402000.udc/function)
if [ "func-$function" != "func-" ]; then
echo "UDC1 owner is changed"
echo disconnect > /sys/class/udc/80402000.udc/soft_connect
sleep 3
echo connect > /sys/class/udc/80402000.udc/soft_connect
else
echo "UDC1 is not attached"
fi
else
if [ "$1" = "udc2" ]; then
function=$(cat /sys/class/udc/80403000.udc/function)
if [ "func-$function" != "func-" ]; then
echo "UDC2 owner is changed"
echo disconnect > /sys/class/udc/80403000.udc/soft_connect
sleep 3
echo connect > /sys/class/udc/80403000.udc/soft_connect
else
echo "UDC2 is not attached"
fi
fi
fi
fi