Received: from eggs.gnu.org ([2001:4830:134:3::10]:39686) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VFPIQ-0002J6-Vr for qemu-devel@nongnu.org; Fri, 30 Aug 2013 10:03:38 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VFPIJ-0000L6-M9 for qemu-devel@nongnu.org; Fri, 30 Aug 2013 10:03:30 -0400 Mime-Version: 1.0 (Apple Message framework v1278) Content-Type: text/plain; charset=iso-8859-1 From: Alexander Graf In-Reply-To: <5220A510.1040807@suse.de> Date: Fri, 30 Aug 2013 16:03:19 +0200 Content-Transfer-Encoding: quoted-printable Message-Id: <8A89FC73-FDFD-45BF-BB65-182DA68B26E1@suse.de> References: <1376606111-3518-1-git-send-email-afaerber@suse.de> <1376606111-3518-3-git-send-email-afaerber@suse.de> <52209D6D.4020307@suse.de> <5220A3BC.4070000@ozlabs.ru> <5220A510.1040807@suse.de> Subject: Re: [Qemu-devel] [PATCH v2 2/4] spapr: Use DeviceClass::fw_name for device tree CPU node List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: =?iso-8859-1?Q?Andreas_F=E4rber?= Cc: Alexey Kardashevskiy , qemu-ppc , qemu-devel@nongnu.org, Prerna Saxena On 30.08.2013, at 15:58, Andreas F=E4rber wrote: > Am 30.08.2013 15:53, schrieb Alexey Kardashevskiy: >> On 08/30/2013 11:26 PM, Andreas F=E4rber wrote: >>> Am 30.08.2013 15:21, schrieb Alexander Graf: >>>>=20 >>>> On 16.08.2013, at 00:35, Andreas F=E4rber wrote: >>>>=20 >>>>> Instead of relying on cpu_model, obtain the device tree node label >>>>> per CPU. Use DeviceClass::fw_name when available. This implicitly >>>>> resolves HOST@0 node labels for those CPUs through inheritance. >>>>>=20 >>>>> Whenever DeviceClass::fw_name is not available, derive it from the = CPU's >>>>> type name and fill it in for that class with a "PowerPC," prefix = for >>>>> PAPR compliance. >>>>=20 >>>> Could we just mandate the fw_name field to always be set for all = classes instead? >>>=20 >>> Sure, we can assert it. But we would then need to set fw_name for = the >>> various 970 families at least, which I have been using with pseries = in >>> the past. Cell and POWER6 are TODO so I'm not concerned about them. = Not >>> sure about RS64 that Alexey mentioned - I wouldn't be able to test. >>> Would be bad to regress and abort with CPU models that were working = okay >>> before. >>=20 >> If we generated fw_name as it would have been done by the current = helpers, >> how would anything regress? >=20 > Well, before, you were talking about assigning "reasonable fw_name > values", and that would for me require knowledge of which value is > reasonable (i.e., correct) for a certain CPU, and I don't have boards = to > check most of them. >=20 > My proposal would be to just do it for the sPAPR-compatible (not sure = if > that is what you meant with "supported"?) CPUs (because that's where = we > intend to use it) and mark the ones we don't know exactly with /* ??? = */ > as done elsewhere in ppc code. Yup, we could even specifically just name them fw_name =3D = "PowerPC,UNKNOWN"; whenever we don't know better as you were suggesting = earlier. Alex