From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:49114) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XqfLO-0005RR-F1 for qemu-devel@nongnu.org; Tue, 18 Nov 2014 04:45:15 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XqfLF-0004pl-Dy for qemu-devel@nongnu.org; Tue, 18 Nov 2014 04:45:06 -0500 Received: from mail-wg0-x231.google.com ([2a00:1450:400c:c00::231]:55037) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XqfLF-0004pc-6c for qemu-devel@nongnu.org; Tue, 18 Nov 2014 04:44:57 -0500 Received: by mail-wg0-f49.google.com with SMTP id x13so27068660wgg.36 for ; Tue, 18 Nov 2014 01:44:56 -0800 (PST) Sender: Paolo Bonzini Message-ID: <546B1514.1000205@redhat.com> Date: Tue, 18 Nov 2014 10:44:52 +0100 From: Paolo Bonzini MIME-Version: 1.0 References: <1416238250-414-1-git-send-email-mreitz@redhat.com> <1416238250-414-3-git-send-email-mreitz@redhat.com> <546A2FD0.3090907@redhat.com> <546B10CC.5040408@redhat.com> In-Reply-To: <546B10CC.5040408@redhat.com> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH 2/5] block: Add AioContextNotifier functions to BB List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Max Reitz , qemu-devel@nongnu.org Cc: Kevin Wolf , Peter Lieven , Markus Armbruster , Stefan Hajnoczi On 18/11/2014 10:26, Max Reitz wrote: > However, when you consider (as far as I looked into it) that a BDS is > only closed when there are either no references to it (which will not > happen as long as it has a BB) or when it is ejected, it suddenly does > make sense: "Ejecting" really is something for the BB, so it makes sense > to wait for that event (even though the name "close notifier" doesn't > sound much like it...). I agree, and indeed the notifier was added to deal with ejection. Thanks for clarifying. I guess if QEMU were written in C++ we would have a hierarchy like this: BlockDevice (abstract) BlockBackend BlockDriverState and there would be no duplication of function names; the BlockBackend implementation would still have to forward to the top BlockDriverState. Paolo