Skip to content

Commit 2f67341

Browse files
reet-gregkh
authored andcommitted
x86/msi: Fix msi message data shadow struct
commit 59b18a1 upstream. The x86 MSI message data is 32 bits in total and is either in compatibility or remappable format, see Intel Virtualization Technology for Directed I/O, section 5.1.2. Fixes: 6285aa5 ("x86/msi: Provide msi message shadow structs") Co-developed-by: Adrian-Ken Rueegsegger <[email protected]> Signed-off-by: Adrian-Ken Rueegsegger <[email protected]> Signed-off-by: Reto Buerki <[email protected]> Signed-off-by: Thomas Gleixner <[email protected]> Cc: [email protected] Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Greg Kroah-Hartman <[email protected]>
1 parent 0912cf0 commit 2f67341

File tree

1 file changed

+11
-8
lines changed
  • arch/x86/include/asm

1 file changed

+11
-8
lines changed

arch/x86/include/asm/msi.h

Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -12,14 +12,17 @@ int pci_msi_prepare(struct irq_domain *domain, struct device *dev, int nvec,
1212
/* Structs and defines for the X86 specific MSI message format */
1313

1414
typedef struct x86_msi_data {
15-
u32 vector : 8,
16-
delivery_mode : 3,
17-
dest_mode_logical : 1,
18-
reserved : 2,
19-
active_low : 1,
20-
is_level : 1;
21-
22-
u32 dmar_subhandle;
15+
union {
16+
struct {
17+
u32 vector : 8,
18+
delivery_mode : 3,
19+
dest_mode_logical : 1,
20+
reserved : 2,
21+
active_low : 1,
22+
is_level : 1;
23+
};
24+
u32 dmar_subhandle;
25+
};
2326
} __attribute__ ((packed)) arch_msi_msg_data_t;
2427
#define arch_msi_msg_data x86_msi_data
2528

0 commit comments

Comments
 (0)