We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4845774 commit 2df5064Copy full SHA for 2df5064
1 file changed
migration_source/v2.2.2.sh
@@ -1,3 +1,7 @@
1
# Enable usb-host on usb-c port
2
-sudo sed -zi "s/dtoverlay=dwc2/dtoverlay=dwc2,dr_mode=host/" /boot/config.txt
3
+#Add it to the dw2 line if it exist
4
+sudo sed -zi "s/dtoverlay=dwc2\n/dtoverlay=dwc2,dr_mode=host\n/" /boot/config.txt
5
+
6
+#Add the line if it does not exist
7
+sudo sed -zi '/dtoverlay=dwc2,dr_mode=host\n/!s/$/\ndtoverlay=dwc2,dr_mode=host\n/' /boot/config.txt
0 commit comments