mirror of https://github.com/thesofproject/sof.git
tools: logger: ignore end-of-file in trace mode
Change logger behaviour such that in trace (-t) mode logger only stops if an error is detected. If no error, logger continues to try and read data from debugfs node. Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
This commit is contained in:
parent
fe75426a93
commit
9fa0aef635
|
@ -371,10 +371,13 @@ static int logger_read(const struct convert_config *config,
|
|||
return ret;
|
||||
}
|
||||
|
||||
while (!feof(config->in_fd)) {
|
||||
while (!ferror(config->in_fd)) {
|
||||
/* getting entry parameters from dma dump */
|
||||
ret = fread(&dma_log, sizeof(dma_log), 1, config->in_fd);
|
||||
if (!ret) {
|
||||
if (config->trace)
|
||||
continue;
|
||||
|
||||
return -ferror(config->in_fd);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue