From owner-freebsd-bugs@freebsd.org Fri Dec 7 15:01:31 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 07736130FEC5 for ; Fri, 7 Dec 2018 15:01:31 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mailman.ysv.freebsd.org (mailman.ysv.freebsd.org [IPv6:2001:1900:2254:206a::50:5]) by mx1.freebsd.org (Postfix) with ESMTP id 905868E51B for ; Fri, 7 Dec 2018 15:01:30 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: by mailman.ysv.freebsd.org (Postfix) id 53E06130FEC4; Fri, 7 Dec 2018 15:01:30 +0000 (UTC) Delivered-To: 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 17438130FEC3 for ; Fri, 7 Dec 2018 15:01:30 +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.3 with cipher TLS_AES_256_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 A9E878E519 for ; Fri, 7 Dec 2018 15:01:29 +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 C97B77371 for ; Fri, 7 Dec 2018 15:01:28 +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 wB7F1Som021604 for ; Fri, 7 Dec 2018 15:01:28 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id wB7F1Sjl021596 for bugs@FreeBSD.org; Fri, 7 Dec 2018 15:01:28 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: bugs@FreeBSD.org Subject: [Bug 233851] Kernel panic, stable/12 r341604, swapon -a in SU mode, geli encrypted swap, Chelsio T6225-CR, and ccr(4) Date: Fri, 07 Dec 2018 15:01:27 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: new 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: Trond.Endrestol@ximalas.info X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: bugs@FreeBSD.org X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version rep_platform op_sys bug_status bug_severity priority component assigned_to reporter Message-ID: 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-Rspamd-Queue-Id: 905868E51B X-Spamd-Result: default: False [-2.96 / 15.00]; local_wl_from(0.00)[freebsd.org]; NEURAL_HAM_MEDIUM(-0.98)[-0.983,0]; NEURAL_HAM_SHORT(-0.98)[-0.980,0]; ASN(0.00)[asn:10310, ipnet:2001:1900:2254::/48, country:US]; NEURAL_HAM_LONG(-0.99)[-0.994,0] X-Rspamd-Server: mx1.freebsd.org 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: Fri, 07 Dec 2018 15:01:31 -0000 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D233851 Bug ID: 233851 Summary: Kernel panic, stable/12 r341604, swapon -a in SU mode, geli encrypted swap, Chelsio T6225-CR, and ccr(4) Product: Base System Version: 12.0-STABLE Hardware: amd64 OS: Any Status: New Severity: Affects Some People Priority: --- Component: kern Assignee: bugs@FreeBSD.org Reporter: Trond.Endrestol@ximalas.info After booting stable/12 r341604, running a custom kernel including cxgbe(4), cxgbev(4), and ccr(4), and running swapon -a in SU mode: GEOM_ELI: Device gpt/swap0.eli created. GEOM_ELI: Encryption: AES-XTS 256 GEOM_ELI: Crypto: hardware Fatal trap 12: page fault while in kernel mode cpuid =3D 3; apic id =3D 06 fault virtual address =3D 0x0 fault code =3D supervisor write data, page not present instruction pointer =3D 0x20:0xffffffff805be1b2 stack pointer =3D 0x28:0xfffffe00a6253770 frame pointer =3D 0x28:0xfffffe00a6253770 code segment =3D base 0x0, limit 0xfffff, type 0x1b =3D DPL 0, pres 1, long 1, def32 0, gran 1 processor eflags =3D interrupt enabled, resume, IOPL =3D 0 current process =3D 65 (g_eli[3] gpt/swap0) trap number =3D 12 panic: page fault cpuid =3D 3 time =3D 1544087308 KDB: stack backtrace: db_trace_self_wrapper() at 0xffffffff8055d9eb =3D db_trace_self_wrapper+0x2b/frame 0xfffffe00a6253420 vpanic() at 0xffffffff808754d3 =3D vpanic+0x1a3/frame 0xfffffe00a6253480 panic() at 0xffffffff80875323 =3D panic+0x43/frame 0xfffffe00a62534e0 trap_fatal() at 0xffffffff80bd745f =3D trap_fatal+0x35f/frame 0xfffffe00a62= 53530 trap_pfault() at 0xffffffff80bd74b9 =3D trap_pfault+0x49/frame 0xfffffe00a4= b7f590 trap() at 0xffffffff80bd6ade =3D trap+0x29e/frame 0xfffffe00a4b7f6a0 calltrap() at 0xffffffff80bb3935 =3D calltrap+0x8/frame 0xfffffe00a4b7f6a0 --- trap 0xc, rip =3D 0xffffffff805be1b2, rsp =3D 0xfffffe00a4b7f770, rbp = =3D 0xfffffe00a4b7f770 t4_wrq_tx_locked() at 0xffffffff805be1b2 =3D t4_wrq_tx_locked+0x12/frame 0xfffffe00a6253770 ccr_process() at 0xffffffff805e3fc3 =3D ccr_process+0x1953/frame 0xfffffe00a4b7f970 crypto_dispatch() at 0xffffffff80ae3fa4 =3D crypto_dispatch+0x144/frame 0xfffffe00a4b7f9b0 g_eli_crypto_run() at 0xffffffff807b5cb3 =3D g_eli_crypto_run+0x273/frame 0xfffffe00a4b7fa10 g_eli_worker() at 0xffffffff807aebc8 =3D g_eli_worker+0x3c8/frame 0xfffffe00a4b7fa70 fork_exit() at 0xffffffff80834d93 =3D fork_exit+0x83/frame 0xfffffe00a4b7fa= b0 fork_trampoline() at 0xffffffff80bb491e =3D fork_trampoline+0xe/frame 0xfffffe00a4b7fab0 --- trap 0, rip =3D 0, rsp =3D 0, rbp =3D 0 --- Uptime: 14s Automatic reboot in 15 seconds - press a key on the console to abort --> Press a key on the console to reboot, The Chelsio NIC is a T6225-CR. Kernel config is https://ximalas.info/~trond/create-zfs/canmount/ENTERPRISE-amd64-stable-12 I tried stable/12 r341623 with ccr(4) removed from the kernel, and there wa= s no problems when I engaged geli encrypted swap in SU mode. That was yesterday. Today, while doing the finishing touches after upgrading to stable/12 r3416= 76, and still in SU mode, I ran the following sequence: killall -TERM moused killall -TERM devd umount -a zfs umount -a swapoff -a kldload ccr swapon -a To my amazement, I saw the crypto accelerator being loaded and recognized. Clearly, the system didn't panic, but maybe it would have later on, leading= me to believe the crypto or the cxbge/ccr subsystem isn't properly initialized early after startup. Please prove me wrong. I rebooted to SU mode to start fresh, and ran this sequence: swapon -a swapoff -a kldload ccr swapon -a I rebooted again to SU mode, and ran this simpler sequence: kldload ccr swapon -a In both cases the kernel panicked as soon as I executed the final command. --=20 You are receiving this mail because: You are the assignee for the bug.=