-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
On 01/12/13 20:21, David Miller wrote:
From: Antonio Quartulli antonio@meshcoding.com Date: Sun, 01 Dec 2013 15:28:58 +0100
Am I wrong or this is a problem in the ARM compiler not doing the right assumption? On x86 and x86_64 offset_of dest is 4, as expected.
These alignment behaviors are defined by the processor ABI, there is no set of global rules that apply, so it behaves differently on different CPUs. What you observe is correct behavior for compilation on ARM processors.
Ok. So, as far as I understand from your and Russell's explanation, the only way to allow ARM to support batman-adv is to ensure that all the _structures_ (no matter if it is a parent structure or not) sent over the wire have a size multiple of 32bits.
If we want to fix this, I think we have to re-work a little more the packet layout before 3.13 is released.
People using batman-adv on ARM-equipped smartphones (and similar) will be happy about this :)
Thanks to both for the hints and for the explanations.
- -- Antonio Quartulli