From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from [140.186.70.92] (port=39994 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PImIx-0002y8-Gx for qemu-devel@nongnu.org; Wed, 17 Nov 2010 13:00:24 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PImIw-0002B2-Az for qemu-devel@nongnu.org; Wed, 17 Nov 2010 13:00:23 -0500 Received: from mx1.redhat.com ([209.132.183.28]:9291) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PImIw-0002Ak-2E for qemu-devel@nongnu.org; Wed, 17 Nov 2010 13:00:22 -0500 Received: from int-mx01.intmail.prod.int.phx2.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id oAHI0Iec014544 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Wed, 17 Nov 2010 13:00:18 -0500 Date: Wed, 17 Nov 2010 20:00:08 +0200 From: "Michael S. Tsirkin" Message-ID: <20101117180008.GE29556@redhat.com> References: <1288704898-30234-1-git-send-email-kraxel@redhat.com> <20101116174306.GC4077@redhat.com> <4CE3D875.9020701@redhat.com> <20101117135842.GA13690@redhat.com> <4CE3F2CD.4030701@redhat.com> <20101117164244.GE27909@redhat.com> <4CE40AAF.7090202@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4CE40AAF.7090202@redhat.com> Subject: [Qemu-devel] Re: [PATCH] spice: add qxl device List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Gerd Hoffmann Cc: qemu-devel@nongnu.org On Wed, Nov 17, 2010 at 06:02:39PM +0100, Gerd Hoffmann wrote: > Hi, > > >>>>Better don't try ... > >>> > >>>Better prevent it then? > >> > >>How can I do that? > > Question still stands: Is there some way to disable hotplug for > certain pci devices? Not sure. It's really a work-around bug, maybe it's better to fix it properly. > >> How does this work btw? Only > >>one vga adapter can drive the legacy vga ports, right? Is there > >>some way to enable/disable this per vga device? > > > >Yes, just disable IO memory. > > This is supposed to disable legacy vga ports (0x03c0+) too? Sure. > >> If so: does qemu > >>emulate this correctly? > > > >It mostly does. > > I doubt it actually enables/disables the legacy vga ports. I'll check when I have the time. We can fix it if it doesn't, > >But the counter wrapping will at least in theory crash qemu, > >this is an even bigger problem than a guest crash. > > I can put it a limit at one million hotplugs or so ... How about a simple allocator? With at most 256 devices on a pci bus * 8 functions, it need not be hard: just a long long bitmask with ffsll used to find a free bit. Also - what is the ID used for? What happens if it's not unique? > >> I also don't see the point in plugging a display like > >>mad. > > > >Just to see if you can exploit some memory corruption maybe? > > Can the guest do that without the hosts help? > Especially plugging *in* something? > > cheers, > Gerd No, but a monitor user connected to qemu over a qmp socket can do this. -- MST