logo

oasis-root

Compiled tree of Oasis Linux based on own branch at <https://hacktivis.me/git/oasis/> git clone https://anongit.hacktivis.me/git/oasis-root.git

vfio_ccw.h (1317B)


  1. /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */
  2. /*
  3. * Interfaces for vfio-ccw
  4. *
  5. * Copyright IBM Corp. 2017
  6. *
  7. * Author(s): Dong Jia Shi <bjsdjshi@linux.vnet.ibm.com>
  8. */
  9. #ifndef _VFIO_CCW_H_
  10. #define _VFIO_CCW_H_
  11. #include <linux/types.h>
  12. /* used for START SUBCHANNEL, always present */
  13. struct ccw_io_region {
  14. #define ORB_AREA_SIZE 12
  15. __u8 orb_area[ORB_AREA_SIZE];
  16. #define SCSW_AREA_SIZE 12
  17. __u8 scsw_area[SCSW_AREA_SIZE];
  18. #define IRB_AREA_SIZE 96
  19. __u8 irb_area[IRB_AREA_SIZE];
  20. __u32 ret_code;
  21. } __attribute__((packed));
  22. /*
  23. * used for processing commands that trigger asynchronous actions
  24. * Note: this is controlled by a capability
  25. */
  26. #define VFIO_CCW_ASYNC_CMD_HSCH (1 << 0)
  27. #define VFIO_CCW_ASYNC_CMD_CSCH (1 << 1)
  28. struct ccw_cmd_region {
  29. __u32 command;
  30. __u32 ret_code;
  31. } __attribute__((packed));
  32. /*
  33. * Used for processing commands that read the subchannel-information block
  34. * Reading this region triggers a stsch() to hardware
  35. * Note: this is controlled by a capability
  36. */
  37. struct ccw_schib_region {
  38. #define SCHIB_AREA_SIZE 52
  39. __u8 schib_area[SCHIB_AREA_SIZE];
  40. } __attribute__((packed));
  41. /*
  42. * Used for returning a Channel Report Word to userspace.
  43. * Note: this is controlled by a capability
  44. */
  45. struct ccw_crw_region {
  46. __u32 crw;
  47. __u32 pad;
  48. } __attribute__((packed));
  49. #endif