From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from [140.186.70.92] (port=51849 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PLu1M-00044M-26 for qemu-devel@nongnu.org; Fri, 26 Nov 2010 03:52:05 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PLu0P-0005NE-4q for qemu-devel@nongnu.org; Fri, 26 Nov 2010 03:51:06 -0500 Received: from mx1.redhat.com ([209.132.183.28]:63002) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PLu0O-0005N1-T8 for qemu-devel@nongnu.org; Fri, 26 Nov 2010 03:50:09 -0500 Message-ID: <4CEF74B1.1030908@redhat.com> Date: Fri, 26 Nov 2010 09:49:53 +0100 From: Gerd Hoffmann MIME-Version: 1.0 Subject: Re: [Qemu-devel] [patch 0/2] USB UHCI global suspend / remote wakeup References: <20101125170439.548474575@redhat.com> <201011260038.29290.paul@codesourcery.com> <20101126021512.GA18020@amt.cnet> In-Reply-To: <20101126021512.GA18020@amt.cnet> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Marcelo Tosatti Cc: Matthew Garrett , kvm , qemu-devel@nongnu.org, Glauber de Oliveira Costa , Adam Jackson , Paul Brook On 11/26/10 03:15, Marcelo Tosatti wrote: > On Fri, Nov 26, 2010 at 12:38:28AM +0000, Paul Brook wrote: >>> This patch enables USB UHCI global suspend/resume feature. The OS will >>> stop the HC once all ports are suspended. If there is activity on the >>> port(s), an interrupt signalling remote wakeup will be triggered. >> >> I'm pretty sure this is wrong. Suspend/resume works based on physical >> topology, i.e. the resume notification should go to the the port/hub to which >> the device is connected, not directly to the host controller. > You are correct in that USB HUB emulation does not propagate resume, but > this does not make this patch incorrect. Well, it does. When the notification is port based our software model should better reflect that, so we have the chance to add resume propagation to the hub emulation later on. I guess the Ops should be moved from the USBBus to the USBPort to reflect that. This way the hub emulation and the uhci root hub can have different callbacks, which is needed to get this correct. cheers, Gerd