Re: [PATCH 2/2] NUMA: replace phys_to_nid()

2022-12-16 Thread Andrew Cooper
On 16/12/2022 11:59 am, Jan Beulich wrote: > On 16.12.2022 12:49, Andrew Cooper wrote: >> On 13/12/2022 11:38 am, Jan Beulich wrote: >>> All callers convert frame numbers (perhaps in turn derived from struct >>> page_info pointers) to an address, just for the function to convert it >>> back to a fr

Re: [PATCH 2/2] NUMA: replace phys_to_nid()

2022-12-16 Thread Jan Beulich
On 16.12.2022 12:49, Andrew Cooper wrote: > On 13/12/2022 11:38 am, Jan Beulich wrote: >> All callers convert frame numbers (perhaps in turn derived from struct >> page_info pointers) to an address, just for the function to convert it >> back to a frame number (as the first step of paddr_to_pdx()).

Re: [PATCH 2/2] NUMA: replace phys_to_nid()

2022-12-16 Thread Andrew Cooper
On 13/12/2022 11:38 am, Jan Beulich wrote: > All callers convert frame numbers (perhaps in turn derived from struct > page_info pointers) to an address, just for the function to convert it > back to a frame number (as the first step of paddr_to_pdx()). Replace > the function by mfn_to_nid() plus a

Re: [PATCH 2/2] NUMA: replace phys_to_nid()

2022-12-13 Thread Julien Grall
Hi Jan, On 13/12/2022 14:08, Jan Beulich wrote: On 13.12.2022 14:48, Julien Grall wrote: On 13/12/2022 12:46, Jan Beulich wrote: On 13.12.2022 13:06, Julien Grall wrote: On 13/12/2022 11:38, Jan Beulich wrote: All callers convert frame numbers (perhaps in turn derived from struct page_info p

Re: [PATCH 2/2] NUMA: replace phys_to_nid()

2022-12-13 Thread Jan Beulich
On 13.12.2022 14:48, Julien Grall wrote: > On 13/12/2022 12:46, Jan Beulich wrote: >> On 13.12.2022 13:06, Julien Grall wrote: >>> On 13/12/2022 11:38, Jan Beulich wrote: All callers convert frame numbers (perhaps in turn derived from struct page_info pointers) to an address, just for the

Re: [PATCH 2/2] NUMA: replace phys_to_nid()

2022-12-13 Thread Julien Grall
Hi Jan, On 13/12/2022 12:46, Jan Beulich wrote: On 13.12.2022 13:06, Julien Grall wrote: On 13/12/2022 11:38, Jan Beulich wrote: All callers convert frame numbers (perhaps in turn derived from struct page_info pointers) to an address, just for the function to convert it back to a frame number

Re: [PATCH 2/2] NUMA: replace phys_to_nid()

2022-12-13 Thread Jan Beulich
On 13.12.2022 13:06, Julien Grall wrote: > On 13/12/2022 11:38, Jan Beulich wrote: >> All callers convert frame numbers (perhaps in turn derived from struct >> page_info pointers) to an address, just for the function to convert it >> back to a frame number (as the first step of paddr_to_pdx()). Rep

Re: [PATCH 2/2] NUMA: replace phys_to_nid()

2022-12-13 Thread Julien Grall
Hi Jan, On 13/12/2022 11:38, Jan Beulich wrote: All callers convert frame numbers (perhaps in turn derived from struct page_info pointers) to an address, just for the function to convert it back to a frame number (as the first step of paddr_to_pdx()). Replace the function by mfn_to_nid() plus a

[PATCH 2/2] NUMA: replace phys_to_nid()

2022-12-13 Thread Jan Beulich
All callers convert frame numbers (perhaps in turn derived from struct page_info pointers) to an address, just for the function to convert it back to a frame number (as the first step of paddr_to_pdx()). Replace the function by mfn_to_nid() plus a page_to_nid() wrapper macro. Replace call sites by