From owner-freebsd-net@freebsd.org Mon Aug 7 17:59:46 2017 Return-Path: Delivered-To: freebsd-net@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 8C4F8DBE9EB for ; Mon, 7 Aug 2017 17:59:46 +0000 (UTC) (envelope-from hps@selasky.org) Received: from mail.turbocat.net (turbocat.net [88.99.82.50]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4047D77309 for ; Mon, 7 Aug 2017 17:59:45 +0000 (UTC) (envelope-from hps@selasky.org) Received: from hps2016.home.selasky.org (unknown [62.141.129.119]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.turbocat.net (Postfix) with ESMTPSA id DA01626080B; Mon, 7 Aug 2017 19:59:43 +0200 (CEST) Subject: Re: mlx4en, timer irq @100%... To: Ben RUBSON , FreeBSD Net References: <72b9de84-5572-3737-b274-34d2c5cdf634@selasky.org> <91DCB96E-4C08-44C5-94E7-E7C686DEFE5F@gmail.com> <4DF74CB8-23D2-4CCF-B699-5B86DAEA65E5@gmail.com> <40602CEA-D417-4E5B-8C68-916958D49A0B@gmail.com> <9c306f10-7c05-d28d-e551-a930603aaafa@selasky.org> <896dd782-cb2c-0259-65d1-b00daae452de@FreeBSD.org> <0DB9F6FF-8BC9-48F5-B359-AC1905B9EB06@gmail.com> From: Hans Petter Selasky Message-ID: <7f14c95d-1ef8-bf82-c469-e6566c3aba66@selasky.org> Date: Mon, 7 Aug 2017 19:57:29 +0200 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:52.0) Gecko/20100101 Thunderbird/52.2.0 MIME-Version: 1.0 In-Reply-To: <0DB9F6FF-8BC9-48F5-B359-AC1905B9EB06@gmail.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 07 Aug 2017 17:59:46 -0000 On 08/07/17 19:19, Ben RUBSON wrote: > >> On 07 Aug 2017, at 18:19, Matt Joras wrote: >> >> On 08/07/2017 09:11, Hans Petter Selasky wrote: >>> Hi, >>> >>> Try to enter "kgdb" and run: >>> >>> thread apply all bt >>> >>> Look for the callout function in question. >>> >>> --HPS >>> >> If you don't have a way to attach kgdb handy you could also break into >> ddb(4) and run "alltrace". Though gdb would be more useful for an >> ongoing session if we need more than the backtrace since you could >> switch to that thread and investigate it directly. >> > > Hi Hans & Matt, > > Thank you for your answers, glad to hear from you :) > > So here is the full kgdb(thread apply all bt) command log : > https://benrubson.github.io/kgdb.log > > We found the faulty thread : > > # procstat -ak | grep "swi4.*tcp" > 12 100029 intr swi4: clock (0) tcp_tw_2msl_scan pfslowtimo softclock_call_cc softclock intr_event_execute_handlers ithread_loop fork_exit fork_trampoline > > # kgdb > (...) > Thread 747 (Thread 100029): > #0 sched_switch (td=0xfffff8000f337500, newtd=0xfffff8010e144000, flags=) at /usr/src/sys/kern/sched_ule.c:1973 > #1 0xfffffe1000f92d80 in ?? () > #2 0xfffffe0f8f74b6e0 in ?? () > #3 0xffffffff810bd274 in handleevents (now=, fake=Error accessing memory address 0xffffffffffffffcc: Bad address. > ) at /usr/src/sys/kern/kern_clocksource.c:223 > Previous frame inner to this frame (corrupt stack?) > (...) > > Of course let me know if you need further info. > Can you try to dump "td": set print pretty on thread 747 frame 0 print *td It might give some more clues. --HPS