From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:37346) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XUbIf-000546-Pq for qemu-devel@nongnu.org; Thu, 18 Sep 2014 08:59:10 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XUbIa-0000dU-Su for qemu-devel@nongnu.org; Thu, 18 Sep 2014 08:59:05 -0400 Received: from mx1.redhat.com ([209.132.183.28]:32958) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XUbIa-0000VC-Fy for qemu-devel@nongnu.org; Thu, 18 Sep 2014 08:59:00 -0400 Message-ID: <541AD702.4030003@redhat.com> Date: Thu, 18 Sep 2014 14:58:42 +0200 From: Paolo Bonzini MIME-Version: 1.0 References: <1411044447-3124-1-git-send-email-arei.gonglei@huawei.com> In-Reply-To: <1411044447-3124-1-git-send-email-arei.gonglei@huawei.com> Content-Type: text/plain; charset=iso-8859-15 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH v2 00/19] usb: convert device init to realize List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: arei.gonglei@huawei.com, qemu-devel@nongnu.org Cc: luonengjun@huawei.com, peter.huangpeng@huawei.com, weidong.huang@huawei.com, kraxel@redhat.com, armbru@redhat.com Il 18/09/2014 14:47, arei.gonglei@huawei.com ha scritto: > From: Gonglei > > DeviceClass->init is the old interface, let's convert usb > devices to the new realize API. In this way, all the > implementations now use error_setg instead of > qerror_report/error_report for reporting error. > > Cc: Markus Armbruster > Cc: Paolo Bonzini > Cc: Gerd Hoffmann > > v2 -> v1: > - fix PATCH 2, using qerror_report_err print error messages > when attach fails (Paolo) > - using errp instead of qerror_report_err introduced by > fix 1 in PATCH 12 (Paolo) > - fix missing return in PATCH 14 (Paolo) > - add 'Reviewed-by' tag for other patches > > Thanks a lot for reviewing! > > > Gonglei (19): > usb-storage: fix possible memory leak and missing error message > usb-bus: convert USBDeviceClass init to realize > usb-net: convert init to realize > libusb: convert init to realize > libusb: using error_report instead of fprintf > usb-hub: convert init to realize > dev-storage: convert init to realize > dev-storage: usring error_report instead of fprintf/printf > dev-uas: convert init to realize > dev-uas: using error_report instead of fprintf > dev-bluetooth: convert init to realize > dev-serial: convert init to realize > usb-ccid: convert init to realize > dev-hid: convert init to realize > dev-wacom: convert init to realize > usb-audio: convert init to realize > usb-redir: convert init to realize > usb-mtp: convert init to realize > usb-bus: remove "init" from USBDeviceClass struct > > hw/usb/bus.c | 79 ++++++++++++++++++++++--------------------- > hw/usb/dev-audio.c | 5 ++- > hw/usb/dev-bluetooth.c | 6 ++-- > hw/usb/dev-hid.c | 27 +++++++-------- > hw/usb/dev-hub.c | 9 +++-- > hw/usb/dev-mtp.c | 5 ++- > hw/usb/dev-network.c | 9 +++-- > hw/usb/dev-serial.c | 22 +++++++----- > hw/usb/dev-smartcard-reader.c | 5 ++- > hw/usb/dev-storage.c | 42 ++++++++++++----------- > hw/usb/dev-uas.c | 17 +++++----- > hw/usb/dev-wacom.c | 5 ++- > hw/usb/host-libusb.c | 33 +++++++++--------- > hw/usb/redirect.c | 21 +++++++----- > include/hw/usb.h | 10 ++++-- > 15 files changed, 150 insertions(+), 145 deletions(-) > Looks good, thanks! Paolo