[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: [Xen-devel] Help/problems with blktap on xen-unstable


  • To: "Roland Paterson-Jones" <roland@xxxxxxxxxxxx>, xen-devel@xxxxxxxxxxxxxxxxxxx
  • From: "Petersson, Mats" <Mats.Petersson@xxxxxxx>
  • Date: Wed, 20 Sep 2006 15:53:01 +0200
  • Delivery-date: Wed, 20 Sep 2006 06:55:53 -0700
  • List-id: Xen developer discussion <xen-devel.lists.xensource.com>
  • Thread-index: Acbcuzv3eQzItf+1Q0mLdQ80LwesmgAAFAlg
  • Thread-topic: [Xen-devel] Help/problems with blktap on xen-unstable

 

> -----Original Message-----
> From: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx 
> [mailto:xen-devel-bounces@xxxxxxxxxxxxxxxxxxx] On Behalf Of 
> Roland Paterson-Jones
> Sent: 20 September 2006 14:44
> To: xen-devel@xxxxxxxxxxxxxxxxxxx
> Subject: Re: [Xen-devel] Help/problems with blktap on xen-unstable
> 
> Roland Paterson-Jones wrote:
> 
> >  So, I guess I need to recompile with an alternate device 
> major number.
> 
> I can find the following refs to 254 in the source (some are dups):
> 
> ./linux-2.6.16.13-xen0/drivers/xen/blktap/blktap.c:              
> major=254, minor numbers begin at 0            */
> ./linux-2.6.16.13-xen0/drivers/xen/blktap/blktap.c:#define 
> BLKTAP_DEV_MAJOR 254         /* TODO: Make major number dynamic  *
> ./linux-2.6-xen-sparse/drivers/xen/blktap/blktap.c:              
> major=254, minor numbers begin at 0            */
> ./linux-2.6-xen-sparse/drivers/xen/blktap/blktap.c:#define 
> BLKTAP_DEV_MAJOR 254         /* TODO: Make major number dynamic  *
> ./tools/blktap/lib/blktaplib.h:#define BLKTAP_DEV_MAJOR 254
> ./tools/blktap/drivers/blktapctrl.c:    
> make_blktap_dev(devname,254,0);
> ./tools/blktap_user/aiotools/blktapctrl.c:    
> make_blktap_dev(devname,254,0);
> ./tools/blktap_user/blktaplib.h:#define BLKTAP_DEV_MAJOR 254
> 
> I'm guessing it would be good to have one definition, but I'm not too 
> familiar with the code structure. Can a .h file span kernel and user 
> source? 

There's nothing preventing the same file being used in both kernel and
user-mode compiles - in fact in this case it would probably be a good
idea to ADD such a header-file - I'm not sure if there's anything ELSE
that should go into such a file [presumably there is some shared data
structures too that could go in there]. The above use of the same
constant in three places + using the same as a magic number is
definitely b0rkened... 

--
Mats



_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.