target/i386: Fix !CONFIG_SYNDBG build
PATCH 1/1 target/i386: Fix !CONFIG_SYNDBG build
Commit bbf3810f2c4f ("target/i386: Fix conditional CONFIG_SYNDBG enablement") broke !CONFIG_SYNDBG builds as hyperv_syndbg_query_options() is missing there. The idea probably was that as "hv-syndbg" is now under '#ifdef CONFIG_SYNDBG', hyperv_feat_enabled(cpu, HYPERV_FEAT_SYNDBG) cannot be true anyway.
It would have been possible to add a stub for hyperv_syndbg_query_options() instead of resurrecting '#ifdef CONFIG_SYNDBG' but avoiding HV_X64_MSR_SYNDBG_OPTIONS altogether instead of zeroing it when !CONFIG_SYNDBG seems preferable.
--- target/i386/kvm/kvm.c | 2 ++ 1 file changed, 2 insertions(+)
target/i386/kvm/kvm.c +2 -0
@@ -4034,11 +4034,13 @@ static int kvm_put_msrs(X86CPU *cpu, int level)kvm_msr_entry_add (cpu,HV_X64_MSR_TSC_EMULATION_STATUS , env->msr_hv_tsc_emulation_status); } +#ifdef CONFIG_SYNDBG if (hyperv_feat_enabled (cpu,HYPERV_FEAT_SYNDBG ) && has_msr_hv_syndbg_options) {kvm_msr_entry_add (cpu,HV_X64_MSR_SYNDBG_OPTIONS ,hyperv_syndbg_query_options ()); } +#endif }if (hyperv_feat_enabled (cpu,HYPERV_FEAT_VAPIC )) { kvm_msr_entry_add(cpu, HV_X64_MSR_APIC_ASSIST_PAGE,
Signature · 1 line
2.47.0
Quoted 11 lines · Vitaly Kuznetsov
Commit
bbf3810f2c4f("target/i386: Fix conditionalCONFIG_SYNDBGenablement") broke !CONFIG_SYNDBG builds ashyperv_syndbg_query_options()is missing there. The idea probably was that as "hv-syndbg" is now under '#ifdefCONFIG_SYNDBG',hyperv_feat_enabled(cpu, HYPERV_FEAT_SYNDBG)cannot be true anyway.It would have been possible to add a stub for
hyperv_syndbg_query_options()instead of resurrecting '#ifdefCONFIG_SYNDBG' but avoidingHV_X64_MSR_SYNDBG_OPTIONSaltogether instead of zeroing it when !CONFIG_SYNDBG seems preferable.
Quoted 6 lines
Reported-by Michael Tokarev <[email protected]>Fixes bbf3810f2c4f ("target/i386: Fix conditional CONFIG_SYNDBG enablement")Signed-off-by Vitaly Kuznetsov <[email protected]>--- target/i386/kvm/kvm.c | 2 ++ 1 file changed, 2 insertions(+)
Quoted 11 lines · Vitaly Kuznetsov
Commit
bbf3810f2c4f("target/i386: Fix conditionalCONFIG_SYNDBGenablement") broke !CONFIG_SYNDBG builds ashyperv_syndbg_query_options()is missing there. The idea probably was that as "hv-syndbg" is now under '#ifdefCONFIG_SYNDBG',hyperv_feat_enabled(cpu, HYPERV_FEAT_SYNDBG)cannot be true anyway.It would have been possible to add a stub for
hyperv_syndbg_query_options()instead of resurrecting '#ifdefCONFIG_SYNDBG' but avoidingHV_X64_MSR_SYNDBG_OPTIONSaltogether instead of zeroing it when !CONFIG_SYNDBG seems preferable.
Quoted 6 lines
Reported-by Michael Tokarev <[email protected]>Fixes bbf3810f2c4f ("target/i386: Fix conditional CONFIG_SYNDBG enablement")Signed-off-by Vitaly Kuznetsov <[email protected]>--- target/i386/kvm/kvm.c | 2 ++ 1 file changed, 2 insertions(+)
Patch queued to hw-misc, thanks.
Quoted 12 lines · Philippe Mathieu-Daudé
Quoted 11 lines · Vitaly Kuznetsov
Commit
bbf3810f2c4f("target/i386: Fix conditionalCONFIG_SYNDBGenablement") broke !CONFIG_SYNDBG builds ashyperv_syndbg_query_options()is missing there. The idea probably was that as "hv-syndbg" is now under '#ifdefCONFIG_SYNDBG',hyperv_feat_enabled(cpu, HYPERV_FEAT_SYNDBG)cannot be true anyway.It would have been possible to add a stub for
hyperv_syndbg_query_options()instead of resurrecting '#ifdefCONFIG_SYNDBG' but avoidingHV_X64_MSR_SYNDBG_OPTIONSaltogether instead of zeroing it when !CONFIG_SYNDBG seems preferable.
Quoted 8 lines
Quoted 6 lines
Reported-by Michael Tokarev <[email protected]>Fixes bbf3810f2c4f ("target/i386: Fix conditional CONFIG_SYNDBG enablement")Signed-off-by Vitaly Kuznetsov <[email protected]>---
target/i386/kvm/kvm.c| 2 ++1 file changed, 2 insertions(+)Patch queued to hw-misc, thanks.
Please note once again there's another fix from pbonzini for this.
/mjt
Quoted 20 lines · Michael Tokarev
Quoted 19 lines · Philippe Mathieu-Daudé
Quoted 17 lines · Vitaly Kuznetsov
Commit
bbf3810f2c4f("target/i386: Fix conditionalCONFIG_SYNDBGenablement") broke !CONFIG_SYNDBG builds ashyperv_syndbg_query_options()is missing there. The idea probably was that as "hv-syndbg" is now under '#ifdefCONFIG_SYNDBG',hyperv_feat_enabled(cpu, HYPERV_FEAT_SYNDBG)cannot be true anyway.It would have been possible to add a stub for
hyperv_syndbg_query_options()instead of resurrecting '#ifdefCONFIG_SYNDBG' but avoidingHV_X64_MSR_SYNDBG_OPTIONSaltogether instead of zeroing it when !CONFIG_SYNDBG seems preferable.Reported-by Michael Tokarev <[email protected]>Fixes bbf3810f2c4f ("target/i386: Fix conditional CONFIG_SYNDBG enablement")Signed-off-by Vitaly Kuznetsov <[email protected]>---
target/i386/kvm/kvm.c| 2 ++1 file changed, 2 insertions(+)
Quoted 3 lines
Quoted 1 line
Patch queued to hw-misc, thanks.
Please note once again there's another fix from pbonzini for this.
OK, dropped.
Quoted 20 lines · Michael Tokarev
Quoted 19 lines · Philippe Mathieu-Daudé
Quoted 17 lines · Vitaly Kuznetsov
Commit
bbf3810f2c4f("target/i386: Fix conditionalCONFIG_SYNDBGenablement") broke !CONFIG_SYNDBG builds ashyperv_syndbg_query_options()is missing there. The idea probably was that as "hv-syndbg" is now under '#ifdefCONFIG_SYNDBG',hyperv_feat_enabled(cpu, HYPERV_FEAT_SYNDBG)cannot be true anyway.It would have been possible to add a stub for
hyperv_syndbg_query_options()instead of resurrecting '#ifdefCONFIG_SYNDBG' but avoidingHV_X64_MSR_SYNDBG_OPTIONSaltogether instead of zeroing it when !CONFIG_SYNDBG seems preferable.Reported-by Michael Tokarev <[email protected]>Fixes bbf3810f2c4f ("target/i386: Fix conditional CONFIG_SYNDBG enablement")Signed-off-by Vitaly Kuznetsov <[email protected]>---
target/i386/kvm/kvm.c| 2 ++1 file changed, 2 insertions(+)
Quoted 3 lines
Quoted 1 line
Patch queued to hw-misc, thanks.
Please note once again there's another fix from pbonzini for this.
I'll send a pull request for this soon; Philippe, can you drop this one? (I'll drop the hda fix from my tree instead)
Thanks,
Paolo