From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:34056) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TORom-0005b1-Ev for qemu-devel@nongnu.org; Wed, 17 Oct 2012 07:29:48 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TORok-0005RO-Rm for qemu-devel@nongnu.org; Wed, 17 Oct 2012 07:29:44 -0400 Received: from mx1.redhat.com ([209.132.183.28]:56010) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TORok-0005QN-J8 for qemu-devel@nongnu.org; Wed, 17 Oct 2012 07:29:42 -0400 Received: from int-mx12.intmail.prod.int.phx2.redhat.com (int-mx12.intmail.prod.int.phx2.redhat.com [10.5.11.25]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id q9HBTfs7014352 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Wed, 17 Oct 2012 07:29:41 -0400 Message-ID: <507E96A3.6020101@redhat.com> Date: Wed, 17 Oct 2012 13:29:39 +0200 From: Gerd Hoffmann MIME-Version: 1.0 References: <1350297511-25437-1-git-send-email-hdegoede@redhat.com> <1350297511-25437-15-git-send-email-hdegoede@redhat.com> In-Reply-To: <1350297511-25437-15-git-send-email-hdegoede@redhat.com> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH 14/22] usb: Add packet combining functions List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Hans de Goede Cc: qemu-devel@nongnu.org Hi, > + /* > + * Process / cancel combined packets, called from > + * usb_ep_combine_input_packets() / usb_combined_packet_cancel(). > + * Only called for devices which call these functions themselves. > + */ > + int (*handle_combined_data)(USBDevice *dev, USBPacket *p); > + void (*cancel_combined_packet)(USBDevice *dev, USBPacket *p); Do we really need these? I think it isn't much work for the callers to do that themself. Saves them providing a callback. And makes the code flow easier to follow by removing a pointless indirection. For handle_combined_data we probably must make usb_ep_combine_input_packets return a status code. cheers, Gerd