blob: a4eed736d974734b62be482c6104cb81cd7a0d6e [file] [log] [blame]
John Wanga66aa8a2020-09-30 13:19:08 +08001[Unit]
2Description=Phosphor Console Muxer listening on device /dev/%I
3BindsTo=dev-%i.device
4After=dev-%i.device
5
6[Service]
Lei YU63beff02021-09-08 15:21:51 +08007ExecStartPre=/bin/sh -c 'echo -n "uart3" > /sys/bus/platform/drivers/aspeed-uart-routing/1e78909c.uart-routing/uart1'
8ExecStartPre=/bin/sh -c 'echo -n "uart1" > /sys/bus/platform/drivers/aspeed-uart-routing/1e78909c.uart-routing/uart3'
9ExecStartPre=/bin/sh -c 'echo -n "io1" > /sys/bus/platform/drivers/aspeed-uart-routing/1e78909c.uart-routing/uart4'
10ExecStartPre=/bin/sh -c 'echo -n "uart4" > /sys/bus/platform/drivers/aspeed-uart-routing/1e78909c.uart-routing/io1'
John Wanga66aa8a2020-09-30 13:19:08 +080011ExecStart=/usr/bin/env obmc-console-server --config {sysconfdir}/obmc-console.conf %i
Lei YU63beff02021-09-08 15:21:51 +080012ExecStopPost=/bin/sh -c 'echo -n "io1" > /sys/bus/platform/drivers/aspeed-uart-routing/1e78909c.uart-routing/uart1'
13ExecStopPost=/bin/sh -c 'echo -n "io3" > /sys/bus/platform/drivers/aspeed-uart-routing/1e78909c.uart-routing/uart3'
14ExecStopPost=/bin/sh -c 'echo -n "io4" > /sys/bus/platform/drivers/aspeed-uart-routing/1e78909c.uart-routing/uart4'
15ExecStopPost=/bin/sh -c 'echo -n "uart1" > /sys/bus/platform/drivers/aspeed-uart-routing/1e78909c.uart-routing/io1'
John Wanga66aa8a2020-09-30 13:19:08 +080016SyslogIdentifier=obmc-console-server
17Restart=always
18
19[Install]
20WantedBy={SYSTEMD_DEFAULT_TARGET}