Message ID | 20230922075913.422435-13-herve.codina@bootlin.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:612c:172:b0:3f2:4152:657d with SMTP id h50csp5424842vqi; Fri, 22 Sep 2023 02:12:08 -0700 (PDT) X-Google-Smtp-Source: AGHT+IEudNntclJ6Pe4cvq/EMOOxR1lZ9uUch9HcS+dNxbmdUdIL2YHFY8/80WgLHvr9W9gTq8DV X-Received: by 2002:a17:90b:19cb:b0:276:cd68:6081 with SMTP id nm11-20020a17090b19cb00b00276cd686081mr5917004pjb.40.1695373928248; Fri, 22 Sep 2023 02:12:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1695373928; cv=none; d=google.com; s=arc-20160816; b=sKjw73TwnP7PYriXhF6ggwTUhiOrqAlMMaGj+QT7zl3lDdatef2C9xvrc9fMzr0hao KW3OSQKz6Q8JeSisIPwtl7PpEH78NYxwwypQmuZr9+SUptOvRVGocemNoNbfjWFCNXK3 uN49zCAoXHPt9t3w1XIqSwgJBsxOuWy7EIzXvZL096f32SStdGEnuNvsNM8cbGyl44O9 2n5yJ2I3Yoi2jMj7aLTzPuDHRjX/KeSam4czehuq0pDbLrNrfaMHMddHXiR2hUELEN1C j5BAuxEyjIiF/7uOs0lh1txAj8GaEGaTZWACi/LoxOm0Y2+irAZ48m0IDOMHq6xSQzjB jdjA== 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=H6LM5oBsAhqZ2AuRWwGids6eXtTepJ+ChJ2w8L/EWt8=; fh=5rCQDomVZxLXb7yR2oN4iSS3zxUnzGJP2HoQaRzhQu0=; b=z0wBCp8E9k1Gi1HWfDCZltdoYRewf1+gIHFIdBLrIHi8zwk5fp7gj4eCt2Xzs+gVk1 NGIrhUx9vXogIGkkwCFfHwf1hfR9gFRbm7dl+KjN8gg/gBxfEvYURW8tCCvUPO1xx7ew KS/flYPhjlX/yljNknrSjconbJqz1/7bS7UB1OUCdE1BQnbrqlb6LwmIBCBaGvjJHRKf WQCjVtwMcKNV7vbRhrX4/OhKNKzUgcxaZEiUKfA5N6QqGJlrA3rYoQOjFBE8v9tnmuuu Vra1cchOfOvFcEChPytoY0ATYg0m1I74ABUSbfq9C07tasaAJ1GJWNHsr0FuWB4rwAaf w35A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@bootlin.com header.s=gm1 header.b=TK8Y6H6J; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.32 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 agentk.vger.email (agentk.vger.email. [23.128.96.32]) by mx.google.com with ESMTPS id kk13-20020a17090b4a0d00b002532c9b252asi3897631pjb.73.2023.09.22.02.12.07 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 22 Sep 2023 02:12:08 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.32 as permitted sender) client-ip=23.128.96.32; Authentication-Results: mx.google.com; dkim=pass header.i=@bootlin.com header.s=gm1 header.b=TK8Y6H6J; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.32 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 agentk.vger.email (Postfix) with ESMTP id 4809082296A3; Fri, 22 Sep 2023 01:01:42 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at agentk.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232311AbjIVIBU (ORCPT <rfc822;chrisfriedt@gmail.com> + 30 others); Fri, 22 Sep 2023 04:01:20 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33016 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232286AbjIVIAz (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Fri, 22 Sep 2023 04:00:55 -0400 Received: from relay8-d.mail.gandi.net (relay8-d.mail.gandi.net [IPv6:2001:4b98:dc4:8::228]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D044B1726; Fri, 22 Sep 2023 01:00:16 -0700 (PDT) Received: by mail.gandi.net (Postfix) with ESMTPA id CC9751BF207; Fri, 22 Sep 2023 08:00:02 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=gm1; t=1695369608; 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=H6LM5oBsAhqZ2AuRWwGids6eXtTepJ+ChJ2w8L/EWt8=; b=TK8Y6H6J1HJKkavNACW/gre+mQe7HlcEmztlvpEsFKszKfwtrfDEyxzMHJaSJv1ag2rCgf RkBmjaeCG9AA8lsNoWu/X2PN0cFgzc9etdgEK2oOWzu5GylvI8joziqiDKqKDHiC3Csj5z tZoIwM3dpLfpJY+FVqDLzutc0W6bPol0Jg21F+6XVNRSScExzTCxFoH+ZAQVHd3ArS6G2p z1UfhM5o4jJRa4dt0m6qxGt8WDuP9Pf11GcjPZSotIVwfV2y0GnTjZIDPv6ZelI149knsc fJGzW5XISv4uzPx79NtwXOFWpmaqy2hNyxC1Wx7k71lphQVX6XVg0czdt93ipQ== From: Herve Codina <herve.codina@bootlin.com> To: Herve Codina <herve.codina@bootlin.com>, "David S. Miller" <davem@davemloft.net>, Eric Dumazet <edumazet@google.com>, Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>, Andrew Lunn <andrew@lunn.ch>, Rob Herring <robh+dt@kernel.org>, Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>, Conor Dooley <conor+dt@kernel.org>, Lee Jones <lee@kernel.org>, Linus Walleij <linus.walleij@linaro.org>, Qiang Zhao <qiang.zhao@nxp.com>, Li Yang <leoyang.li@nxp.com>, Liam Girdwood <lgirdwood@gmail.com>, Mark Brown <broonie@kernel.org>, Jaroslav Kysela <perex@perex.cz>, Takashi Iwai <tiwai@suse.com>, Shengjiu Wang <shengjiu.wang@gmail.com>, Xiubo Li <Xiubo.Lee@gmail.com>, Fabio Estevam <festevam@gmail.com>, Nicolin Chen <nicoleotsuka@gmail.com>, Christophe Leroy <christophe.leroy@csgroup.eu>, Randy Dunlap <rdunlap@infradead.org> Cc: netdev@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, linux-arm-kernel@lists.infradead.org, alsa-devel@alsa-project.org, Simon Horman <horms@kernel.org>, Christophe JAILLET <christophe.jaillet@wanadoo.fr>, Thomas Petazzoni <thomas.petazzoni@bootlin.com> Subject: [PATCH v6 12/30] soc: fsl: cpm1: qmc: Introduce available timeslots masks Date: Fri, 22 Sep 2023 09:58:47 +0200 Message-ID: <20230922075913.422435-13-herve.codina@bootlin.com> X-Mailer: git-send-email 2.41.0 In-Reply-To: <20230922075913.422435-1-herve.codina@bootlin.com> References: <20230922075913.422435-1-herve.codina@bootlin.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-GND-Sasl: herve.codina@bootlin.com X-Spam-Status: No, score=-0.8 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on agentk.vger.email Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (agentk.vger.email [0.0.0.0]); Fri, 22 Sep 2023 01:01:42 -0700 (PDT) X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1777728412294905324 X-GMAIL-MSGID: 1777728412294905324 |
Series |
Add support for QMC HDLC, framer infrastructure and PEF2256 framer
|
|
Commit Message
Herve Codina
Sept. 22, 2023, 7:58 a.m. UTC
Available timeslots masks define timeslots available for the related channel. These timeslots are defined by the QMC binding. Timeslots used are initialized to available timeslots but can be a subset of available timeslots. This prepares the dynamic timeslots management (ie. changing timeslots at runtime). Signed-off-by: Herve Codina <herve.codina@bootlin.com> Reviewed-by: Christophe Leroy <christophe.leroy@csgroup.eu> --- drivers/soc/fsl/qe/qmc.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/drivers/soc/fsl/qe/qmc.c b/drivers/soc/fsl/qe/qmc.c index 5da15a25600e..653d458b84b6 100644 --- a/drivers/soc/fsl/qe/qmc.c +++ b/drivers/soc/fsl/qe/qmc.c @@ -177,7 +177,9 @@ struct qmc_chan { struct qmc *qmc; void __iomem *s_param; enum qmc_mode mode; + u64 tx_ts_mask_avail; u64 tx_ts_mask; + u64 rx_ts_mask_avail; u64 rx_ts_mask; bool is_reverse_data; @@ -875,7 +877,8 @@ static int qmc_of_parse_chans(struct qmc *qmc, struct device_node *np) of_node_put(chan_np); return ret; } - chan->tx_ts_mask = ts_mask; + chan->tx_ts_mask_avail = ts_mask; + chan->tx_ts_mask = chan->tx_ts_mask_avail; ret = of_property_read_u64(chan_np, "fsl,rx-ts-mask", &ts_mask); if (ret) { @@ -884,7 +887,8 @@ static int qmc_of_parse_chans(struct qmc *qmc, struct device_node *np) of_node_put(chan_np); return ret; } - chan->rx_ts_mask = ts_mask; + chan->rx_ts_mask_avail = ts_mask; + chan->rx_ts_mask = chan->rx_ts_mask_avail; mode = "transparent"; ret = of_property_read_string(chan_np, "fsl,operational-mode", &mode);