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

Commit d0776158 authored by Radu's avatar Radu
Browse files

Add USB information to bugreport

Include the output of two commands useful especially for usb-related debugging
  - lsusb (toybox) - list usb devices connected to the host
  - typec_connector_class - list information about the type-c ports of the system

Bug: 375337894
Flag: EXEMPT additional logs to bugreport
Ignore-AOSP-First: typec_connector_class currently developed internally but designed to be public.
Test: manual - check if bugreport contains entries for lsusb and typec_connector_class and if the output of typec_connector_class_is_similar to:

    port0
      uevent: DEVTYPE=typec_port
      TYPEC_PORT=port0
      vconn_source: no
      supported_accessory_modes: none
      power_role: source [sink]
      data_role: host [device]
      preferred_role: source
      power_operation_mode: default
      usb_power_delivery_revision: 0.0
      usb_typec_revision: 0.0
      waiting_for_supplier: 0
    port1
      [...port1 info]

Change-Id: If0ff2bfb45023698d18bfbaee522bd29843224af
parent 74e06f23
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -1841,6 +1841,11 @@ Dumpstate::RunStatus Dumpstate::dumpstate() {
        RunCommand("DUMP VENDOR RIL LOGS", {"vril-dump"}, options.Build());
    }

    /* Dump USB information */
    RunCommand("typec_connector_class", {"typec_connector_class"},
               CommandOptions::WithTimeout(10).AsRootIfAvailable().Build());
    RunCommand("lsusb", {"lsusb"}, CommandOptions::WithTimeout(10).AsRootIfAvailable().Build());

    printf("========================================================\n");
    printf("== Android Framework Services\n");
    printf("========================================================\n");