From patchwork Tue Nov 28 14:08:07 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Herve Codina X-Patchwork-Id: 170803 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:ce62:0:b0:403:3b70:6f57 with SMTP id o2csp3946949vqx; Tue, 28 Nov 2023 06:09:15 -0800 (PST) X-Google-Smtp-Source: AGHT+IG3sJyVmOwEEHZ0/JIXcwzmabtYiGV+rnBP3RmEYJrQRAkNcHgiXD4WTBsh7n8tC7Xkg6zW X-Received: by 2002:a17:902:eb4d:b0:1cf:f876:5f04 with SMTP id i13-20020a170902eb4d00b001cff8765f04mr1820540pli.37.1701180555456; Tue, 28 Nov 2023 06:09:15 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1701180555; cv=none; d=google.com; s=arc-20160816; b=H8t6jbkuOhgs9Y5mxLhAvXNTA5r9X0yZqV6UTyqvhyyMoV6gt78Bkt13EP/Oh3Dvlg I01VnzGyfvrrCifuV8k/Imgrw5p7PxHY9/KAlDcujo2HynGViCEGGau0mwVLhxdOa0Qg 5AemM+zzbZLLoXOodr87wiEBWTQIa2y8dSoeBnUeQ2HUmRt0VIovM9uufeu4kPAjldhS Widxiyk7LwPNsS5L0h6HleA7WnbdWPOS318W8ZbFtnNhO+5RHrVPQlX4MIMz+6QDffFE mP5iptm9rRA1tC3VFXGuKht4Olfn0mfrMNjBn58ileEEP71xeI80uPH0qpklTruZwAIz GgjA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=282hcH89JVtequN/Tx+bi17jTVwS4jbP3rmgY25XcYY=; fh=vamCZaQ7EeQQjV+Jpg1PpgbwecLJumQNdtvzT0FcvGs=; b=AtHhzY7tw4BZ7qHFyTxW8bUXfc0aAiZduM0qoCEYucwDehf5pwVD18R2qDic3haCxZ w0Jf5lgdCO8+ZAuCTAnsst1Y9zTPREANqc+hSNxBEkRCQE2Oq8C5l8LFqhH+/i57Of/M YPG7svoBFnerlRjcyUJWt1GhtlSVBFT/yVJ95+0lHmlN6oTkDz+iI46Q4YDnVJaEIOCs RjEog65rNX7EkqnPGDl4IHBkFoXQnKJic0snbxcjQJQsQxNLpr6gj08ktBYxT4jgNncB HtPJhBCIuwHfF2/PwSsJtrT7C0so4gZjZkGbK47qsdsCJnkZ9TsSGsbm/pe8SN/vAdWW wTNg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@bootlin.com header.s=gm1 header.b=Y5lQZvkf; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:1 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=bootlin.com Received: from morse.vger.email (morse.vger.email. [2620:137:e000::3:1]) by mx.google.com with ESMTPS id f14-20020a170902ce8e00b001cfb5736747si7836233plg.460.2023.11.28.06.09.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 28 Nov 2023 06:09:15 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:1 as permitted sender) client-ip=2620:137:e000::3:1; Authentication-Results: mx.google.com; dkim=pass header.i=@bootlin.com header.s=gm1 header.b=Y5lQZvkf; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:1 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=bootlin.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by morse.vger.email (Postfix) with ESMTP id 3E68680B19FF; Tue, 28 Nov 2023 06:09:09 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at morse.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1346187AbjK1OIt (ORCPT + 99 others); Tue, 28 Nov 2023 09:08:49 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49546 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1345591AbjK1OIe (ORCPT ); Tue, 28 Nov 2023 09:08:34 -0500 Received: from relay3-d.mail.gandi.net (relay3-d.mail.gandi.net [IPv6:2001:4b98:dc4:8::223]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4902910F0 for ; Tue, 28 Nov 2023 06:08:32 -0800 (PST) Received: by mail.gandi.net (Postfix) with ESMTPA id 2AA9460011; Tue, 28 Nov 2023 14:08:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=gm1; t=1701180510; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=282hcH89JVtequN/Tx+bi17jTVwS4jbP3rmgY25XcYY=; b=Y5lQZvkffElWDiwaQeqCVprLA/uEKsTSaTYH/j9DbzELUeqUYwUzp0OGaTkaRjf1ZADs42 xlLETRaG+SSZgGvLaC9S5BGJ8X0B35c7yB4hjl/hLt17hZc3qnhzDDlMtM66laZQCVdlop Yitr4SC57O6LXd3S+QvPJs/bHVoyBMpRkSFNfGoetjE4x7aFZHqCgoWGiFGrk6xwwIFn3S Of1wVE5FDLnbDTMpqkkmGeLfWOuvvthwFbIlqFGXCe9DuUkJVhCr1MePR+03gwR/Hj33dp msvHvntjNC8uylYdS/znlD+ZGvIqkdpN8OvCqj605gvva1rNZrA+6Y44VdD3MQ== From: Herve Codina To: Herve Codina , Qiang Zhao , Li Yang , Jakub Kicinski , Shengjiu Wang , Xiubo Li , Fabio Estevam , Nicolin Chen , Liam Girdwood , Mark Brown , Jaroslav Kysela , Takashi Iwai , Christophe Leroy Cc: Arnd Bergmann , linuxppc-dev@lists.ozlabs.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, alsa-devel@alsa-project.org, Thomas Petazzoni Subject: [PATCH 08/17] soc: fsl: cpm1: qmc: Rename qmc_setup_tsa* to qmc_init_tsa* Date: Tue, 28 Nov 2023 15:08:07 +0100 Message-ID: <20231128140818.261541-9-herve.codina@bootlin.com> X-Mailer: git-send-email 2.42.0 In-Reply-To: <20231128140818.261541-1-herve.codina@bootlin.com> References: <20231128140818.261541-1-herve.codina@bootlin.com> MIME-Version: 1.0 X-GND-Sasl: herve.codina@bootlin.com X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on morse.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (morse.vger.email [0.0.0.0]); Tue, 28 Nov 2023 06:09:09 -0800 (PST) X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1783817102107427204 X-GMAIL-MSGID: 1783817102107427204 qmc_setup_tsa* are called once at initialisation. They initialize the QMC TSA table. In order to introduce setup function later on for dynamic timeslots management, rename the function to avoid later confusion. Signed-off-by: Herve Codina Reviewed-by: Christophe Leroy --- drivers/soc/fsl/qe/qmc.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/drivers/soc/fsl/qe/qmc.c b/drivers/soc/fsl/qe/qmc.c index 0413e25d4c67..e3f2afb8fa4d 100644 --- a/drivers/soc/fsl/qe/qmc.c +++ b/drivers/soc/fsl/qe/qmc.c @@ -919,7 +919,7 @@ static int qmc_of_parse_chans(struct qmc *qmc, struct device_node *np) return qmc_check_chans(qmc); } -static int qmc_setup_tsa_64rxtx(struct qmc *qmc, const struct tsa_serial_info *info) +static int qmc_init_tsa_64rxtx(struct qmc *qmc, const struct tsa_serial_info *info) { struct qmc_chan *chan; unsigned int i; @@ -961,7 +961,7 @@ static int qmc_setup_tsa_64rxtx(struct qmc *qmc, const struct tsa_serial_info *i return 0; } -static int qmc_setup_tsa_32rx_32tx(struct qmc *qmc, const struct tsa_serial_info *info) +static int qmc_init_tsa_32rx_32tx(struct qmc *qmc, const struct tsa_serial_info *info) { struct qmc_chan *chan; unsigned int i; @@ -1019,7 +1019,7 @@ static int qmc_setup_tsa_32rx_32tx(struct qmc *qmc, const struct tsa_serial_info return 0; } -static int qmc_setup_tsa(struct qmc *qmc) +static int qmc_init_tsa(struct qmc *qmc) { struct tsa_serial_info info; int ret; @@ -1030,12 +1030,12 @@ static int qmc_setup_tsa(struct qmc *qmc) return ret; /* - * Setup one common 64 entries table or two 32 entries (one for Tx and - * one for Tx) according to assigned TS numbers. + * Initialize one common 64 entries table or two 32 entries (one for Tx + * and one for Tx) according to assigned TS numbers. */ return ((info.nb_tx_ts > 32) || (info.nb_rx_ts > 32)) ? - qmc_setup_tsa_64rxtx(qmc, &info) : - qmc_setup_tsa_32rx_32tx(qmc, &info); + qmc_init_tsa_64rxtx(qmc, &info) : + qmc_init_tsa_32rx_32tx(qmc, &info); } static int qmc_setup_chan_trnsync(struct qmc *qmc, struct qmc_chan *chan) @@ -1391,7 +1391,7 @@ static int qmc_probe(struct platform_device *pdev) qmc_write32(qmc->scc_pram + QMC_GBL_C_MASK32, 0xDEBB20E3); qmc_write16(qmc->scc_pram + QMC_GBL_C_MASK16, 0xF0B8); - ret = qmc_setup_tsa(qmc); + ret = qmc_init_tsa(qmc); if (ret) goto err_tsa_serial_disconnect;