From: Robin Bowes Subject: Re: Getting xen to recognise large disks Date: Tue, 21 Nov 2006 01:01:26 +0000 Message-ID: References: <8A87A9A84C201449A0C56B728ACF491E01F905@liverpoolst.ad.cl.cam.ac.uk> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <8A87A9A84C201449A0C56B728ACF491E01F905@liverpoolst.ad.cl.cam.ac.uk> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: xen-devel@lists.xensource.com List-Id: xen-devel@lists.xenproject.org Ian Pratt wrote: >> major minor #blocks name >> 202 16 782819328 xvdb >> >> When I look at the same partition in the host, I see this: >> major minor #blocks name >> 9 2 2930303616 md2 >> >> There appears to be a problem in passing the size of the device to the >> DomU guest. > > Hmm, 2930303616 - 2^31 = 782819968 > > Argh -- I can see the problem: see the connect function in blkfront.c. > > Fortunately, it can be fixed without an interface change. Just change > 'sectors' from an unsigned long to a blkif_sector_t and update the > xenbus_gather to use: "sectors", "%llu", §ors > > You'll also need to edit the xenbus_printf (to %llu) in the connect > function in blkback.c too. > > Please post a patch! Ian, I'd love to post a patch, but I'm afraid I'm not a coder. I'm downloading the SRPMS as I type and I'll give it a go, but it might be an idea if someone with more coding skills fixes this. I'll post an update when I've had a go. R.