From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:59042) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fn3eP-00047S-9w for qemu-devel@nongnu.org; Tue, 07 Aug 2018 11:11:58 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fn3eO-0004yi-EZ for qemu-devel@nongnu.org; Tue, 07 Aug 2018 11:11:57 -0400 From: Alberto Garcia In-Reply-To: <20180628000745.4477-15-mreitz@redhat.com> References: <20180628000745.4477-1-mreitz@redhat.com> <20180628000745.4477-15-mreitz@redhat.com> Date: Tue, 07 Aug 2018 17:11:49 +0200 Message-ID: MIME-Version: 1.0 Content-Type: text/plain Subject: Re: [Qemu-devel] [Qemu-block] [PATCH v9 14/31] block: Add bdrv_dirname() 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 Thu 28 Jun 2018 02:07:28 AM CEST, Max Reitz wrote: > This function may be implemented by block drivers to derive a directory > name from a BDS. Concatenating this g_free()-able string with a relative > filename must result in a valid (not necessarily existing) filename, so > this is a function that should generally be not implemented by format > drivers, because this is protocol-specific. > > If a BDS's driver does not implement this function, bdrv_dirname() will > fall through to the BDS's file if it exists. If it does not, the > exact_filename field will be used to generate a directory name. > > Signed-off-by: Max Reitz Reviewed-by: Alberto Garcia Berto