From owner-freebsd-bugs@freebsd.org Tue Feb 13 00:42:25 2018 Return-Path: Delivered-To: freebsd-bugs@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id EB5E7F0925E for ; Tue, 13 Feb 2018 00:42:24 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mxrelay.ysv.freebsd.org (mxrelay.ysv.freebsd.org [IPv6:2001:1900:2254:206a::19:3]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mxrelay.ysv.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 6D98D77A98 for ; Tue, 13 Feb 2018 00:42:24 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2001:1900:2254:206a::16:76]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.ysv.freebsd.org (Postfix) with ESMTPS id 9899420230 for ; Tue, 13 Feb 2018 00:42:23 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org ([127.0.1.118]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id w1D0gN85014687 for ; Tue, 13 Feb 2018 00:42:23 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id w1D0gNbV014686 for freebsd-bugs@FreeBSD.org; Tue, 13 Feb 2018 00:42:23 GMT (envelope-from bugzilla-noreply@freebsd.org) X-Authentication-Warning: kenobi.freebsd.org: www set sender to bugzilla-noreply@freebsd.org using -f From: bugzilla-noreply@freebsd.org To: freebsd-bugs@FreeBSD.org Subject: [Bug 225450] 11.1-* panics on AMD Opteron 2k due to EARLY_AP_STARTUP Date: Tue, 13 Feb 2018 00:42:23 +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: 11.1-STABLE X-Bugzilla-Keywords: patch X-Bugzilla-Severity: Affects Many People X-Bugzilla-Who: pablo.ruiz@gmail.com X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: freebsd-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.25 Precedence: list List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Feb 2018 00:42:25 -0000 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D225450 --- Comment #18 from Pablo Ruiz --- I've tried the following patch: diff --git a/sys/x86/x86/delay.c b/sys/x86/x86/delay.c index 8cbe6012a96..00dfff48c19 100644 --- a/sys/x86/x86/delay.c +++ b/sys/x86/x86/delay.c @@ -70,7 +70,7 @@ delay_tc(int n) func =3D get_tsc; mask =3D ~0u; } else { - if (tc->tc_quality <=3D 0) + if (tc->tc_quality <=3D 0 || n =3D=3D 1) return (0); func =3D tc->tc_get_timecount; mask =3D tc->tc_counter_mask; diff --git a/sys/x86/x86/mp_x86.c b/sys/x86/x86/mp_x86.c index 04975dd8a2e..c2a90e9a7d4 100644 --- a/sys/x86/x86/mp_x86.c +++ b/sys/x86/x86/mp_x86.c @@ -952,7 +952,7 @@ init_secondary_tail(void) #endif mtx_unlock_spin(&ap_boot_mtx); -while(1); +//while(1); /* Wait until all the AP's are up. */ while (atomic_load_acq_int(&smp_started) =3D=3D 0) ..... But I got to 'db' prompt to: cpu0 BSP: ID: 0x00000000 VER: 0x80050010 LDR: 0x00000000 DFR: 0xffffffff lint0: 0x00010700 lint1: 0x00000400 TPR: 0x00000000 SVR: 0x000001ff timer: 0x000100ef therm: 0x00010000 err: 0x000000f0 pmc: 0x00010400 AMD ext features: 0x00010003 AMD elvt0: 0x00010000 SMP: AP CPU #1 Launched! cpu1 AP: FFa tFa FFa FFa Fa kFernel trap 12 with interrupts disabled Fatal trap 12: page fault while in kernel mode cpuid =3D 2; apic id =3D 02 fault virtual address =3D 0x441 fault code =3D supervisor read data, page not present instruction pointer =3D 0x20:0xffffffff80ffb704 stack pointer =3D 0x28:0xfffffe001b97ba90 frame pointer =3D 0x28:0xfffffe001b97baa0 code segment =3D base 0x0, limit 0xfffff, type 0x1b =3D DPL 0, pres 1, long 1, def32 0, gran 1 processor eflags =3D resume, IOPL =3D 0 current process =3D 11 (idle: cpu2) [ thread pid 11 tid 100005 ] Stopped at spinlock_exit+0x14: movq 0x440(%rbx),%rax db> show thread Thread 100005 at 0xfffff8000332c000: proc (pid 11): 0xfffff80003328000 name: idle: cpu2 stack: 0xfffffe001b9a6000-0xfffffe001b9a9fff flags: 0x40024 pflags: 0x200000 state: CAN RUN priority: 255 container lock: sched lock 0 (0xffffffff827ee880) db> bt Tracing pid 11 tid 100005 td 0xfffff8000332c000 spinlock_exit() at spinlock_exit+0x14/frame 0xfffffe001b97baa0 _mtx_lock_spin_cookie() at _mtx_lock_spin_cookie+0xa5/frame 0xfffffe001b97b= b10 i8254_delay() at i8254_delay+0x143/frame 0xfffffe001b97bb50 _mtx_lock_spin_cookie() at _mtx_lock_spin_cookie+0xa5/frame 0xfffffe001b97b= bc0 i8254_delay() at i8254_delay+0x143/frame 0xfffffe001b97bc00 _mtx_lock_spin_cookie() at _mtx_lock_spin_cookie+0xa5/frame 0xfffffe001b97b= c70 i8254_delay() at i8254_delay+0x143/frame 0xfffffe001b97bcb0 _mtx_lock_spin_cookie() at _mtx_lock_spin_cookie+0xa5/frame 0xfffffe001b97b= d20 i8254_delay() at i8254_delay+0x143/frame 0xfffffe001b97bd60 _mtx_lock_spin_cookie() at _mtx_lock_spin_cookie+0xa5/frame 0xfffffe001b97b= dd0 i8254_delay() at i8254_delay+0x143/frame 0xfffffe001b97be10 _mtx_lock_spin_cookie() at _mtx_lock_spin_cookie+0xa5/frame 0xfffffe001b97b= e80 i8254_delay() at i8254_delay+0x143/frame 0xfffffe001b97bec0 _mtx_lock_spin_cookie() at _mtx_lock_spin_cookie+0xa5/frame 0xfffffe001b97b= f30 i8254_delay() at i8254_delay+0x143/frame 0xfffffe001b97bf70 _mtx_lock_spin_cookie() at _mtx_lock_spin_cookie+0xa5/frame 0xfffffe001b97b= fe0 i8254_delay() at i8254_delay+0x143/frame 0xfffffe001b97c020 _mtx_lock_spin_cookie() at _mtx_lock_spin_cookie+0xa5/frame 0xfffffe001b97c= 090 .... --=20 You are receiving this mail because: You are the assignee for the bug.=