WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

Re: [Xen-devel] out of bounds handling for get_mfn_from_gpfn()

>Okay, maybe we need to be more restrictive: 20 bits for 32b (4GB), 22 
>bits for 32b-pae (16GB), and some suitable large value for 64b (31 
>would be fine, it's good for up to 8TB).

Then perhaps the way to go would be to really check against
((RO_MPT_VIRT_END - RO_MPT_VIRT_START) / sizeof(*phys_to_machine_mapping)).
This wouldn't be 31 bits for x86-64, but it seems to me that allowing 35-bit 
gpfn-s
wouldn't be that bad an idea (and the fact that the array currently may only get
populated up to 31-bit gpfn-s wouldn't seem to cause any problems). I'll 
prepare a
patch...

Jan

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