From mboxrd@z Thu Jan 1 00:00:00 1970 From: Avi Kivity Subject: Re: [PATCH] pass virtio disk geometry via config space Date: Fri, 18 Apr 2008 19:23:45 +0300 Message-ID: <4808CB11.2080704@qumranet.com> References: <1208372219-21053-1-git-send-email-ryanh@us.ibm.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Cc: kvm-devel@lists.sourceforge.net To: Ryan Harper Return-path: In-Reply-To: <1208372219-21053-1-git-send-email-ryanh@us.ibm.com> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: kvm-devel-bounces@lists.sourceforge.net Errors-To: kvm-devel-bounces@lists.sourceforge.net List-Id: kvm.vger.kernel.org Ryan Harper wrote: > From: Ryan Harper > > Rather than faking up some geometry, allow the backend to push the disk > geometry via virtio pci config option. Keep the old geo code around for > compatibility. > > Applied, thanks. > struct virtio_blk_config > { > uint64_t capacity; > uint32_t size_max; > uint32_t seg_max; > + uint16_t cylinders; > + uint8_t heads; > + uint8_t sectors; > }; > > I packed the structure here to avoid gcc surprises on odd architectures. -- Any sufficiently difficult bug is indistinguishable from a feature. ------------------------------------------------------------------------- This SF.net email is sponsored by the 2008 JavaOne(SM) Conference Don't miss this year's exciting event. There's still time to save $100. Use priority code J8TL2D2. http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone