From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:50017) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VMYfr-0007gz-UF for qemu-devel@nongnu.org; Thu, 19 Sep 2013 03:29:21 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VMYfm-00082c-CY for qemu-devel@nongnu.org; Thu, 19 Sep 2013 03:29:15 -0400 Received: from mx.ipv6.kamp.de ([2a02:248:0:51::16]:50948 helo=mx01.kamp.de) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VMYfm-00082Y-0y for qemu-devel@nongnu.org; Thu, 19 Sep 2013 03:29:10 -0400 Message-ID: <523AA7C2.4010000@kamp.de> Date: Thu, 19 Sep 2013 09:29:06 +0200 From: Peter Lieven MIME-Version: 1.0 References: <1379425736-11326-1-git-send-email-pl@kamp.de> <1379425736-11326-21-git-send-email-pl@kamp.de> <523968F8.3080808@redhat.com> In-Reply-To: <523968F8.3080808@redhat.com> Content-Type: text/plain; charset=ISO-8859-15; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCHv2 20/20] block/raw: copy block limits and alignment information on raw_open List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Paolo Bonzini Cc: kwolf@redhat.com, ronniesahlberg@gmail.com, stefanha@redhat.com, qemu-devel@nongnu.org, anthony@codemonkey.ws On 18.09.2013 10:48, Paolo Bonzini wrote: > Il 17/09/2013 15:48, Peter Lieven ha scritto: >> Signed-off-by: Peter Lieven >> --- >> block/raw_bsd.c | 4 ++++ >> 1 file changed, 4 insertions(+) >> >> diff --git a/block/raw_bsd.c b/block/raw_bsd.c >> index 0bfa5fc..dfdb375 100644 >> --- a/block/raw_bsd.c >> +++ b/block/raw_bsd.c >> @@ -149,6 +149,10 @@ static int raw_create(const char *filename, QEMUOptionParameter *options) >> static int raw_open(BlockDriverState *bs, QDict *options, int flags) >> { >> bs->sg = bs->file->sg; >> + bs->max_discard = bs->file->max_discard; >> + bs->discard_alignment = bs->file->discard_alignment; >> + bs->max_write_zeroes = bs->file->max_write_zeroes; >> + bs->write_zeroes_alignment = bs->file->write_zeroes_alignment; >> return 0; > What about introducing a BlockLimits struct? Good idea. Do you like the rest of the series? Peter