diff options
| author | Alexander Potapenko <glider@google.com> | 2025-09-15 16:23:10 +0200 |
|---|---|---|
| committer | Alexander Potapenko <glider@google.com> | 2025-09-19 08:38:14 +0000 |
| commit | adbde109f03932b9eee8106ce8bad4bc506d0713 (patch) | |
| tree | 1ba09463fde777a99591884afea2ad12255e2cc6 /sys/linux/dev_kvm_amd64.txt | |
| parent | dd232cacbbd407c55bf26299264db0a2c3f0cfcf (diff) | |
sys/linux: executor: add IN_DX and OUT_DX to SYZOS x86 API
Add SYZOS calls that correspond to the IN and OUT x86 instructions
that perform port I/O.
These instructions have different variants, for now we just implement
the one that takes the port number from DX instead of encoding it in
the opcode.
Diffstat (limited to 'sys/linux/dev_kvm_amd64.txt')
| -rw-r--r-- | sys/linux/dev_kvm_amd64.txt | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/sys/linux/dev_kvm_amd64.txt b/sys/linux/dev_kvm_amd64.txt index 351f55827..41fb947cd 100644 --- a/sys/linux/dev_kvm_amd64.txt +++ b/sys/linux/dev_kvm_amd64.txt @@ -75,6 +75,20 @@ syzos_api_wr_drn { arg_value int64 } +x86_in_out_size = 1, 2, 4 + +syzos_api_in_dx { + arg_port int64[0:65535] + arg_size flags[x86_in_out_size, int64] +} + +# In fact the accepted value always fit into int32. +syzos_api_out_dx { + arg_port int64[0:65535] + arg_size flags[x86_in_out_size, int64] + arg_val int64 +} + syzos_api_call$x86 [ uexit syzos_api$x86[0, intptr] code syzos_api$x86[10, syzos_api_code$x86] @@ -83,6 +97,8 @@ syzos_api_call$x86 [ rdmsr syzos_api$x86[50, syzos_api_rdmsr] wr_crn syzos_api$x86[70, syzos_api_wr_crn] wr_drn syzos_api$x86[110, syzos_api_wr_drn] + in_dx syzos_api$x86[130, syzos_api_in_dx] + out_dx syzos_api$x86[170, syzos_api_out_dx] ] [varlen] kvm_text_x86 [ |
