From owner-freebsd-mips@freebsd.org Tue Mar 6 20:15:08 2018 Return-Path: Delivered-To: freebsd-mips@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 58972F2B0C8 for ; Tue, 6 Mar 2018 20:15:08 +0000 (UTC) (envelope-from juli@northcloak.com) Received: from mail-qt0-x22e.google.com (mail-qt0-x22e.google.com [IPv6:2607:f8b0:400d:c0d::22e]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 001136856B for ; Tue, 6 Mar 2018 20:15:07 +0000 (UTC) (envelope-from juli@northcloak.com) Received: by mail-qt0-x22e.google.com with SMTP id c7so26100273qtn.3 for ; Tue, 06 Mar 2018 12:15:07 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=northcloak-com.20150623.gappssmtp.com; s=20150623; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=5xLhy7G5E8Ly6BTOx6DG1R14A0mvhodkDZsFxEc+lJE=; b=Mq/2py2crzOwjics2DEsHSQ9tKrJjZh5qShHI0BZUBb7VK52a+4mlSFSSXXTwdj5fr 2jz0oELF3DyiwPECkp0nuHZdnJyXQwWz2X2/Mr0EDhpLMT+TRYTIQ+H2nUDED+1CuoHG iLDVY0wdGRo7cPLsD9ll4w1wdKL7O+yjhfhFWeEJ0GA1cHKnVMTpBd0ZnUwehYpoYzjx /6rz+h7mCGoS4GoNuEJ0O+OpKx8chpq9v+3sayOedLRqCjUe3jsx0r04PSopUc1FpGb0 y4YhEBqU2cN1LqJfMvXBmuhiYudNrtrbj4y/CknflpmEeDyrlzpqX43Sx5ACWcZUKsnv meSQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=5xLhy7G5E8Ly6BTOx6DG1R14A0mvhodkDZsFxEc+lJE=; b=qxhb0rK33g7MjCF/ktXbaYOCCuiWISbgGs5kKnXqa6+H9xPKzdm5/LegSjnlEBw4EQ 8u4vwhHYYGvtN0HgLSfOABxV1W9t7hcgQMQDgJOavpk6bUg2BWU4jahSzERGHTE4kbOF wdtr2+lQmLavVSRdELDyYSNmiO2N6OuPmWnH2MI70HnkUl9csM2fbwCYpOe3QlzQMWwT ECBuOj9CGeRZ8zWVwDigqe08S4ZOSvPO0ihgJAphJDMeitZ5AAmA1nbUfpXTN3DCOyFa h60iKKO8hnSfbvjWXMChS0mTo1IUI6WRX8HSPNegR1xlAVf1wk6LMkfsw9ZwnI+47srN Sj9A== X-Gm-Message-State: AElRT7G5dfEC5XyO3UKEJoMHof6HP6kURLL3iBm072sCPt9NSxNYWren fsR2X5vnX9rLz1Oiq4yxgZe3J5GWqy2kpMByoB77bg== X-Google-Smtp-Source: AG47ELsiPhTr07lLA+AruZ0Xgs/cOTClxPv4Z9H+5QEO84cKC6Hc2mf9VmZh0h4iZIMwQbs6BZQglvnYd60hgPSIgKA= X-Received: by 10.200.51.168 with SMTP id c37mr30555545qtb.90.1520367307469; Tue, 06 Mar 2018 12:15:07 -0800 (PST) MIME-Version: 1.0 Received: by 10.200.4.42 with HTTP; Tue, 6 Mar 2018 12:14:27 -0800 (PST) In-Reply-To: <1949943.3JoNfSzP6x@ralph.baldwin.cx> References: <20180305211635.GA21623@lyxys.ka.sub.org> <5A9DEE9E.6050906@grosbein.net> <5A9DF0D6.7090306@grosbein.net> <1949943.3JoNfSzP6x@ralph.baldwin.cx> From: Juli Mallett Date: Tue, 6 Mar 2018 12:14:27 -0800 Message-ID: Subject: Re: ELF - panic on installworld To: John Baldwin Cc: freebsd-mips@freebsd.org Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.25 X-BeenThere: freebsd-mips@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: Porting FreeBSD to MIPS List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 06 Mar 2018 20:15:08 -0000 On 6 March 2018 at 10:29, John Baldwin wrote: > On Tuesday, March 06, 2018 08:37:26 AM Eugene Grosbein wrote: > > 06.03.2018 8:27, Eugene Grosbein wrote: > > > > > 06.03.2018 4:16, Wolfgang Zenker wrote: > > > > >> I'm trying to run installworld using 11-STABLE on an Ubiquity Edge > > >> Router Lite (mips64, 2 cores, 512 MB Ram). Unfortunately I haven't > > >> managed to finish the installworld yet, I always get a > > >> panic: kernel stack overflow - trapframe at 0xffffffff80917eb0 > > >> in slightly different places during the installworld. Of the 4 panics > I > > >> have seen on the serial console, 3 had the trapframe at > 0xffffffff80917eb0 > > >> and one at 0xffffffff80915eb0 > > >> /usr/src and /usr/obj are nfs-mounted, and I have configured almost 2 > GB > > >> of swap. The build was done in a Qemu environment. > > >> > > >> Any hints how to proceed from here? > > > > > > Try increasing kernel stack size from default 2 pages to 4 by > rebuilding > > > the kernel with options KSTACK_PAGES=4 > > > > Note also, that depending on your network configuration, KSTACK_PAGES=4 > > may or may not be enough. If it does not help, you need to double it > once more. > > KSTACK_PAGES doesn't work on MIPS because the MIPS kstack has to be > hardwired > into the TLB and the code that does that assumes a hardcoded stack size. > That said, we could easily use a more flexible wired TLB entry scheme, including smartly using pagemask in the cases where the number of pages is suitable. If we wanted to allow wiring of mappings into the TLB flexibly at runtime we could do that, or we could just at compile-time have different code to handle different KSTACK_PAGES values. People have strong feelings about some of those options, but if there's a workload-oriented pressure to move in a different direction, it should be very easy to do. Juli.