Commit Graph

6 Commits

Author SHA1 Message Date
Ash Blake
993d1613c5 rosemary: usb: unify Usb and UsbGadget services
Change-Id: Iba27b07cc62aa646b1550aa7ced6eb4ffaab4e69
2022-11-12 10:48:38 +03:00
Ash Blake
aa51222c2a rosemary: usb: make sure rndis.gs4 exists when linking it 2022-11-12 10:48:38 +03:00
Ash Blake
68edd8118c rosemary: usb: fix usb preferences by spoofing roles
Our device has broken roles: they appear to be permanently set to
NONE and don't respond to configfs writes. This causes Android to
not see the USB port as connected, breaking the USB settings.

To repair USB preferences, we spoof roles in the following fashion:
  - data role: DEVICE (if NONE)
  - port mode: UFP (if NONE)
2022-11-12 10:48:38 +03:00
Ash Blake
ecfab0dcb6 rosemary: usb: implement gadget
Implement a USB gadget HAL based on the default implementation from
AOSP and move key features from init.mt6768.usb.rc to it. Also remove
triggers for some proprietary USB features that aren't too useful on
custom ROMs and seem to exist mostly for engineering purposes.

Change-Id: Ie920fea8b3834d3bada2609df66ca68ddbb980b1
2022-11-12 10:48:38 +03:00
Ash Blake
9d9d5dcd81 mt6768-common: usb: adapt implementation to rosemary 2022-11-12 10:48:38 +03:00
Ash Blake
1e9c5160b3 rosemary: build USB HAL from wahoo
Change-Id: I273b3ce64c21f4f3609219e20f6b3ece5f05079f
2022-11-12 10:48:38 +03:00