#1375 closed defect (fixed)

uC5282 BSP rtems_cpu_usage_report/bsp_clock_nanoseconds_since_last_tick reports negative times

Reported by: strauman Owned by: Joel Sherrill
Priority: normal Milestone: 4.9
Component: bsps Version: 4.9
Severity: normal Keywords:
Cc: Blocked By:
Blocking:

Description

The clock driver routine (uC5282 BSP)
'bsp_clock_nanoseconds_since_last_tick()'
is wrong. It computes the time as if the
programmable high-resolution timer (PIT)
was counting up but it is in fact counting
down.

As a consequence, the CPU usage reported
by rtems_cpu_usage_report() is screwed up
on the uC5282 platform.

The attached patch fixes this and also
explains a few details...

Attachments (2)

rtems-uC5282-ns_clock.diff (2.7 KB) - added by strauman on 02/12/09 at 22:05:55.
proposed fix
pr1375.diff (2.7 KB) - added by Joel Sherrill on 03/02/09 at 18:06:11.
Patch to 4.9 and newer

Download all attachments as: .zip

Change History (4)

Changed on 02/12/09 at 22:05:55 by strauman

Attachment: rtems-uC5282-ns_clock.diff added

proposed fix

Changed on 03/02/09 at 18:06:11 by Joel Sherrill

Attachment: pr1375.diff added

Patch to 4.9 and newer

comment:1 Changed on 03/02/09 at 18:06:11 by Joel Sherrill

attachments.isobsolete: 01

comment:2 Changed on 03/02/09 at 18:06:24 by Joel Sherrill

Resolution: fixed
Status: newclosed

Applied to 4.9 and head

Note: See TracTickets for help on using tickets.