From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id A8B61C27C53 for ; Fri, 7 Jun 2024 04:59:56 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:From:References:CC:To: Subject:MIME-Version:Date:Message-ID:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=EMNFI/4DJe6eNhF4HJlXyji1WjCDXvTpnDVdY3v2CRs=; b=zisQtvOaPM2nfa AVjvULiT+g3RtT+C2B+W+HkSKymXAwP9jnX101PJLu6kiNybbssAEEl4v9XqbzxZa/0tZza7JRjoE wcGEJMT7ke2IpvTokKcbn31WI0dcVif51BPjzvk8eElDbQ7uq+2oh4vC9uiw8Zl47hd2KUFhDcGFe j43cpEMlfgL13Qi36/o1OFlf/ZIdd73KMqFJQfd/7p7imgltnIKMs/HhelXzxJPBlGamgPprL97Re XcZJIs+piPwStrrKwdIWaT9h5rmZpwLKMWfTsbphyJv2asep1a7qsDqbKY+pUTTx3JzZFIW7Hd4zc 5Ju2m2USpoAHhJxA1vMg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1sFRhV-0000000CRAT-2Iby; Fri, 07 Jun 2024 04:59:41 +0000 Received: from fllv0015.ext.ti.com ([198.47.19.141]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1sFRhS-0000000CR9W-3spt for linux-arm-kernel@lists.infradead.org; Fri, 07 Jun 2024 04:59:40 +0000 Received: from lelv0265.itg.ti.com ([10.180.67.224]) by fllv0015.ext.ti.com (8.15.2/8.15.2) with ESMTP id 4574xK6P032178; Thu, 6 Jun 2024 23:59:20 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1717736360; bh=q9zM+C2ALOTZzdhqIQKT3rHPlePwj64EjR20S0wa0Co=; h=Date:Subject:To:CC:References:From:In-Reply-To; b=qzFkKSblR0UyD30+76tK6YHGKVTzVQqAaX/J7YhfK+5mP/gb/9aQa3NFNce0562AZ q/hGR67pKwk19VSKd9LlowEgIoK815ficPeFeh70uugFPE2cxarJeiMYd0Qpe2g+4m AgMIdqYR3mJ3JAl9u4EYcFnz5zaK12olAS9QUy20= Received: from DLEE110.ent.ti.com (dlee110.ent.ti.com [157.170.170.21]) by lelv0265.itg.ti.com (8.15.2/8.15.2) with ESMTPS id 4574xKqp003605 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL); Thu, 6 Jun 2024 23:59:20 -0500 Received: from DLEE107.ent.ti.com (157.170.170.37) by DLEE110.ent.ti.com (157.170.170.21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.23; Thu, 6 Jun 2024 23:59:20 -0500 Received: from lelvsmtp5.itg.ti.com (10.180.75.250) by DLEE107.ent.ti.com (157.170.170.37) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.23 via Frontend Transport; Thu, 6 Jun 2024 23:59:19 -0500 Received: from [10.249.135.225] ([10.249.135.225]) by lelvsmtp5.itg.ti.com (8.15.2/8.15.2) with ESMTP id 4574xDlX007855; Thu, 6 Jun 2024 23:59:13 -0500 Message-ID: Date: Fri, 7 Jun 2024 10:29:12 +0530 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH net-next v9 2/2] net: ti: icssg_prueth: add TAPRIO offload support To: Vladimir Oltean , MD Danish Anwar CC: Jan Kiszka , Dan Carpenter , Andrew Lunn , Simon Horman , Diogo Ivo , Wolfram Sang , Randy Dunlap , Niklas Schnelle , Vignesh Raghavendra , Richard Cochran , Roger Quadros , Paolo Abeni , Jakub Kicinski , Eric Dumazet , "David S. Miller" , , , , , Jacob Keller , Roger Quadros References: <20240531044512.981587-3-danishanwar@ti.com> <20240531135157.aaxgslyur5br6zkb@skbuf> <20240531044512.981587-1-danishanwar@ti.com> <20240531044512.981587-1-danishanwar@ti.com> <20240531044512.981587-3-danishanwar@ti.com> <20240531044512.981587-3-danishanwar@ti.com> <20240531135157.aaxgslyur5br6zkb@skbuf> <9bcc04a9-645a-4571-a679-ffe67300877a@ti.com> <9bcc04a9-645a-4571-a679-ffe67300877a@ti.com> <20240603135100.t57lr4u3j6h6zszd@skbuf> <20240603140559.krc6ap5qbltutsvj@skbuf> Content-Language: en-US From: "Anwar, Md Danish" In-Reply-To: <20240603140559.krc6ap5qbltutsvj@skbuf> X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240606_215939_109456_D0637A98 X-CRM114-Status: GOOD ( 17.87 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On 6/3/2024 7:35 PM, Vladimir Oltean wrote: > On Mon, Jun 03, 2024 at 04:51:00PM +0300, Vladimir Oltean wrote: >>>>> +static void tas_reset(struct prueth_emac *emac) >>>>> +{ >>>>> + struct tas_config *tas = &emac->qos.tas.config; >>>>> + int i; >>>>> + >>>>> + for (i = 0; i < TAS_MAX_NUM_QUEUES; i++) >>>>> + tas->max_sdu_table.max_sdu[i] = 2048; >>>> >>>> Macro + short comment for the magic number, please. >>>> >>> >>> Sure I will add it. Each elements in this array is a 2 byte value >>> showing the maximum length of frame to be allowed through each gate. >> >> Is the queueMaxSDU[] array active even with the TAS being in the reset >> state? Does this configuration have any impact upon the device MTU? >> I don't know why 2048 was chosen. > > Another comment here is: in the tc-taprio UAPI, a max-sdu value of 0 > is special and means "no maxSDU limit for this TX queue". You are > programming the values from taprio straight away to hardware, so, > assuming there's no bug there, it means that the hardware also > understands 0 to mean "no maxSDU limit". > I discussed this with the firmware team. They are not treating 0 as something special (""no maxSDU limit for this TX queue"). They have limit on every queue. Driver needs to handle the max-sdu size carefully. > If so, then during tas_reset(), after which the TAS should be disabled, > why aren't you also using 0 as a default value, but 2048? As using 0 doesn't mean anything special in firmware. The default value during reset is kept as the max supported value. There's also one thing missing here, the max-sdu table in firmware is updated (by calling tas_update_maxsdu_table()) only once by driver during tas_reset(). The firmware table should also be updated once before triggering the list change so that the firmware would know what are the max-sdu value that user has requested. If a user request max-sdu as 0 0 0 80 for 4 queues. The driver will update these values to firmware as PRUETH_MAX_MTU, PRUETH_MAX_MTU, PRUETH_MAX_MTU, 80. -- Thanks and Regards, Md Danish Anwar _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel