]> xenbits.xensource.com Git - people/andrewcoop/xen.git/commitdiff
dbg xen-fred
authorAndrew Cooper <andrew.cooper3@citrix.com>
Fri, 27 Dec 2024 22:21:46 +0000 (22:21 +0000)
committerAndrew Cooper <andrew.cooper3@citrix.com>
Mon, 6 Jan 2025 14:39:28 +0000 (14:39 +0000)
xen/arch/x86/setup.c
xen/arch/x86/smpboot.c

index c275714e85903a69d38d5cb589476b39d7dedf0a..d16cdd929338dd30673452b6eda5c3ced8208624 100644 (file)
@@ -1181,6 +1181,44 @@ void asmlinkage __init noreturn __start_xen(void)
     early_cpu_init(true);
     early_microcode_init(bi);
 
+    printk("*** FRED: %u, LKGS: %u, NMI_SRC %u, opt_fred %d\n",
+           boot_cpu_has(X86_FEATURE_FRED),
+           boot_cpu_has(X86_FEATURE_LKGS),
+           boot_cpu_has(X86_FEATURE_NMI_SRC),
+           opt_fred);
+
+    /* printk("*** cr4 %p\n", _p(read_cr4())); */
+
+    /* printk("int3\n"); */
+    /* asm volatile ("int3"); */
+
+    /* printk("rex64 int3\n"); */
+    /* asm volatile ("rex64 int3"); */
+
+    /* printk("int1\n"); */
+    /* asm volatile ("data16 addr32 int1"); */
+
+    /* printk("syscall\n"); */
+    /* asm volatile ("syscall"); */
+
+    /* printk("sysenter\n"); */
+    /* asm volatile ("sysenter"); */
+
+    /* printk("Good CET-IBT\n"); */
+    /* asm volatile ("lea 1f(%%rip), %%rax\n\t" */
+    /*               "jmp *%%rax\n\t" */
+    /*               "1: endbr64; cmc" */
+    /*               ::: "rax"); */
+
+    /* printk("Bad CET-IBT\n"); */
+    /* asm volatile ("lea 1f(%%rip), %%rax\n\t" */
+    /*               "jmp *%%rax\n\t" */
+    /*               "1: cmc" */
+    /*               ::: "rax"); */
+
+    /* panic("done\n"); */
+
+
     if ( pvh_boot )
         pvh_print_info();
 
index b9bb76f7a5765932451e73005b4d6c5a9e8db484..659f9969898e08a2fa52d720e31fbdcae93f2635 100644 (file)
@@ -1046,6 +1046,8 @@ static int cpu_smpboot_alloc(unsigned int cpu)
     unsigned long stub_page;
     int rc = -ENOMEM;
 
+    printk("*** CPU %u, %s(%u)\n", smp_processor_id(), __func__, cpu);
+
     if ( node != NUMA_NO_NODE )
         memflags = MEMF_node(node);
 
@@ -1150,6 +1152,8 @@ static struct notifier_block cpu_smpboot_nfb = {
 
 void __init smp_prepare_cpus(void)
 {
+    printk("*** CPU %u, %s()\n", smp_processor_id(), __func__);
+
     register_cpu_notifier(&cpu_smpboot_nfb);
 
     mtrr_aps_sync_begin();