[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[lwip-users] [lwip users] using threads in our application safely ???
From: |
Durgaprasad Chivukula |
Subject: |
[lwip-users] [lwip users] using threads in our application safely ??? |
Date: |
Mon, 10 Oct 2005 11:34:25 +0200 |
Hi Friends ,
I already posted lot of questions to this group regarding my tftp client implementation of lwip , but I did not get any replies .I also posted my source code implementation , but the same. I hope you can guide me with my probelm this time . As I said I am writing a tftp client application on lwip using the socket API ,tapif interface (using bridge configuration ) on Redhat linux
2.4.20-8 . I need to put and get files from/ to a remote server. But both put and get are not working.While getting I am only getting first 512 bytes and then tapif_input function halts I am creating only 1 thread in my application and I guess this is making problems , How can I use thread mechanism safely in my application ??? I am herewith attaching my implementation to this email , please have a look and suggest me in this ...Help!!!!!!!
Also one more thing is I profile my whole stack using gprof /Functioncheck (profiling tools on linux ) as a part of my work , these tools are giving erroneous(wrong) results for example sys_arch_sem_wait is called 744 times , sys_sem_signal is called 699 times ...and so on.... do u guys really think that these functions are called this many number of times.... I run my application and then run the tool , so it is a dynamic execution profiler.....I guess there is a problem with my thread implementation....
Please find below attached source code of my tftp client....in a zip file ... the important parts of the code to look at are
1. main_changed.c (main function , main_thread function , setpeer , get ,put
2. tftp_changed.c (tftp_sendfile , tftp_recvfile)
3.tftpsubs_changed.c (which implements the buffer mechanism )
Please help me!!!!!
Regards
Durga
TFTP_client.zip
Description: Zip archive