summaryrefslogtreecommitdiff
path: root/include/asm-generic
diff options
context:
space:
mode:
authorWei Liu <wei.liu@kernel.org>2021-02-03 18:04:30 +0300
committerWei Liu <wei.liu@kernel.org>2021-02-11 11:47:06 +0300
commitd589ae61bc27b2b9aaac0bf20a9077b6fbda32b6 (patch)
tree229749e0813f6bf2b7d721930c9b90192c91420a /include/asm-generic
parent333abaf5abb396820c4c7c26a8eecc7523c99184 (diff)
downloadlinux-d589ae61bc27b2b9aaac0bf20a9077b6fbda32b6.tar.xz
asm-generic/hyperv: update hv_msi_entry
We will soon need to access fields inside the MSI address and MSI data fields. Introduce hv_msi_address_register and hv_msi_data_register. Fix up one user of hv_msi_entry in mshyperv.h. No functional change expected. Signed-off-by: Wei Liu <wei.liu@kernel.org> Reviewed-by: Michael Kelley <mikelley@microsoft.com> Link: https://lore.kernel.org/r/20210203150435.27941-12-wei.liu@kernel.org
Diffstat (limited to 'include/asm-generic')
-rw-r--r--include/asm-generic/hyperv-tlfs.h28
1 files changed, 26 insertions, 2 deletions
diff --git a/include/asm-generic/hyperv-tlfs.h b/include/asm-generic/hyperv-tlfs.h
index 562a29981632..8ac797e6a91a 100644
--- a/include/asm-generic/hyperv-tlfs.h
+++ b/include/asm-generic/hyperv-tlfs.h
@@ -481,12 +481,36 @@ struct hv_create_vp {
u64 flags;
} __packed;
+union hv_msi_address_register {
+ u32 as_uint32;
+ struct {
+ u32 reserved1:2;
+ u32 destination_mode:1;
+ u32 redirection_hint:1;
+ u32 reserved2:8;
+ u32 destination_id:8;
+ u32 msi_base:12;
+ };
+} __packed;
+
+union hv_msi_data_register {
+ u32 as_uint32;
+ struct {
+ u32 vector:8;
+ u32 delivery_mode:3;
+ u32 reserved1:3;
+ u32 level_assert:1;
+ u32 trigger_mode:1;
+ u32 reserved2:16;
+ };
+} __packed;
+
/* HvRetargetDeviceInterrupt hypercall */
union hv_msi_entry {
u64 as_uint64;
struct {
- u32 address;
- u32 data;
+ union hv_msi_address_register address;
+ union hv_msi_data_register data;
} __packed;
};