From fd85a26b17f6ff713a9825cd8c62e9d1935df6e7 Mon Sep 17 00:00:00 2001 From: Rander Wang Date: Mon, 23 Jul 2018 13:50:32 +0800 Subject: [PATCH] ipc: Refine some IPC data structures to make its size 4bytes aligned Host communicates with dsp by sending or receiving data in memory windows which are in PCI MMIO space. Some platforms like ICL require the transaction size is 4bytes aligned. So it is better to make the data size 4bytes aligned to make it work on all platforms. Signed-off-by: Rander Wang --- src/include/uapi/ipc.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/include/uapi/ipc.h b/src/include/uapi/ipc.h index a5f46490a94a..3444d25c30b1 100644 --- a/src/include/uapi/ipc.h +++ b/src/include/uapi/ipc.h @@ -298,6 +298,7 @@ struct sof_ipc_dai_dmic_pdm_ctrl { uint16_t polarity_mic_b; /* Optionally invert mic B signal (0 or 1) */ uint16_t clk_edge; /* Optionally swap data clock edge (0 or 1) */ uint16_t skew; /* Adjust PDM data sampling vs. clock (0..15) */ + uint16_t pad; /* Make sure the total size is 4 bytes aligned */ } __attribute__((packed)); /* This struct contains the global settings for all 2ch PDM controllers. The @@ -832,6 +833,7 @@ struct sof_ipc_fw_version { uint8_t date[12]; uint8_t time[10]; uint8_t tag[6]; + uint8_t pad[2]; /* Make sure the total size is 4 bytes aligned */ } __attribute__((packed)); /* FW ready Message - sent by firmware when boot has completed */