Skip to content

Conversation

@stephan-gh
Copy link
Contributor

Some boards have more than one USB port. In that case, there is a second
GPIO on the debug board to simulate a USB disconnection for those.

Add the option to describe both USB disconnect GPIOs using
"usb0_disconnect" and "usb1_disconnect" and change both of them
when disabling USB power.

In the future it might be useful to control them separately, but for now
this ensures that power to the board is cut properly when the board is
powered off.

Also fix some mistakes in schema.yaml that prevented actually validating the properties below ftdi_gpio.

Cc: @superna9999

unevaluatedItems is for array items, we need unevaluatedProperties here.
But actually this can just be additionalProperties.
"patternProperties" must be on the same indentation level as "properties",
otherwise it just defines a property called "patternProperties" in
cdba.yaml.

Also add additionalProperties: false, so properties not matching the regex
are actually disallowed and reported.
Some boards have more than one USB port. In that case, there is a second
GPIO on the debug board to simulate a USB disconnection for those.

Add the option to describe both USB disconnect GPIOs using
"usb0_disconnect" and "usb1_disconnect" and change both of them
when disabling USB power.

In the future it might be useful to control them separately, but for now
this ensures that power to the board is cut properly when the board is
powered off.
Copy link
Member

@superna9999 superna9999 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice catch, thx for the fix!

@superna9999 superna9999 merged commit 95a4070 into linux-msm:master Mar 18, 2025
55 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants