Received: from eggs.gnu.org ([2001:4830:134:3::10]:44893) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YgbBx-00048M-DQ for qemu-devel@nongnu.org; Fri, 10 Apr 2015 11:50:02 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YgbBu-0007Jh-Lb for qemu-devel@nongnu.org; Fri, 10 Apr 2015 11:50:01 -0400 Received: from mx1.redhat.com ([209.132.183.28]:56105) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YgbBu-0007JH-Gd for qemu-devel@nongnu.org; Fri, 10 Apr 2015 11:49:58 -0400 Date: Fri, 10 Apr 2015 12:49:55 -0300 From: Eduardo Habkost Message-ID: <20150410154955.GY7031@thinpad.lan.raisama.net> References: <1428519763-21644-1-git-send-email-ehabkost@redhat.com> <1428519763-21644-4-git-send-email-ehabkost@redhat.com> <20150409184830.GB18590@thinpad.lan.raisama.net> <20150410092751.3573d267@igors-macbook-pro.local> <5527881D.6040300@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <5527881D.6040300@redhat.com> Subject: Re: [Qemu-devel] [PATCH v2 3/4] target-i386: Register QOM properties for feature flags List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Paolo Bonzini Cc: Igor Mammedov , Jiri Denemark , qemu-devel@nongnu.org, Andreas =?iso-8859-1?Q?F=E4rber?= On Fri, Apr 10, 2015 at 10:21:49AM +0200, Paolo Bonzini wrote: > > > On 10/04/2015 09:27, Igor Mammedov wrote: > > > + for (i = 0; names[i]; i++) { > > > + char *feat_name = names[i]; > > > + feat2prop(feat_name); > > > + char *prop_name = g_strdup_printf("cpuid-%s", feat_name); > > > > BTW: I've remembered why we've chosen feat- vs. cpuid- prefix > > it was to make CPU features platform neutral so that libvirt > > would use the same prefix for x86, arm other targets. > > Ok, that make sense, but if we want to make it platform-neutral, let's > spell it "feature-" or remove the prefix altogether. I am liking the idea of removing the prefix. I can't find a compelling reason for making boolean properties that affect CPUID special and different from other boolean properties in X86CPU. > > If we remove it, perhaps we could add a QOM property with the list of > features? I am not even sure this will be necessary. libvirt, for example, is already aware of the list of CPU feature flags it can set/unset, so it probably wouldn't need the list. If it becomes necessary, we can add it. I will send v4 without the prefix. -- Eduardo