Commit c0c76d9
KVM: selftests: Add helpers to make Xen-style VMCALL/VMMCALL hypercalls
Add wrappers to do hypercalls using VMCALL/VMMCALL and Xen's register ABI
(as opposed to full Xen-style hypercalls through a hypervisor provided
page). Using the common helpers dedups a pile of code, and uses the
native hypercall instruction when running on AMD.
Signed-off-by: Sean Christopherson <seanjc@google.com>
Message-Id: <20230204024151.1373296-3-seanjc@google.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>1 parent 4009e0b commit c0c76d9
3 files changed
Lines changed: 21 additions & 54 deletions
File tree
- tools/testing/selftests/kvm
- include/x86_64
- lib/x86_64
- x86_64
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1063 | 1063 | | |
1064 | 1064 | | |
1065 | 1065 | | |
| 1066 | + | |
| 1067 | + | |
1066 | 1068 | | |
1067 | 1069 | | |
1068 | 1070 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1161 | 1161 | | |
1162 | 1162 | | |
1163 | 1163 | | |
| 1164 | + | |
| 1165 | + | |
| 1166 | + | |
| 1167 | + | |
| 1168 | + | |
| 1169 | + | |
| 1170 | + | |
| 1171 | + | |
| 1172 | + | |
| 1173 | + | |
1164 | 1174 | | |
1165 | 1175 | | |
1166 | 1176 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
225 | 225 | | |
226 | 226 | | |
227 | 227 | | |
228 | | - | |
229 | 228 | | |
230 | | - | |
231 | | - | |
232 | | - | |
233 | | - | |
234 | | - | |
235 | | - | |
236 | | - | |
| 229 | + | |
237 | 230 | | |
238 | 231 | | |
239 | 232 | | |
| |||
242 | 235 | | |
243 | 236 | | |
244 | 237 | | |
245 | | - | |
246 | | - | |
247 | | - | |
248 | | - | |
249 | | - | |
250 | | - | |
251 | | - | |
| 238 | + | |
252 | 239 | | |
253 | 240 | | |
254 | 241 | | |
255 | 242 | | |
256 | 243 | | |
257 | 244 | | |
258 | | - | |
259 | | - | |
260 | | - | |
261 | | - | |
262 | | - | |
| 245 | + | |
| 246 | + | |
263 | 247 | | |
264 | 248 | | |
265 | 249 | | |
| |||
281 | 265 | | |
282 | 266 | | |
283 | 267 | | |
284 | | - | |
285 | | - | |
286 | | - | |
287 | | - | |
288 | | - | |
289 | | - | |
290 | | - | |
| 268 | + | |
291 | 269 | | |
292 | 270 | | |
293 | 271 | | |
294 | 272 | | |
295 | 273 | | |
296 | | - | |
297 | | - | |
298 | | - | |
299 | | - | |
300 | | - | |
301 | | - | |
302 | | - | |
| 274 | + | |
303 | 275 | | |
304 | 276 | | |
305 | 277 | | |
306 | 278 | | |
307 | 279 | | |
308 | | - | |
309 | | - | |
310 | | - | |
311 | | - | |
312 | | - | |
313 | | - | |
314 | | - | |
| 280 | + | |
315 | 281 | | |
316 | 282 | | |
317 | 283 | | |
318 | 284 | | |
319 | 285 | | |
320 | 286 | | |
321 | 287 | | |
322 | | - | |
323 | | - | |
324 | | - | |
325 | | - | |
326 | | - | |
327 | | - | |
328 | | - | |
| 288 | + | |
329 | 289 | | |
330 | 290 | | |
331 | 291 | | |
| |||
360 | 320 | | |
361 | 321 | | |
362 | 322 | | |
363 | | - | |
364 | | - | |
365 | | - | |
366 | | - | |
367 | | - | |
368 | | - | |
| 323 | + | |
369 | 324 | | |
370 | 325 | | |
371 | 326 | | |
| |||
0 commit comments