Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Set Serial Clockrate based on data parsed from host firmware #6215

Merged
merged 2 commits into from
Sep 20, 2024

Conversation

MrChromebox
Copy link
Contributor

@MrChromebox MrChromebox commented Sep 18, 2024

Description

Set PcdSerialClockRate from SerialPortInfo in UefiPayloadEntry.

The initial approach was to add a ClockRate field to UNIVERSAL_PAYLOAD_SERIAL_PORT_INFO data struct, but simplified to setting the PCD directly based on feedback from reviewers.

These changes enable the serial clock rate value, which is already passed in from the host firmware, to be used when configuring the serial port for debug output. AMD Zen platform devices require this in order to have functional serial output.

  • Breaking change?
  • Impacts security?
  • Includes tests?

How This Was Tested

build/boot multiple AMD/Intel devices and verify serial output works for all.

Integration Instructions

N/A

Copy link

@vbpandya vbpandya left a comment

Choose a reason for hiding this comment

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

stating the obvious caught by CI :)
"WARNING - Line 3 of commit message is too long (76 >= 76)"

@MrChromebox MrChromebox force-pushed the set_serial branch 3 times, most recently from d05a6e5 to bcb953e Compare September 18, 2024 20:15
@gguo11837463
Copy link
Contributor

gguo11837463 commented Sep 18, 2024

Before make this change, please make sure this document got update.
https://universalscalablefirmware.github.io/documentation/2_universal_payload.html
image
Header Revision should be changed from 1 to 2.
Header Length should be change from 18 to 22.

Source Code should be change like below.
if (SerialPortInfo->Header.Revision >= 1) {
XXX
}

@MrChromebox
Copy link
Contributor Author

@gguo11837463 have opened a PR to update the documentation here:
UniversalScalableFirmware/documentation#61

Will update this PR to only use the ClockRate if header version >= 2.

@MrChromebox MrChromebox changed the title Set Serial CLockrate based on data parsed from host firmware Set Serial Clockrate based on data parsed from host firmware Sep 19, 2024
@ChaselChiu ChaselChiu added the push Auto push patch series in PR if all checks pass label Sep 20, 2024
@mergify mergify bot merged commit c358009 into tianocore:master Sep 20, 2024
126 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
push Auto push patch series in PR if all checks pass
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants