Skip to content

Commit

Permalink
xtensa: include xtensa-types.h for xt-clang
Browse files Browse the repository at this point in the history
Newer Xtensa toolchain needs to include xtensa-types.h so that
macros in tie.h can be used without compilation errors.
The exact verison needing this is unknown but first encountered
in RJ-2023.2. Tested with older toolchain and that did not
cause any compilation errors so just include xtensa-types.h
if xt-clang is used. Haven't seen newer toolchains being
generated with xcc, so skip that for now.

Note that Zephyr SDK and the public HAL in Zephyr do not provide
this file.

(cherry picked from commit 8a4b3a4)

Original-Signed-off-by: Anthony Giardina <anthony.giardina@intel.com>
Original-Signed-off-by: Daniel Leung <daniel.leung@intel.com>
GitOrigin-RevId: 8a4b3a4
Cr-Build-Id: 8738819815572775377
Cr-Build-Url: https://cr-buildbucket.appspot.com/build/8738819815572775377
Copybot-Job-Name: zephyr-main-copybot-downstream
Change-Id: Ia9bd373be491363f9593de72bd55ffd24986b6b5
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/zephyr/+/5808857
Commit-Queue: Eric Yilun Lin <yllin@google.com>
Tested-by: Eric Yilun Lin <yllin@google.com>
Reviewed-by: Eric Yilun Lin <yllin@google.com>
Tested-by: ChromeOS Prod (Robot) <chromeos-ci-prod@chromeos-bot.iam.gserviceaccount.com>
  • Loading branch information
agiardin authored and Chromeos LUCI committed Aug 23, 2024
1 parent aff41aa commit 3380c0e
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions arch/xtensa/include/xtensa_asm2_context.h
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,10 @@
#ifndef ZEPHYR_ARCH_XTENSA_INCLUDE_XTENSA_ASM2_CONTEXT_H_
#define ZEPHYR_ARCH_XTENSA_INCLUDE_XTENSA_ASM2_CONTEXT_H_

#if defined(__XT_CLANG__)
#include <xtensa/xtensa-types.h>
#endif

#include <xtensa/corebits.h>
#include <xtensa/config/core-isa.h>
#include <xtensa/config/tie.h>
Expand Down

0 comments on commit 3380c0e

Please sign in to comment.