Commit 9b843cda authored by Anton Blanchard's avatar Anton Blanchard Committed by Linus Torvalds
Browse files

[PATCH] ppc64: set/clear SMT capable bit at boot

Allow the SMT bit to be set/reset at boot, like the ALTIVEC bit.  This
means we will enable SMT on unknown cpus that support it.
Signed-off-by: default avatarAnton Blanchard <>
Signed-off-by: default avatarAndrew Morton <>
Signed-off-by: default avatarLinus Torvalds <>
parent 515bae9c
......@@ -884,6 +884,7 @@ static int __init early_init_dt_scan_cpus(unsigned long node,
char *type = get_flat_dt_prop(node, "device_type", NULL);
u32 *prop;
unsigned long size;
/* We are scanning "cpu" nodes only */
if (type == NULL || strcmp(type, "cpu") != 0)
......@@ -929,6 +930,17 @@ static int __init early_init_dt_scan_cpus(unsigned long node,
cur_cpu_spec->cpu_user_features |= PPC_FEATURE_HAS_ALTIVEC;
* Check for an SMT capable CPU and set the CPU feature. We do
* this by looking at the size of the ibm,ppc-interrupt-server#s
* property
prop = (u32 *)get_flat_dt_prop(node, "ibm,ppc-interrupt-server#s",
cur_cpu_spec->cpu_features &= ~CPU_FTR_SMT;
if (prop && ((size / sizeof(u32)) > 1))
cur_cpu_spec->cpu_features |= CPU_FTR_SMT;
return 0;
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment