Commit | Line | Data |
---|---|---|
685a6bf8 | 1 | /* SPDX-License-Identifier: GPL-2.0-only */ |
83e2ec76 GZ |
2 | /* |
3 | * VMware VMCI Driver | |
4 | * | |
5 | * Copyright (C) 2012 VMware, Inc. All rights reserved. | |
83e2ec76 GZ |
6 | */ |
7 | ||
8 | #ifndef VMCI_DOORBELL_H | |
9 | #define VMCI_DOORBELL_H | |
10 | ||
11 | #include <linux/vmw_vmci_defs.h> | |
12 | #include <linux/types.h> | |
13 | ||
14 | #include "vmci_driver.h" | |
15 | ||
16 | /* | |
17 | * VMCINotifyResourceInfo: Used to create and destroy doorbells, and | |
18 | * generate a notification for a doorbell or queue pair. | |
19 | */ | |
20 | struct vmci_dbell_notify_resource_info { | |
21 | struct vmci_handle handle; | |
22 | u16 resource; | |
23 | u16 action; | |
24 | s32 result; | |
25 | }; | |
26 | ||
27 | /* | |
28 | * Structure used for checkpointing the doorbell mappings. It is | |
29 | * written to the checkpoint as is, so changing this structure will | |
30 | * break checkpoint compatibility. | |
31 | */ | |
32 | struct dbell_cpt_state { | |
33 | struct vmci_handle handle; | |
34 | u64 bitmap_idx; | |
35 | }; | |
36 | ||
37 | int vmci_dbell_host_context_notify(u32 src_cid, struct vmci_handle handle); | |
38 | int vmci_dbell_get_priv_flags(struct vmci_handle handle, u32 *priv_flags); | |
39 | ||
f2db7361 | 40 | bool vmci_dbell_register_notification_bitmap(u64 bitmap_ppn); |
83e2ec76 GZ |
41 | void vmci_dbell_scan_notification_entries(u8 *bitmap); |
42 | ||
43 | #endif /* VMCI_DOORBELL_H */ |