Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 10 Jul 2010 21:15:48 +0300
From:      Alexander Motin <mav@FreeBSD.org>
To:        Doug Barton <dougb@FreeBSD.org>
Cc:        svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org
Subject:   Re: svn commit: r209634 - head/sys/x86/isa
Message-ID:  <4C38B8D4.1020804@FreeBSD.org>
In-Reply-To: <4C38B747.9020104@FreeBSD.org>
References:  <201007011851.o61IpI9r054345@svn.freebsd.org> <alpine.BSF.2.00.1007041807230.2565@yncgbc.qbhto.arg> <4C38B747.9020104@FreeBSD.org>

next in thread | previous in thread | raw e-mail | index | archive | help
Hi.

Doug Barton wrote:
> Did you see this message from me? Any hope of getting this fixed?

Yes, sorry. I am just not sure how to properly do it. Two previous
attempts appeared to be wrong: one for ISA PNP, another for ACPI. :(
I'll look on it again tomorrow.

> On 07/04/10 18:10, Doug Barton wrote:
>> This commit results in a panic at boot time for me very early on.
>> Screenshots at:
>> http://people.freebsd.org/~dougb/panic-01.jpg
>> http://people.freebsd.org/~dougb/panic-02.jpg
>> http://people.freebsd.org/~dougb/panic-03.jpg
>>
>> Not sure if it's relevant or not, but after the trace is done I typed
>> 'call reboot()' and it said "panic: privcheck td != curthread"
>>
>> This is on -current, Core 2 Duo, i386, SMP. Updating to the revision
>> immediately before this one is fine, so I'm sure this is the change that
>> is causing the panic.
>>
>>
>> Doug
>>
>>
>> On Thu, 1 Jul 2010, Alexander Motin wrote:
>>
>>> Author: mav
>>> Date: Thu Jul  1 18:51:18 2010
>>> New Revision: 209634
>>> URL: http://svn.freebsd.org/changeset/base/209634
>>>
>>> Log:
>>>  Rework r209456:
>>>  Instead of using fake rid (which ISA doesn't like), delete untrusted
>>>  IRQ resource and let it be recreated.
>>>
>>> Modified:
>>>  head/sys/x86/isa/atrtc.c
>>>  head/sys/x86/isa/clock.c
>>>
>>> Modified: head/sys/x86/isa/atrtc.c
>>> ==============================================================================
>>>
>>> --- head/sys/x86/isa/atrtc.c    Thu Jul  1 17:46:12 2010    (r209633)
>>> +++ head/sys/x86/isa/atrtc.c    Thu Jul  1 18:51:18 2010    (r209634)
>>> @@ -259,7 +259,8 @@ atrtc_attach(device_t dev)
>>>     if (!atrtcclock_disable &&
>>>         (resource_int_value(device_get_name(dev), device_get_unit(dev),
>>>          "clock", &i) != 0 || i != 0)) {
>>> -            sc->intr_rid = -1;
>>> +        sc->intr_rid = 0;
>>> +        bus_delete_resource(dev, SYS_RES_IRQ, sc->intr_rid);
>>>         if (!(sc->intr_res = bus_alloc_resource(dev, SYS_RES_IRQ,
>>>             &sc->intr_rid, 8, 8, 1, RF_ACTIVE))) {
>>>             device_printf(dev,"Can't map interrupt.\n");
>>>
>>> Modified: head/sys/x86/isa/clock.c
>>> ==============================================================================
>>>
>>> --- head/sys/x86/isa/clock.c    Thu Jul  1 17:46:12 2010    (r209633)
>>> +++ head/sys/x86/isa/clock.c    Thu Jul  1 18:51:18 2010    (r209634)
>>> @@ -535,7 +535,8 @@ attimer_attach(device_t dev)
>>>     tc_init(&sc->tc);
>>>     if (resource_int_value(device_get_name(dev), device_get_unit(dev),
>>>         "clock", &i) != 0 || i != 0) {
>>> -            sc->intr_rid = -1;
>>> +            sc->intr_rid = 0;
>>> +        bus_delete_resource(dev, SYS_RES_IRQ, sc->intr_rid);
>>>         if (!(sc->intr_res = bus_alloc_resource(dev, SYS_RES_IRQ,
>>>             &sc->intr_rid, 0, 0, 1, RF_ACTIVE))) {
>>>             device_printf(dev,"Can't map interrupt.\n");
>>>
>>>
>>
> 
> 
> 


-- 
Alexander Motin



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4C38B8D4.1020804>