Skip to content

Conversation

@cfernald
Copy link
Collaborator

@cfernald cfernald commented Dec 4, 2025

UefiExt: Implement the reload command for Patina

This commit implements the automatic reload functionality provided by
the Patina core. This involves the following steps:

  1. Load the new core, and compress it.
  2. Request the core allocate memory for the compressed data.
  3. Write the compressed data to the core's memory.
  4. Request the core to load the compressed data.
  5. Switch the register state to jump to the new core.

ComToTcpServer: Send messages and blocks on COM

When sending large packets, the device FIFO may not be emptied fast enough
and data can end up getting lost. Patina can handle this to some degree,
but if the data lost is the checksum bytes, the stub does not realize the
packet was finished and will just wait indefinitely for more data.

This change forces the data to be sent in smaller blocks with delays in
between to allow the device to catch up. Ideally this is replaced by
proper flow control in the future.

@os-d os-d changed the title Implement support for core reload [REBASE & FF] Implement support for core reload Dec 4, 2025
When sending large packets, the device FIFO may not be emptied fast enough
and data can end up getting lost. Patina can handle this to some degree,
but if the data lost is the checksum bytes, the stub does not realize the
packet was finished and will just wait indefinitely for more data.

This change forces the data to be sent in smaller blocks with delays in
between to allow the device to catch up. Ideally this is replaced by
proper flow control in the future.
This commit implements the automatic reload functionality provided by
the Patina core. This involves the following steps:

1. Load the new core, and compress it.
2. Request the core allocate memory for the compressed data.
3. Write the compressed data to the core's memory.
4. Request the core to load the compressed data.
5. Switch the register state to jump to the new core.
@cfernald cfernald merged commit 13f7160 into microsoft:main Dec 8, 2025
5 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.

4 participants