Add a new capability, KVM_CAP_S390_CSS_SUPPORT, which will pass intercepts for channel I/O instructions to userspace. Only I/O instructions interacting with I/O interrupts need to be handled in-kernel: - TEST PENDING INTERRUPTION (tpi) dequeues and stores pending interrupts entirely in-kernel. - TEST SUBCHANNEL (tsch) dequeues pending interrupts in-kernel and exits via KVM_EXIT_S390_TSCH to userspace for subchannel- related processing.
Showing the changes to include/uapi/linux (1 of 10 files). Show all
Unified · Split
| @@ -168,6 +168,7 @@ struct kvm_pit_config { · 167 unmodified lines | ||
| 168 | 168 | #define KVM_EXIT_PAPR_HCALL 19 |
| 169 | 169 | #define KVM_EXIT_S390_UCONTROL 20 |
| 170 | 170 | #define KVM_EXIT_WATCHDOG 21 |
| 171 | +#define KVM_EXIT_S390_TSCH 22 | |
| 171 | 172 | |
| 172 | 173 | /* For KVM_EXIT_INTERNAL_ERROR */ |
| 173 | 174 | /* Emulate instruction failed. */ |
| @@ -285,6 +286,15 @@ struct kvm_run { · 111 unmodified lines | ||
| 285 | 286 | __u64 ret; |
| 286 | 287 | __u64 args[9]; |
| 287 | 288 | } papr_hcall; |
| 289 | + /* KVM_EXIT_S390_TSCH */ | |
| 290 | + struct { | |
| 291 | + __u16 subchannel_id; | |
| 292 | + __u16 subchannel_nr; | |
| 293 | + __u32 io_int_parm; | |
| 294 | + __u32 io_int_word; | |
| 295 | + __u32 ipb; | |
| 296 | + __u8 dequeued; | |
| 297 | + } s390_tsch; | |
| 288 | 298 | /* Fix the size of the union. */ |
| 289 | 299 | char padding[256]; |
| 290 | 300 | }; |
| @@ -645,6 +655,7 @@ struct kvm_ppc_smmu_info { · 354 unmodified lines | ||
| 645 | 655 | #define KVM_CAP_IRQFD_RESAMPLE 82 |
| 646 | 656 | #define KVM_CAP_PPC_BOOKE_WATCHDOG 83 |
| 647 | 657 | #define KVM_CAP_PPC_HTAB_FD 84 |
| 658 | +#define KVM_CAP_S390_CSS_SUPPORT 85 | |
| 648 | 659 | |
| 649 | 660 | #ifdef KVM_CAP_IRQ_ROUTING |
| 650 | 661 | |