From mboxrd@z Thu Jan 1 00:00:00 1970 Received: by 2002:a17:505:110e:b0:1be9:327d:8ee3 with SMTP id pu14csp2585715njb; Mon, 12 May 2025 02:07:30 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCXkBppAryuaMQPivmxuzYAVUgh7GBMAFJB+hraNyxZFjKu8XHOB1OjvbFeLAh6xMYJOFQ1VV/+GhrXy5Q==@linaro.org X-Google-Smtp-Source: AGHT+IH7ls0sYyrU+yfiaPfCubI6CF1MHRDz+FHj/AOZ3OS1+zbEC1QPWargms6U0TNl+i+LW6hf X-Received: by 2002:a05:622a:1c0d:b0:494:781b:e14 with SMTP id d75a77b69052e-494781b2badmr28556291cf.24.1747040850215; Mon, 12 May 2025 02:07:30 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1747040850; cv=pass; d=google.com; s=arc-20240605; b=SA/JPMpXq7GVr1cTADDg1NSAveyxHGNYEvwwCyAV5A9GHHfXfLKzoNVDiGM8RvGhx1 1SNOPgNilEim+iAQpducOjrllT/txWnJue3K/1FB6BPkgFoHjtMeogROTsb1bifmbIuG BW6FsbbW3KHWWBIYwearKpvReIaFUOb8tzRUg/ZaFZIzhSeLoVXhuQef7mNfkNDe9ZAx gYEo8eNyJgnopvoRfVtiPVIruxDGLrj3cwRsXJkoBAlVHmhCCgSze3bOqR73qGwDe0gP /UMgpxWThYwSsDMBcfhH8daglUPnXPlX3kfmrt3jhzwGz7vTUsu49uqUkBKbEwoWX8OP Rt9A== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=user-agent:in-reply-to:content-disposition:mime-version :list-unsubscribe:list-subscribe:list-id:precedence:references :reply-to:message-id:subject:cc:to:from:date:dkim-signature; bh=5odr4a2Xq+180JEfvS0fVAKnaUgen9zbM0bNb4Nha9w=; fh=aRowwS2WOsbUoH+f3JbrE04vG+4t9UnANYb75BhyhHM=; b=PgrhQjFwSyGbvqbce8kSK3GiDzBitWxMPEjmC+QVSv2vJ7GKA+1SLd+lotszYq4Wgp 7fz+T5iyj1QEvxpu+boK9XBtNCPnJY92jPq5fCTYDzMJBK+WrL1GLj+cMYmYk4BNKYth CHwV0vL5vZoxorg2Dha12UEXbHZtXFbXVZSc5CEeXZtJe8eVo5vQgiIdrZna/HzZf7AP /6VCrpHo7cD03Q7IdWpwNKhENu/z5P24lLshU/s3XaGwxlgQ63zdi7iyeKSlRvWjSL7M IesBJ/MFDxHu5XgDisDU5D78B58tenocrhWrWlzud8Dl8Xv+vJi/6tea3eIyrYzQaerS cL1A==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=CTnU96ja; arc=pass (i=1 spf=pass spfdomain=redhat.com dkim=pass dkdomain=redhat.com dmarc=pass fromdomain=redhat.com); spf=pass (google.com: domain of kvm+bounces-46154-alex.bennee=linaro.org@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="kvm+bounces-46154-alex.bennee=linaro.org@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=redhat.com Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id d75a77b69052e-49452458b13si85852051cf.112.2025.05.12.02.07.30 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 12 May 2025 02:07:30 -0700 (PDT) Received-SPF: pass (google.com: domain of kvm+bounces-46154-alex.bennee=linaro.org@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=CTnU96ja; arc=pass (i=1 spf=pass spfdomain=redhat.com dkim=pass dkdomain=redhat.com dmarc=pass fromdomain=redhat.com); spf=pass (google.com: domain of kvm+bounces-46154-alex.bennee=linaro.org@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="kvm+bounces-46154-alex.bennee=linaro.org@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=redhat.com Received: from smtp.subspace.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-ECDSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 4C64017AB50 for ; Mon, 12 May 2025 09:07:31 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id A6800255E2A; Mon, 12 May 2025 09:07:26 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b="CTnU96ja" Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id A1C6617BB6 for ; Mon, 12 May 2025 09:07:24 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=170.10.133.124 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1747040846; cv=none; b=IbayBcwWLIcVTG9SwiJCbPp1fKx5qSELl8FtUf6EgNkvYXEboenSC8Kif7uSjsWKNNP1BMfbCbPO8e+VK4Mbfy1n37EyDSwJfETEhgRDxURjxqAo1SIxCtzNsTvrfsY+mdZLbV2YpGYVRye/lIZbjx4JY1OYIlvXSeRKgMOxTck= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1747040846; c=relaxed/simple; bh=TOcAHwmbXWBt8hhO/LpUSu7leJ3168e2PtCljpq4C6Q=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=UkEaT74Ba+wig7Dqu2n8gyT7zhzIvfqqUXfldNCO6kfpT6a0zbbTr3Gn+nKm/O21E3ylCZRGcDpIhNpyX3HmQf5CEnnNUzW0hhyYBClWOkvYrGVDnCz4HtNqhO59gVvaWZJ6X42XDYWpLEW2d6WZm/ouCOmoLHbxDKHxIBwQNbU= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=redhat.com; spf=pass smtp.mailfrom=redhat.com; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b=CTnU96ja; arc=none smtp.client-ip=170.10.133.124 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=redhat.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=redhat.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1747040843; h=from:from:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:in-reply-to:in-reply-to: references:references; bh=5odr4a2Xq+180JEfvS0fVAKnaUgen9zbM0bNb4Nha9w=; b=CTnU96jamCzbWxO8SyuyxiWYFDUfs8KzUPw86tSwpptp44zaj+4drC3SlwsZ2xtwAceRN1 zXnezDxrEbuw9pDMqgF7vyf7OVN9IJDDX74QlpAsvW8Hdj7pDwtMU+44JkAJuhvay+L5Sc 0AJhqdqWLLv86mZh2GFQWLy6dX/YNug= Received: from mx-prod-mc-04.mail-002.prod.us-west-2.aws.redhat.com (ec2-54-186-198-63.us-west-2.compute.amazonaws.com [54.186.198.63]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-56-W3OS7mmcMvm-XVakSNQqgA-1; Mon, 12 May 2025 05:07:19 -0400 X-MC-Unique: W3OS7mmcMvm-XVakSNQqgA-1 X-Mimecast-MFC-AGG-ID: W3OS7mmcMvm-XVakSNQqgA_1747040836 Received: from mx-prod-int-04.mail-002.prod.us-west-2.aws.redhat.com (mx-prod-int-04.mail-002.prod.us-west-2.aws.redhat.com [10.30.177.40]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mx-prod-mc-04.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id C99FC1955DEA; Mon, 12 May 2025 09:07:15 +0000 (UTC) Received: from redhat.com (unknown [10.42.28.162]) by mx-prod-int-04.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id D175119560A3; Mon, 12 May 2025 09:07:01 +0000 (UTC) Date: Mon, 12 May 2025 10:06:58 +0100 From: Daniel =?utf-8?B?UC4gQmVycmFuZ8Op?= To: Peter Maydell Cc: Thomas Huth , Zhao Liu , Xiaoyao Li , Philippe =?utf-8?Q?Mathieu-Daud=C3=A9?= , Markus Armbruster , Paolo Bonzini , qemu-devel@nongnu.org, Richard Henderson , kvm@vger.kernel.org, Gerd Hoffmann , Laurent Vivier , Jiaxun Yang , Yi Liu , "Michael S. Tsirkin" , Eduardo Habkost , Marcel Apfelbaum , Alistair Francis , Daniel Henrique Barboza , Marcelo Tosatti , qemu-riscv@nongnu.org, Weiwei Li , Amit Shah , Yanan Wang , Helge Deller , Palmer Dabbelt , Ani Sinha , Igor Mammedov , Fabiano Rosas , Liu Zhiwei , =?utf-8?Q?Cl=C3=A9ment?= Mathieu--Drif , qemu-arm@nongnu.org, =?utf-8?Q?Marc-Andr=C3=A9?= Lureau , Huacai Chen , Jason Wang Subject: Re: How to mark internal properties (was: Re: [PATCH v4 12/27] target/i386/cpu: Remove CPUX86State::enable_cpuid_0xb field) Message-ID: Reply-To: Daniel =?utf-8?B?UC4gQmVycmFuZ8Op?= References: <20250508133550.81391-1-philmd@linaro.org> <20250508133550.81391-13-philmd@linaro.org> <23260c74-01ba-45bc-bf2f-b3e19c28ec8a@intel.com> <2f526570-7ab0-479c-967c-b3f95f9f19e3@redhat.com> Precedence: bulk X-Mailing-List: kvm@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/2.2.14 (2025-02-20) X-Scanned-By: MIMEDefang 3.0 on 10.30.177.40 X-TUID: l5N6jyd8L1OO On Mon, May 12, 2025 at 09:46:30AM +0100, Peter Maydell wrote: > On Fri, 9 May 2025 at 11:04, Thomas Huth wrote: > > Thanks for your clarifications, Zhao! But I think this shows again the > > problem that we have hit a couple of times in the past already: Properties > > are currently used for both, config knobs for the users and internal > > switches for configuration of the machine. We lack a proper way to say "this > > property is usable for the user" and "this property is meant for internal > > configuration only". > > > > I wonder whether we could maybe come up with a naming scheme to better > > distinguish the two sets, e.g. by using a prefix similar to the "x-" prefix > > for experimental properties? We could e.g. say that all properties starting > > with a "q-" are meant for QEMU-internal configuration only or something > > similar (and maybe even hide those from the default help output when running > > "-device xyz,help" ?)? Anybody any opinions or better ideas on this? > > I think a q-prefix is potentially a bit clunky unless we also have > infrastructure to say eg DEFINE_INTERNAL_PROP_BOOL("foo", ...) > and have it auto-add the prefix, and to have the C APIs for > setting properties search for both "foo" and "q-foo" so you > don't have to write qdev_prop_set_bit(dev, "q-foo", ...). I think it is also not obvious enough that a 'q-' prefix means private. Perhaps borrow from the C world and declare that a leading underscore indicates a private property. People are more likely to understand and remember that, than 'q-'. With regards, Daniel -- |: https://berrange.com -o- https://www.flickr.com/photos/dberrange :| |: https://libvirt.org -o- https://fstop138.berrange.com :| |: https://entangle-photo.org -o- https://www.instagram.com/dberrange :|