vfio-ccw: add handling for async channel instructions
Add a region to the vfio-ccw device that can be used to submit asynchronous I/O instructions. ssch continues to be handled by the existing I/O region; the new region handles hsch and csch. Interrupt status continues to be reported through the same channels as for ssch. Acked-by: Eric Farman <farman@linux.ibm.com> Reviewed-by: Farhan Ali <alifm@linux.ibm.com> Signed-off-by: Cornelia Huck <cohuck@redhat.com>
This commit is contained in:
parent
b094085737
commit
d5afd5d135
8 changed files with 270 additions and 18 deletions
|
|
@ -354,6 +354,8 @@ struct vfio_region_gfx_edid {
|
|||
};
|
||||
|
||||
#define VFIO_REGION_TYPE_CCW (2)
|
||||
/* ccw sub-types */
|
||||
#define VFIO_REGION_SUBTYPE_CCW_ASYNC_CMD (1)
|
||||
|
||||
/*
|
||||
* 10de vendor sub-type
|
||||
|
|
|
|||
|
|
@ -12,6 +12,7 @@
|
|||
|
||||
#include <linux/types.h>
|
||||
|
||||
/* used for START SUBCHANNEL, always present */
|
||||
struct ccw_io_region {
|
||||
#define ORB_AREA_SIZE 12
|
||||
__u8 orb_area[ORB_AREA_SIZE];
|
||||
|
|
@ -22,4 +23,15 @@ struct ccw_io_region {
|
|||
__u32 ret_code;
|
||||
} __packed;
|
||||
|
||||
/*
|
||||
* used for processing commands that trigger asynchronous actions
|
||||
* Note: this is controlled by a capability
|
||||
*/
|
||||
#define VFIO_CCW_ASYNC_CMD_HSCH (1 << 0)
|
||||
#define VFIO_CCW_ASYNC_CMD_CSCH (1 << 1)
|
||||
struct ccw_cmd_region {
|
||||
__u32 command;
|
||||
__u32 ret_code;
|
||||
} __packed;
|
||||
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue