Received: from eggs.gnu.org ([2001:4830:134:3::10]:44095) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VfmBE-0003F1-Eo for qemu-devel@nongnu.org; Mon, 11 Nov 2013 02:45:13 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VfmB5-0005Wn-0E for qemu-devel@nongnu.org; Mon, 11 Nov 2013 02:45:04 -0500 Received: from e23smtp02.au.ibm.com ([202.81.31.144]:38183) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VfmB4-0005UO-9j for qemu-devel@nongnu.org; Mon, 11 Nov 2013 02:44:54 -0500 Received: from /spool/local by e23smtp02.au.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Mon, 11 Nov 2013 17:44:47 +1000 From: Alexey Kardashevskiy Date: Mon, 11 Nov 2013 18:44:29 +1100 Message-Id: <1384155875-26999-1-git-send-email-aik@ozlabs.ru> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Subject: [Qemu-devel] [PATCH v3 0/6] spapr: add "compat" machine option List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Alexey Kardashevskiy , qemu-ppc@nongnu.org, Alexander Graf , =?UTF-8?q?Andreas=20F=C3=A4rber?= The further I go, more questions I get. Here are 6 patches. The first three is what I would like to have in QEMU to support "compat" option for a CPU. The option now accepts "power6"/"power7" as after all we will limit number of threads per core (not in this series though) and since 2.05 does not limit number of threads at all, referring to actual CPU models seems right. The last three is what I would suggest doing if we needed ability to enable/disable CPU features the way x86 does this. I used "VSX" as an example but this is just an example so "-cpu host,-vsx,+vsx,vsx=on" works. Using this, I suspect I could try converting x86's parser for "-cpu", would it work? btw I am sure there must be macro like BITNR (convert mask with 1 bit set to a number of the bit which is set) but I failed to find it. What did I miss? Please, comment. Thanks. Alexey Kardashevskiy (6): cpu: add suboptions support target-ppc: make use of new -cpu suboptions handling target-ppc: add "compat" CPU option qemu-option: support +foo/-foo command line agruments bitops: add BITNR macro target-ppc: demonstrate new "vsx" property hw/ppc/spapr.c | 13 +++++++- include/qemu/bitops.h | 12 ++++++++ include/qom/cpu.h | 29 ++++++++++++++++++ include/sysemu/sysemu.h | 1 + qom/cpu.c | 27 +++++++++++++++++ target-ppc/cpu-models.h | 10 +++++++ target-ppc/cpu.h | 4 +++ target-ppc/translate_init.c | 73 +++++++++++++++++++++++++++++++++++++++++++++ util/qemu-option.c | 6 ++++ vl.c | 42 ++++++++++++++++++++++++++ 10 files changed, 216 insertions(+), 1 deletion(-) -- 1.8.4.rc4