Re: panic: mutex pmap not owned at ... efirt_machdep.c:255

From: Kyle Evans <kevans_at_freebsd.org>
Date: Mon, 6 Aug 2018 13:27:04 -0500
On Sun, Aug 5, 2018 at 5:43 AM, Konstantin Belousov <kostikbel_at_gmail.com> wrote:
> On Sat, Aug 04, 2018 at 09:46:39PM -0500, Kyle Evans wrote:
>>
>> He now gets a little further, but ends up with the same panic due to
>> efirtc_probe trying to get time to verify the rtc's actually
>> implemented. What kind of approach must we take to ensure curcpu is
>> synced?
>
> It does not panic for me, when I load efirt.ko from the loader prompt.
> Anyway, try this

Right, I also don't get a panic on any of my machines from this.
Hopefully he'll have a chance to try this soon.

> diff --git a/sys/amd64/amd64/pmap.c b/sys/amd64/amd64/pmap.c
> index 572b2197453..f84f56b98e2 100644
> --- a/sys/amd64/amd64/pmap.c
> +++ b/sys/amd64/amd64/pmap.c
> _at__at_ -2655,7 +2655,7 _at__at_ pmap_pinit0(pmap_t pmap)
>                         __pcpu[i].pc_ucr3 = PMAP_NO_CR3;
>                 }
>         }
> -       PCPU_SET(curpmap, kernel_pmap);
> +       PCPU_SET(curpmap, pmap);
>         pmap_activate(curthread);
>         CPU_FILL(&kernel_pmap->pm_active);
>  }
Received on Mon Aug 06 2018 - 16:27:27 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:41:17 UTC