summaryrefslogtreecommitdiff
path: root/src/soc/qualcomm/common
diff options
context:
space:
mode:
authorJulius Werner <jwerner@chromium.org>2023-09-07 13:38:06 -0700
committerJulius Werner <jwerner@chromium.org>2023-09-14 23:53:54 +0000
commit37833fc4be8a67aedd6e806d3addd706cc1db57b (patch)
tree8702ec1596563bec879396641a269b8fe8543bc8 /src/soc/qualcomm/common
parentb7832de0260b042c25bf8f53abcb32e20a29ae9c (diff)
qualcomm/common: Remove carriage returns from QcLib log
The memory log we get returned by QcLib contains Windows line endings ("\r\n"), while we prefer to have POSIX line endings in the CBMEM console (just "\n"). Filter the '\r' character out when copying that log into the CBMEM console to convert. Signed-off-by: Julius Werner <jwerner@chromium.org> Change-Id: I0652300c2393fbc0b3c9875bb0ca1aa921e59098 Reviewed-on: https://review.coreboot.org/c/coreboot/+/77722 Reviewed-by: Yu-Ping Wu <yupingso@google.com> Reviewed-by: Shelley Chen <shchen@google.com> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Diffstat (limited to 'src/soc/qualcomm/common')
-rw-r--r--src/soc/qualcomm/common/qclib.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/soc/qualcomm/common/qclib.c b/src/soc/qualcomm/common/qclib.c
index 561870eaab..cfe3e2ac1e 100644
--- a/src/soc/qualcomm/common/qclib.c
+++ b/src/soc/qualcomm/common/qclib.c
@@ -115,8 +115,11 @@ static void write_qclib_log_to_cbmemc(struct qclib_cb_if_table_entry *te)
int i;
char *ptr = (char *)te->blob_address;
- for (i = 0; i < te->size; i++)
- __cbmemc_tx_byte(*ptr++);
+ for (i = 0; i < te->size; i++) {
+ char c = *ptr++;
+ if (c != '\r')
+ __cbmemc_tx_byte(c);
+ }
}
static void write_table_entry(struct qclib_cb_if_table_entry *te)