From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:48530) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XWafA-0003Gp-NW for qemu-devel@nongnu.org; Tue, 23 Sep 2014 20:42:37 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XWaf5-0007VJ-Op for qemu-devel@nongnu.org; Tue, 23 Sep 2014 20:42:32 -0400 Received: from szxga03-in.huawei.com ([119.145.14.66]:25266) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XWaf5-0007QS-59 for qemu-devel@nongnu.org; Tue, 23 Sep 2014 20:42:27 -0400 From: "Gonglei (Arei)" Date: Wed, 24 Sep 2014 00:42:01 +0000 Message-ID: <33183CC9F5247A488A2544077AF1902086DDA283@SZXEMA503-MBS.china.huawei.com> References: <1411477717-6988-1-git-send-email-arei.gonglei@huawei.com> <1411477717-6988-6-git-send-email-arei.gonglei@huawei.com> <5421A7D7.7050804@redhat.com> In-Reply-To: <5421A7D7.7050804@redhat.com> Content-Language: zh-CN Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Subject: Re: [Qemu-devel] [PATCH 5/7] qdev: set the object property's description to the qdev property's. List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Paolo Bonzini , "qemu-devel@nongnu.org" Cc: "Huangweidong (C)" , "stefanha@redhat.com" , "mst@redhat.com" , Luonengjun , "Huangpeng (Peter)" , "armbru@redhat.com" , "aliguori@amazon.com" , "lcapitulino@redhat.com" , "afaerber@suse.de" > Subject: Re: [PATCH 5/7] qdev: set the object property's description to t= he qdev > property's. >=20 > Il 23/09/2014 15:08, arei.gonglei@huawei.com ha scritto: > > From: Gonglei > > > > When we call qdev_alias_all_properties() adding alias properties to > > the source object all qdev properties on the target DeviceState, > > set the object property's description to the qdev property's. > > > > c: Paolo Bonzini > > Cc: Michael S. Tsirkin > > Cc: Markus Armbruster > > Signed-off-by: Gonglei > > --- > > hw/core/qdev.c | 3 +++ > > 1 file changed, 3 insertions(+) > > > > diff --git a/hw/core/qdev.c b/hw/core/qdev.c > > index fcb1638..61d352c 100644 > > --- a/hw/core/qdev.c > > +++ b/hw/core/qdev.c > > @@ -796,6 +796,9 @@ void qdev_alias_all_properties(DeviceState *target, > Object *source) > > object_property_add_alias(source, prop->name, > > OBJECT(target), > prop->name, > > &error_abort); > > + object_property_set_description(source, prop->name, > > + > prop->info->description, > > + &error_abort); >=20 > Please do this directly in object_property_add_alias. >=20 OK.=20 This way I have to add a description string parametet to object_property_add_alias function. Will do in the next version. :) Best regards, -Gonglei > Paolo >=20 > > } > > class =3D object_class_get_parent(class); > > } while (class !=3D object_class_by_name(TYPE_DEVICE)); > >