Dear Roberts,
Thank you, for your effective replies to my questions.
I replaced the [.config] file with [a10Core-kernel-3.0.42.config] and make the uImage successfully and then boot the TC linux from uSD with it.
Also I make a new script.bin for GPIO support (but not for SPI because I don't know how to do it).
Now GPIO attached and work correctly, but when I reboot Marsboard the GPIO disappear!
How can I establish the GPIO for ever ?
I tested the modprobe but It did not have any permanent effect after insmod (and before insmod it make "not found in modules.dep" error).
Also when I run insmod command for spi_sunxi.ko, I get the following error:
root@box:~# insmod /mnt/mmcblk0p2/My_Added_Modules/lib/modules/3.0.42/kernel/drivers/spi/spi_sunxi.ko
Segmentation fault
The dmesg command report the following error:
:
:
[ 1768.180000] [spi]: sw spi init !!
[ 1768.180000] [spi]: Found 0 spi devices in config files
[ 1768.190000] [spi]: boards num modalias max_spd_hz bus_num cs mode
[ 1768.200000] Unable to handle kernel NULL pointer dereference at virtual address 00000000
[ 1768.210000] pgd = e7298000
[ 1768.210000] [00000000] *pgd=672e8831, *pte=00000000, *ppte=00000000
[ 1768.220000] Internal error: Oops: 80000007 [#1] PREEMPT
[ 1768.220000] Modules linked in: spi_sunxi(+)
[ 1768.220000] CPU: 0 Not tainted (3.0.42 #6)
[ 1768.220000] PC is at 0x0
[ 1768.220000] LR is at spi_sunxi_register_spidev+0x1e4/0x2a4 [spi_sunxi]
[ 1768.220000] pc : [<00000000>] lr : [<bf009c34>] psr: 60000013
[ 1768.220000] sp : e72e3e08 ip : e72e3c88 fp : e72e3e5c
[ 1768.220000] r10: c0097754 r9 : 000008ab r8 : 00000000
[ 1768.220000] r7 : bf00b124 r6 : 00000000 r5 : 00000000 r4 : 00000004
[ 1768.220000] r3 : 00000002 r2 : e72e2000 r1 : 00000000 r0 : 00000000
[ 1768.220000] Flags: nZCv IRQs on FIQs on Mode SVC_32 ISA ARM Segment user
[ 1768.220000] Control: 10c5387d Table: 67298019 DAC: 00000015
:
:
[ 1768.220000] Backtrace:
[ 1768.220000] [<bf009a50>] (spi_sunxi_register_spidev+0x0/0x2a4 [spi_sunxi]) from [<bf00d728>] (spi_sunxi_init+0xb0/0x174 [spi_sunxi])
[ 1768.220000] r7:e48fd500 r6:00000000 r5:e72e3e64 r4:00000004
[ 1768.220000] [<bf00d678>] (spi_sunxi_init+0x0/0x174 [spi_sunxi]) from [<c003539c>] (do_one_initcall+0x40/0x184)
[ 1768.220000] r6:00000000 r5:e72e2000 r4:c07e7c00
[ 1768.220000] [<c003535c>] (do_one_initcall+0x0/0x184) from [<c0098bec>] (sys_init_module+0x3c8/0x1ad0)
[ 1768.220000] [<c0098824>] (sys_init_module+0x0/0x1ad0) from [<c003ba80>] (ret_fast_syscall+0x0/0x30)
[ 1768.220000] Code: bad PC value
[ 1768.730000] ---[ end trace fa9e0a8b1d7a4898 ]---
Please help me about the above error.
Thank you again.