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

Re: [Xen-devel] [PATCH v13 for-xen-4.5 09/21] x86/VPMU: Add public xenpmu.h



On 10/13/2014 09:31 AM, Jan Beulich wrote:

--- a/xen/include/public/arch-x86/xen-x86_32.h
+++ b/xen/include/public/arch-x86/xen-x86_32.h
@@ -136,6 +136,16 @@ struct cpu_user_regs {
  typedef struct cpu_user_regs cpu_user_regs_t;
  DEFINE_XEN_GUEST_HANDLE(cpu_user_regs_t);
+struct xen_pmu_regs {
+    uint32_t eip;
+    uint32_t esp;
+    uint32_t eflags;
+    uint16_t cs;
+    uint16_t ss;
+};
I still don't see why this and ...

--- a/xen/include/public/arch-x86/xen-x86_64.h
+++ b/xen/include/public/arch-x86/xen-x86_64.h
@@ -174,6 +174,16 @@ struct cpu_user_regs {
  typedef struct cpu_user_regs cpu_user_regs_t;
  DEFINE_XEN_GUEST_HANDLE(cpu_user_regs_t);
+struct xen_pmu_regs {
+    __DECL_REG(ip);
+    __DECL_REG(sp);
+    __DECL_REG(flags);
+    uint16_t cs;
+    uint16_t ss;
+};
aren't folded and aren't placed in the PMU-specific header.

Because it follows cpu_user_regs() definitions. I thought you agreed to that but if not I can move it to PMU code.


Furthermore I'm sure you realized (the latest when adding back
the eflags field for VM86 mode recognition) that to the consumer of
this data things are still ambiguous: You can't tell protected from
real mode, yet HVM guests definitely use that mode.

I can set a bit in the sample's flag field if the guest is in real mode.

-boris
-boris

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.