Hello,
I am attempting to run and debug the the HelloWorld_GCC sample application as described here:
Linux Application Debugging Using DS-5 – DS-5 Development Studio – ARM Developer
The application builds fine,however when I connect to the target in the debugger, Linux is launched in the FVP and the Debug Control window indicates the connection status as "connecting", but then eventually times out and changes to "disconnecting". I see a couple of entries in the final lines of the Telnet session that look suspicious:
INIT: Entering runlevel: 5
Configuring network interfaces... smc91x 1a000000.ethernet: eth0: link up, 10Mbps, half-duplex, lpa 0x0000
done.
Starting Xserver
Starting system message bus: dbus.
Starting Connection Manager
Starting OpenBSD Secure Shell server: sshd
v2m_cfg_write: writing 018023d8 to 00100001
v2m_cfg_write: writing 00000000 to 00700000
Starting rpcbind daemon...rpcbind: cannot create socket for udp6
rpcbind: cannot create socket for tcp6
Starting syslogd/klogd: done
* Starting Avahi mDNS/DNS-SD Daemon: avahi-daemon
...done.
Starting auto-serial-console: done
Last login: Fri Aug 12 21:44:15 UTC 2016 on tty1
root@genericarmv7a:~# v2m_cfg_write: writing 00000000 to 00700000
Questons:
1. Is the socket creation failure for rpcbind a problem or benign?
2. Why is v2m_cfg attempting to write zero bytes, and never returns?
I am running DS-5 Professional v5.24.1 on Windows 10.
Please let me know if you have any suggestions on what the issue may be. If you would like me to post the entire content of the Telnet session, I can do that as well. I am able to manually cd to the /writeable directory from Telnet and run the 'hello' app on the FVP, I just can't connect to it with the debugger via gdb.
Thanks,
Frank
Hello Frank,
Firstly, please accept my apologies for the delay in a response to your query.
Trying the same on a Windows 10 VM, it works ok for me, and I see :
However, I can answer some of your questions :
1) Is the socket creation failure for rpcbind a problem or benign? -> Benign. I see the same error and it still works.
2) Why is v2m_cfg attempting to write zero bytes, and never returns? ->It's actually reporting writing 'value' to 'address', not a length of data.
I believe this is just some stdio output, I can hit return at the cmd prompt and happily enter commands.
So, what do you see in the 'App Console' window ?
Then going back to the models' Linux command prompt, if you type
ps
What processes are listed near the end ?
You should see the gdbserver session started, and then a process for the 'Hello World_GCC' application, something like :
As can be seen, processid (pid) 1136 is the gdbserver session, with pid 1140 is my HelloWorld application itself.
We need to find out what isn't working, could it be the gdbserver itself, or the downloading of the application, or the comms between DS-5 and gdbserver.
So please let me know what you see on your setup.
Stuart
Hi Stuart,
Thanks very much for the reply, and sorry the delay in getting back to you.
To answer your question about what I see in the 'App Console' window, I see:
"Preparing the debug session
Debug session has been started, connecting to gdbserver"
It appears that the issue is connecting to the gdb-server. Below is a screen shot of what I am seeing. Notice that the status in the bottom right indicates "Launching HelloWorld...FVP: (99%)" and stays at 99% forever until I exit. Also, the Debug Control and Commands windows seem to imply a issue with disconnecting from the gdb-server.
As you suggested, I ran 'ps' at the Telnet console, and I do see that both the gdb-server and HelloWorld_GCC processes are running:
Since I am able to see 'HelloWorld_GCC' in the /writeable directory, and the process is running, I assume that this implies that there are no issues with downloading and executing the file to the target?
Any help you can provide would be greatly appreciated. If it would help to expedite the exchange, I can call you to discuss this in more detail. Please let me know as I will be traveling next week and need to get this working before then.
Regards,
I thought it might also be helpful for me to show the Connection tab for the Debug Configuration. Let me know if you see anything that does not look correct.
I saw that DS-5 v5.25.0 was available, so I installed it to see if that would yield different results, but unfortunately no.
One screen shot I have not included yet is of the Linux desktop running on the FVP. That seems to run fine, and I am able to open a terminal session and execute HelloWorld_GCC.
Hi Frankc,
Sorry about the delay, I have been out of the office.
We think there's a networking issue that is preventing the gdbserver <-> gdb comms being set up correctly.
I need to check a few things with some of my colleagues first to clarify my understanding on this.
I shall be in touch.