Skip to content

zephyr/soc: Add MediaTek DSPs#34

Merged
nashif merged 2 commits intozephyrproject-rtos:masterfrom
andyross:mtk-updates
Dec 2, 2024
Merged

zephyr/soc: Add MediaTek DSPs#34
nashif merged 2 commits intozephyrproject-rtos:masterfrom
andyross:mtk-updates

Conversation

@andyross
Copy link
Collaborator

Add HAL integration for mt8186/88 and mt8196 DSP processors.

Add HAL integration for mt8186/88 and mt8196 DSP processors.

Also rename the existing mt8195 HAL directory to match the newer
naming scheme in the Zephyr SOC family.

Signed-off-by: Andy Ross <andyross@google.com>
First, recent Cadence toolchains have begun using the UINT32_C() to
define constants, but don't include stdint.h to import it.  And in any
case the stdint.h headers in our toolchains aren't
assembly-compatible.  Give it a reasonable definition inline.

Also, replace the use of the "addi.a" pseudoinstruction in the (unused
by Zephyr) register context macros with a simple "addi".  I'm unable
to figure this one out, this isn't a documented mnemonic, it's not
supported by any version of binutils (or even xt-clang in its default
mode).  When I disassemble the upstream HALs, I can verify that the
emitted instruction for the sequence is a regular addi (though in the
Cadence binaries it's packed in a VLIW bundle, which doesn't match the
assembly source here...).  My guess is that this is a hint for bundle
packing, but I don't know.

Regardless, our headers dating back into SOF have always just used
"addi" here, which builds fine and will run compatibly.  And again,
Zephyr doesn't use this HAL feature anyway.

Signed-off-by: Andy Ross <andyross@google.com>
@andyross
Copy link
Collaborator Author

andyross commented Dec 2, 2024

Coming by to beg for review and realizing this has no reviewers. Add @dcpleung @nashif

@nashif nashif merged commit ba3f1ce into zephyrproject-rtos:master Dec 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants