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

Netstack s/r: Configure the new network config in the loaded stack. #11389

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

copybara-service[bot]
Copy link

@copybara-service copybara-service bot commented Jan 24, 2025

Netstack s/r: Configure the new network config in the loaded stack.

  • Refactor the scrapping of network config in {sandbox/boot}/network.go to
    make is easy to configure in the loaded stack during restore.
  • Remove ReplaceConfig at the inet.Stack level.
  • Restore some fields correctly in tcpip.Stack.
  • Store the required network config in the loader and use it to set new
    configuration in the loaded stack during restore.

This CL doesn't change any behavior when netstack s/r is disabled.
When netstack s/r is enabled:

  • the network configuration will be applied to the loaded stack from the spec
    instead of using the newly created stack.
  • Previously the network config was applied to the new network stack and then
    copied to the loaded stack in the ReplaceConfig method. Now, the network config
    is directly applied to the loaded stack with the exception when XDP is enabled.

@copybara-service copybara-service bot added the exported Issue was exported automatically label Jan 24, 2025
@copybara-service copybara-service bot force-pushed the test/cl719364530 branch 9 times, most recently from cc3cd9b to 8bddb44 Compare January 28, 2025 20:34
@copybara-service copybara-service bot changed the title netstack refactor Netstack s/r: Configure the new network config in the loaded stack. Jan 28, 2025
- Refactor the scrapping of network config in {sandbox/boot}/network.go to
make is easy to configure in the loaded stack during restore.
- Remove ReplaceConfig at the inet.Stack level.
- Restore some fields correctly in tcpip.Stack.
- Store the required network config in the loader and use it to set new
configuration in the loaded stack during restore.

This CL doesn't change any behavior when netstack s/r is disabled.
When netstack s/r is enabled:
- the network configuration will be applied to the loaded stack from the spec
instead of using the newly created stack.
- Previously the network config was applied to the new network stack and then
copied to the loaded stack in the ReplaceConfig method. Now, the network config
is directly applied to the loaded stack with the exception when XDP is enabled.

PiperOrigin-RevId: 719364530
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
exported Issue was exported automatically
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant