Commit Graph

1303 Commits

Author SHA1 Message Date
Edwin Zhai a98113bfce HV: fully check VMCS control settings
Reshuffle VMX init code, and check both allowed 0-settings and
1-settings of related MSR to make the final VMCS control value.

Signed-off-by: Edwin Zhai <edwin.zhai@intel.com>
Acked-by: Anthony Xu <anthony.xu@intel.com>
2018-08-02 14:54:00 +08:00
Mingqiang Chi ae8836d960 hv:fix return value violation for vioapic_get_rte
Change this API to void type
Add pre-condition, state the input parameters are not NULL.

Signed-off-by: Mingqiang Chi <mingqiang.chi@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2018-08-02 14:47:43 +08:00
Yonghua Huang cd3a62f89b HV: Refine invalid parameter handling in hypervisor shell
- print error message for command parameter error
   when callback/handler is called.

Signed-off-by: Yonghua Huang <yonghua.huang@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2018-08-02 14:34:30 +08:00
Mingqiang Chi 61782d7430 hv:Rename port/mmio read and write APIs
mmio_write_long --> mmio_write32
mmio_write_word --> mmio_write16
mmio_write_byte --> mmio_write8
mmio_read_long  --> mmio_read32
mmio_read_word  --> mmio_read16
mmio_read_byte  --> mmio_read8

io_write_long --> pio_write32
io_write_word --> pio_write16
io_write_byte --> pio_write8
io_read_long  --> pio_read32
io_read_word  --> pio_read16
io_read_byte  --> pio_read8
io_write      --> pio_write
io_read       --> pio_read

setl --> set32
setw --> set16
setb --> set8

igned-off-by: Mingqiang Chi <mingqiang.chi@intel.com>
2018-08-02 14:03:38 +08:00
Yin Fengwei 7db4c0aac9 DM: Add funciton to update PM_WAK_STS
According to ACPI spec, when system back to working mode from
S3, WAK_STS bit (15) should be set.

Signed-off-by: Yin Fengwei <fengwei.yin@intel.com>
Reviewed-by: Victor Sun <victor.sun@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2018-08-02 13:14:03 +08:00
Yin Fengwei a8a27d82d0 dm: add S3 support for UOS
We do:
 - pause target vm
 - suspend all virtual devices
 - wait for resume notification
 - resume all virtual devices
 - reset target vm

Signed-off-by: Yin Fengwei <fengwei.yin@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2018-08-02 13:14:03 +08:00
Yin Fengwei 8ee4c0b1dd DM: add vm_stop/reset_watchdog
When guest enter/exit S3, we need to do
1. stop watchdog timer when guest enter S3 to avoid watchdog
   timer reset guest when guest is in S3 state.
2. reset watchdog timer when guest exit from S3.

Signed-off-by: Yin Fengwei <fengwei.yin@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2018-08-02 13:14:03 +08:00
Yin Fengwei a2241d983d DM: register pm ops to monitor
Then, acrnctl could send command to monitor module of DM and call
functions defined in pm ops. One example is: acrnctl resume UOS
after UOS enter S3.

Also add general pm.c and move pm related function to this file.

Signed-off-by: Yan Like <like.yan@intel.com>
Signed-off-by: Yin Fengwei <fengwei.yin@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2018-08-02 13:14:03 +08:00
Yin Fengwei f576f97ea8 hv: add vm restart API
And export the API to DM. DM will do system reboot/S3 resume based
on this API.

Also add the pre-assumption description for some vm APIs.

Signed-off-by: Yin Fengwei <fengwei.yin@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2018-08-02 13:14:03 +08:00
Yin Fengwei a4eebb0ef8 hv: cleanup inline assembly code in vmx.c a little bit
1. We could explicitly use specific register to avoid one more
   register allocated.
2. If we explicitly assign register, it's not neccessary to
   add the register in clobber list according to gcc mannual.
3. For vmptrld, we add memory to clobber list also.

Signed-off-by: Yin Fengwei <fengwei.yin@intel.com>
Reviewed-by: Edwin Zhai <edwin.zhai@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2018-08-02 13:14:03 +08:00
Xiangyang Wu 77c3917544 HV:treewide:avoid using multiple # or ## in a macro
In the C99 standard, the order of evaluation associated with
multiple #, multiple ## or a mix of # and ## preprocessor
operator is unspecified. For this case, gcc 7.3.0 manual
does not specify related implementation. So it is unsafe
to use multiple # or ## in a macro.
BTW, there are some macros with one or more "##" which are
not used by hypervisor.

Update relate codes to avoid using multiple # or ## in a macro;
Remove unused macros with one or more "##";
Remove "struct __hack;" at the end of GETCC since it is useless.

Note:
     '##' operator usage constraints: A ## preprocessing token shall
     not occur at the beginning or at the end of a replacement list
     for either form of macro definition.
V1--V2:
	Update relate codes to avoid using multiple # or ## in a macro.
V2-->V3:
	Remove unused macros with one or more "##";
	Remove "struct __hack;" at the end of GETCC since it is useless.

Signed-off-by: Xiangyang Wu <xiangyang.wu@linux.intel.com>
Reviewed-by: Junjie Mao <junjie.mao@intel.com>
2018-08-02 13:10:16 +08:00
Sainath Grandhi 581a336bc8 HV: Add Partitioning mode option for ACRN
Adding Kconfig option to choose and compile partitioning mode for ACRN.
Current implementation does not allow ACRN to support sharing mode
and partitioning mode out of a single binary.

Signed-off-by: Sainath Grandhi <sainath.grandhi@intel.com>
2018-08-02 12:58:09 +08:00
Mingqiang Chi 93ed0371a0 hv:cleanup console/uart code
-- Check uart enabled flag, it will return if the flag is false.
-- Add function declaration (uart16550_set_property) in console.h
-- Remove unnecessary function declaration(get_serial_handle)
-- Change uart_enabled and port_mapped to bool
-- Fix MISRA-C integer violations

Signed-off-by: Mingqiang Chi <mingqiang.chi@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2018-08-02 11:25:40 +08:00
Yonghua Huang 22005c6bf6 HV: Refine hypervisor shell commands
- removed shell commands:
    --vcpu_pause
    --vcpu_resume
    --lsreq
    --(warm) reboot
    --vcpu_dumpmem

 - updated shell commands:
    --vm_console    -> sos_console
    --trigger crash  -> reboot
    --merge 'set_loglevel' & 'get_loglevel' to 'loglevel'

 - new adding shell commands:
   --dumpmem  --> dump host physical memory

 - other update
   update the type of return value of 'shell_input_line()'
   from 'uint8_t' to 'bool' and update related source code.

Signed-off-by: Yonghua Huang <yonghua.huang@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2018-08-02 11:21:16 +08:00
Huihuang Shi 1664e0c842 HV:fix rest integer violations
Fix integer related violations.
V1->V2:
  clean all memset/calloc integer violations excpet bsp/boot directory

Signed-off-by: Huihuang Shi <huihuang.shi@intel.com>
Reviewed-by: Junjie Mao <junjie.mao@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2018-08-02 09:51:58 +08:00
David B. Kinder 56904bc235 doc: CSS tweak for table caption location
Default behavior is for figure captions below the figure, but table
captions above the table.  Tweak the CSS for tables to put the caption
below instead.

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2018-08-01 11:18:49 -07:00
Alek Du 64f62959dc acrn-manager: create acrn-hypervisor-dev package
As first step to separate misc folder into github/intel/ioc-cbc-tools we
need let acrn create devel package. This package will let ioc-cbc-tools
use acrn manager interface API to control lifecycle.

The Clear Linux autospec script will *detect* /usr/include/acrn/*.h and
thus help us create the devel package. This devel pacakge will be in the
build_req for ioc-cbc-tools autospec.

Signed-off-by: Alek Du <alek.du@intel.com>
Reviewed-by: Yu Wang <yu1.wang@intel.com>
Reviewed-by: Like Yan <like.yan@intel.com>
2018-08-01 15:55:10 +08:00
Shiqing Gao 51c75e9e3c hv: treewide: fix 'Function prototype/defn param type mismatch'
Fix the parameter type mismatch between API declaration and definition.

Signed-off-by: Shiqing Gao <shiqing.gao@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2018-08-01 15:53:29 +08:00
Zhang, wenling cf8fd8cfbc Revert "HV: clear memory region used by UOS before it exit"
This reverts commit cf7a94071b.
2018-08-01 11:32:31 -04:00
Yonghua Huang 9c24c5c85d HV:Remame 'shell_internal.c' to 'shell.c'
Rename it as 'shell_public.c' has been deleted.

Signed-off-by: Yonghua Huang <yonghua.huang@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2018-08-01 12:49:27 +08:00
Yonghua Huang 3b06282187 HV:Remove i/o session sw interface from hypervisor shell
to remove it as no requirement of bounding i/o handlers
  dynamically in hypervisor shell

  - update source code related with i/o session

  - move shell command definitions from shell_pulic.c
    to shell_internal.c

  - remove shell_public.c

Signed-off-by: Yonghua Huang <yonghua.huang@intel.com>
Reviewed-by: Jason Chen CJ <jason.cj.chen@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2018-08-01 12:49:27 +08:00
Jason Chen CJ a8e9d83e59 samples: change WIFI BDF to 3:0:0
SBL used to use 4:0:0 for WIFI device BDF, now it change back to 3:0:0

Signed-off-by: Jason Chen CJ <jason.cj.chen@intel.com>
2018-08-01 12:46:25 +08:00
Victor Sun 00bfde3cde HV: rename resume_vm to start_vm in hypercall api
Currently we don't support resume VM in HC API, the real meaning
of the code is to start VM.

Signed-off-by: Victor Sun <victor.sun@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2018-08-01 12:06:54 +08:00
Yuan Liu 5e31e7c66f IOC mediator: Add parking brake and Hvac signals
This patch adds new signals about parking brake and Hvac in the signal
definition and signal whitelist.

Signed-off-by: Yuan Liu <yuan1.liu@intel.com>
Acked-by: Yu Wang <yu1.wang@intel.com>
2018-08-01 11:37:19 +08:00
Li, Fei1 457ecd6ef7 hv: softirq: refine softirq
1. add register_softirq to register a softirq handler
2. rename exec_softirq to do_softirq; raise_softirq to fire_softirq.
3. in do_softirq call registered softirq handler not call
the device softirq handle function directly
4. enable irq after vm exit and disable irq after the first
call do_softirq before vm enter.
5. call do_softirq again when irq disabled to handle the risk
unhandled softirq.
6. rename SOFTIRQ_DEV_ASSIGN to SOFTIRQ_PTDEV
7. remove SOFTIRQ_ATOMIC

Signed-off-by: Li, Fei1 <fei1.li@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2018-08-01 11:36:27 +08:00
Li, Fei1 073583cc41 hv: softirq: move softirq.c to common directory
Softirq is not x86 architectural related.

Signed-off-by: Li, Fei1 <fei1.li@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
Reviewed-by: Jason Chen CJ <jason.cj.chen@intel.com>
2018-08-01 11:36:27 +08:00
Yin Fengwei dec24a9f9f hv: add check to invalid CR8 writting from guest
According to SDM, inject #GP(0) if guest tries to write reserved
bit of CR8.

Signed-off-by: Yin Fengwei <fengwei.yin@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2018-08-01 11:35:30 +08:00
Yin Fengwei 13a50c929d hv: Explicitly trap VMXE and PCIDE bit for CR4 write
Now, we let guest own most CR4 bit. Which means guest
handles whether the CR4 writting is invalid or not and
GP injection if it's invalid writing.

Two bits are exception here:

we filter VMX and PCID feature to guest (which means
they are supported on native).

So we can't depends on guest to inject GP for these bits.
Instead, we should explicitly trap these CR4 bits update
and inject GP to guest from HV.

Signed-off-by: Yin Fengwei <fengwei.yin@intel.com>
Acked-by: Anthony Xu <anthony.xu@intel.com>
2018-08-01 11:35:30 +08:00
Yin Fengwei f0ef41c754 hv: Extend the always off mask of CR0 and CR4
According to SDM:
writing a nonzero value to 63:32 bits of CR0 and CR4 results #GP(0).
writing a nonzero value to reserved bit of CR4 results #GP(0).

We merge the check with always off mask of CR0 and CR4.

Signed-off-by: Yin Fengwei <fengwei.yin@intel.com>
Acked-by: Anthony Xu <anthony.xu@intel.com>
2018-08-01 11:35:30 +08:00
Yin Fengwei d18642a8a6 hv: Add function to check whether cr0 written operation is valid
Move the check to delicated function and do the check as early
as possible.

Add more check and inject GP to guest if check fails according to
SDM.

Signed-off-by: Yin Fengwei <fengwei.yin@intel.com>
Reviewed-by: Anthony Xu <anthony.xu@intel.com>
2018-08-01 11:35:30 +08:00
David B. Kinder ce7257e12e doc: tweak logo href to projectacrn.org
Have the logo link to the project site rather than the doc site

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2018-07-31 12:04:36 -07:00
David B. Kinder 6d2553532a doc: fix doc errors from acrn_vhm_mm.h API changes
API changes to acrn-kernel/include/linux/vhm/acrn_vhm_mm.h in
https://github.com/projectacrn/acrn-kernel/pull/48 renamed functions
that were referenced in the GTG-g_api.rst document, causing the
documentation build to fail.

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2018-07-31 09:47:46 -07:00
David B. Kinder 014bef6fec doc: add virtio-console HLD document
transcode, review, and publish virtio-console developer-guides doc

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2018-07-31 09:47:27 -07:00
Binbin Wu 50af102872 dm: bios: update vSBL binary to v0.8
Update vSBL with the following new features:
	Support watchdog status report when boot.
	Update vFastboot version to 0.8
Add a changelog file.
Add a md5sum file of vSBL images.

Signed-off-by: Binbin Wu <binbin.wu@intel.com>
2018-07-31 12:49:19 +08:00
CHEN Gang 87a4abdd9d tools: acrn-crashlog: fix build warnings with gcc8.1.1
This patch is to fix the build warning with gcc8.1.1. Most of them are
warnings for buffer overflow from snprintf and strncpy.

Signed-off-by: CHEN Gang <gang.c.chen@intel.com>
Reviewed-by: Zhi Jin <zhi.jin@intel.com>
Reviewed-by: Liu, Xinwu <xinwu.liu@intel.com>
Reviewed-by: xiaojin2 <xiaojing.liu@intel.com>
2018-07-31 11:24:11 +08:00
Xiangyang Wu 6e77a8d5f1 HV:treewide:rename enum vpic_wire_mode, stack_canary, segment_override, pde_index
For data structure types "enum vpic_wire_mode, struct stack_canary",
its name is identical with variable name in the same scope.
This MISRA C  violation is detected by static analysis tool.
For variables "segment_override, pde_index", its name is identical
with function name. This MISRA C  violation is detected.
Naming convention rule:Variable name can be shortened from
its data structure type name.

The following udpates are made:
enum vpic_wire_mode vpic_wire_mode-->enum vpic_wire_mode wire_mode
struct stack_canary stack_canary-->struct stack_canary stk_canary
uint8_t segment_override:1 --> uint8_t seg_override:1
uint32_t pde_index--> uint32_t pde_idx

V1-->V2:
	Remove update "enum cpu_state cpu_state-->enum cpu_state state"
	and "enum irqstate irqstate-->enum irq_ops_mode ops_mode", other
	patch will cover it.
V2-->V3:
	Update "uint32_t pde_index--> uint32_t pde_idx".

Signed-off-by: Xiangyang Wu <xiangyang.wu@linux.intel.com>
2018-07-31 11:20:21 +08:00
Wei Liu 52fe9f419f hv: use macro instead of specify number
use macro instead of specify number

Signed-off-by: Wei Liu <weix.w.liu@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2018-07-31 11:17:11 +08:00
Xie, nanlin 8ed98d33b7 DM: fix make install issue in auto boot UOS service
fix make install issue

Signed-off-by: Nanlin Xie <nanlin.xie@intel.com>
2018-07-31 10:37:44 +08:00
Xiangyang Wu 8e2c730043 HV:VLAPIC:add suffix "_fn" for function pointer
For some function pointer type, its name is identical with
variable name in the same scope. This MISRA C violation is
detected.

Naming convention rule:If the type is function
pointer, its name needs suffix "_fn".

The following udpates are made:
*apicv_set_intr_ready-->*apicv_set_intr_ready_fn
*apicv_pending_intr-->*apicv_pending_intr_fn
*apicv_set_tmr-->*apicv_set_tmr_fn
*apicv_batch_set_tmr-->*apicv_batch_set_tmr_fn
*apicv_intr_accepted-->*apicv_intr_accepted_fn
*apicv_post_intr-->*apicv_post_intr_fn
*enable_x2apic_mode-->*enable_x2apic_mode_fn

V1-->V2:
	Update function pointer when it is used as calling
	since no need to dereference a function pointer
	before calling.

Signed-off-by: Xiangyang Wu <xiangyang.wu@linux.intel.com>
Reviewed-by: Junjie Mao <junjie.mao@intel.com>
2018-07-31 10:33:22 +08:00
Xiangyang Wu 2c95a8c4aa HV:treewide:rename struct pic and iommu_domain
For data structure types "struct pic and struct iommu_domain",
its name is identical with variable name in the same scope.
This MISRA C  violation is detected.

Naming convention rule:If the data structure type is used by only one
module and its name meaning is simplistic, its name needs prefix
shorten module name.
Naming convention rule:Variable name can be shortened from its
data structure type name.

The following udpates are made:
struct pic pic-->struct i8259_reg_state i8259
struct iommu_domain iommu_domain-->struct iommu_domain iommu

V1-->V2:
	Update "struct iommu_domain iommu_domain-->struct iommu_domain iommu"

Signed-off-by: Xiangyang Wu <xiangyang.wu@linux.intel.com>
Reviewed-by: Junjie Mao <junjie.mao@intel.com>
2018-07-31 10:33:22 +08:00
Junjie Mao 17771c0ac2 HV: io: refine state transitions of VHM requests
Instead of using two members for maintaining the state of a VHM request, this
patch replaces the transitions with a single state. Basically the lifecycle of a
VHM request shall be:

    FREE -> PENDING -> PROCESSING -> COMPLETE -> FREE -> ...

The structure header of vhm_request has more details of the transitions access
limitations under different states.

Also drop the set but unused member vcpu.ioreq_pending.

For backward-compatibility, the obsolete 'valid' member is still kept and
maintained before SOS and DM adapts to the new state transitions.

v2 -> v3:

    * Use complete_ioreq to mark an I/O request finished in
      dm_emulate_(pio|mmio)_post.

Signed-off-by: Junjie Mao <junjie.mao@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2018-07-31 10:22:03 +08:00
Junjie Mao 941eb9db02 HV: io: move I/O emulation post-work to io.c
There are some functions for the post work of I/O emulation. This patch moves
these functions to io.c for clarity. No functional change introduced.

Signed-off-by: Junjie Mao <junjie.mao@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2018-07-31 10:22:03 +08:00
Junjie Mao d8179519b9 HV: io: add post-work for PCICFG and WP requests
Currently no post-work is done for I/O requests of type PCICFG or WP. The
impacts include:

    1. ''valid'' in VHM request buffers are left as 1 even after the I/O request
       completes. This violates the pre-condition of acrn_insert_request_wait()
       but does not cause failures since a new I/O request can never happen
       before the previous one completes.

    2. Values read from PCI configuration spaces are never passed to UOS.

This patch adds the post-work for these two kinds of I/O requests. The post-work
for port I/O is invoked for PCICFG since it is essentially a port I/O and the
request structure is compatible. No post-work is needed for WP as it is only
triggered for EPT violations on writes, while post-work is mainly for reads.

v2 -> v3:

    * Consistently use 0/1 (not false/true) for the ''valid'' member.
    * Add comments to suggest when the hypervisor can see REQ_PCICFG and why
      dm_emulate_pio_post also works in such cases.
    * Rename: mark_ioreq_done -> complete_ioreq
    * Rename: complete_request -> emulate_io_post
    * Rename: hcall_notify_req_finish -> hcall_notify_ioreq_finish

Signed-off-by: Junjie Mao <junjie.mao@intel.com>
Reviewed-by: Jason Chen CJ <jason.cj.chen@intel.com>
2018-07-31 10:22:03 +08:00
Junjie Mao 26ab2c9146 HV: io: move MMIO handler registration to io.c
This patch solely moves MMIO handler registration APIs from ept.c to io.c as it
is related more to I/O request handling.

Signed-off-by: Junjie Mao <junjie.mao@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2018-07-31 10:22:03 +08:00
Junjie Mao b21b172347 HV: io: refactoring vmexit handler on EPT violation
This is the counterpart to the PIO emulation side.

1. ept_violation_vmexit_handler (entry point for handling vmexit on EPT instruction):

    Extract mmio address, size, direction and value (for write only), fill in an
    I/O request, invoke do_io to handle that and emulate_pio_post for
    post-processing.

2. emulate_io

    Handle the given I/O request, either completed by registered MMIO handlers
    or sent to VHM.

3. emulate_mmio_post:

    Update guest registers after the emulation is done.

v2 -> v3:

    * Rename: emulate_mmio_by_handler -> hv_emulate_mmio.
    * Inline the original hv_emulate_mmio.
    * No longer check alignment. The handlers are responsible for handling
      unaligned accesses.

v1 -> v2:

    * Rename: do_io -> emulate_io.

Signed-off-by: Junjie Mao <junjie.mao@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2018-07-31 10:22:03 +08:00
Junjie Mao 50e4bc1758 HV: io: refactoring vmexit handler on I/O instruction
This patch refactors how I/O instructions are emulated, in order for a unify the
I/O emulation path. The major control flow includes:

1. pio_instr_vmexit_handler (entry point for handling vmexit on I/O instruction):

    Extract port address, register size, direction and value (for write only),
    fill in an I/O request (of type io_request), invokes do_io to handle that
    and update the guest registers if the request has been successfully handled
    when do_io returns.

2. emulate_io:

    Handle the given I/O request. The request is handled or sent to VHM if it
    returns 0 (the actual status can be found in io_req->processed). On errors a
    negative error code is returned.

3. emulate_pio_by_handler:

    Look for the PIO handler for the given request and invoke that
    handler. Return 0 if a proper handler is found and invoked (the status of
    the emulation can be found in io_req->processed), -EIO when the request
    spans across devices, and -ENODEV when no handler is found.

4. emulate_pio_post:

    Update guest registers after the emulation is done. Currently this can
    happen either right after do_io() or after the vcpu is resumed. Status check
    on the I/O request and follow-up actions on failure will also go here.

Note:

Currently do_io can return 0 with io_req->processed being REQ_STATE_PENDING if
the request is sent to VHM for further processing. In this case the current vcpu
will be paused after handling this vm_exit, and dm_emulate_pio_post will be
invoked to do the rest after this vcpu is resumed. When vcpus are scheduled back
to exactly where they are scheduled out later, do_io should be responsible for
the post_work and the processing of do_io results shall be mostly the same.

v2 -> v3:

    * Rename: emulate_pio_by_handler -> hv_emulate_pio.
    * Properly mask the value passed to port I/O handler.

v1 -> v2:

    * Rename: do_io -> emulate_io.
    * Rename io_instr_vmexit_handler -> pio_instr_vmexit_handler to reflect the
      fact that it handles port I/O only.

Signed-off-by: Junjie Mao <junjie.mao@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2018-07-31 10:22:03 +08:00
David B. Kinder d4d8a128cf doc: tweak formatting for :kbd: role
update custom css to make kbd tag more interesting

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2018-07-30 16:13:03 -07:00
David B. Kinder 9c3d77e4b9 doc: tweek known-issues pattern for hypercall API
Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2018-07-30 10:34:42 -07:00
Mingqiang Chi 99ebd926c2 hv:Delete serial files
Delete 3 serial files

Signed-off-by: Mingqiang Chi <mingqiang.chi@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
	deleted:    debug/serial.c
	deleted:    debug/serial_internal.h
	deleted:    include/debug/serial.h
2018-07-30 16:25:16 +08:00
Mingqiang Chi ae3004028b hv:Reshuffle console/uart code
The current hierarchy :
  CONSOLE --> SERIAL -->UART DRIVER
This patch remove SERIAL layer, that is console will
call UART driver directly, change it to:
  CONSOLE  --> UART DRIVER
Remove some related data structures and registration and callback.
Cleanup vuart.c

Signed-off-by: Mingqiang Chi <mingqiang.chi@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2018-07-30 16:25:16 +08:00