From f4a4e7d3046d4a97faa171829a4e546059757094 Mon Sep 17 00:00:00 2001 From: Johannes Cornelis Draaijer Date: Tue, 24 Jan 2023 16:40:55 +0100 Subject: [PATCH] Make all register blocks (with delays) Repr(C) Fixes an incorrect assumption that was broken in [Rust PR 102750](https://github.com/rust-lang/rust/pull/102750) --- src/peripherals.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/peripherals.rs b/src/peripherals.rs index 214c3a3..b1361fe 100644 --- a/src/peripherals.rs +++ b/src/peripherals.rs @@ -135,6 +135,7 @@ mod pac_override_impl { } } + #[repr(C)] pub struct MacRegisterBlock { #[doc = "0x00 - Ethernet MAC configuration register"] pub maccr: DelayedReg, @@ -207,6 +208,7 @@ mod pac_override_impl { } } + #[repr(C)] pub struct DmaRegisterBlock { #[doc = "0x00 - Ethernet DMA bus mode register"] pub dmabmr: DelayedReg, @@ -274,6 +276,7 @@ mod pac_override_impl { } } + #[repr(C)] pub struct PtpRegisterBlock { #[doc = "0x00 - Ethernet PTP time stamp control register"] pub ptptscr: DelayedReg,