Current-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Panic on acorn32 current

On 04/03/2018 17:09, Mike Pumford wrote:
Finally had some time to bring my system up to date and found a problem.

Got a panic at start of day (transcribed from a shot of the screen):
fdc0 at pioc0 offset 0x3f0-0x3f7 irq12 drq 0x00002000

uvmfault(0xf036f42c, 217000, 2) -> e
Fatal kernel mode ata abort: 'Translation Fault (P)'
trapframe: 0xf03ccc40
FSR=183bd007, FAR=002170ef, spsr=20000093
r0 =002170ef, r1 =f02f2a65, r2 =0000000d, r3 =00217047
r4 =08000013, r5 =00000066, r6 =f02f2a65, r7 =f0351190
r8 =f02f2a64, r9 =00000005, r10=f02f2a64, r11=f04cccc0
r12=f03ccccc, ssp=f04ccc94, slr=f0027288, pc =f02d90d8

Stopped in pid 0.1 (system) at netbsd:strlcpy+0x30:strb r5, [r0], #001
0xf03cccc8: netbsd:irq_claim+0xc
0xf03cccf0: netbsd:intr_claim+0x58
0xf03ccd28: netbsd:fdcattach+0xc0

Tracking it back it was introduced quite a while back (rev 1.13) of the file which made the section of the file containg the irq description strings read only (but the irq_claim code writes them).

The following patch fixes this issue and also corrects another bug that causes the interrupt names to get corrupted in systat. The legacy irq counter code expects all the irq names to be the same length and this patch restores that behaviour.

This needs a pullup to 8.0 (which has exactly the same bug). 7.1 is also impacted but I've not actually run the patch there. With this patch applied current and 8.0-BETA actually boot up and work pretty much the same as the previous rather ancient 6.99.40 kernel it was running before and there doesn't appear to be any obvious performance drop with the new code.

Take back the performance comment. Something is monumentally wrong with the 8.0-BETA ps. It takes ages to run:

For comparison:
# file /bin/ps
/bin/ps: ELF 32-bit LSB executable, ARM, version 1, dynamically linked (uses shared libs), for NetBSD 6.99.40, compiled for: arm, not stripped
# time ps>/dev/null
        0.22 real         0.02 user         0.18 sys

And in a chroot with the 8.0-BETA userland:

# file /bin/ps
/bin/ps: ELF 32-bit LSB shared object, ARM, version 1 (ARM), dynamically linked, interpreter /libexec/ld.elf_so, for NetBSD 8.0, compiled for: arm, not stripped
# time ps >/dev/null
        8.19 real         1.25 user         6.62 sys

I'd guess the bug is in the libraries as running the 8.0 ps with the 6.99.40 libraries performs at the same speed as the native 6.99.40 binary.


I've spotted some other issues:
1. Slight misdetect of the NE2000 derived ethernet chip
2. Hangs when attempt is made to reboot.
3. Bad behaviour in ddb.

I've run into these before and I've got some rather hacky fixes. Once they are cleaned up I'll send out another message with patches for those as well.


Home | Main Index | Thread Index | Old Index