On Tue, Apr 29, 2025 at 05:41:43PM +0200, Jiří Denemark wrote: > On Tue, Apr 29, 2025 at 13:03:12 +0100, Daniel P. Berrangé wrote: > > On Tue, Apr 29, 2025 at 01:42:22PM +0200, Peter Krempa wrote: > > > On Tue, Apr 29, 2025 at 12:36:40 +0100, Daniel P. Berrangé wrote: > > > > On Tue, Apr 15, 2025 at 04:13:08AM -0400, Narayana Murty N wrote: > > > > > <model usable='unknown' vendor='IBM'>POWER7</model> > > > > > <model usable='unknown' vendor='IBM'>POWER8</model> > > > > > <model usable='unknown' vendor='IBM'>POWER9</model> > > > > > + <model usable='unknown' vendor='IBM'>power11</model> > > > > > > > > QEMU allows both upper & lowercase for CPU names, and libvirt > > > > has stuck with uppercase historically. > > > > > > > > What's the justification for changing this approach for > > > > power11 ? > > > > > > qemu itself reports the model lowercase now. In v2 of this series I've > > > pointed that out because defining this caused test data to change which > > > was suspiciuous. > > > > By 'reports the model lowercase' i presume you're referring to '-cpu help' > > and/or 'query-cpu-definitions' ? That doesn't seem to be a new change > > either though. I've not gone far back, but qemu 8.2.0 seems to already > > be using lowercase. > > > > So I'm still wondering why we're changing our decision about CPU naming > > /now/ with power11 ? The commit message needs to explain and justify > > this change. > > Well, when I replied to the original patch, my memory was telling me > QEMU switched to lower case names and had to add compatibility code to > translate our existing upper case names. And adding a new CPU model > looked like a good excuse to stop doing that (for new models of course) > and just define the model in lower case. Now that you're questioning > this I tried to find evidence and I could not find it :-( So there are > two options... either I'm bad at searching or I my memory confused this > with dropping version suffixes (_vX.Y) in virCPUppc64ConvertLegacy. Or > both options are true at the same time :-) > > Maybe Andrea can remember more, I think he was involved in all this ages > ago.
It seems that CPU models have been reported in lower case at least going all the way back to QEMU 3.0.0 from 2018: https://gitlab.com/libvirt/libvirt/-/blob/c7e09b7b5fe7f64f12318d150b281343c6d64fd5/tests/qemucapabilitiesdata/caps_3.0.0.ppc64.replies It would probably make sense for libvirt to align with this decision, and accept/generate lower case CPU model names. Of course upper case CPU models would still need to be accepted for backwards compatibility reasons. Note that I'm suggesting we adopt this approach consistently for all CPU models, including existing ones. So power8 should be accepted, as should be POWER11. CC'ing Daniel and David, both of which have worked on ppc64 in the past and might be able to offer additional insights / historical context. -- Andrea Bolognani / Red Hat / Virtualization