mirror of
https://github.com/projectacrn/acrn-hypervisor.git
synced 2026-06-06 17:21:22 +00:00
HV/DM: Unify the usage of aligned for structure definition with alignment
Now one macro is added to define the alignment requirement. >#define __aligned(x) __attribute__((aligned(x))) Some code uses the __aligned(x) to define the alignment while the other code uses the original alignment definition. So they are unified. Tracked-On: projectacrn/acrn-hypervisor#2131 Signed-off-by: Zhao Yakui <yakui.zhao@intel.com> Acked-by: Anthony Xu <anthony.xu@intel.com>
This commit is contained in:
@@ -217,7 +217,7 @@ struct xhci_dev_ctx {
|
||||
struct xhci_slot_ctx u_slot;
|
||||
struct xhci_endp_ctx u_ep[XHCI_MAX_ENDPOINTS];
|
||||
} ctx_dev_slep;
|
||||
} __attribute__((aligned(XHCI_DEV_CTX_ALIGN)));
|
||||
} __aligned(XHCI_DEV_CTX_ALIGN);
|
||||
#define ctx_slot ctx_dev_slep.u_slot
|
||||
#define ctx_ep ctx_dev_slep.u_ep
|
||||
|
||||
@@ -364,7 +364,7 @@ struct xhci_trb {
|
||||
#define XHCI_TRB_ERROR_INVALID_SID 0x22
|
||||
#define XHCI_TRB_ERROR_SEC_BW 0x23
|
||||
#define XHCI_TRB_ERROR_SPLIT_XACT 0x24
|
||||
} __attribute__((aligned(4)));
|
||||
} __aligned(8);
|
||||
|
||||
struct xhci_dev_endpoint_trbs {
|
||||
struct xhci_trb trb[(XHCI_MAX_STREAMS *
|
||||
|
||||
Reference in New Issue
Block a user