]> xenbits.xensource.com Git - people/dariof/xen.git/commit
x86/srat: fix the end pfn check in valid_numa_range()
authorHaozhong Zhang <haozhong.zhang@intel.com>
Mon, 12 Feb 2018 01:44:23 +0000 (09:44 +0800)
committerAndrew Cooper <andrew.cooper3@citrix.com>
Mon, 12 Feb 2018 11:08:33 +0000 (11:08 +0000)
commit722648676751fda39086f54d961640f88174360b
treeb5a2f8db4117eb48d6c5e25965a829d4d9ba7460
parentb2fd2ec8e165837ff5d1a9ec8a816eaa622c8272
x86/srat: fix the end pfn check in valid_numa_range()

... and fix the coding style on fly.

valid_numa_range(..., epfn << PAGE_SHIFT, ...) and its only caller
memory_add(..., epfn, pxm) interpret epfn inconsistently. The former
interprets epfn as the last pfn, while the latter interprets it as the
last pfn plus one. Fix this inconsistency in valid_numa_range(), since
most of other places use the latter interpretation.

Signed-off-by: Haozhong Zhang <haozhong.zhang@intel.com>
Acked-by: Andrew Cooper <andrew.cooper3@citrix.com>
xen/arch/x86/srat.c