[arm-gnu] kernel module debugging
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[arm-gnu] kernel module debugging



Dear sirs,
I'm evaluating Codebench IDE for linux (on ubuntu 11.04) especially to try linux kernel module debugging possibilities. I have a custom desk with at91sam9g20 running linux-2.6.39.1 and
I have read your application notes about linux development and debugging.
Surprisingly I was able to connect the board with jlink and do some stepping even with the settings provided for at91sam7s-ek. When I tried to debug a testing module I was not succesful, breakpoints are not working etc.

add-symbol-file ~/workspace/module_pokus/hello.ko 0xbf000000
add symbol table from file "/home/honza/workspace/module_pokus/hello.ko" at
	.text_addr = 0xbf000000
(y or n) [answered Y; input not from terminal]
Reading symbols from /home/honza/workspace/module_pokus/hello.ko...done.
arm-none-linux-gnueabi-sprite: Got packet: 'mbf000044,4'
arm-none-linux-gnueabi-sprite: Couldn't read from the target memory
arm-none-linux-gnueabi-sprite: Sent response: 'E22'
Error in re-setting breakpoint 1: Cannot access memory at address 0xbf000044

I'm pretty sure that this is caused by wrong settings for the desk, so I wrote my own xml setting file
<board>
    <properties>
        <property name="banked-regs"/>
        <property name="core-family">
            arm9
        </property>
    </properties>
    <memory-map>
        <memory-device address="0x20000000" size="32M" type="ram">
            <description>
                32MB SDRAM
            </description>
        </memory-device>
        <memory-device address="0x00200000" size="16K" type="ram">
            <description>
                SRAM1
            </description>
        </memory-device>
        <memory-device address="0x00300000" size="16K" type="ram">
            <description>
                SRAM2
            </description>
        </memory-device>
    </memory-map>
</board>

Unfortunately using this config file I'm not enable to debug kernel any more - running the debugger halts the board correctly but after resuming eclipse shows No source available for "0xffff0008" and the board is stopped again (see the screenshot in attachment).

Could you please give me any advice how to make kernel modules debugging work?

with best regards
Jan Pohanka

--
Tato zpráva byla vytvořena převratným poštovním klientem Opery: http://www.opera.com/mail/

Attachment: debug_problem.png
Description: PNG image