@@ -299,66 +299,54 @@ Initialization and Deinitialization
299
299
300
300
The following structure represents a port I/O handler:
301
301
302
- .. note :: add reference to vm_io_handler_desc definition in ioreq.h
302
+ .. doxygenstruct :: vm_io_handler_desc
303
+ :project: Project ACRN
303
304
304
305
The following structure represents a MMIO handler.
305
306
306
- .. note :: add reference to mem_io_node definition in ioreq.h
307
-
307
+ .. doxygenstruct :: mem_io_node
308
+ :project: Project ACRN
308
309
309
310
The following APIs are provided to initialize, deinitialize or configure
310
311
I/O bitmaps and register or unregister I/O handlers:
311
312
312
- .. code-block :: c
313
-
314
- /* Initialize the I/O bitmap for vm. */
315
- void setup_io_bitmap(struct vm *vm)
316
-
317
- /* Allow a VM to access a port I/O range.
318
- * This API enables direct access from the given vm to the port I/O space
319
- * starting from address_arg to address_arg + nbytes - 1.
320
- */
321
- void allow_guest_io_access(struct vm *vm, uint32_t address_arg, uint32_t nbytes)
313
+ .. doxygenfunction :: setup_io_bitmap
314
+ :project: Project ACRN
322
315
323
- /* Free I/O bitmaps and port I/O handlers of vm. */
324
- void free_io_emulation_resource(struct vm *vm)
316
+ .. doxygenfunction :: allow_guest_pio_access
317
+ :project: Project ACRN
325
318
326
- /* Register a port I/O handler. */
327
- void register_io_emulation_handler(struct vm *vm, struct vm_io_range *range,
328
- io_read_fn_t io_read_fn_ptr, io_write_fn_t io_write_fn_ptr)
319
+ .. doxygenfunction :: free_io_emulation_resource
320
+ :project: Project ACRN
329
321
330
- /* Register a MMIO handler. */
331
- int register_mmio_emulation_handler(struct vm *vm, hv_mem_io_handler_t read_write,
332
- uint64_t start, uint64_t end, void *handler_private_data)
322
+ .. doxygenfunction :: register_io_emulation_handler
323
+ :project: Project ACRN
333
324
334
- /* Unregister a MMIO handler.*/
335
- void unregister_mmio_emulation_handler(struct vm *vm, uint64_t start, uint64_t end)
325
+ .. doxygenfunction :: register_mmio_emulation_handler
326
+ :project: Project ACRN
336
327
337
- .. note :: change these to reference API material from ioreq.h
328
+ .. doxygenfunction :: unregister_mmio_emulation_handler
329
+ :project: Project ACRN
338
330
339
331
I/O Emulation
340
332
=============
341
333
342
334
The following APIs are provided for I/O emulation at runtime:
343
335
344
- .. code-block :: c
345
-
346
- /* Emulate the given I/O access for vcpu. */
347
- int32_t emulate_io(struct vcpu *vcpu, struct io_request *io_req)
348
-
349
- /* Deliver io_req to SOS and suspend vcpu till its completion. */
350
- int32_t acrn_insert_request_wait(struct vcpu *vcpu, struct io_request *io_req)
336
+ .. doxygenfunction :: emulate_io
337
+ :project: Project ACRN
351
338
352
- /* General post-work for port I/O emulation. */
353
- void emulate_io_post(struct vcpu *vcpu)
339
+ .. doxygenfunction :: acrn_insert_request_wait
340
+ :project: Project ACRN
354
341
355
- /* General post-work for MMIO emulation. */
356
- void emulate_mmio_post(struct vcpu *vcpu, struct io_request *io_req)
342
+ .. doxygenfunction :: emulate_io_post
343
+ :project: Project ACRN
357
344
358
- /* Post-work of I/O requests for MMIO. */
359
- void dm_emulate_mmio_post(struct vcpu *vcpu)
345
+ .. doxygenfunction :: emulate_mmio_post
346
+ :project: Project ACRN
360
347
361
- /* The handler of VM exits on I/O instructions. */
362
- int32_t pio_instr_vmexit_handler(struct vcpu *vcpu)
348
+ .. doxygenfunction :: dm_emulate_mmio_post
349
+ :project: Project ACRN
363
350
364
- .. note :: change these to reference API material from ioreq.h
351
+ .. doxygenfunction :: pio_instr_vmexit_handler
352
+ :project: Project ACRN
0 commit comments