Hi all,

[quick Q: is there any way to access physical memory locations,
specifically the GPIO registers, from userspace on SA-linux ? mmap(2) or
read(2) from either /dev/mem or /dev/kmem don't seem to work]

As per the subject. insmod on either 2.2.10-rmk2-np11 or 2.2.12-rmk1-np12
gives a very reproducible oops and a solid hang. I tried a home-compiled
insmod as well as the one from RedHat rawhide-arm4l; same results. I tried
the null module below as well as loop.o, dummy.o and ppp-deflate.o; no
change.

Platform:
LART board, SA-1100DA rev 9; 32M memory

Tools:
gcc version egcs-2.91.57 19980901 (egcs-1.1 release)
binutils 2.9.1.0.15

The module that I used:
/*
 * void.c
 * Dummy test driver.
 */

#include <linux/module.h>
#include <linux/init.h>

int __init init_module(void)
{
        printk(KERN_CRIT "Reached init_module.\n");
        return 0;
}

void cleanup_module(void)
{
        printk(KERN_CRIT "Reached cleanup_module.\n");
}

The result:

bash-2.01# insmod -V
insmod version 2.1.121
<snip usage for brevity>
bash-2.01# ./insmod dummy.o

bash-2.01# insmod void.o
Bad mode in prefetch abort handler detected: mode SVC_32
Vectors:
00000000: ef9f0000 ea0000a1 e59ff398 ea000093  ea000086 ea0000a9 ea000078
ea0000a6
00000020: 00000000 00000000 00000000 00000000  00000000 00000000 00000000
00000000
Stubs:
00000200: e59fd1a4 e24ee004 e58de000 e14fe000  e58de004 e3ced03f e38dd093
e169f00d
00000220: e20ee00f e28fd0b4 e79de10e e1b0f00e  e59fd17c e24ee008 e58de000
e14fe000
00000240: e58de004 e3ced03f e38dd093 e169f00d  e20ee00f e28fdf41 e79de10e
e1b0f00e
00000260: e59fd14c e24ee004 e58de000 e14fe000  e58de004 e3ced03f e38dd093
e169f00d
00000280: e21ee00f 059fe114 159fe114 e1b0f00e  e59fd118 e58de000 e14fe000
e58de004
000002a0: e3ced03f e38dd093 e169f00d e20ee00f  e28fd068 e79de10e e1b0f00e
e25ef004
000002c0: eafffffe 00000000 00000000 00000000  00000000 00000000 00000000
00000000
000002e0: c000f5e0 c000f388 c000f388 c000f4a0  c000f388 c000f388 c000f388
c000f388
00000300: c000f388 c000f388 c000f388 c000f388  c000f388 c000f388 c000f388
c000f388
00000320: c000f660 c000f39c c000f39c c000f520  c000f39c c000f39c c000f39c
c000f39c
00000340: c000f39c c000f39c c000f39c c000f39c  c000f39c c000f39c c000f39c
c000f39c
00000360: c000f580 c000f374 c000f374 c000f440  c000f374 c000f374 c000f374
c000f374
00000380: c000f374 c000f374 c000f374 c000f374  c000f374 c000f374 c000f374
c000f374
000003a0: c000f6e0 c000f360 c000f820 c00bf8d0  c00bf8dc c00bf8e8 00000000
00000000
000003c0: 00000000 00000000 00000000 00000000  00000000 00000000 00000000
00000000
000003e0: 00000000 00000000 00000000 00000000  00000000 00000000 00000000
00000000
00000400: 00000000 00000000 00000000 00000000  00000000 00000000 00000000
00000000
00000420: 00000000 00000000 00000000 00000000  00000000 00000000 00000000
00000000
00000440: 00000000 00000000 00000000 00000000  00000000 00000000 00000000
00000000
00000460: 00000000 00000000 00000000 00000000  00000000 00000000 00000000
00000000
00000480: 00000000 00000000 00000000 00000000  00000000 00000000 00000000
00000000
000004a0: 00000000 00000000 00000000 00000000  00000000 00000000


The oops, run through ksymoops:

Options used: -v ../../vmlinux (specified)
              -o ../../modules (specified)
              -K (specified)
              -L (specified)
              -m ../../System.map (specified)
              -c 1 (default)

No modules in ksyms, skipping objects
Reading Oops report from the terminal
Internal error: Oops: 0
CPU: 0
pc : [<c401ca64>]    lr : [<c2800060>]
sp : c1635ed4  ip : c1635f2c  fp : c1635f28
r10: 400fea44  r9 : ffffffea  r8 : c2800048
r7 : c28000c8  r6 : 00000000  r5 : c2800000  r4 : 00000000
r3 : c280004c  r2 : c00f6350  r1 : c00e5000  r0 : c2800088
Flags: NzCv  IRQs on  FIQs on  Mode SVC_32  Segment user
Control: C07B917F  Table: C07B917F  DAC: 00000015
Process insmod (pid: 27, stackpage=c1635000)
Stack:
c1635f00:                            c2800060  c401ca64 a0000013 ffffffff
c1635fb0
c1635f20: c1635f2c c001ff48 c2800058 00000004  c2800048 c1635f3c c2800048
c06e0000
c1635f40: c06e2000 00000048 c00c0e44 c2800048  000000c8 00000000 00000000
00000000
c1635f60: 00000000 00000000 00000000 00000000  00000000 00000000 00000000
00000000
c1635f80: 00000000 00000000 00000000 020113e0  c000f908 00000080 c1634000
c1635ff4
c1635fa0: 00000000 00000000 c1635fb4 c000f760  c001f958 020113e0 020113e0
02017d90
c1635fc0: 00000000 00000000 020113e0 00000002  02000a24 02008260 0200472c
00000000
c1635fe0: 400fea44 bffffe38 02017d90 bffffd40  020046bc 02007ee8 60000010
020113e0
Backtrace:
Function entered at [<c280004c>] from [<c001ff48>]
Function entered at [<c001f94c>] from [<c000f760>]
  r9 = 00000000
  r8 = c1635ff4
  r7 = c1634000
  r6 = 00000080
  r5 = c000f908
  r4 = 020113e0
Code: pc not in code space
Warning, Code line not seen, dumping what data is available

>>EIP: c401ca64 <END_OF_CODE+3f3ace8/????>
Trace: c280004c <END_OF_CODE+271e2d0/????>
Trace: c001ff48 <L0+14/18>
Trace: c001f94c <sys_init_module+0/0>
Trace: c000f760 <fast_syscall_return+0/4>

1 warning issued.  Results may not be reliable.

Any ideas ?

JDB

--
Jan-Derk Bakker, [EMAIL PROTECTED]

The lazy man's proverb:
    'There's no business like slow business !'


unsubscribe: body of `unsubscribe linux-arm' to [EMAIL PROTECTED]

Reply via email to