This is the mail archive of the ecos-discuss@sources.redhat.com mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: help in tcp/ip stack !!!


Hi, Jonathan:
I trace it , and find a strange thing .
Before the memory exception happen , there are not any threads in the thread
queue ,system is runing  a thread which not exist . I trace the variable
"queue_map", and find :
     before that , system put idle thread  to sleep and give zero to
"queue_map", and make NONE thread in the
     running  queue .
At that time , I just connected one tcp to ecos , and the function
cyg_thread_delete hadn't run,ecos application is just doing write(),send
something through tcp . So I'm sure that the exception is not caused by the
application .

I think you maybe met this before , when you disigned ecos . because there
are many assertions about queue_map in the source code of mlqueue.cxx.
Can you give me some advice .It 's very important to me.
thinks.
Best regard .

----- Original Message -----
From: "Jonathan Larmour" <jlarmour@redhat.com>
To: "wangwei" <wangw@start.com.cn>
Cc: <ecos-discuss@sources.redhat.com>
Sent: Wednesday, June 06, 2001 9:45 PM
Subject: Re: [ECOS] help in tcp/ip stack !!!


> wangwei wrote:
> >
> > Thank you ,Jonathan:
> >
> > I try the method you told me, but the except still happened ,
> > and sometimes I got the error of  "out of mbuf" .
> > I suspect when many client connected the server,it will write much data
> > by tcp , and it will occupy too much mbuf , and cause "exh 4" when the
> > mbuffer is exhausted .
>
> It looks like you'll have to track down where the exception happened. You
> should probably be able to install a signal handler for the exception in
> question (likely a SEGV or BUS). If you look at the sival_ptr of the
> siginfo_t, that will contain a pointer to the registers, in
> Hal_SavedRegisters format. Or set a breakpoint on
> cyg_posix_exception_handler and look at the exception_info argument which
> is also a pointer to Hal_SavedRegisters.
>
> From that you can determine the PC and possibly also what happened.
>
> Jifl
> --
> Red Hat, Rustat House, Clifton Road, Cambridge, UK. Tel: +44 (1223) 271062
> Maybe this world is another planet's Hell -Aldous Huxley || Opinions==mine
> Come to the Red Hat TechWorld open source conference in Brussels!
> Keynotes, techie talks and exhibitions    http://www.redhat-techworld.com/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]