[v7,1/5] KVM: selftests: Add missing break between -e and -g option in dirty_log_perf_test

Message ID 20221031173819.1035684-2-vipinsh@google.com
State New
Headers
Series dirty_log_perf_test vCPU pinning |

Commit Message

Vipin Sharma Oct. 31, 2022, 5:38 p.m. UTC
  Passing -e option (Run VCPUs while dirty logging is being disabled) in
dirty_log_perf_test also unintentionally enables -g (Do not enable
KVM_CAP_MANUAL_DIRTY_LOG_PROTECT2). Add break between two switch case
logic.

Fixes: cfe12e64b065 ("KVM: selftests: Add an option to run vCPUs while disabling dirty logging")
Signed-off-by: Vipin Sharma <vipinsh@google.com>
---
 tools/testing/selftests/kvm/dirty_log_perf_test.c | 1 +
 1 file changed, 1 insertion(+)
  

Comments

Sean Christopherson Oct. 31, 2022, 6:46 p.m. UTC | #1
On Mon, Oct 31, 2022, Vipin Sharma wrote:
> Passing -e option (Run VCPUs while dirty logging is being disabled) in
> dirty_log_perf_test also unintentionally enables -g (Do not enable
> KVM_CAP_MANUAL_DIRTY_LOG_PROTECT2). Add break between two switch case
> logic.
> 
> Fixes: cfe12e64b065 ("KVM: selftests: Add an option to run vCPUs while disabling dirty logging")
> Signed-off-by: Vipin Sharma <vipinsh@google.com>
> ---

Reviewed-by: Sean Christopherson <seanjc@google.com>
  

Patch

diff --git a/tools/testing/selftests/kvm/dirty_log_perf_test.c b/tools/testing/selftests/kvm/dirty_log_perf_test.c
index f99e39a672d3..56e08da3a87f 100644
--- a/tools/testing/selftests/kvm/dirty_log_perf_test.c
+++ b/tools/testing/selftests/kvm/dirty_log_perf_test.c
@@ -411,6 +411,7 @@  int main(int argc, char *argv[])
 		case 'e':
 			/* 'e' is for evil. */
 			run_vcpus_while_disabling_dirty_logging = true;
+			break;
 		case 'g':
 			dirty_log_manual_caps = 0;
 			break;