Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 20 Sep 2004 22:46:03 +0400
From:      Roman Kurakin <rik@cronyx.ru>
To:        FreeBSD Current <freebsd-current@freebsd.org>
Cc:        Nate Lawson <nate@root.org>
Subject:   mp_machdep.c (was Re: [Fwd: Re: Bug reports requested - acpi])
Message-ID:  <414F256B.1030304@cronyx.ru>
In-Reply-To: <414E7581.2070505@root.org>
References:  <41421D6A.8070805@cronyx.ru> <414CB97C.7030606@cronyx.ru> <414E7581.2070505@root.org>

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

    I have problem with one of my SMP systems (see end of letter).
It looks that following patch:

Index: mp_machdep.c
===================================================================
RCS file: /home/ncvs/src/sys/i386/i386/mp_machdep.c,v
retrieving revision 1.238
diff -u -r1.238 mp_machdep.c
--- mp_machdep.c        1 Sep 2004 06:42:01 -0000       1.238
+++ mp_machdep.c        20 Sep 2004 18:20:49 -0000
@@ -747,6 +747,11 @@
        POSTCODE(INSTALL_AP_TRAMP_POST);

        pmap_kenter(boot_address + KERNBASE, boot_address);
+#ifdef I386_CPU
+       invltlb();
+#else
+       invlpg((u_int)dst);
+#endif
        for (x = 0; x < size; ++x)
                *dst++ = *src++;

solves the problem. I'll check it on not very recent hacked current.
So this is initial request. I'll check it with current current without my
hacks to double check that this works always and inform if this helps.

    The intent of this letter to ask community if this workaround for my
problem or real bug fix. If this is only workaround please let me know
and I'll continue to dig with version I currently use.
(I don't like workarounds)

Best regards,
                      Roman Kurakin

[...]

>>
>> Roman Kurakin:
>>
>>> GDB: no debug ports present
>>> KDB: debugger backends: ddb
>>> KDB: current backend: ddb
>>> SMAP type=01 base=0000000000000000 len=000000000009fc00
>>> SMAP type=01 base=000000000009fc00 len=0000000000000400
>>> SMAP type=02 base=00000000000f0000 len=0000000000010000
>>> SMAP type=02 base=00000000fec00000 len=0000000000001000
>>> SMAP type=02 base=00000000fee00000 len=0000000000001000
>>> SMAP type=02 base=00000000ffff0000 len=0000000000010000
>>> SMAP type=01 base=0000000000100000 len=0000000007ef0000
>>> SMAP type=03 base=0000000007ff3000 len=000000000000d000
>>> SMAP type=04 base=0000000007ff0000 len=0000000000003000
>>> Copyright (c) 1992-2004 The FreeBSD Project.
>>> Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 
>>> 1994
>>>        The Regents of the University of California. All rights 
>>> reserved.
>>> FreeBSD 6.0-CURRENT #0: Wed Sep  8 18:38:21 MSD 2004
>>>    
>>> root@devel12.cronyx.ru:/home/rik/Develop/FreeBSD/obj/home/rik/Develop/FreeBS 
>>>
>>> D/src/sys/GENERIC
>>> WARNING: WITNESS option enabled, expect reduced performance.
>>> Preloaded elf kernel "/boot/kernel/kernel" at 0xc0a29000.
>>> Preloaded elf module "/boot/kernel/acpi.ko" at 0xc0a29250.
>>> Calibrating clock(s) ... i8254 clock: 1193142 Hz
>>> CLK_USE_I8254_CALIBRATION not specified - using default frequency
>>> Timecounter "i8254" frequency 1193182 Hz quality 0
>>> Calibrating TSC clock ... TSC clock: 232752120 Hz
>>> CPU: Pentium II/Pentium II Xeon/Celeron (232.75-MHz 686-class CPU)
>>>  Origin = "GenuineIntel"  Id = 0x634  Stepping = 4
>>>  
>>> Features=0x80fbff<FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMO 
>>>
>>> V,MMX>
>>> real memory  = 134152192 (127 MB)
>>> Physical memory chunk(s):
>>> 0x0000000000001000 - 0x000000000009efff, 647168 bytes (158 pages)
>>> 0x0000000000100000 - 0x00000000003fffff, 3145728 bytes (768 pages)
>>> 0x0000000000c29000 - 0x0000000007d7ffff, 118845440 bytes (29015 pages)
>>> avail memory = 121626624 (115 MB)
>>> Table 'FACP' at 0x7ff3040
>>> Table 'APIC' at 0x7ff5440
>>> MADT: Found table at 0x7ff5440
>>> MP Configuration Table version 1.1 found at 0xc00f1400
>>> APIC: Using the MADT enumerator.
>>> MADT: Found CPU APIC ID 0 ACPI ID 0: enabled
>>> SMP: Added CPU 0 (AP)
>>> MADT: Found CPU APIC ID 1 ACPI ID 1: enabled
>>> SMP: Added CPU 1 (AP)
>>> ACPI APIC Table: <GBT    >
>>> kernel trap 12 with interrupts disabled
>>>
>>>
>>> Fatal trap 12: page fault while in kernel mode
>>> cpuid = 0; apic id = 00
>>> fault virtual address   = 0x0
>>> fault code              = supervisor read, page not present
>>> instruction pointer     = 0x8:0xc05f7930
>>> stack pointer           = 0x10:0xc0c21b6c
>>> frame pointer           = 0x10:0xc0c21b78
>>> code segment            = base 0x0, limit 0xfffff, type 0x1b
>>>                        = DPL 0, pres 1, def32 1, gran 1
>>> processor eflags        = interrupt enabled, resume, IOPL = 0
>>> current process         = 0 ()
>>> [thread 0]
>>> Stopped at      _mtx_lock_flags+0x34:   cmpl    $0xc084dedc,0(%ebx)
>>> db> tr
>>> _mtx_lock_flags(0,0,c0808d71,127,c08b33c0,0,c0808d71,126) at 
>>> _mtx_lock_flags+0x3
>>> 4
>>> vm_fault(c103a000,c009f000,2,0,c08af7a0) at vm_fault+0x216
>>> trap_pfault(c0c21cd8,0,c009f000) at trap_pfault+0x13b
>>> trap(c07e0018,10,c0900010,18e,c088f7a1) at trap+0x335
>>> calltrap() at calltrap+0x5
>>> --- trap 0xc, eip = 0xc077f293, esp = 0xc0c21d18, ebp = 0xc0c21d24 ---
>>> install_ap_tramp(c0905ee0,c07f42a0,0,1,c0c21d6c) at 
>>> install_ap_tramp+0x43
>>> start_all_aps(c0c21d84,c061b63f,c08b90a0,c07f3c13,0) at 
>>> start_all_aps+0x2f
>>> cpu_mp_start(c08b90a0,c07f3c13,0,1,c0c21d98) at cpu_mp_start+0x13b
>>> mp_start(0,c1ec00,c1e000,0,c043f465) at mp_start+0x47
>>> mi_startup() at mi_startup+0x96
>>> begin() at begin+0x2c
>>> db> show locks
>>> exclusive sleep mutex system map r = 0 (0xc103a084) locked @ 
>>> /home/rik/Develop/F
>>> reeBSD/src/sys/vm/vm_map.c:2994
>>> exclusive sleep mutex Giant r = 1 (0xc08b33c0) locked @ 
>>> /home/rik/Develop/FreeBS
>>> D/src/sys/vm/vm_fault.c:294
>>> db>
>>
>
>





Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?414F256B.1030304>