From mboxrd@z Thu Jan 1 00:00:00 1970 From: Anthony Liguori Subject: Re: [PATCH] virtio_blk: Dont waste major numbers Date: Thu, 31 Jan 2008 15:50:41 -0600 Message-ID: <47A242B1.40709@codemonkey.ws> References: <200801311553.53653.borntraeger__25311.9055800655$1201791369$gmane$org@de.ibm.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Cc: kvm-devel , virtualization-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org To: Christian Borntraeger Return-path: In-Reply-To: <200801311553.53653.borntraeger__25311.9055800655$1201791369$gmane$org-tA70FqPdS9bQT0dZR+AlfA@public.gmane.org> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: kvm-devel-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org Errors-To: kvm-devel-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org List-Id: kvm.vger.kernel.org Christian Borntraeger wrote: > Rusty, > > currently virtio_blk uses one major number per device. While this works > quite well on most systems it is wasteful and will exhaust major numbers > on larger installations. > > This patch allocates a major number on init and will use 16 minor numbers > for each disk. That will allow ~64k virtio_blk disks. > There's are some other limitations to the number of virtio block devices. For instances... > sprintf(vblk->disk->disk_name, "vd%c", virtblk_index++); This gets bogus after 64 disks. We also have a hard limit for virtio-pci based on the number of PCI slots available. One thing I was considering was whether we should try to support multiple disks per virtio device. Otherwise, this patch looks good to me. Regards, Anthony Liguori ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/