Skip to content

logger sample fails on qemu_xtensa due to lack of backend #10164

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
nashif opened this issue Sep 22, 2018 · 8 comments
Closed

logger sample fails on qemu_xtensa due to lack of backend #10164

nashif opened this issue Sep 22, 2018 · 8 comments
Assignees
Labels
area: Logging bug The issue is a bug, or the PR is fixing a bug priority: medium Medium impact/importance bug
Milestone

Comments

@nashif
Copy link
Member

nashif commented Sep 22, 2018

Getting no output on both, see PR #10163 and the CI results.

@nashif nashif added the bug The issue is a bug, or the PR is fixing a bug label Sep 22, 2018
@nordic-krch
Copy link
Collaborator

@finikorg @aescolar question: you've been involved in adding native_posix backend to the logger. Have you tried to run logger example on native_posix? I don't see any output.

@nashif regarding qemu_xtensa target. It has no logger backends (as uart is the only available).

@aescolar
Copy link
Member

aescolar commented Sep 24, 2018

Regarding the native_posix case:
it was working on: 8644203
it was broken on: 68249ce
(after merging #9362)

Bisecting:
ok - c71a559
nok - ba01a39

@aescolar
Copy link
Member

Which is not really surprissing:

------------------------ subsys/logging/CMakeLists.txt ------------------------
index a27cf1e..e46c5e0 100644
@@ -15,6 +15,6 @@ zephyr_sources_ifdef(
   )
 
 zephyr_sources_ifdef(
-  CONFIG_LOG_BACKEND_NATIVE_POSIX
-  log_backend_native_posix.c
+  CONFIG_LOG_CMDS
+  log_cmds.c
   )

@aescolar
Copy link
Member

I'll make a PR to fix that merge screw up.

@nashif
Copy link
Member Author

nashif commented Sep 24, 2018

@nashif regarding qemu_xtensa target. It has no logger backends (as uart is the only available).

I am not sure I am following this, why does it need a special logger backend? it was logging just fine with old logger to the console. How is this different from qemu_x86 or qemu_nios2? What logger backends do those have?

@finikorg
Copy link
Collaborator

qemu uses own UART so it uses usual UART logging backend, @nordic-krch native_posix backend in only for native_posix board configuration.

@nashif nashif added the priority: medium Medium impact/importance bug label Sep 30, 2018
@nordic-krch
Copy link
Collaborator

@nashif

I am not sure I am following this, why does it need a special logger backend? it was logging just fine with old logger to the console.

It's because new logger does not have (yet?) console backend. It has uart backend. So if target has no uart (or native_posix, or rtt when pr comes) it cannot do logging. We should add console backend but we need to be aware that it is byte API so it will slower than optimized uart backend (current uart backend is polling based, it's poor and needs to be improved as well but at least there is room for improvement).

@finikorg
Copy link
Collaborator

finikorg commented Oct 2, 2018

native_posix should be working fine, I tested several samples, all OK.

@nordic-krch nordic-krch changed the title logger sample fails on both native_posix and qemu_xtensa. logger sample fails on qemu_xtensa due to lack of backend Feb 12, 2019
@nashif nashif assigned nashif and unassigned nordic-krch Mar 4, 2019
@nashif nashif added this to the v1.14.0 milestone Mar 4, 2019
@nashif nashif added the In progress For PRs: is work in progress and should not be merged yet. For issues: Is being worked on label Mar 4, 2019
nashif added a commit to nashif/zephyr that referenced this issue Mar 4, 2019
Add backend for the xtensa simulator.

Fixes zephyrproject-rtos#10164

Signed-off-by: Anas Nashif <[email protected]>
@ghost ghost removed the In progress For PRs: is work in progress and should not be merged yet. For issues: Is being worked on label Mar 4, 2019
nashif added a commit that referenced this issue Mar 4, 2019
Add backend for the xtensa simulator.

Fixes #10164

Signed-off-by: Anas Nashif <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: Logging bug The issue is a bug, or the PR is fixing a bug priority: medium Medium impact/importance bug
Projects
None yet
Development

No branches or pull requests

4 participants