<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd">
<html lang="en" style="--code-editor-font: var(--default-mono-font, "GitLab Mono"), JetBrains Mono, Menlo, DejaVu Sans Mono, Liberation Mono, Consolas, Ubuntu Mono, Courier New, andale mono, lucida console, monospace;">
<head>
<meta content="text/html; charset=UTF-8" http-equiv="Content-Type">
<title>
GitLab
</title>
<style data-premailer="ignore" type="text/css">
a { color: #1068bf; }
</style>
<style>img {
max-width: 100%; height: auto;
}
body {
font-size: .875rem;
}
body {
-webkit-text-shadow: rgba(255,255,255,.01) 0 0 1px;
}
body {
font-family: "GitLab Sans",-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Noto Sans",Ubuntu,Cantarell,"Helvetica Neue",sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji"; font-size: inherit;
}
</style>
</head>
<body style="font-size: inherit; -webkit-text-shadow: rgba(255,255,255,.01) 0 0 1px; font-family: "GitLab Sans",-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Noto Sans",Ubuntu,Cantarell,"Helvetica Neue",sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji";">
<div class="content">
<p style="color: #777777;">
<a href="https://gitlab.rtems.org/ar-in0">Armaan Chowfin</a>
commented on a
<a href="https://gitlab.rtems.org/rtems/rtos/rtems/-/merge_requests/1094#note_144216">discussion</a>:
</p>
<div class="md" style="position: relative; z-index: 1; color: #3a383f; word-wrap: break-word;">
<p dir="auto" style="color: #3a383f; margin: 0 0 1rem;" align="initial">Hi Gedare</p>
<p dir="auto" style="color: #3a383f; margin: 0 0 1rem;" align="initial">I discovered a few more lm3s69xx uart problems- this time I was trying to get lm4f120 builds (testsuites/samples) to run on my tm4c123 target board, with picocom on host to display text.</p>
<ol dir="auto" style="text-align: initial; margin: 0 0 1rem; padding: 0;">
<li style="margin-top: 0; line-height: 1.6em; margin-left: 25px; padding-left: 3px;">
<em style="margin-top: 0;">None of the samples (all use the simple console driver) could display text</em>. The simple console driver path does not initialize the uart port (enable, set baud). For VMs, qemu most probably does uart port initialization during machine init - <code style="font-size: 90%; color: #18171d; word-wrap: break-word; background-color: #ececef; border-radius: .25rem; font-family: "GitLab Mono", "JetBrains Mono", "Menlo", "DejaVu Sans Mono", "Liberation Mono", "Consolas", "Ubuntu Mono", "Courier New", "andale mono", "lucida console", monospace; font-variant-ligatures: none; white-space: pre-wrap; overflow-wrap: break-word; word-break: keep-all; padding: 0.125rem 0.25rem;">NEEDS_SIMPLE_CONSOLE</code> samples all work on the lm3s6965evb.</li>
<li style="line-height: 1.6em; margin-left: 25px; padding-left: 3px;">
<em style="margin-top: 0;">ticker.exe exceeds tm4c123 memory limits in every configuration (1 task/4 task/simple console/legacy console).</em> This was creating a double fault: <code style="font-size: 90%; color: #18171d; word-wrap: break-word; background-color: #ececef; border-radius: .25rem; font-family: "GitLab Mono", "JetBrains Mono", "Menlo", "DejaVu Sans Mono", "Liberation Mono", "Consolas", "Ubuntu Mono", "Courier New", "andale mono", "lucida console", monospace; font-variant-ligatures: none; white-space: pre-wrap; overflow-wrap: break-word; word-break: keep-all; padding: 0.125rem 0.25rem;">_Internal_error() -> printk() -> bus error at uart->fr during write_polled()</code> . (verified by reading BFSR and MMFAR regs, see <a href="https://interrupt.memfault.com/blog/cortex-m-hardfault-debug" rel="nofollow noreferrer noopener" target="_blank">https://interrupt.memfault.com/blog/cortex-m-hardfault-debug</a>)</li>
</ol>
<p dir="auto" style="color: #3a383f; margin: 0 0 1rem;" align="initial">I moved uart initialization code (uart_clock_enable, baudrate set) to <code style="font-size: 90%; color: #18171d; word-wrap: break-word; background-color: #ececef; border-radius: .25rem; margin-top: 0; font-weight: inherit; overflow-wrap: break-word; white-space: break-spaces; font-family: "GitLab Mono", "JetBrains Mono", "Menlo", "DejaVu Sans Mono", "Liberation Mono", "Consolas", "Ubuntu Mono", "Courier New", "andale mono", "lucida console", monospace; font-variant-ligatures: none; word-break: keep-all; padding: 0.125rem 0.25rem;">bsp_start_hook_1()</code>). This fixes the uart prints for all samples and double fault too.</p>
<ol start="3" dir="auto" style="text-align: initial; margin: 0 0 1rem; padding: 0;">
<li style="margin-top: 0; line-height: 1.6em; margin-left: 25px; padding-left: 3px;">The TM4C123 datasheet (<a href="https://www.ti.com/lit/ds/symlink/tm4c123gh6pm.pdf" rel="nofollow noreferrer noopener" target="_blank" style="margin-top: 0;">https://www.ti.com/lit/ds/symlink/tm4c123gh6pm.pdf</a>, page <span data-escaped-char>~</span>650, 660) mentions a GPIOPCTL register <code style="font-size: 90%; color: #18171d; word-wrap: break-word; background-color: #ececef; border-radius: .25rem; font-family: "GitLab Mono", "JetBrains Mono", "Menlo", "DejaVu Sans Mono", "Liberation Mono", "Consolas", "Ubuntu Mono", "Courier New", "andale mono", "lucida console", monospace; font-variant-ligatures: none; white-space: pre-wrap; overflow-wrap: break-word; word-break: keep-all; padding: 0.125rem 0.25rem;">0x52C</code>) that needs to be configured to enable uart. The port register struct in rtems lm3s69xx does not track this, but the uart prints were fixed without adding pctl code. I'm not sure why this should happen...</li>
</ol>
<p dir="auto" style="color: #3a383f; margin: 0 0 1rem;" align="initial">Should I create an issue in rtos/rtems for all the lm3s69xx fixes? I could have a larger MR in a day or so.</p>
<p dir="auto" style="color: #3a383f; margin: 0;" align="initial">Regarding the rtems-tools, it might be better to create a new issue in tools/.</p>
</div>
</div>
<div class="footer" style="margin-top: 10px;">
<p style="font-size: small; color: #626168;">
—
<br>
<a href="https://gitlab.rtems.org/rtems/rtos/rtems/-/merge_requests/1094#note_144216">View it on GitLab</a>.
<br>
You're receiving this email because of your account on <a target="_blank" rel="noopener noreferrer" href="https://gitlab.rtems.org">gitlab.rtems.org</a>. <a href="https://gitlab.rtems.org/-/sent_notifications/2-81hi5tb0hjf8hdi890k70qtek/unsubscribe" target="_blank" rel="noopener noreferrer">Unsubscribe</a> from this thread · <a href="https://gitlab.rtems.org/-/profile/notifications" target="_blank" rel="noopener noreferrer" class="mng-notif-link">Manage all notifications</a> · <a href="https://gitlab.rtems.org/help" target="_blank" rel="noopener noreferrer" class="help-link">Help</a>
<span style="color: transparent; font-size: 0; display: none; overflow: hidden; opacity: 0; width: 0; height: 0; max-width: 0; max-height: 0;">
Notification message regarding https://gitlab.rtems.org/rtems/rtos/rtems/-/merge_requests/1094#note_144216 at 1772574058
</span>
<script type="application/ld+json">{"@context":"http://schema.org","@type":"EmailMessage","action":{"@type":"ViewAction","name":"View Merge request","url":"https://gitlab.rtems.org/rtems/rtos/rtems/-/merge_requests/1094#note_144216"}}</script>
</p>
</div>
</body>
</html>