Re: [PATCH v5 23/23] sev: add migration blocker

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



* Brijesh Singh (brijesh.singh@xxxxxxx) wrote:
> SEV guest migration is not yet implemented yet.
> 
> Signed-off-by: Brijesh Singh <brijesh.singh@xxxxxxx>
> ---
>  accel/kvm/sev.c | 13 +++++++++++++
>  1 file changed, 13 insertions(+)
> 
> diff --git a/accel/kvm/sev.c b/accel/kvm/sev.c
> index 3edfb5b08416..10647645eacd 100644
> --- a/accel/kvm/sev.c
> +++ b/accel/kvm/sev.c
> @@ -19,6 +19,7 @@
>  #include "sysemu/sev.h"
>  #include "sysemu/sysemu.h"
>  #include "qapi-event.h"
> +#include "migration/blocker.h"
>  
>  #define DEFAULT_GUEST_POLICY    0x1 /* disable debug */
>  #define DEFAULT_SEV_DEVICE      "/dev/sev"
> @@ -36,6 +37,7 @@
>  static int sev_fd;
>  static SEVState *sev_state;
>  static MemoryRegionRAMReadWriteOps  sev_ops;
> +static Error *sev_mig_blocker;
>  
>  #define SEV_FW_MAX_ERROR      0x17
>  
> @@ -460,6 +462,7 @@ static void
>  sev_launch_finish(SEVState *s)
>  {
>      int ret, error;
> +    Error *local_err = NULL;
>  
>      ret = sev_ioctl(KVM_SEV_LAUNCH_FINISH, 0, &error);
>      if (ret) {
> @@ -470,6 +473,16 @@ sev_launch_finish(SEVState *s)
>  
>      s->cur_state = SEV_STATE_RUNNING;
>      DPRINTF("SEV: LAUNCH_FINISH\n");

(from a previous patch)
Please use the tracing facility rather than new DPRINTF's
if possible - if you've not used it before, then
--enable-trace-backends=log   is the easy way to get going
and you can turn on and off the stuff you're interested in
tracing at run time without having to rebuild.

> +
> +    /* add migration blocker */
> +    error_setg(&sev_mig_blocker,
> +               "SEV: Migration is not implemented");
> +    ret = migrate_add_blocker(sev_mig_blocker, &local_err);
> +    if (local_err) {
> +        error_report_err(local_err);
> +        error_free(sev_mig_blocker);
> +        exit(1);
> +    }

Yep, reasonable:


Reviewed-by: Dr. David Alan Gilbert <dgilbert@xxxxxxxxxx>

>  }
>  
>  static void
> -- 
> 2.9.5
> 
--
Dr. David Alan Gilbert / dgilbert@xxxxxxxxxx / Manchester, UK



[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux