From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from [140.186.70.92] (port=53542 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OOWG0-0003Nw-Ak for qemu-devel@nongnu.org; Tue, 15 Jun 2010 09:34:01 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1OOWFw-000782-EC for qemu-devel@nongnu.org; Tue, 15 Jun 2010 09:32:45 -0400 Received: from mail.codesourcery.com ([38.113.113.100]:56195) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OOWFw-00077n-4l for qemu-devel@nongnu.org; Tue, 15 Jun 2010 09:32:44 -0400 From: Paul Brook Subject: Re: [Qemu-devel] [RFC PATCH 1/5] qdev: Create qdev_get_dev_path() Date: Tue, 15 Jun 2010 14:32:38 +0100 References: <20100614054923.879.33717.stgit@localhost.localdomain> <201006151419.54215.paul@codesourcery.com> In-Reply-To: <201006151419.54215.paul@codesourcery.com> MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Message-Id: <201006151432.38864.paul@codesourcery.com> List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Markus Armbruster Cc: "chrisw@redhat.com" , "kvm@vger.kernel.org" , Jan Kiszka , "qemu-devel@nongnu.org" , Alex Williamson , "avi@redhat.com" , "kraxel@redhat.com" > > > Every hotplug-capable bus must have a proper addressing scheme, I think > > > this is a reasonable and achievable requirement. Then we don't need > > > instance numbers for those buses. > > > > What about USB? > > USB has useful device addresses (physical ports). > These aren't used by most of the higher-level protocols (logically USB is a > flat bus structure), but the physically tree topology is still there if you > look hard enough. ... and thinking about it a bit more, this adds an extra addressing possibility. USB devices have both physical and logical. The physical addresses is which port the device is plugged into (including port addresses of any intermediate hubs). These never change, so should be the canonical address. The logical address is set by the guest OS so may change (or be absent). Most software uses the logical address, so this is by far the most useful option for mapping from a guest device to a qemu device. Paul