WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

[Xen-devel] Xen support for i386/core and i386/core2?

To: xen-devel@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-devel] Xen support for i386/core and i386/core2?
From: Markus Armbruster <armbru@xxxxxxxxxx>
Date: Wed, 15 Nov 2006 16:55:22 +0100
Delivery-date: Wed, 15 Nov 2006 07:55:36 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Gnus/5.1008 (Gnus v5.10.8) Emacs/21.4 (gnu/linux)
Xen's oprofile code is derived from Linux.  Linux's version knows
core, Xen's doesn't.

Linux code (arch/i386/oprofile/nmi_int.c):

static int __init ppro_init(char ** cpu_type)
{
        __u8 cpu_model = boot_cpu_data.x86_model;

        if (cpu_model == 14)
                *cpu_type = "i386/core";
        else if (cpu_model == 15)
                *cpu_type = "i386/core_2";
        else if (cpu_model > 0xd)
                return 0;
        else if (cpu_model == 9) {
                *cpu_type = "i386/p6_mobile";
        } else if (cpu_model > 5) {
                *cpu_type = "i386/piii";
        } else if (cpu_model > 2) {
                *cpu_type = "i386/pii";
        } else {
                *cpu_type = "i386/ppro";
        }

        model = &op_ppro_spec;
        return 1;
}

Current Xen code:

static int __init ppro_init(char *cpu_type)
{
        __u8 cpu_model = current_cpu_data.x86_model;

        if (cpu_model > 0xd) {
                printk("xenoprof: Initialization failed. "
                       "Intel processor model %d for P6 class family is not "
                       "supported\n", cpu_model);
                return 0;
        }

        if (cpu_model == 9) {
                strncpy (cpu_type, "i386/p6_mobile", XENOPROF_CPU_TYPE_SIZE - 
1);
        } else if (cpu_model > 5) {
                strncpy (cpu_type, "i386/piii", XENOPROF_CPU_TYPE_SIZE - 1);
        } else if (cpu_model > 2) {
                strncpy (cpu_type, "i386/pii", XENOPROF_CPU_TYPE_SIZE - 1);
        } else {
                strncpy (cpu_type, "i386/ppro", XENOPROF_CPU_TYPE_SIZE - 1);
        }

        model = &op_ppro_spec;
        return 1;
}

Andrew Theurer posted a patch back in October[*], which makes the Xen
code match the Linux code.  What happened to it?

[*] http://lists.xensource.com/archives/html/xen-devel/2006-10/msg00032.html

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