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

Revert "runtime: confidential: Do not set the max_vcpu to cpu" #8533

Merged

Conversation

fidencio
Copy link
Member

This reverts commit b0157ad.

commit b0157ad73a41b7e23d3c3ca7a761e27eab29ae29
Refs: 3.3.0-alpha0-124-gb0157ad73
Author:     Fabiano Fidêncio <fabiano.fidencio@intel.com>
AuthorDate: Fri Aug 11 14:55:11 2023 +0200
Commit:     Fabiano Fidêncio <fabiano.fidencio@intel.com>
CommitDate: Fri Nov 10 12:58:20 2023 +0100

    runtime: confidential: Do not set the max_vcpu to cpu

    We don't have to do this since we're relying on the
    `static_sandbox_resource_mgmt` feature, which gives us the correct
    amount of memory and CPUs to be allocated.

    Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>

This commit was removing a requirement that was made previously, but due to the SMP issue we're facing with the QEMU used for TDX (see commit d1b54ed*), QEMU will fail to start due to:

Invalid CPU topology: product of the hierarchy must match maxcpus:
sockets (1) * dies (1) * cores (1) * threads (1) != maxcpus (240)"

This has no affect on the SEV / SNP workflow and hopefully we'll be able to re-revet this soon enough, when this gets solved on te QEMU side.

Fixes: #8532

@fidencio fidencio added ok-to-test force-skip-ci Stop the CI running for a PR (remember: if you break it, you fix it!) labels Nov 29, 2023
@fidencio
Copy link
Member Author

/test

@katacontainersbot katacontainersbot added the size/tiny Smallest and simplest task label Nov 29, 2023
@fidencio fidencio force-pushed the topic/fix-invalid-cpu-topology-for-tdx branch from c0bc518 to aab4786 Compare November 29, 2023 20:59
This reverts commit b0157ad.
```
commit b0157ad
Refs: 3.3.0-alpha0-124-gb0157ad73
Author:     Fabiano Fidêncio <fabiano.fidencio@intel.com>
AuthorDate: Fri Aug 11 14:55:11 2023 +0200
Commit:     Fabiano Fidêncio <fabiano.fidencio@intel.com>
CommitDate: Fri Nov 10 12:58:20 2023 +0100

    runtime: confidential: Do not set the max_vcpu to cpu

    We don't have to do this since we're relying on the
    `static_sandbox_resource_mgmt` feature, which gives us the correct
    amount of memory and CPUs to be allocated.

    Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
```

This commit was removing a requirement that was made previously, but due
to the SMP issue we're facing with the QEMU used for TDX (see commit
d1b54ed*), QEMU will fail to start due
to:
```
Invalid CPU topology: product of the hierarchy must match maxcpus:
sockets (1) * dies (1) * cores (1) * threads (1) != maxcpus (240)"
```

This has no affect on the SEV / SNP workflow and hopefully we'll be able
to re-revet this soon enough, when this gets solved on te QEMU side.

Last but not least, this is not a "clean" revert as we're using
conf.NumVCPUs() instead of conf.NumVCPUs, to ensure we're dealing with
uint32.

Fixes: kata-containers#8532

Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
@fidencio fidencio force-pushed the topic/fix-invalid-cpu-topology-for-tdx branch from aab4786 to f15e16b Compare November 29, 2023 23:41
@fidencio
Copy link
Member Author

/test

@fidencio fidencio merged commit 9b30d97 into kata-containers:main Nov 30, 2023
163 of 172 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
force-skip-ci Stop the CI running for a PR (remember: if you break it, you fix it!) ok-to-test size/tiny Smallest and simplest task
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Regression: TDX: Revert commit b0157ad73a41b7e23d3c3ca7a761e27eab29ae29
4 participants