otgcontrol: add debug hack disabling OTG detection in default state
Due to the authorized mode (default state) not being implemented properly yet with filtering and such, a concern regarding short while in a bag or such was discussed. As a hot fix, the device connection (POGO ID pin) is deactivated in default mode until this has been properly implemented, but enabled when explicitly entering unauthorized mode from the test-application in order to use the QR code reader.pull/10/head
parent
2edbefedce
commit
e27d817e3c
|
@ -188,7 +188,8 @@ static int otgcontrol_reset_fsm(struct rm_otgcontrol_data *otgc_data)
|
|||
"%s: Activating one-wire GPIO IRQ\n",
|
||||
__func__);
|
||||
|
||||
otgcontrol_activate_gpio_irq(otgc_data);
|
||||
/* otgcontrol_activate_gpio_irq(otgc_data);*/
|
||||
otgcontrol_deactivate_gpio_irq(otgc_data);
|
||||
|
||||
dev_dbg(otgc_data->dev,
|
||||
"%s: Checking if device is connected and initiating default "
|
||||
|
@ -1282,6 +1283,8 @@ static int otgcontrol_do_set_controlmode(
|
|||
|
||||
otgc_data->otg_controlstate = OTG1_STATE__MANUAL_CONTROL;
|
||||
otgc_data->otg1_controllermode = OTG_MODE__MANUAL_CONTROL;
|
||||
|
||||
otgcontrol_deactivate_gpio_irq(otgc_data);
|
||||
break;
|
||||
|
||||
case OTG_MODE__ONEWIRE_AUTH:
|
||||
|
@ -1303,6 +1306,8 @@ static int otgcontrol_do_set_controlmode(
|
|||
otgc_data->otg_controlstate = OTG1_STATE__ONEWIRE_AUTH_NOT_CONNECTED;
|
||||
}
|
||||
otgc_data->otg1_controllermode = OTG_MODE__ONEWIRE_AUTH;
|
||||
|
||||
otgcontrol_deactivate_gpio_irq(otgc_data);
|
||||
break;
|
||||
|
||||
case OTG_MODE__USB_NO_AUTH:
|
||||
|
@ -1324,6 +1329,8 @@ static int otgcontrol_do_set_controlmode(
|
|||
otgc_data->otg_controlstate = OTG1_STATE__USB_NO_AUTH_NOT_CONNECTED;
|
||||
}
|
||||
otgc_data->otg1_controllermode = OTG_MODE__USB_NO_AUTH;
|
||||
|
||||
otgcontrol_activate_gpio_irq(otgc_data);
|
||||
break;
|
||||
|
||||
default:
|
||||
|
@ -1504,7 +1511,9 @@ static int otgcontrol_do_device_disconnected_procedure(
|
|||
"%s: Activating one-wire GPIO IRQ\n",
|
||||
__func__);
|
||||
|
||||
otgcontrol_activate_gpio_irq(otgc_data);
|
||||
/* otgcontrol_activate_gpio_irq(otgc_data);*/
|
||||
if (otgc_data->otg1_controllermode == OTG_MODE__USB_NO_AUTH)
|
||||
otgcontrol_activate_gpio_irq(otgc_data);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue