]> www.infradead.org Git - users/hch/misc.git/commitdiff
powerpc/cputable: Remove unnecessary copy of cpu_spec->oprofile_type
authorLeonardo Bras <leonardo@linux.ibm.com>
Sat, 15 Feb 2020 05:36:37 +0000 (02:36 -0300)
committerMichael Ellerman <mpe@ellerman.id.au>
Wed, 1 Apr 2020 03:30:51 +0000 (14:30 +1100)
Before checking for cpu_type == NULL, this same copy happens, so doing
it here will just write the same value to the t->oprofile_type
again.

Remove the repeated copy, as it is unnecessary.

Signed-off-by: Leonardo Bras <leonardo@linux.ibm.com>
Reviewed-by: Michael Neuling <mikey@neuling.org>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/20200215053637.280880-1-leonardo@linux.ibm.com
arch/powerpc/kernel/cputable.c

index 245be4fafe134a95c468ee7086ce2f985231dd3e..13eba2eb46fe2c56d25c5fdb7ba59a21e34efb15 100644 (file)
@@ -2198,7 +2198,6 @@ static struct cpu_spec * __init setup_cpu_spec(unsigned long offset,
                 */
                if (old.oprofile_cpu_type != NULL) {
                        t->oprofile_cpu_type = old.oprofile_cpu_type;
-                       t->oprofile_type = old.oprofile_type;
                        t->cpu_features |= old.cpu_features & CPU_FTR_PMAO_BUG;
                }
        }