Date: Wed, 11 Oct 2017 00:31:54 +0000 (UTC) From: Ed Maste <emaste@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r324510 - stable/11/sys/conf Message-ID: <201710110031.v9B0VsNT072086@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: emaste Date: Wed Oct 11 00:31:54 2017 New Revision: 324510 URL: https://svnweb.freebsd.org/changeset/base/324510 Log: MFC r309151: Use explicit 0x200000 for the amd64 kernel physaddr (instead of MAXPAGESIZE) MAXPAGESIZE is not well defined by the GNU ld documentation. Different linkers, and different versions of the same linker, use different MAXPAGESIZE values. Current versions of GNU gold and LLVM's lld use 4K. When set to 4K the kernel panics at boot due to an issue with x86bios. Here we want the kernel physaddr to be the amd64 superpage size, so use that value (2MB) explicitly. With this change GNU gold and LLVM lld can link a working amd64 kernel. PR: 214718 (x86bios) Sponsored by: The FreeBSD Foundation Modified: stable/11/sys/conf/ldscript.amd64 Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/conf/ldscript.amd64 ============================================================================== --- stable/11/sys/conf/ldscript.amd64 Tue Oct 10 23:54:25 2017 (r324509) +++ stable/11/sys/conf/ldscript.amd64 Wed Oct 11 00:31:54 2017 (r324510) @@ -6,7 +6,7 @@ SEARCH_DIR("/usr/lib"); SECTIONS { /* Read-only sections, merged into text segment: */ - kernphys = CONSTANT (MAXPAGESIZE); + kernphys = 0x200000; . = kernbase + kernphys + SIZEOF_HEADERS; /* * Use the AT keyword in order to set the right LMA that contains
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201710110031.v9B0VsNT072086>