Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit c4e6499d authored by Ray Chi's avatar Ray Chi
Browse files

redfin: usb: add state of usb extcon to monitorffs

Monitorffs needs to check the state of usb extcon to pull up
USB gadget. Therefore, this patch add state of usb extcon and
send this information to monitorffs.

Bug: 173086594
Test: verified pass
Merged-In: I29df29efcf55118241f0ca7072b034c1fb5a37f2
Change-Id: I2c19f769991b014dfa7051e114abfecc40b90a6e
parent 488ea9bd
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -66,7 +66,8 @@ using ::android::hardware::usb::gadget::V1_1::IUsbGadget;
using ::std::string;

constexpr char kGadgetName[] = "a600000.dwc3";
static MonitorFfs monitorFfs(kGadgetName);
constexpr char kExtconUsbState[] = "/sys/class/extcon/extcon4/cable.0/state";
static MonitorFfs monitorFfs(kGadgetName, kExtconUsbState);

struct UsbGadget : public IUsbGadget {
    UsbGadget();