I wrote kernel module under rtl 1.1 (kernel
2.0.36), communicating with my linux programs using
shared memory (above 63MB - Pentium 200 MMX
total memory 64MB ).
shm_struct *shm_ptr;
shm_struct *shm_ptr_tab[10];
shm_ptr = (shm_struct *)
BASE_ADDR; where BASE_ADDR = 63*0x100000
shm_ptr_tab[idx] = (shm_struct *)
BASE_ADDR+4096+idx*4096;
and it worked fine.
Now I'm trying the same module under beta4 (G)
(kernel 2.2.9)(above 127MB - Pentium II total memory 128MB ),
and if I using above form I have segmentation fault after first try to set an
element of my structures.
After that I modified assigment:
shm_ptr = (shm_struct *) ioremap( BASE_ADDR,
sizeof( shm_struct ) )
and now I can insmod but when I trying to
rmmod my system hangs (probably on iounmap function).
Do You have any idea WHY ????
Best regards
Krzysztof Perkowski