From patchwork Fri Jul 18 02:11:37 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Joel Stanley X-Patchwork-Id: 371294 Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from lists.ozlabs.org (lists.ozlabs.org [103.22.144.68]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 0F9111400D5 for ; Fri, 18 Jul 2014 12:12:49 +1000 (EST) Received: from ozlabs.org (ozlabs.org [103.22.144.67]) by lists.ozlabs.org (Postfix) with ESMTP id E01641A0475 for ; Fri, 18 Jul 2014 12:12:48 +1000 (EST) X-Original-To: linuxppc-dev@lists.ozlabs.org Delivered-To: linuxppc-dev@lists.ozlabs.org Received: from mail-pa0-x232.google.com (mail-pa0-x232.google.com [IPv6:2607:f8b0:400e:c03::232]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 660B11A03F0 for ; Fri, 18 Jul 2014 12:12:11 +1000 (EST) Received: by mail-pa0-f50.google.com with SMTP id et14so4408007pad.23 for ; Thu, 17 Jul 2014 19:12:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=jms.id.au; s=google; h=from:to:cc:subject:date:message-id; bh=U6aLY3k1QR0dHZjvWE221d7VcREh0MdXOimHQhtMvY8=; b=hoWjGXusMMLuMnPUtOkx/Qtei//AxA81Saq/Gwuo2LDn4MVCHaFKa8G1cXVM8ED0Rg yHtWFXPcbEkBFTsblnUZBik6h+ihclg6x0+mw0TM6hKU4JLgdsPTMbrGfFYj39jTE44B 0SnhFhteHC1+Z14h4puhydMxBF+YT8sD7Ez2Y= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=U6aLY3k1QR0dHZjvWE221d7VcREh0MdXOimHQhtMvY8=; b=IOevbKHoeTkUvt9B31sDh2yMMnuA6iI40NzfFXEPAdY3Fkdw3BbwtxE7XAcSz3EZu0 07dj7O+PHV1ctOI2w5oemb8rvsvRcdIVS+nSotLMOQzdYfHnee3bEsTeACNph6mTiQeX 7wAqfl6DH5C/8W3LZFzX+MCt+Kn3wvCoyzYALocZgijLtkEyuVgdRIffVZavWLQ9Fapl Xt4aazmRmNVdUcM5hKPeBu2fljxx6Y4ZIyExScW1vixTudamhKE6takWClhkTePArlib Uy+jYi1xyUJU316w9eBXnbd8te9G3gJUPd55ZrTcqpUO5VuH5PqI3xl4NX1h+7B+6iBT mLlw== X-Gm-Message-State: ALoCoQllmJ+Hmq8UZo5bzSRsgkXgEGYP2rwe5Zky3jwR8Awd0s14m/XRUv548ugesqvFswAT6YiO X-Received: by 10.70.54.162 with SMTP id k2mr1278631pdp.138.1405649529746; Thu, 17 Jul 2014 19:12:09 -0700 (PDT) Received: from icarus.au.ibm.com (122-49-187-71.ip.adam.com.au. [122.49.187.71]) by mx.google.com with ESMTPSA id mw3sm5241075pdb.55.2014.07.17.19.12.06 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 17 Jul 2014 19:12:09 -0700 (PDT) From: Joel Stanley To: benh@kernel.crashing.org Subject: [PATCH] powerpc: Add cputable definition for POWER8 DD1 Date: Fri, 18 Jul 2014 11:41:37 +0930 Message-Id: <1405649497-679-1-git-send-email-joel@jms.id.au> X-Mailer: git-send-email 2.0.1 Cc: mikey@neuling.org, paulus@samba.org, anton@samba.org, preeti@linux.vnet.ibm.com, linuxppc-dev@lists.ozlabs.org X-BeenThere: linuxppc-dev@lists.ozlabs.org X-Mailman-Version: 2.1.16 Precedence: list List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org Sender: "Linuxppc-dev" These processors do not currently support doorbell IPIs, so remove them from the feature list if we are at DD 1.xx for the 0x004d part. This fixes a regression caused by d4e58e5928f8 (powerpc/powernv: Enable POWER8 doorbell IPIs). With that patch the kernel would hang at boot when calling smp_call_function_many, as the doorbell would not be received by the target CPUs: .smp_call_function_many+0x2bc/0x3c0 (unreliable) .on_each_cpu_mask+0x30/0x100 .cpuidle_register_driver+0x158/0x1a0 .cpuidle_register+0x2c/0x110 .powernv_processor_idle_init+0x23c/0x2c0 .do_one_initcall+0xd4/0x260 .kernel_init_freeable+0x25c/0x33c .kernel_init+0x1c/0x120 .ret_from_kernel_thread+0x58/0x7c Fixes: d4e58e5928f8 (powerpc/powernv: Enable POWER8 doorbell IPIs) Signed-off-by: Joel Stanley --- arch/powerpc/include/asm/cputable.h | 1 + arch/powerpc/kernel/cputable.c | 20 ++++++++++++++++++++ 2 files changed, 21 insertions(+) diff --git a/arch/powerpc/include/asm/cputable.h b/arch/powerpc/include/asm/cputable.h index bc23477..0fdd7ee 100644 --- a/arch/powerpc/include/asm/cputable.h +++ b/arch/powerpc/include/asm/cputable.h @@ -447,6 +447,7 @@ extern const char *powerpc_base_platform; CPU_FTR_DBELL | CPU_FTR_HAS_PPR | CPU_FTR_DAWR | \ CPU_FTR_ARCH_207S | CPU_FTR_TM_COMP) #define CPU_FTRS_POWER8E (CPU_FTRS_POWER8 | CPU_FTR_PMAO_BUG) +#define CPU_FTRS_POWER8_DD1 (CPU_FTRS_POWER8 & ~CPU_FTR_DBELL) #define CPU_FTRS_CELL (CPU_FTR_USE_TB | CPU_FTR_LWSYNC | \ CPU_FTR_PPCAS_ARCH_V2 | CPU_FTR_CTRL | \ CPU_FTR_ALTIVEC_COMP | CPU_FTR_MMCRA | CPU_FTR_SMT | \ diff --git a/arch/powerpc/kernel/cputable.c b/arch/powerpc/kernel/cputable.c index 965291b..0c15764 100644 --- a/arch/powerpc/kernel/cputable.c +++ b/arch/powerpc/kernel/cputable.c @@ -527,6 +527,26 @@ static struct cpu_spec __initdata cpu_specs[] = { .machine_check_early = __machine_check_early_realmode_p8, .platform = "power8", }, + { /* Power8 DD1: Does not support doorbell IPIs */ + .pvr_mask = 0xffffff00, + .pvr_value = 0x004d0100, + .cpu_name = "POWER8 (raw)", + .cpu_features = CPU_FTRS_POWER8_DD1, + .cpu_user_features = COMMON_USER_POWER8, + .cpu_user_features2 = COMMON_USER2_POWER8, + .mmu_features = MMU_FTRS_POWER8, + .icache_bsize = 128, + .dcache_bsize = 128, + .num_pmcs = 6, + .pmc_type = PPC_PMC_IBM, + .oprofile_cpu_type = "ppc64/power8", + .oprofile_type = PPC_OPROFILE_INVALID, + .cpu_setup = __setup_cpu_power8, + .cpu_restore = __restore_cpu_power8, + .flush_tlb = __flush_tlb_power8, + .machine_check_early = __machine_check_early_realmode_p8, + .platform = "power8", + }, { /* Power8 */ .pvr_mask = 0xffff0000, .pvr_value = 0x004d0000,