forked from mirrors/linux
		
	powerpc/64s: Fix POWER9 DD2.2 and above in DT CPU features
The CPU_FTR_POWER9_DD2_1 flag is intended to be set for DD2.1 and above (which is what the cputable setup does). Fix DT CPU features quirk setup to match. Signed-off-by: Nicholas Piggin <npiggin@gmail.com> [mpe: Merge with upstream changes] Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
This commit is contained in:
		
							parent
							
								
									15a3204d24
								
							
						
					
					
						commit
						9e9626ed3a
					
				
					 1 changed files with 8 additions and 3 deletions
				
			
		| 
						 | 
					@ -708,11 +708,16 @@ static __init void cpufeatures_cpu_quirks(void)
 | 
				
			||||||
	 */
 | 
						 */
 | 
				
			||||||
	if ((version & 0xffffff00) == 0x004e0100)
 | 
						if ((version & 0xffffff00) == 0x004e0100)
 | 
				
			||||||
		cur_cpu_spec->cpu_features |= CPU_FTR_POWER9_DD1;
 | 
							cur_cpu_spec->cpu_features |= CPU_FTR_POWER9_DD1;
 | 
				
			||||||
 | 
						else if ((version & 0xffffefff) == 0x004e0200)
 | 
				
			||||||
 | 
							; /* DD2.0 has no feature flag */
 | 
				
			||||||
	else if ((version & 0xffffefff) == 0x004e0201)
 | 
						else if ((version & 0xffffefff) == 0x004e0201)
 | 
				
			||||||
		cur_cpu_spec->cpu_features |= CPU_FTR_POWER9_DD2_1;
 | 
							cur_cpu_spec->cpu_features |= CPU_FTR_POWER9_DD2_1;
 | 
				
			||||||
	else if ((version & 0xffffefff) == 0x004e0202)
 | 
						else if ((version & 0xffffefff) == 0x004e0202) {
 | 
				
			||||||
		cur_cpu_spec->cpu_features |= CPU_FTR_P9_TM_HV_ASSIST |
 | 
							cur_cpu_spec->cpu_features |= CPU_FTR_P9_TM_HV_ASSIST;
 | 
				
			||||||
			CPU_FTR_P9_TM_XER_SO_BUG;
 | 
							cur_cpu_spec->cpu_features |= CPU_FTR_P9_TM_XER_SO_BUG;
 | 
				
			||||||
 | 
							cur_cpu_spec->cpu_features |= CPU_FTR_POWER9_DD2_1;
 | 
				
			||||||
 | 
						} else /* DD2.1 and up have DD2_1 */
 | 
				
			||||||
 | 
							cur_cpu_spec->cpu_features |= CPU_FTR_POWER9_DD2_1;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	if ((version & 0xffff0000) == 0x004e0000) {
 | 
						if ((version & 0xffff0000) == 0x004e0000) {
 | 
				
			||||||
		cur_cpu_spec->cpu_features &= ~(CPU_FTR_DAWR);
 | 
							cur_cpu_spec->cpu_features &= ~(CPU_FTR_DAWR);
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
		Reference in a new issue