Made alignment typedefs more robust for IAR #410

Merged
LoveKarlsson merged 3 commits from iar-robust-alignment into development 2026-04-29 10:30:45 -05:00
LoveKarlsson commented 2025-08-06 03:26:14 -05:00 (Migrated from github.com)

Description

The Zephyr project unfortunately defines a macro __packed which overrides the IAR keyword, and that causes the typedefs in core/alignment.h not be unaligned. This is also being backported to 3.6 as that version is what Zephyr is currently using.

PR checklist

## Description The Zephyr project unfortunately defines a macro __packed which overrides the IAR keyword, and that causes the typedefs in core/alignment.h not be unaligned. This is also being backported to 3.6 as that version is what Zephyr is currently using. ## PR checklist - [x] **changelog** : provided - [x] **Mbed TLS development PR** not required because: code is in crypto - [x] **Mbed TLS 4.1 PR** not required because: code is in crypto - [x] **TF-PSA-Crypto development PR** provided https://github.com/Mbed-TLS/TF-PSA-Crypto/pull/410 - [x] **TF-PSA-Crypto 1.1 PR** provided https://github.com/Mbed-TLS/TF-PSA-Crypto/pull/779 - [x] **framework PR** not required - [x] **3.6 PR** provided https://github.com/Mbed-TLS/mbedtls/pull/10202 - **tests** not required because: integration fix, up to the integrator to validate
valeriosetti commented 2026-04-14 09:24:28 -05:00 (Migrated from github.com)

@davidhorstmann-arm I just added this to the Community project because this has recently been re-raised again in Zephyr scope. I also started the CI on it.
I don't know if I can review this though because I don't have an IAR compiler that I can use to verify the solution.

@davidhorstmann-arm I just added this to the `Community` project because this has recently been re-raised again in [Zephyr scope](https://github.com/zephyrproject-rtos/TF-PSA-Crypto/pull/7). I also started the CI on it. I don't know if I can review this though because I don't have an IAR compiler that I can use to verify the solution.
gilles-peskine-arm (Migrated from github.com) reviewed 2026-04-15 05:08:07 -05:00
gilles-peskine-arm (Migrated from github.com) left a comment
No description provided.
LGTM I've checked locally that this doesn't break the build with IAR 9.40 for arm, in a bare-metal build. I haven't tried running tests or building in Zephyr.
valeriosetti (Migrated from github.com) reviewed 2026-04-24 09:48:00 -05:00
valeriosetti (Migrated from github.com) left a comment
No description provided.
CI failures seems related to an outdated `framework` submodule. Can you please rebase the PR on top of `development`? I will re-approve again once it's updated
valeriosetti commented 2026-04-24 09:49:17 -05:00 (Migrated from github.com)

Also I think that now this requires also a backport to tf-psa-crypto-1.1 branch

Also I think that now this requires also a backport to `tf-psa-crypto-1.1` branch
LoveKarlsson (Migrated from github.com) reviewed 2026-04-27 01:49:59 -05:00
LoveKarlsson commented 2026-04-27 02:10:02 -05:00 (Migrated from github.com)

Also I think that now this requires also a backport to tf-psa-crypto-1.1 branch

Added a new PR #779 for that

> Also I think that now this requires also a backport to `tf-psa-crypto-1.1` branch Added a new PR #779 for that
gilles-peskine-arm (Migrated from github.com) approved these changes 2026-04-29 04:36:37 -05:00
gilles-peskine-arm (Migrated from github.com) left a comment

LGTM

LGTM
valeriosetti (Migrated from github.com) approved these changes 2026-04-29 04:38:37 -05:00
Sign in to join this conversation.
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
gh-Mbed-TLS/TF-PSA-Crypto!410
No description provided.