public inbox for ecos-discuss@sourceware.org
 help / color / mirror / Atom feed
From: Andrew Lunn <andrew@lunn.ch>
To: Alok Singh <aloks@broadcom.com>
Cc: ecos-discuss@ecos.sourceware.org
Subject: Re: [ECOS]  Stack Trace and running task when exception occurs -
Date: Sun, 09 Sep 2007 16:37:00 -0000	[thread overview]
Message-ID: <20070909163655.GC3557@lunn.ch> (raw)
In-Reply-To: <FE7FB54DCB7C6949A1D3F9FF22DA6C13848657@lvl7in-mail01.lvl7.com>

On Sun, Sep 09, 2007 at 04:32:10PM +0530, Alok Singh wrote:
> 
> Hi,
> 

> Does eCos provides the details of the task that was running when
> exception occurred? I think I know that it doesn't, but just wanted
> to get your views?? Or is there a way to get this information
> without altering (enhancing) the current eCos code.

It depends on what details you want. cyg_thread_self() will tell you
the current thread. However, be careful, it could of been an ISR/DSR
that caused the exception, not the thread. 

If you have a hardware exception, eg /0, sigfault etc, the info
parameter passed to the exception handler may be the saved
registers. This is architecture dependent. eg look at
packages/hal/arm/arch/current/src/hal_misc.c lines 136-158 and follow
the code patch though into your exception handler.

    Andrew


-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

  reply	other threads:[~2007-09-09 16:37 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-09-09 11:02 Alok Singh
2007-09-09 16:37 ` Andrew Lunn [this message]
2007-09-09 20:18   ` Sergei Gavrikov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20070909163655.GC3557@lunn.ch \
    --to=andrew@lunn.ch \
    --cc=aloks@broadcom.com \
    --cc=ecos-discuss@ecos.sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).