From patchwork Wed Oct 28 10:46:21 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lulu Su X-Patchwork-Id: 1389231 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 4CLld166Q6z9sVt for ; Wed, 28 Oct 2020 21:47:01 +1100 (AEDT) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=wistron.com Received: from bilbo.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) by lists.ozlabs.org (Postfix) with ESMTP id 4CLld142CtzDqSV for ; Wed, 28 Oct 2020 21:47:01 +1100 (AEDT) X-Original-To: skiboot-stable@lists.ozlabs.org Delivered-To: skiboot-stable@lists.ozlabs.org Authentication-Results: lists.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=wistron.com (client-ip=103.200.3.18; helo=segapp01.wistron.com; envelope-from=lulu_su@wistron.com; receiver=) Authentication-Results: lists.ozlabs.org; dmarc=none (p=none dis=none) header.from=wistron.com Received: from segapp01.wistron.com (segapp01.wistron.com [103.200.3.18]) by lists.ozlabs.org (Postfix) with ESMTP id 4CLlcw4cnQzDqS6 for ; Wed, 28 Oct 2020 21:46:56 +1100 (AEDT) Received: from EXCHAPP04.whq.wistron (unverified [10.37.38.27]) by TWNHUMSW2.wistron.com (Clearswift SMTPRS 5.6.0) with ESMTP id for ; Wed, 28 Oct 2020 18:46:53 +0800 Received: from EXCHAPP01.whq.wistron (10.37.38.24) by EXCHAPP04.whq.wistron (10.37.38.27) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.1913.5; Wed, 28 Oct 2020 18:46:52 +0800 Received: from gitserver.wistron.com (10.37.38.233) by EXCHAPP01.whq.wistron (10.37.38.24) with Microsoft SMTP Server id 15.1.1913.5 via Frontend Transport; Wed, 28 Oct 2020 18:46:52 +0800 From: Lulu Su To: Date: Wed, 28 Oct 2020 18:46:21 +0800 Message-ID: <20201028104621.26677-2-Lulu_Su@wistron.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20201028104621.26677-1-Lulu_Su@wistron.com> References: <20201028104621.26677-1-Lulu_Su@wistron.com> MIME-Version: 1.0 X-TM-SNTS-SMTP: 5ABBF3115D5BC219A91A5D8E2A3B94F104D9ADF76EBED64E7206295A96112EEE2000:8 Subject: [Skiboot-stable] [PATCH 2/2] hw/phb4.c: limit the max-link-speed of Mowgli's phb0 to gen3 X-BeenThere: skiboot-stable@lists.ozlabs.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Patches, review, and discussion for stable releases of skiboot" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: skiboot-stable@lists.ozlabs.org Errors-To: skiboot-stable-bounces+incoming=patchwork.ozlabs.org@lists.ozlabs.org Sender: "Skiboot-stable" From: LuluTHSu Add a condition in phb4_get_max_link_speed(), when it's mowgli's phb0, max-link-speed is set to gen3. For mowgli platform spec. Cc: skiboot-stable@lists.ozlabs.org Signed-off-by: LuluTHSu --- hw/phb4.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/hw/phb4.c b/hw/phb4.c index 17a233f..ef6b176 100644 --- a/hw/phb4.c +++ b/hw/phb4.c @@ -2966,6 +2966,10 @@ static unsigned int phb4_get_max_link_speed(struct phb4 *p, struct dt_node *np) /* Priority order: NVRAM -> dt -> GEN3 dd2.00 -> GEN4 */ max_link_speed = 4; + if(dt_node_is_compatible(dt_root,"ibm,mowgli") && p->pec==0){ + max_link_speed = 3; + prlog(PR_DEBUG, "Set the max link speed of Mowgli phb0 to gen3\n"); + } if (p->rev == PHB4_REV_NIMBUS_DD20 && ((0xf & chip->ec_level) == 0) && chip->ec_rev == 0) max_link_speed = 3;