Skip to content

type-c-service/tps6699x: Fix EPR capable flag not being set - #938

Closed
RobertZ2011 wants to merge 1 commit into
OpenDevicePartnership:stable-v0.1.yfrom
RobertZ2011:stable-v0.1.y
Closed

type-c-service/tps6699x: Fix EPR capable flag not being set#938
RobertZ2011 wants to merge 1 commit into
OpenDevicePartnership:stable-v0.1.yfrom
RobertZ2011:stable-v0.1.y

Conversation

@RobertZ2011

Copy link
Copy Markdown
Contributor

This flag was not being set properly.

@RobertZ2011 RobertZ2011 self-assigned this Aug 6, 2026
@RobertZ2011
RobertZ2011 force-pushed the stable-v0.1.y branch 2 times, most recently from 7dc74f3 to b2e1585 Compare August 6, 2026 23:32
@RobertZ2011
RobertZ2011 requested a lite review from Copilot August 6, 2026 23:32

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

This PR fixes PortStatus.epr reporting for the TPS6699x Type-C/PD controller integration by deriving the flag from the received Source Capabilities (Fixed Supply PDO) rather than leaving it unset. While doing so, it also switches dual_power and unconstrained_power extraction to use the decoded Fixed Supply PDO fields directly. A small documentation tweak updates the PortStatus comment to reflect that epr represents capability (not “mode active”).

Changes:

  • Decode the first received source PDO as a Fixed Supply PDO and use it to populate dual_power, unconstrained_power, and epr in sink explicit-contract status.
  • Add PortStatus.epr assignment based on epr_capable.
  • Update the PortStatus field doc comment to “EPR capable”.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
type-c-service/src/driver/tps6699x.rs Sets PortStatus.epr (and related partner-power flags) from the decoded Fixed Supply Source PDO when acting as a sink with an explicit contract.
embedded-service/src/type_c/controller.rs Updates the documentation for PortStatus.epr to reflect capability semantics.

Comment thread embedded-service/src/type_c/controller.rs
@RobertZ2011
RobertZ2011 marked this pull request as ready for review August 6, 2026 23:38
@RobertZ2011
RobertZ2011 requested review from a team as code owners August 6, 2026 23:38
@RobertZ2011
RobertZ2011 enabled auto-merge (squash) August 6, 2026 23:38
@RobertZ2011

Copy link
Copy Markdown
Contributor Author

Forgot to do this in a separate branch, moved to #941.

@RobertZ2011 RobertZ2011 closed this Aug 7, 2026
auto-merge was automatically disabled August 7, 2026 16:12

Pull request was closed

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.

3 participants