[RTEMS Project] #3002: Incorrect bit reference in ARM GIC

RTEMS trac trac at rtems.org
Thu Apr 20 11:47:46 UTC 2017


#3002: Incorrect bit reference in ARM GIC
---------------------+-----------------------------
 Reporter:  munster  |      Owner:  joel.sherrill@…
     Type:  defect   |     Status:  new
 Priority:  normal   |  Milestone:  4.12
Component:  bsps     |    Version:  4.12
 Severity:  normal   |   Keywords:  ARM,GIC
---------------------+-----------------------------
 Incorrect bit reference in /c/src/lib/libbsp/arm/shared/include/arm-gic.h,
 line 46.
 The macro GIC_ID_TO_TWO_BITS_REG_OFFSET supposed to convert interrupt ID
 to an index of a **two-bit** field in a register.
 The correct way is:
 {{{
 #define GIC_ID_TO_TWO_BITS_REG_OFFSET(id) (((id) & 0xfU) << 1)
 }}}

--
Ticket URL: <http://devel.rtems.org/ticket/3002>
RTEMS Project <http://www.rtems.org/>
RTEMS Project


More information about the bugs mailing list