Skip to content

[BUG] Compilation fails for i.MX8MP with Xtensa toolchain #11183

Description

@dbaluta

Describe the bug

Using Xtensa proprietary toolchain based on xt-clang (Clang 10.0.1) compilation fails with following error

/home/bamboo/sof_dir/zephyr/drivers/timer/xtensa_sys_timer.c
In file included from /home/bamboo/sof_dir/zephyr/drivers/timer/xtensa_sys_timer.c:78:
/home/bamboo/sof_dir/zephyr/drivers/timer/system_timer_generic.h:312:30: error: use of undeclared identifier '__LONG_WIDTH__'
               (timer_core_cycles_t)TIMER_CORE_COUNTER_MASK;
                                    ^
/home/bamboo/sof_dir/zephyr/drivers/timer/system_timer_generic.h:217:54: note: expanded from macro 'TIMER_CORE_COUNTER_MASK'
#define TIMER_CORE_COUNTER_MASK (UINT64_MAX >> (64 - TIMER_CORE_COUNTER_WIDTH))
                                                     ^
/home/bamboo/sof_dir/zephyr/drivers/timer/system_timer_generic.h:213:34: note: expanded from macro 'TIMER_CORE_COUNTER_WIDTH'
#define TIMER_CORE_COUNTER_WIDTH __LONG_WIDTH__

To Reproduce

XTENSA_TOOLS_ROOT=~/work/repos/imx-audio-toolchain/Xtensa_Tool/ ./scripts/xtensa-build-zephyr.py -p imx8m

Reproduction Rate

100%

Expected behavior

Code should compile cleanly

Impact

Major, CI fails with no possibility to test further changes.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working as expected

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions