From mboxrd@z Thu Jan 1 00:00:00 1970 From: Gerd Hoffmann Subject: Re: [Qemu-devel] [patch 0/2] USB UHCI global suspend / remote wakeup Date: Fri, 26 Nov 2010 09:49:53 +0100 Message-ID: <4CEF74B1.1030908@redhat.com> References: <20101125170439.548474575@redhat.com> <201011260038.29290.paul@codesourcery.com> <20101126021512.GA18020@amt.cnet> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Cc: Paul Brook , qemu-devel@nongnu.org, kvm , Matthew Garrett , Adam Jackson , Glauber de Oliveira Costa To: Marcelo Tosatti Return-path: Received: from mx1.redhat.com ([209.132.183.28]:40585 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753932Ab0KZIuL (ORCPT ); Fri, 26 Nov 2010 03:50:11 -0500 In-Reply-To: <20101126021512.GA18020@amt.cnet> Sender: kvm-owner@vger.kernel.org List-ID: 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