]> xenbits.xen.org Git - xenclient/xen.git/commitdiff
tboot patch 1/5 - unified shutdown entry
authorRoss Philipson <ross.philipson@citrix.com>
Wed, 4 Feb 2009 15:56:51 +0000 (10:56 -0500)
committerRoss Philipson <ross.philipson@citrix.com>
Wed, 4 Feb 2009 15:56:51 +0000 (10:56 -0500)
tboot removed the shutdown_entry32 and shutdown_entry64 from
tboot_shared_t and now has just a single shutdown_entry field.

 Changes to be committed:
modified:   xen/arch/x86/tboot.c
modified:   xen/include/asm-x86/tboot.h

xen/arch/x86/tboot.c
xen/include/asm-x86/tboot.h

index 697ca9f4613a116e224aad3935136bdd17f79730..b03338f54f430593ef08abe1de9e3a1e6adcbed4 100644 (file)
@@ -37,8 +37,7 @@ void __init tboot_probe(void)
     printk("TBOOT: found shared page at phys addr %lx:\n", p_tboot_shared);
     printk("  version: %d\n", tboot_shared->version);
     printk("  log_addr: 0x%08x\n", tboot_shared->log_addr);
-    printk("  shutdown_entry32: 0x%08x\n", tboot_shared->shutdown_entry32);
-    printk("  shutdown_entry64: 0x%08x\n", tboot_shared->shutdown_entry64);
+    printk("  shutdown_entry: 0x%08x\n", tboot_shared->shutdown_entry);
     printk("  shutdown_type: %d\n", tboot_shared->shutdown_type);
     printk("  s3_tb_wakeup_entry: 0x%08x\n", tboot_shared->s3_tb_wakeup_entry);
     printk("  s3_k_wakeup_entry: 0x%08x\n", tboot_shared->s3_k_wakeup_entry);
@@ -82,11 +81,7 @@ void tboot_shutdown(uint32_t shutdown_type)
 
     write_ptbase(idle_vcpu[0]);
 
-#ifdef __x86_64__
-    asm volatile ( "call *%%rdi" :: "D" (g_tboot_shared->shutdown_entry64) );
-#else
-    asm volatile ( "call *%0" :: "r" (g_tboot_shared->shutdown_entry32) );
-#endif
+    ((void(*)(void))(unsigned long)g_tboot_shared->shutdown_entry)();
 
     BUG(); /* should not reach here */
 }
index 64883ceb7f3ce9c8424a51f168bf6ec916e58299..282ad667b5225fc3cbe491f523c654146337df28 100644 (file)
@@ -61,8 +61,7 @@ typedef struct __attribute__ ((__packed__)) {
     uuid_t    uuid;              /* {663C8DFF-E8B3-4b82-AABF-19EA4D057A08} */
     uint32_t  version;           /* Version number: 0x01, 0x02, ... */
     uint32_t  log_addr;          /* physical addr of tb_log_t log */
-    uint32_t  shutdown_entry32;  /* entry point for tboot shutdown from 32b */
-    uint32_t  shutdown_entry64;  /* entry point for tboot shutdown from 64b */
+    uint32_t  shutdown_entry;    /* entry point for tboot shutdown */
     uint32_t  shutdown_type;     /* type of shutdown (TB_SHUTDOWN_*) */
     uint32_t  s3_tb_wakeup_entry;/* entry point for tboot s3 wake up */
     uint32_t  s3_k_wakeup_entry; /* entry point for xen s3 wake up */