From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jens Axboe Subject: Re: [PATCH/RFC] virtio_blk: check for hardsector size from host Date: Thu, 29 May 2008 10:30:05 +0200 Message-ID: <20080529083004.GQ25504@kernel.dk> References: <200805271105.00077.borntraeger@de.ibm.com> <20080529081255.GO25504@kernel.dk> <20080529081357.GP25504@kernel.dk> <200805291027.25369.borntraeger@de.ibm.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: Rusty Russell , virtualization@lists.linux-foundation.org, kvm@vger.kernel.org To: Christian Borntraeger Return-path: Received: from brick.kernel.dk ([87.55.233.238]:21880 "EHLO kernel.dk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754642AbYE2IaH (ORCPT ); Thu, 29 May 2008 04:30:07 -0400 Content-Disposition: inline In-Reply-To: <200805291027.25369.borntraeger@de.ibm.com> Sender: kvm-owner@vger.kernel.org List-ID: On Thu, May 29 2008, Christian Borntraeger wrote: > Am Donnerstag, 29. Mai 2008 schrieb Jens Axboe: > > > > Just that u64 seems like overkill: u32? > > > > > > Definitely, u32 would be just fine, u64 is way overkill :-) > > > > Even u16 would work, the block layer doesn't use more than an unsigned > > short for storing hardware sector size anyway. > > Thanks, good to know. Do you think, that could change in the future? > The virtio definition is going to be a public interface, so if there > is a chance that u16 is not enough in the future I would respin the > patch with u32, otherwise u16. I'd say go with the u32, it's the safest option for an exported interface. -- Jens Axboe