diff options
author | Ronald G. Minnich <rminnich@gmail.com> | 2005-11-23 21:01:08 +0000 |
---|---|---|
committer | Ronald G. Minnich <rminnich@gmail.com> | 2005-11-23 21:01:08 +0000 |
commit | fb0a64ba77dbf1fa00d07453c76b875cd124cfcb (patch) | |
tree | 43738db444fd43b8b29ebe9db5a685b8edbd8066 /src/cpu/amd/dualcore/amd_sibling.c | |
parent | 872141a40291b73f061ae95a78baadb557efcd83 (diff) |
CAR patch from YH LU
git-svn-id: svn://svn.coreboot.org/coreboot/trunk@2096 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1
Diffstat (limited to 'src/cpu/amd/dualcore/amd_sibling.c')
-rw-r--r-- | src/cpu/amd/dualcore/amd_sibling.c | 24 |
1 files changed, 7 insertions, 17 deletions
diff --git a/src/cpu/amd/dualcore/amd_sibling.c b/src/cpu/amd/dualcore/amd_sibling.c index c74b282cb6..4375a1d8a8 100644 --- a/src/cpu/amd/dualcore/amd_sibling.c +++ b/src/cpu/amd/dualcore/amd_sibling.c @@ -15,6 +15,7 @@ static int first_time = 1; static int disable_siblings = !CONFIG_LOGICAL_CPUS; + void amd_sibling_init(device_t cpu, struct node_core_id id) { unsigned long i; @@ -93,9 +94,13 @@ struct node_core_id get_node_core_id(void) return id; } +unsigned int read_nb_cfg_54(void) +{ + msr_t msr; + msr = rdmsr(NB_CFG_MSR); + return ( ( msr.hi >> (54-32)) & 1); +} - -#if 0 static int get_max_siblings(int nodes) { device_t dev; @@ -160,20 +165,6 @@ unsigned get_apicid_base(unsigned ioapic_num) nb_cfg_54 = read_nb_cfg_54(); -#if 0 - //it is for all e0 single core and nc_cfg_54 low is set, but in the auto.c stage we do not set that bit for it. - if(nb_cfg_54 && (!disable_siblings) && (siblings == 0)) { - //we need to check if e0 single core is there - int i; - for(i=0; i<nodes; i++) { - if(is_e0_later_in_bsp(i)) { - siblings = 1; - break; - } - } - } -#endif - //contruct apicid_base if((!disable_siblings) && (siblings>0) ) { @@ -199,4 +190,3 @@ unsigned get_apicid_base(unsigned ioapic_num) return apicid_base; } -#endif |