From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:48043) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TA19k-000122-U1 for qemu-devel@nongnu.org; Fri, 07 Sep 2012 12:11:50 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TA19j-0006lt-VL for qemu-devel@nongnu.org; Fri, 07 Sep 2012 12:11:44 -0400 Received: from mx1.redhat.com ([209.132.183.28]:38069) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TA19j-0006ln-N4 for qemu-devel@nongnu.org; Fri, 07 Sep 2012 12:11:43 -0400 Message-ID: <504A1CBB.6000800@redhat.com> Date: Fri, 07 Sep 2012 18:11:39 +0200 From: Kevin Wolf MIME-Version: 1.0 References: <1346079626-16386-1-git-send-email-pbonzini@redhat.com> <504A17B6.6020703@redhat.com> In-Reply-To: <504A17B6.6020703@redhat.com> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] ping Re: [RFC PATCH 00/13] Embedded NBD server List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Paolo Bonzini Cc: stefanha@gmail.com, qemu-devel@nongnu.org Am 07.09.2012 17:50, schrieb Paolo Bonzini: > Il 27/08/2012 17:00, Paolo Bonzini ha scritto: >> The part where I need >> a second opinion and/or ack is patch 12 and 13. They fix the case of >> a disk being unplugged while NBD export is active. To do this I add a >> NotifierList to a BlockDriverState. Does this look okay, or is it too >> ad hoc? > > Ping... Kevin/Stefan, could you look at just these two patches: > > http://permalink.gmane.org/gmane.comp.emulators.qemu/167411 > [12/13] block: add close notifiers > > http://permalink.gmane.org/gmane.comp.emulators.qemu/167410 > [13/13] nbd: add notifier to close exports when the image is closed > > and if you need some context: > > http://permalink.gmane.org/gmane.comp.emulators.qemu/167400 > [09/13] qmp: add NBD server commands > > > Everything else is totally uninteresting. I was planning to review it in more detail next week, but I just had a quick look. I'm not sure if automatically shutting down the NBD server when the guest stops using it is always right (for removable media it could even be an eject from the guest), but introducing a notifier list doesn't look too bad. We can probably use it for other things that are currently hardcoded in bdrv_close() with some if statements, like disabling I/O throttling, cancelling a block job, etc. Kevin