Received: by 2002:a05:6359:c8b:b0:c7:702f:21d4 with SMTP id go11csp1727508rwb; Fri, 7 Oct 2022 17:58:57 -0700 (PDT) X-Google-Smtp-Source: AMsMyM55FQQq3jAST4/ded8Ym/tO/zPZfrSdzl+uUJqFvWw/vfi6ZRvosjvGzc1NG05UG2qWJg82 X-Received: by 2002:a17:903:4ca:b0:179:d21f:f04b with SMTP id jm10-20020a17090304ca00b00179d21ff04bmr7448542plb.7.1665190736774; Fri, 07 Oct 2022 17:58:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1665190736; cv=none; d=google.com; s=arc-20160816; b=PHDCl2HMddTb0dnor/LROBzx3D467azMqmUhpfZtfqALIO33OGFmjURX/DYzJdpB5u GlgzCIxVDpC1En9xyygYuOKVM3zg3FBNZ+JUTqwuogiBFJEIL1d/1mKXzvN3cJR++GqB Al92lWbQy8+MUr4Z0OAJysJnlSdVEJOHAF9Oq77w5bmoLM74tbYGYAhI9vemK1DLyFIa TxWh/HoV/9sOjYIxd8aFMyI7AFIhkypD8x0FnrfL8r7NsIY2PShWfwy291kFmc7lBj3n 1x3vb/Xm+U8QiEky7PdgSnu/67sKlkEE3hM0DmXGTIOgvuckgDQ66k/WbmzhblAHcY1k ozeA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:content-language :in-reply-to:mime-version:user-agent:date:message-id:from:references :cc:to:subject; bh=GIYSQDVvbKbIUa2Tsa2WGHsBzPMpngE4dlO8yyzvfeg=; b=hjFrdfooSsNT/joxKNYRGkPZ6RDuWU/FvPMquX6HG47vr6aEQZ0CGzT0eybWXGY4ya CC+nWESwnMTCIYfjmmewRAnrjje3a+x4u0oweBxfft2IDn9Qos85li5Zq1KyFqM9SO9c mKUSIjYbHfLq8kJ7kaYI6FqE0nCh8d2AyPHpRteZaqIS/i8phcrWKJCwniruP5n7WeDS lPrflKpyv7BTpUE/A1Fq+MS+awKq26a8Y0tgA9LcG/ZLYI1ClMq7n7pH4LX/gK97H9HV FtakSefGCBM9ezxOzpPGGPnm7LtXph+5hb9jm1F0DjqRcrxHCC48R6C6nIcSDUrqsl3u 1WWg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id c5-20020a170902f30500b00176db576db9si3092710ple.275.2022.10.07.17.58.45; Fri, 07 Oct 2022 17:58:56 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229565AbiJHA5B (ORCPT + 99 others); Fri, 7 Oct 2022 20:57:01 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33634 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229379AbiJHA4w (ORCPT ); Fri, 7 Oct 2022 20:56:52 -0400 Received: from mailgw.kylinos.cn (unknown [124.126.103.232]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B77527AC3D; Fri, 7 Oct 2022 17:56:50 -0700 (PDT) X-UUID: 2ebf0370a34f46b4abc3e11987af5c9e-20220930 X-Spam-Fingerprint: 0 X-GW-Reason: 11105 X-Policy-Incident: 5pS25Lu25Lq66LaF6L+HMTDkurrpnIDopoHlrqHmoLg= X-Content-Feature: ica/max.line-size 73 audit/email.address 1 dict/adv 1 dict/prolog 2 dict/software 1 X-CPASD-INFO: de9937b40a214caa8fcf90116348478d@rbVzWWBqkGRcgXR9g6asm1iXk5ZpXFG AeG1UaGJnZISVhH5xTV5uYFV9fWtVYV9dYVR6eGxQYmBgZFJ4i3-XblBgXoZgUZB3s6dzWWNlkg== X-CLOUD-ID: de9937b40a214caa8fcf90116348478d X-CPASD-SUMMARY: SIP:-1,APTIP:-2.0,KEY:0.0,FROMBLOCK:1,OB:0.0,URL:-5,TVAL:155. 0,ESV:1.0,ECOM:-5.0,ML:0.0,FD:0.0,CUTS:108.0,IP:-3.0,MAL:-5.0,PHF:-5.0,PHC:-5 .0,SPF:4.0,EDMS:-5,IPLABEL:-5.0,FROMTO:0,AD:0,FFOB:0.0,CFOB:0.0,SPC:0,SIG:-5, AUF:6,DUF:6086,ACD:96,DCD:96,SL:0,EISP:0,AG:0,CFC:0.439,CFSR:0.08,UAT:0,RAF:2 ,IMG:-5.0,DFA:0,DTA:0,IBL:-5,ADI:-5,SBL:0,REDM:0,REIP:0,ESB:0,ATTNUM:0,EAF:0, CID:-5.0,VERSION:2.3.17 X-CPASD-ID: 2ebf0370a34f46b4abc3e11987af5c9e-20220930 X-CPASD-BLOCK: 1000 X-CPASD-STAGE: 1 X-UUID: 2ebf0370a34f46b4abc3e11987af5c9e-20220930 X-User: jianghaoran@kylinos.cn Received: from [192.168.11.89] [(223.70.160.245)] by mailgw (envelope-from ) (Generic MTA) with ESMTP id 1221825997; Fri, 30 Sep 2022 19:24:42 +0800 Subject: Re: [PATCH] taprio: Set the value of picos_per_byte before fill sched_entry To: Jakub Kicinski Cc: vinicius.gomes@intel.com, jhs@mojatatu.com, xiyou.wangcong@gmail.com, jiri@resnulli.us, davem@davemloft.net, edumazet@google.com, pabeni@redhat.com, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, vladimir.oltean@nxp.com References: <20220928065830.1544954-1-jianghaoran@kylinos.cn> <20220929191815.51362581@kernel.org> From: jianghaoran Message-ID: Date: Fri, 30 Sep 2022 19:18:52 +0800 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.8.1 MIME-Version: 1.0 In-Reply-To: <20220929191815.51362581@kernel.org> Content-Type: text/plain; charset=gbk; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-3.2 required=5.0 tests=BAYES_00,KHOP_HELO_FCRDNS, NICE_REPLY_A,PDS_RDNS_DYNAMIC_FP,RDNS_DYNAMIC,SPF_HELO_NONE, T_SPF_PERMERROR autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org ?? 2022/9/30 ????10:18, Jakub Kicinski ะด??: > On Wed, 28 Sep 2022 14:58:30 +0800 jianghaoran wrote: >> If the value of picos_per_byte is set after fill sched_entry, >> as a result, the min_duration calculated by length_to_duration is 0, >> and the validity of the input interval cannot be judged, >> too small intervals couldn't allow any packet to be transmitted. > > Meaning an invalid configuration is accepted but no packets > can ever be transmitted? Could you make the user-visible > issue clearer? Yes, It's possible that the user specifies an too small interval that couldn't allow any packet to be transmitted.According to the following example, the interval is set to 9, and the network port enp5s0f0 cannot send any data > >> It will appear like commit b5b73b26b3ca ("taprio: >> Fix allowing too small intervals") described problem. >> Here is a further modification of this problem. >> >> example: > > Here as well it seems worthwhile to mention what this is an example of. > e.g. "example configuration which will not be able to transmit packets" > >> tc qdisc replace dev enp5s0f0 parent root handle 100 taprio \ >> num_tc 3 \ >> map 2 2 1 0 2 2 2 2 2 2 2 2 2 2 2 2 \ >> queues 1@0 1@1 2@2 \ >> base-time 1528743495910289987 \ >> sched-entry S 01 9 \ >> sched-entry S 02 9 \ >> sched-entry S 04 9 \ >> clockid CLOCK_TAI > > Please add a Fixes tag pointing to the first commit where the issue was > present, and CC Vladimir Oltean on the next > version. > Thank you for your suggestion. I will modify it as suggested