Changeset 61c91532 in mainline for kernel/genarch/src/drivers/ns16550/ns16550.c
- Timestamp:
- 2025-04-17T16:18:27Z (5 days ago)
- Children:
- 634340fd
- Parents:
- a65ccc4 (diff), 888c06e (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)
links above to see all the changes relative to each parent. - git-author:
- Wayne Thornton <wmthornton-dev@…> (2025-04-17 16:18:27)
- git-committer:
- GitHub <noreply@…> (2025-04-17 16:18:27)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
kernel/genarch/src/drivers/ns16550/ns16550.c
ra65ccc4 r61c91532 112 112 } 113 113 114 static void ns16550_ putuchar(outdev_t *dev, char32_t ch)114 static void ns16550_write(outdev_t *dev, const char *s, size_t n) 115 115 { 116 116 ns16550_instance_t *instance = (ns16550_instance_t *) dev->data; 117 117 118 if ((!instance->parea.mapped) || (console_override)) { 119 if (ch == '\n') 118 if (instance->parea.mapped && !console_override) 119 return; 120 121 const char *top = s + n; 122 assert(top >= s); 123 124 for (; s < top; s++) { 125 if (*s == '\n') 120 126 ns16550_sendb(instance, '\r'); 121 127 122 if (ascii_check(ch)) 123 ns16550_sendb(instance, (uint8_t) ch); 124 else 125 ns16550_sendb(instance, U_SPECIAL); 128 ns16550_sendb(instance, (uint8_t) *s); 126 129 } 127 130 } 128 131 129 132 static outdev_operations_t ns16550_ops = { 130 .write = ns16550_ putuchar,133 .write = ns16550_write, 131 134 .redraw = NULL 132 135 };
Note:
See TracChangeset
for help on using the changeset viewer.