Received: from eggs.gnu.org ([2001:4830:134:3::10]:41667) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a3ilW-0001gk-GY for qemu-devel@nongnu.org; Tue, 01 Dec 2015 06:06:39 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1a3ilQ-0001Rx-UK for qemu-devel@nongnu.org; Tue, 01 Dec 2015 06:06:34 -0500 From: Alberto Garcia In-Reply-To: <1447127063-4662-9-git-send-email-mreitz@redhat.com> References: <1447127063-4662-1-git-send-email-mreitz@redhat.com> <1447127063-4662-9-git-send-email-mreitz@redhat.com> Date: Tue, 01 Dec 2015 12:06:14 +0100 Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Subject: Re: [Qemu-devel] [Qemu-block] [PATCH 8/8] block: Assert !bs->refcnt in bdrv_close() List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Max Reitz , qemu-block@nongnu.org Cc: Kevin Wolf , qemu-devel@nongnu.org On Tue 10 Nov 2015 04:44:23 AM CET, Max Reitz wrote: > The only caller of bdrv_close() left is bdrv_delete(). We may as well > assert that, in a way (there are some things in bdrv_close() that make > more sense under that assumption, such as the call to > bdrv_release_all_dirty_bitmaps() which in turn assumes that no frozen > bitmaps are attached to the BDS). > > In addition, being called only in bdrv_delete() means that we can drop > bdrv_close()'s forward declaration at the top of block.c. > > Signed-off-by: Max Reitz Reviewed-by: Alberto Garcia Berto