summaryrefslogtreecommitdiff
path: root/data
diff options
context:
space:
mode:
authorkhramshinr <khramshinr@gmail.com>2024-06-18 12:57:24 +0600
committerMergify <37929162+mergify[bot]@users.noreply.github.com>2024-06-22 17:11:25 +0000
commitfba36052246b31252d9826e0c117c9ba1fdc4317 (patch)
tree887544cb7c8d02392a96ca72fac45f9f91c4af84 /data
parent537706e0c640bc48e90af6636b1063da8101a8c4 (diff)
downloadvyos-1x-fba36052246b31252d9826e0c117c9ba1fdc4317.tar.gz
vyos-1x-fba36052246b31252d9826e0c117c9ba1fdc4317.zip
T5949: Add option to disable USB autosuspend
(cherry picked from commit c0b2693cebc3429e1974a9cec5946fa88ffc0205)
Diffstat (limited to 'data')
-rw-r--r--data/templates/system/40_usb_autosuspend.j25
1 files changed, 5 insertions, 0 deletions
diff --git a/data/templates/system/40_usb_autosuspend.j2 b/data/templates/system/40_usb_autosuspend.j2
new file mode 100644
index 000000000..01ba86420
--- /dev/null
+++ b/data/templates/system/40_usb_autosuspend.j2
@@ -0,0 +1,5 @@
+{% set autosuspend = "auto" %}
+{% if disable_usb_autosuspend is vyos_defined %}
+{% set autosuspend = "on" %}
+{% endif %}
+ACTION=="add", SUBSYSTEM=="usb", TEST=="power/control", ATTR{power/control}="{{ autosuspend }}"