This patch adds the MTRR MSRs save/restore support. Signed-off-by: Disheng Su <disheng.su@intel.com> _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Define a new save/restore structure, with its own save/restore routines, rather than appending to hvm_hw_vcpu. Do not declare extern functions in .c files (decalring those functions as save/restore handlers for your new state structure may get rid of those externs anyway). You cannot include Xen private header files from public header files, so you cannot get at <asm/mtrr.h>. You''ll need to define appropriate array sizes in the save.h header file independently of private Xen header files. Hopefully the state you are saving is architectural and so has ''well known'' sizes and ranges that we won''t mind hardcoding in a public header file? -- Keir On 10/12/07 06:00, "Su, Disheng" <disheng.su@intel.com> wrote:> This patch adds the MTRR MSRs save/restore support. > > Signed-off-by: Disheng Su <disheng.su@intel.com> > _______________________________________________ > Xen-devel mailing list > Xen-devel@lists.xensource.com > http://lists.xensource.com/xen-devel_______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Keir Fraser wrote:> Define a new save/restore structure, with its own save/restore > routines, rather than appending to hvm_hw_vcpu. Do not declare extern > functions in .c files (decalring those functions as save/restore > handlers for your new state structure may get rid of those externs > anyway). You cannot include Xen private header files from public > header files, so you cannot get at <asm/mtrr.h>. You''ll need to > define appropriate array sizes in the save.h header file > independently of private Xen header files. Hopefully the state you > are saving is architectural and so has ''well known'' sizes and ranges > that we won''t mind hardcoding in a public header file? >Attached patch is per your comments. The> -- Keir > > On 10/12/07 06:00, "Su, Disheng" <disheng.su@intel.com> wrote: > >> This patch adds the MTRR MSRs save/restore support. >> >> Signed-off-by: Disheng Su <disheng.su@intel.com> >> _______________________________________________ >> Xen-devel mailing list >> Xen-devel@lists.xensource.com >> http://lists.xensource.com/xen-develBest Regards, Disheng, Su _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel