public inbox for ecos-bugs@sourceware.org
help / color / mirror / Atom feed
From: bugzilla-daemon@bugs.ecos.sourceware.org
To: unassigned@bugs.ecos.sourceware.org
Subject: [Bug 1001387] Kinetis Interrupt vector enumeration incorrect
Date: Wed, 16 Nov 2011 20:44:00 -0000	[thread overview]
Message-ID: <20111116204359.2339D2F78001@mail.ecoscentric.com> (raw)
In-Reply-To: <bug-1001387-777@http.bugs.ecos.sourceware.org/>

Please do not reply to this email. Use the web interface provided at:
http://bugs.ecos.sourceware.org/show_bug.cgi?id=1001387

--- Comment #1 from Ilija Kocho <ilijak@siva.com.mk> 2011-11-16 20:43:55 GMT ---
(In reply to comment #0)
> In the Kinetis port (using TWRK60N512), the enum KinetisExtInterrupt_e, and
> consequently the vectors returned by CYGHWR_HAL_KINETIS_PIN_IRQ_VECTOR() seem
> incorrect; for example, for PORTA returned value is 88, but should be 103. I
> suspect this is because the platform does not define
> CYGNUM_HAL_INTERRUPT_SYS_TICK and CYGNUM_HAL_INTERRUPT_EXTERNAL; the fallback
> arm values for these are 0 and 1 respectively, while the Kinetis values should
> be 15 and 16 respectively.

Tomas

It's a matter of different enumerations:

In Freescale's headers, the interrupt (and exception) numbers simply begin from
0 (including Stack Pointer reset value).

ARM CMSIS standard begins counting from -14 (NMI) that places SysTick at -1 and
makes External Interrupts start at 0.

eCos has separate enumerations for system exceptions and interrupt vectors (see
hal/cortexm/arch/<version>/include/hal_intr.h). In the same file you will find
definitions for CYGNUM_HAL_INTERRUPT_SYS_TICK (0) and
CYGNUM_HAL_INTERRUPT_EXTERNAL (1), hence External Interrupt enumeration starts
from 1.

Speaking of Kinetis interrupt enumeration one additional clarification just
FAOD. /Reserved/ interrupts remain with their original names i.e.
.._Reserved108 follows .._PORTE in order to maintain correspondence with
Freescale's names. Simply regard them as names not numbers. With the time, some
of them, as new devices appear, may be assigned by Freescale to new
peripherals. Even the present list is an union of two devices: K60 and K40.

Ilija

-- 
Configure bugmail: http://bugs.ecos.sourceware.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.


  reply	other threads:[~2011-11-16 20:44 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-11-16 14:46 [Bug 1001387] New: " bugzilla-daemon
2011-11-16 20:44 ` bugzilla-daemon [this message]
2011-11-17 17:56 ` [Bug 1001387] " bugzilla-daemon
  -- strict thread matches above, loose matches on Subject: below --
2011-11-16 14:46 [Bug 1001387] New: " bugzilla-daemon
2011-11-16 20:44 ` [Bug 1001387] " bugzilla-daemon
2011-11-17 17:56 ` bugzilla-daemon

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=20111116204359.2339D2F78001@mail.ecoscentric.com \
    --to=bugzilla-daemon@bugs.ecos.sourceware.org \
    --cc=unassigned@bugs.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).