From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:46445) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZMA1k-0005YO-TF for qemu-devel@nongnu.org; Mon, 03 Aug 2015 03:19:17 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZMA1h-0000QI-MC for qemu-devel@nongnu.org; Mon, 03 Aug 2015 03:19:16 -0400 Received: from mailout1.w1.samsung.com ([210.118.77.11]:54335) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZMA1h-0000Q1-Gn for qemu-devel@nongnu.org; Mon, 03 Aug 2015 03:19:13 -0400 Received: from eucpsbgm1.samsung.com (unknown [203.254.199.244]) by mailout1.w1.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTP id <0NSH00I5IWBY2I00@mailout1.w1.samsung.com> for qemu-devel@nongnu.org; Mon, 03 Aug 2015 08:19:10 +0100 (BST) From: Pavel Fedin References: In-reply-to: Date: Mon, 03 Aug 2015 10:19:09 +0300 Message-id: <00bd01d0cdbc$b0f97ab0$12ec7010$@samsung.com> MIME-version: 1.0 Content-type: text/plain; charset=utf-8 Content-transfer-encoding: quoted-printable Content-language: ru Subject: Re: [Qemu-devel] [PATCH v7 6/6] Add gicversion option to virt machine List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: 'Peter Maydell' Cc: 'Shlomo Pongratz' , 'Shlomo Pongratz' , 'QEMU Developers' , 'Christoffer Dall' , 'Eric Auger' Hello! > > gicdev =3D qdev_create(NULL, gictype); > > - qdev_prop_set_uint32(gicdev, "revision", 2); > > + > > + for (i =3D 0; i < vbi->smp_cpus; i++) { > > + CPUState *cpu =3D qemu_get_cpu(i); > > + CPUARMState *env =3D cpu->env_ptr; > > + env->nvic =3D gicdev; > > + } >=20 > We definitely need to come up with a something cleaner > than this (which is ugly for two reasons This could be done: a) as property b) as global variable because 'gicdev' is a single of its kind. But, actually, this is currently only for TCG, which needs it in order = to forward system register accesses to GICv3 code. Would it be OK if i = just omit this assignment ? Kind regards, Pavel Fedin Expert Engineer Samsung Electronics Research center Russia