aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/include/uapi
diff options
context:
space:
mode:
authorFarhan Ali <alifm@linux.ibm.com>2020-05-05 14:27:41 +0200
committerCornelia Huck <cohuck@redhat.com>2020-06-02 13:14:08 +0200
commit24c986748ba670c903a9d6a11ee96de2b3f5f1b8 (patch)
tree4117927cb0d8a23c596dc72b5e0f22f1213efd46 /include/uapi
parentvfio-ccw: Refactor the unregister of the async regions (diff)
downloadwireguard-linux-24c986748ba670c903a9d6a11ee96de2b3f5f1b8.tar.xz
wireguard-linux-24c986748ba670c903a9d6a11ee96de2b3f5f1b8.zip
vfio-ccw: Introduce a new schib region
The schib region can be used by userspace to get the subchannel- information block (SCHIB) for the passthrough subchannel. This can be useful to get information such as channel path information via the SCHIB.PMCW fields. Signed-off-by: Farhan Ali <alifm@linux.ibm.com> Signed-off-by: Eric Farman <farman@linux.ibm.com> Reviewed-by: Cornelia Huck <cohuck@redhat.com> Message-Id: <20200505122745.53208-5-farman@linux.ibm.com> Signed-off-by: Cornelia Huck <cohuck@redhat.com>
Diffstat (limited to 'include/uapi')
-rw-r--r--include/uapi/linux/vfio.h1
-rw-r--r--include/uapi/linux/vfio_ccw.h10
2 files changed, 11 insertions, 0 deletions
diff --git a/include/uapi/linux/vfio.h b/include/uapi/linux/vfio.h
index 015516bcfaa3..7a1abbd889bd 100644
--- a/include/uapi/linux/vfio.h
+++ b/include/uapi/linux/vfio.h
@@ -378,6 +378,7 @@ struct vfio_region_gfx_edid {
/* sub-types for VFIO_REGION_TYPE_CCW */
#define VFIO_REGION_SUBTYPE_CCW_ASYNC_CMD (1)
+#define VFIO_REGION_SUBTYPE_CCW_SCHIB (2)
/*
* The MSIX mappable capability informs that MSIX data of a BAR can be mmapped
diff --git a/include/uapi/linux/vfio_ccw.h b/include/uapi/linux/vfio_ccw.h
index cbecbf0cd54f..758bf214898d 100644
--- a/include/uapi/linux/vfio_ccw.h
+++ b/include/uapi/linux/vfio_ccw.h
@@ -34,4 +34,14 @@ struct ccw_cmd_region {
__u32 ret_code;
} __packed;
+/*
+ * Used for processing commands that read the subchannel-information block
+ * Reading this region triggers a stsch() to hardware
+ * Note: this is controlled by a capability
+ */
+struct ccw_schib_region {
+#define SCHIB_AREA_SIZE 52
+ __u8 schib_area[SCHIB_AREA_SIZE];
+} __packed;
+
#endif