aphexia wrote:
Is it because the cpu expects a continuous 32 bit number, and so the entire 4 bytes should be reversed?
The nice thing about just using 32-bit integers is that you don't need to worry about stuff like that.
kzinti wrote:
I find it unlikely that alignment is going to be a problem with these structures since they are usually "allocated" using a page allocator (and pages are 4K aligned).
True, the approach is better suited to the GDT or IDT.
kzinti wrote:
But for what's it's worth, one can easily force the alignment to 32 bits with __attribute__ ((aligned(4)).
You can, but why would you want to? In all seriousness, just using a 32-bit integer is going to be way easier than using a structure with multiple parts for no reason.