Mailing List Archive

Cs 13594 - broken?
> i'm almost sure following change set break 32b HVM guest
> save/restore on
> 64b hypvisor:
> r13594: Make domctl/sysctl interfaces 32-/64-bit invariant.
>
> restoring 32b linux cause a guest kernel panic, but restoring saved
> image from previous changeset is okay. i.e. saved image
> become damaged
> in r13594.

Looking at that patch (and the current changeset matches the patch for
the below code with about +30 lines offset), I think this code is
broken:
@@ -976,10 +976,16 @@ int xc_linux_save(int xc_handle, int io_
goto out;
}

- if (xc_get_pfn_type_batch(xc_handle, dom, batch, pfn_type))
{
+ for ( j = 0; j < batch; j++ )
+ ((uint32_t *)pfn_type)[i] = pfn_type[i];
Shouldn't that be [j] in both places?
+ if ( xc_get_pfn_type_batch(xc_handle, dom, batch,
+ (uint32_t *)pfn_type) )
+ {
ERROR("get_pfn_type_batch failed");
goto out;
}
+ for ( j = batch-1; j >= 0; j-- )
+ pfn_type[i] = ((uint32_t *)pfn_type)[i];
And here, as well?


Admittedly, this probably won't fix the 32/64 HVM restore being broken,
but I doubt that the code ACTUALLY works as it stands today.

I'm still trying to find a reason for the restore not working...

--
Mats



_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xensource.com
http://lists.xensource.com/xen-devel
Re: Cs 13594 - broken? [ In reply to ]
At 13:55 +0100 on 31 Jan (1170251725), Petersson, Mats wrote:
> Shouldn't that be [j] in both places?

Yep; that's fixed in the staging tree, but hasn't made it to the public
tree yet.

Cheers,

Tim.


_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xensource.com
http://lists.xensource.com/xen-devel
RE: Cs 13594 - broken? [ In reply to ]
> -----Original Message-----
> From: Tim Deegan [mailto:Tim.Deegan@xensource.com]
> Sent: 31 January 2007 13:01
> To: Petersson, Mats
> Cc: edwin.zhai@intel.com; Keir; xen-devel@lists.xensource.com
> Subject: Re: [Xen-devel] Cs 13594 - broken?
>
> At 13:55 +0100 on 31 Jan (1170251725), Petersson, Mats wrote:
> > Shouldn't that be [j] in both places?
>
> Yep; that's fixed in the staging tree, but hasn't made it to
> the public
> tree yet.

So it is - sorry for the duplicated error report... :-(

--
Mats
>
> Cheers,
>
> Tim.
>
>
>
>



_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xensource.com
http://lists.xensource.com/xen-devel