From 644cc645242317caa94124b1cdb21478dd124594 Mon Sep 17 00:00:00 2001 From: Astro Date: Sun, 29 Sep 2019 01:39:12 +0200 Subject: [PATCH] eth: align DescEntries --- src/eth/rx.rs | 2 +- src/eth/tx.rs | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/src/eth/rx.rs b/src/eth/rx.rs index c56ff19..34a919e 100644 --- a/src/eth/rx.rs +++ b/src/eth/rx.rs @@ -11,7 +11,7 @@ pub enum Error { } /// Descriptor entry -#[repr(C)] +#[repr(C, align(0x08))] pub struct DescEntry { word0: DescWord0, word1: DescWord1, diff --git a/src/eth/tx.rs b/src/eth/tx.rs index 4007363..a9b0d19 100644 --- a/src/eth/tx.rs +++ b/src/eth/tx.rs @@ -4,6 +4,7 @@ use crate::println; use super::{MTU, regs}; /// Descriptor entry +#[repr(C, align(0x08))] pub struct DescEntry { word0: DescWord0, word1: DescWord1,