From owner-freebsd-bugs@freebsd.org Sat Aug 3 01:36:29 2019 Return-Path: Delivered-To: freebsd-bugs@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 82954A1EC4 for ; Sat, 3 Aug 2019 01:36:29 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mailman.nyi.freebsd.org (mailman.nyi.freebsd.org [IPv6:2610:1c1:1:606c::50:13]) by mx1.freebsd.org (Postfix) with ESMTP id 460mpP2pMFz3GDD for ; Sat, 3 Aug 2019 01:36:29 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: by mailman.nyi.freebsd.org (Postfix) id 60246A1EC3; Sat, 3 Aug 2019 01:36:29 +0000 (UTC) Delivered-To: bugs@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 5FE6CA1EC2 for ; Sat, 3 Aug 2019 01:36:29 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) server-signature RSA-PSS (4096 bits) client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 460mpP1sf8z3GDC for ; Sat, 3 Aug 2019 01:36:29 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2610:1c1:1:606c::50:1d]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 23902B7B6 for ; Sat, 3 Aug 2019 01:36:29 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org ([127.0.1.5]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id x731aTKQ029271 for ; Sat, 3 Aug 2019 01:36:29 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from bugzilla@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id x731aTn4029270 for bugs@FreeBSD.org; Sat, 3 Aug 2019 01:36:29 GMT (envelope-from bugzilla-noreply@freebsd.org) X-Authentication-Warning: kenobi.freebsd.org: bugzilla set sender to bugzilla-noreply@freebsd.org using -f From: bugzilla-noreply@freebsd.org To: bugs@FreeBSD.org Subject: [Bug 236899] Boot hang on ASUS VivoBook 15 X505ZA Date: Sat, 03 Aug 2019 01:36:28 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: kern X-Bugzilla-Version: 12.0-STABLE X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Some People X-Bugzilla-Who: commit-hook@freebsd.org X-Bugzilla-Status: Closed X-Bugzilla-Resolution: DUPLICATE X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: bugs@FreeBSD.org X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 03 Aug 2019 01:36:29 -0000 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D236899 --- Comment #9 from commit-hook@freebsd.org --- A commit references this bug: Author: jhb Date: Sat Aug 3 01:36:07 UTC 2019 New revision: 350551 URL: https://svnweb.freebsd.org/changeset/base/350551 Log: Don't reset memory attributes when mapping physical addresses for ACPI. Previously, AcpiOsMemory was using pmap_mapbios which would always map the requested address Write-Back (WB). For several AMD Ryzen laptops, the BIOS uses AcpiOsMemory to directly access the PCI MCFG region in order to access PCI config registers. This has the side effect of remapping the MCFG region in the direct map as WB instead of UC hanging the laptops during boot. On the one laptop I examined in detail, the _PIC global method used to switch from 8259A PICs to I/O APICs uses a pair of PCI config space registers at offset 0x84 in the device at 0:0:0 to as a pair of address/data registers to access an indirect register in the chipset and clear a single bit to switch modes. To fix, alter the semantics of pmap_mapbios() such that it does not modify the attributes of any existing mappings and instead uses the existing attributes. If a new mapping is created, this new mapping uses WB (the default memory attribute). Special thanks to the gentleman whose name I don't have who brought two affected laptops to the hacker lounge at BSDCan. Direct access to the affected systems permitted finding the root cause within an hour or so. PR: 231760, 236899 Reviewed by: kib, alc MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D20327 Changes: head/sys/amd64/amd64/pmap.c head/sys/i386/i386/pmap.c head/sys/i386/i386/pmap_base.c head/sys/i386/include/pmap_base.h --=20 You are receiving this mail because: You are the assignee for the bug.=