You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

15 lines
303 B

  1. #!/bin/sh
  2. # Copyright (C) 2016 OpenWrt.org
  3. # Copyright (C) 2016 Yousong Zhou <yszhou4tech@gmail.com>
  4. [ "$SUBSYSTEM" = "virtio-ports" ] || exit 0
  5. syspath="/sys/$DEVPATH"
  6. name="$(cat "$syspath/name" 2>/dev/null)"
  7. [ -n "$name" ] || exit 0
  8. case "$ACTION" in
  9. "add")
  10. /etc/init.d/qemu-ga start
  11. ;;
  12. esac