x86/power/64: Use __pa() for physical address computation
authorRafael J. Wysocki <rafael.j.wysocki@intel.com>
Sun, 14 Aug 2016 02:07:32 +0000 (04:07 +0200)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Mon, 15 Aug 2016 22:39:37 +0000 (00:39 +0200)
The value of temp_level4_pgt is the physical address of the
top-level page directory, so use __pa() to compute it.

Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Acked-by: Ingo Molnar <mingo@kernel.org>
arch/x86/power/hibernate_64.c

index a3e3ccc87138a7d44e6fe12114403b25a2d4affa..9634557a544478fdde15eff06d8fa120ffce894d 100644 (file)
@@ -113,7 +113,7 @@ static int set_up_temporary_mappings(void)
                        return result;
        }
 
-       temp_level4_pgt = (unsigned long)pgd - __PAGE_OFFSET;
+       temp_level4_pgt = __pa(pgd);
        return 0;
 }