Received: by 2002:a05:7412:1e0b:b0:fc:a2b0:25d7 with SMTP id kr11csp744372rdb; Thu, 15 Feb 2024 14:16:27 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCXrk6/1m5HryM4s5lu6XLfTDq9XU9H6eooLIAfBni6sBBakhYWGBWGW6BK+1hk7mW7M1h7max0WwYs9m0krm9WHen8nVkkYuM34TRd2QA== X-Google-Smtp-Source: AGHT+IHuk66o8hue88vuRbZuq0S74o/32F8kuRJhiT1SUE+Nw9t5KC7DGkx+rk8L1zJ4LfEmIq9w X-Received: by 2002:a05:620a:51d8:b0:787:1c36:4fc5 with SMTP id cx24-20020a05620a51d800b007871c364fc5mr3107456qkb.64.1708035387383; Thu, 15 Feb 2024 14:16:27 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1708035387; cv=pass; d=google.com; s=arc-20160816; b=lcH5SCAMbEJEBbLB73U+49/BWjcAMJSGNJne82YIcPf4ZvTN6aSj3d3BogqtBRYZ1g fy3cFF6PMb2FILDgZRXw6p0QnyUpTjooaSn6k3PjCoN3WnWDiibty5Kn03xslSPg4FpQ eflztDUYjfN45i6qLpOEqB4AmP+TLj5ShhIKmQORjiakRnkEjOlTsQyNUOhzTgrJylXZ gulfSI0u98AWwVUGUDG58ZkdcLJY7oAiy0oCSM39xIPEgXTxQKMFnbfG1GlxK29QHCp3 fupV8RKYMNwRNDTb5HmvokGHMn+hdKnzSj3hfJoiYJpComL8M6nlciTSopHqD/3Lk5m8 aJ3Q== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=xd7lrsen2it77yQmo7Ql0gP9UsW8IXDRnS5i0NzUgnI=; fh=Usz7XAB1EI7Q/DdLEXd449E1MLGpSzqdCCNe5XKh9R0=; b=gxwut8tS4GjrMsyAZDg/VQSfwtXP9kU5C2ILQmetbscNDbK+MD4cM4CPw5j0+M2FcY 14PTpmgQuRHm1yK9BL9q+qgV4+R4usWuxMJ72jgWgs6Wj7TOP7gf+pCO9OjXcSH+bNJN bH+gbkmS/VK2l9wjk3xBmW4Mqn07B/WC1M+WVWkBRdpKWx/Hydq+NWpEaA0AafN4U8lF 54c5gtgUGb7D+31dOEgGHBldLvB3arSRKmHF/buYvYuLf3Xbn17RTZ0VzvniAIdHOA/t B35G9MpppPF5vnOvPGfCepEe+f8eGmiaTHnR1BoZE8DpnxygA2puZujVCLthA92Nj88h cnGg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@ibm.com header.s=pp1 header.b=idf+UuKk; arc=pass (i=1 spf=pass spfdomain=linux.ibm.com dkim=pass dkdomain=ibm.com dmarc=pass fromdomain=linux.ibm.com); spf=pass (google.com: domain of linux-kernel+bounces-67765-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-67765-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=REJECT sp=NONE dis=NONE) header.from=ibm.com Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id a11-20020a05620a102b00b00785ec238993si2392854qkk.578.2024.02.15.14.16.27 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 15 Feb 2024 14:16:27 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-67765-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@ibm.com header.s=pp1 header.b=idf+UuKk; arc=pass (i=1 spf=pass spfdomain=linux.ibm.com dkim=pass dkdomain=ibm.com dmarc=pass fromdomain=linux.ibm.com); spf=pass (google.com: domain of linux-kernel+bounces-67765-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-67765-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=REJECT sp=NONE dis=NONE) header.from=ibm.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 2564D1C215A8 for ; Thu, 15 Feb 2024 22:16:27 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id CDB10153516; Thu, 15 Feb 2024 22:08:40 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=ibm.com header.i=@ibm.com header.b="idf+UuKk" Received: from mx0b-001b2d01.pphosted.com (mx0b-001b2d01.pphosted.com [148.163.158.5]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 6EE2C151CC6; Thu, 15 Feb 2024 22:08:37 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=148.163.158.5 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708034919; cv=none; b=eoBxFxruQUV+xU3FC99/ugGuVX/IZoNA1+d4ceKJnuzsIlQlO3j/7LXqS4JyXJ7dZHKD1kUoudFydRQpn9Tr4Bn0Yg0MjEbZpbbc3CvfLFPXdFwpBD7Jzs48tiMv4iRUzZjlX8Nf62Gr/a3unwMise5bzN4/VczFmbAmUuOanIk= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708034919; c=relaxed/simple; bh=lblN2MxrNHftFgMgHVzLgv+0vLc3TPzvtG1g+PjEmhs=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=ZzAZuzqq982DrX5k/kRX/bY7PKETS9wrxWr9pwFFHyKiMyRzfATWEtwOLtdViA+dc1EfsaDCuBhGXqZAg3OehBKt5DUzk468zBENNDyeH5KkEItdU3BTLG6EnKeZ9kOpRru7BL6ZY/lBm/MGvGKgfLcxdQUX+DXRodyWOTYYweA= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.ibm.com; spf=pass smtp.mailfrom=linux.ibm.com; dkim=pass (2048-bit key) header.d=ibm.com header.i=@ibm.com header.b=idf+UuKk; arc=none smtp.client-ip=148.163.158.5 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.ibm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linux.ibm.com Received: from pps.filterd (m0353724.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.17.1.19/8.17.1.19) with ESMTP id 41FLX1AO019281; Thu, 15 Feb 2024 22:08:09 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ibm.com; h=from : to : cc : subject : date : message-id : in-reply-to : references : mime-version : content-transfer-encoding; s=pp1; bh=xd7lrsen2it77yQmo7Ql0gP9UsW8IXDRnS5i0NzUgnI=; b=idf+UuKkauTb1zwU63vMpUta0cjhC50VLLdP8iR5kWnep3iuKeUJJU2evqtEwBy7EiUT eC3B1BwEC3Pv6AtXyfXnrvr3gQQAKFedcypris9f/Mtc0oBvGWIKEPjBmhwGJgtveLZu v4Lgt4nto1wJNeqoFn/umcvztNZNRlZfAFkgxOVqQRdCzoMzDvb6p7feYGYf69KJ5axD 8bVNKCaDZ3QIvQUZAD+GRfw6JyJs+hTUX5Xu5/YHDfSumtzyBBgE+16LazpcluTHlcrU h+fiGxL24rR0QYhiDxF0j3phHSr5q2qO8d9mZMWHh/gZOAcHGj3x7pBf3BWMo9EcBMoa kQ== Received: from ppma13.dal12v.mail.ibm.com (dd.9e.1632.ip4.static.sl-reverse.com [50.22.158.221]) by mx0a-001b2d01.pphosted.com (PPS) with ESMTPS id 3w9tmf8mx8-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 15 Feb 2024 22:08:08 +0000 Received: from pps.filterd (ppma13.dal12v.mail.ibm.com [127.0.0.1]) by ppma13.dal12v.mail.ibm.com (8.17.1.19/8.17.1.19) with ESMTP id 41FLKApd010063; Thu, 15 Feb 2024 22:08:08 GMT Received: from smtprelay05.wdc07v.mail.ibm.com ([172.16.1.72]) by ppma13.dal12v.mail.ibm.com (PPS) with ESMTPS id 3w6npm7811-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 15 Feb 2024 22:08:07 +0000 Received: from smtpav03.dal12v.mail.ibm.com (smtpav03.dal12v.mail.ibm.com [10.241.53.102]) by smtprelay05.wdc07v.mail.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 41FM844v34865452 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 15 Feb 2024 22:08:07 GMT Received: from smtpav03.dal12v.mail.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id AF2725807A; Thu, 15 Feb 2024 22:08:02 +0000 (GMT) Received: from smtpav03.dal12v.mail.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 6CEAC58072; Thu, 15 Feb 2024 22:08:02 +0000 (GMT) Received: from slate16.aus.stglabs.ibm.com (unknown [9.61.14.18]) by smtpav03.dal12v.mail.ibm.com (Postfix) with ESMTP; Thu, 15 Feb 2024 22:08:02 +0000 (GMT) From: Eddie James To: linux-fsi@lists.ozlabs.org Cc: linux-kernel@vger.kernel.org, linux-i2c@vger.kernel.org, linux-clk@vger.kernel.org, devicetree@vger.kernel.org, andi.shyti@kernel.org, eajames@linux.ibm.com, alistair@popple.id.au, joel@jms.id.au, jk@ozlabs.org, sboyd@kernel.org, mturquette@baylibre.com, robh@kernel.org, krzysztof.kozlowski+dt@linaro.org, conor+dt@kernel.org Subject: [PATCH 02/33] clk: ast2600: Add FSI parent clock with correct rate Date: Thu, 15 Feb 2024 16:07:28 -0600 Message-Id: <20240215220759.976998-3-eajames@linux.ibm.com> X-Mailer: git-send-email 2.39.3 In-Reply-To: <20240215220759.976998-1-eajames@linux.ibm.com> References: <20240215220759.976998-1-eajames@linux.ibm.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-TM-AS-GCONF: 00 X-Proofpoint-GUID: qu9m3EEKVKG-DGbpYkJKjIZdu1nYUI1H X-Proofpoint-ORIG-GUID: qu9m3EEKVKG-DGbpYkJKjIZdu1nYUI1H X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.272,Aquarius:18.0.1011,Hydra:6.0.619,FMLib:17.11.176.26 definitions=2024-02-15_20,2024-02-14_01,2023-05-22_02 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 mlxscore=0 priorityscore=1501 impostorscore=0 suspectscore=0 mlxlogscore=999 adultscore=0 clxscore=1015 lowpriorityscore=0 spamscore=0 malwarescore=0 bulkscore=0 phishscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2311290000 definitions=main-2402150171 In order to calculate correct FSI bus clocks, the FSI clock must correctly calculate the rate from the parent (APLL / 4). Signed-off-by: Eddie James --- drivers/clk/clk-ast2600.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/drivers/clk/clk-ast2600.c b/drivers/clk/clk-ast2600.c index 909c3137c428..faf88324f7b1 100644 --- a/drivers/clk/clk-ast2600.c +++ b/drivers/clk/clk-ast2600.c @@ -19,7 +19,7 @@ * This includes the gates (configured from aspeed_g6_gates), plus the * explicitly-configured clocks (ASPEED_CLK_HPLL and up). */ -#define ASPEED_G6_NUM_CLKS 72 +#define ASPEED_G6_NUM_CLKS 73 #define ASPEED_G6_SILICON_REV 0x014 #define CHIP_REVISION_ID GENMASK(23, 16) @@ -157,7 +157,7 @@ static const struct aspeed_gate_data aspeed_g6_gates[] = { [ASPEED_CLK_GATE_UART11CLK] = { 59, -1, "uart11clk-gate", "uartx", 0 }, /* UART11 */ [ASPEED_CLK_GATE_UART12CLK] = { 60, -1, "uart12clk-gate", "uartx", 0 }, /* UART12 */ [ASPEED_CLK_GATE_UART13CLK] = { 61, -1, "uart13clk-gate", "uartx", 0 }, /* UART13 */ - [ASPEED_CLK_GATE_FSICLK] = { 62, 59, "fsiclk-gate", NULL, 0 }, /* FSI */ + [ASPEED_CLK_GATE_FSICLK] = { 62, 59, "fsiclk-gate", "fsiclk", 0 }, /* FSI */ }; static const struct clk_div_table ast2600_eclk_div_table[] = { @@ -821,6 +821,9 @@ static void __init aspeed_g6_cc(struct regmap *map) hw = clk_hw_register_fixed_factor(NULL, "i3cclk", "apll", 0, 1, 8); aspeed_g6_clk_data->hws[ASPEED_CLK_I3C] = hw; + + hw = clk_hw_register_fixed_factor(NULL, "fsiclk", "apll", 0, 1, 4); + aspeed_g6_clk_data->hws[ASPEED_CLK_FSI] = hw; }; static void __init aspeed_g6_cc_init(struct device_node *np) -- 2.39.3