This is the mail archive of the ecos-bugs@sourceware.org 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]
Other format: [Raw text]

[Bug 1001475] New: Generic 16x5x driver do not clear overrun errorat boot


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

           Summary: Generic 16x5x driver do not clear overrun error at
                    boot
           Product: eCos
           Version: CVS
          Platform: All
        OS/Version: Other
            Status: UNCONFIRMED
          Severity: normal
          Priority: low
         Component: Serial
        AssignedTo: unassigned@bugs.ecos.sourceware.org
        ReportedBy: bernard.fouche@kuantic.com
                CC: ecos-bugs@ecos.sourceware.org
             Class: Advice Request


Created an attachment (id=1552)
 --> (http://bugs.ecos.sourceware.org/attachment.cgi?id=1552)
always read a byte when clearing FIFO

(Original problem and fix proposal were made incorrectly in bug #1001392.)

When the driver runs its config_port() routine the first time, it clears the
FIFOs. However it does not clear the Overrun Error situation.

The side effect is, if an overrun condition exists prior to running
config_port(), the driver will loop forever in the DSR: the DSR code, when
considering RxTO, reads RHR only if there is at least a byte reported in the
FIFO.

But config_port() cleared the FIFO, so no byte is available there, so there is
no read from RHR, the overrun error condition continues, DSR loops forever at
boot time and the system is stuck.

Typical use case:

- a data logger always producing information is connected on a serial port.
- the system is being debugged with OpenOCD, and 'soft_reset_halt' is used:
there is no hardware reset done, so the serial controller always runs, even if
config_port() wasn't fired yet.

The patch is more than minimal, it can't break anything and it handles this
weird error case.

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


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