Please do not use HTML for email. On Mon, Mar 07, 2005 at 01:30:02PM -0000, jhoney jhoney wrote: > I am calling socket function (sock_*) from the kernel. In my work no > application is being run, everything should be done from the kernel > only. The actual application runs on other boad and communicates with > the pci add-on card which runs linux and I have to make use of the > TCP/IP stack.To test this I have written one server programe which is > running from the kernel. Any particular reason why you are running servers in the kernel? > I faced the following problem. when I connected more than two clients > from other machine to the server progarm, it is getting hanged, I > guess it is due to the accept() function. > > But in actual application program, the process is going to block > until the accept returns. Since I do not have any application, how to > simulate this. > > I had one plan of using kernel threads for accept. will it be > appropriate? > > Can I create process from the kernel so that for each connection , > process is going to block when accept is called . You can solve a lot of your problems by not running applications in the kernel in the first place. There is zero speed to be gained from running in kernel, and most of the time it is much harder: every programming mistake is lethal for the system. Erik -- Erik Mouw J.A.K.Mouw@xxxxxxxxxxxxxx mouw@xxxxxxxxxxxx
Attachment:
signature.asc
Description: Digital signature