Skip to content
This repository was archived by the owner on Jan 17, 2019. It is now read-only.

readme: upgrade readme with logger instruction - #104

Merged
lgirdwood merged 1 commit into
thesofproject:masterfrom
bkokoszx:readme_update
Oct 15, 2018
Merged

lgirdwood merged 1 commit into
thesofproject:masterfrom
bkokoszx:readme_update

Conversation

@bkokoszx

Copy link
Copy Markdown
Contributor

I've added logger instruction to readme file - issue #102

Signed-off-by: Bartosz Kokoszko bartoszx.kokoszko@linux.intel.com

Comment thread README Outdated
======

logger is used to print logs delivered from FW dma_trace mechanism, by searching log
entries in *.ldc file generated by rimage

@mengdonglin mengdonglin Oct 13, 2018 •

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@bkokoszx Thanks for the documentation! Could you also give a brief introduction about *.ldc file? Or is there already a document about *.ldc file?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mengdonglin I've updated that.

Comment thread README Outdated
======

logger is used to print logs delivered from FW dma_trace mechanism, by searching log
entries in *.ldc file generated by rimage

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since you're renaming logger binary name from logger to sof_logger in PR #105, please make sure the binary name in this document has an update as well.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, I remember about it. I will update binary instruction name after PR #105 approval.

Comment thread README Outdated
======

logger is used to print logs delivered from FW dma_trace mechanism, by searching log
entries in *.ldc file generated by rimage

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Before giving the examples, would you please give a list of all parameters? like this

Usage: sof_logger [OPTIONS]...
Options:
-h help
-l, specify the ldc file
-t get traces from "/sys/kernel/debug/sof/trace", instead of the default "/sys/kernel/debug/sof/etrace"
-o specify the output file, instead of the stdout
-i ...

Examples:

  • Get traces from "/sys/kernel/debug/sof/etrace" file and print logs to stdout
    $ sof_logger -l ldc_file

  • Get gets traces from "/sys/kernel/debug/sof/etrace" file and prints logs to a specified output file
    $logger -l ldc_file -o out_file
    ...

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mengdonglin I've updated that.

Comment thread README
stdout

logger -l ldc_file

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have a basic question, is there a default ldc_file?
I wonder if the ldc_file could be generated when we build the firmware. And if there is a default ldc file, can we save this parameter sometimes?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ldc_file is generated always when we build the firmware and its name differs for particular platforms (sof-apl.ldc, sof-cnl.ldc etc.) - also *.ldc file content could be different for platforms since they can have different log_messages. For that reason, in my opinion it is hard to define deafult *.ldc file

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mengdonglin Please refer to a high level documentation of the process being delivered in thesofproject/sof-docs#51.

Comment thread README
set clock value to 19.9 (MHz).

logger -l ldc_file -i trace_dump -o out_file -c 19.9

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can the firmware know the MHz by itself by reading some register? So the user need not specify the clock value by -c. I think the previous trace tool does not request this.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mengdonglin
with @akloniex we have incorporated c flag from previous rmbox tool.
I am not sure now, but I think that there is possibility for fw to get frequency of its clock - another problem is to convey that information to logger (we can think of adding clk freq information at the begginig of *ldc file, so that logger can read that).

Comment thread README Outdated
xtensa-byt-elf-objdump -D image.bin.elf > image.dis.txt


logger

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should be sof-logger now. Can we also have these instructions in the sof-docs wiki too.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@lgirdwood name updated

Signed-off-by: Bartosz Kokoszko <bartoszx.kokoszko@linux.intel.com>
@lgirdwood
lgirdwood merged commit b37b8ef into thesofproject:master Oct 15, 2018
@bkokoszx
bkokoszx deleted the readme_update branch October 16, 2018 07:47
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants