From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:46944) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VHb53-0007JU-HI for qemu-devel@nongnu.org; Thu, 05 Sep 2013 11:02:51 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VHb4x-0008He-GQ for qemu-devel@nongnu.org; Thu, 05 Sep 2013 11:02:45 -0400 Message-ID: <52289D0B.8080906@suse.de> Date: Thu, 05 Sep 2013 17:02:35 +0200 From: =?ISO-8859-15?Q?Andreas_F=E4rber?= MIME-Version: 1.0 References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-15 Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] [PATCH] target-arm: Implement qmp query-cpu-definitions List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Cole Robinson Cc: Peter Maydell , qemu-ppc , qemu-devel@nongnu.org, Alexander Graf Hi, Am 04.09.2013 17:23, schrieb Cole Robinson: > Libvirt uses this to introspect available CPU models. >=20 > Signed-off-by: Cole Robinson > --- > Maybe this will be centrally handled after the QOM CPU work is done? No, this API is about a pre-QOM command line switch, whose implementation is target-specific. What got standardized for multiple targets was the CPUClass::class_by_name() hook for the opposite direction of -cpu to ObjectClass lookup (with the goal of obsoleting cpu_init()). It is not wrong to implement query-cpus for arm, but -cpu is considered deprecated. And personally especially for arm I would rather welcome someone contributing a proper, e.g., Raspberry Pi board (with clean separation of what is on the SoC and what on the board to avoid duplication among boards) than tweaking some other unrelated board with -cpu and then complaining that it doesn't work as expected. ;) For machines that use soft-core CPUs (FPGAs) or for mach-virt as non-physical machine it does make sense, but query-cpus gives us a list irrespective of whether they are compatible with the board. Same for ppc btw - plugging, e.g., a 440 CPU into pseries or mac99 won't work. Short-term my view is to use fixed CPU types, ignoring -cpu, where the CPU cannot be exchanged (e.g., DIGIC patch series) and a suitable link<> type otherwise. The long-term goal is to have machines be config files (thereby user-creatable) assembling QOM objects by specifying memory mapping and IRQ routing. The latter two parts don't work with the old qdev and SysBusDevice APIs. That said, patch itself looks correct, Reviewed-by: Andreas F=E4rber Regards, Andreas --=20 SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 N=FCrnberg, Germany GF: Jeff Hawn, Jennifer Guild, Felix Imend=F6rffer; HRB 16746 AG N=FCrnbe= rg