Re: [Xen-devel] [PATCH v4 10/16] xen/mm: Switch map_pages_to_xen to use MFN typesafe

2018-03-05 Thread Julien Grall
Hi, On 05/03/18 14:39, Jan Beulich wrote: On 05.03.18 at 15:07, wrote: On 02/03/18 15:06, Jan Beulich wrote: On 21.02.18 at 15:02, wrote: --- a/xen/arch/x86/x86_64/mm.c +++ b/xen/arch/x86/x86_64/mm.c @@ -40,6 +40,10 @@ asm(".file \"" __FILE__

Re: [Xen-devel] [PATCH v4 10/16] xen/mm: Switch map_pages_to_xen to use MFN typesafe

2018-03-05 Thread Jan Beulich
>>> On 05.03.18 at 15:07, wrote: > On 02/03/18 15:06, Jan Beulich wrote: > On 21.02.18 at 15:02, wrote: >>> --- a/xen/arch/x86/x86_64/mm.c >>> +++ b/xen/arch/x86/x86_64/mm.c >>> @@ -40,6 +40,10 @@ asm(".file \"" __FILE__ "\""); >>> #include >>>

Re: [Xen-devel] [PATCH v4 10/16] xen/mm: Switch map_pages_to_xen to use MFN typesafe

2018-03-05 Thread Julien Grall
Hi, On 02/03/18 15:06, Jan Beulich wrote: On 21.02.18 at 15:02, wrote: --- a/xen/arch/x86/x86_64/mm.c +++ b/xen/arch/x86/x86_64/mm.c @@ -40,6 +40,10 @@ asm(".file \"" __FILE__ "\""); #include #include +/* Override macros from asm/page.h to make them work with

Re: [Xen-devel] [PATCH v4 10/16] xen/mm: Switch map_pages_to_xen to use MFN typesafe

2018-03-02 Thread Jan Beulich
>>> On 02.03.18 at 16:06, wrote: On 21.02.18 at 15:02, wrote: >> --- a/xen/arch/x86/x86_64/mm.c >> +++ b/xen/arch/x86/x86_64/mm.c >> @@ -40,6 +40,10 @@ asm(".file \"" __FILE__ "\""); >> #include >> #include >> >> +/* Override macros from

Re: [Xen-devel] [PATCH v4 10/16] xen/mm: Switch map_pages_to_xen to use MFN typesafe

2018-03-02 Thread Jan Beulich
>>> On 21.02.18 at 15:02, wrote: > --- a/xen/arch/x86/x86_64/mm.c > +++ b/xen/arch/x86/x86_64/mm.c > @@ -40,6 +40,10 @@ asm(".file \"" __FILE__ "\""); > #include > #include > > +/* Override macros from asm/page.h to make them work with mfn_t */ > +#undef page_to_mfn >

Re: [Xen-devel] [PATCH v4 10/16] xen/mm: Switch map_pages_to_xen to use MFN typesafe

2018-02-23 Thread Wei Liu
On Wed, Feb 21, 2018 at 02:02:53PM +, Julien Grall wrote: > The current prototype is slightly confusing because it takes a virtual > address and a physical frame (not address!). Switching to MFN will improve > safety and reduce the chance to mistakenly invert the 2 parameters. > >

Re: [Xen-devel] [PATCH v4 10/16] xen/mm: Switch map_pages_to_xen to use MFN typesafe

2018-02-22 Thread Tian, Kevin
> From: Julien Grall [mailto:julien.gr...@arm.com] > Sent: Wednesday, February 21, 2018 10:03 PM > > The current prototype is slightly confusing because it takes a virtual > address and a physical frame (not address!). Switching to MFN will improve > safety and reduce the chance to mistakenly

[Xen-devel] [PATCH v4 10/16] xen/mm: Switch map_pages_to_xen to use MFN typesafe

2018-02-21 Thread Julien Grall
The current prototype is slightly confusing because it takes a virtual address and a physical frame (not address!). Switching to MFN will improve safety and reduce the chance to mistakenly invert the 2 parameters. Signed-off-by: Julien Grall --- Cc: Stefano Stabellini